Quantcast
Browsing all 520 articles
Browse latest View live

[ANN] Dune 3.3.0

On behalf of the dune team, I’m pleased to announce the release of version 3.3.0. This is the first version that supports the upcoming OCaml 5.0. It also improves safety by sandboxing more rules and...

View Article


Is there a way to avoid reinstalling package if it's upto date?

Hi, as per my observations, Dune doesn’t recompile a project if the sources have not changed, however, when it comes to installing the artefacts, it follows the re-install approach even if there are...

View Article


Image may be NSFW.
Clik here to view.

Working on a local project with opam

Hello Disclaimer: I am a total beginner with opam as I am normally using esy as my package manager. But I wanted to try out opam just as a learning experience. I did setup a local development...

View Article

How to Separate Dev environment from Build

I’m currently working on a project where I want to use omd@2.0.0~alpha2 in the project and ocaml-lsp-server to develop it, however OPAM only allows one to be installed at a time due to omd<=1.3...

View Article

Dune how to define custom build task

dune has very powerful extensions, but the documentation doesn’t tell you directly. Today I’ll share a specific example of how we can make dune do many things with a dune configuration. For example...

View Article


Use dune to link with c library

I’m trying to compile a project that uses a native . so library. I’ve written an ocaml wrapper for it and added foreign_stub to dune file, but it yields undefined reference errors during linking. How...

View Article

Missing dependency file after upgrading lang dune above 2.9

Hi, I have a custom test in my code base that is defined this way: (tests (names test_json_parsing) (libraries yojson stork test_utils) (deps (glob_files *.json)) (flags (:standard -linkall -g -open...

View Article

Image may be NSFW.
Clik here to view.

Accidentally broke dune by running "dune exec ./" in home instead of project...

Hi ! I’m still relatively new to dune so I hope I’m not missing something very obvious here. Also my first post here, sorry if it kinda sucks I’m programming in a linux terminal with neovim and I...

View Article


Opam-cross-windows now supports OCaml 4.14.0!

Hi there! Bit of a late announcement but the opam-cross-windows project now supports the OCaml compiler version 4.14.0: GitHub - ocaml-cross/opam-cross-windows: An OCaml cross-toolchain for Windows...

View Article


Source setting in dune

I used dune init to start a new project. That gave me a top-level dune-project file, containing among other things (source (github username/reponame)) Since I don’t wish to host the project on Github,...

View Article

[ANN] dune 3.4.0

On behalf of the dune team, I’m pleased to announce the release of version 3.4.0. Bug fixes, a couple new features, better hints and error messages - I won’t restate what’s in the changelog below....

View Article

Setting up dune --root inside VS Code

I’m currently on a somewhat unusual setting: I am updating some documentation inside a dune project, and this documentation has some example code which constitutes an independent dune project itself...

View Article

Copying a non-code file into build context

In my jsoo-based project, there is a manifest.json file and an icons dir besides dune file. project_dir |- dune |- manifest.json |- icons |- main.ml How do I mark this json file and the icons dir as a...

View Article


Need help with file structure

I have this project |-- lib | |-- foo | | |-- bar.ml | | |-- bar.mli | | |-- baz.ml | | |-- baz.mli | | |-- dune | |-- lib.ml | |-- dune |-- test | |-- foo_test | | |-- bar_test.ml | | |-- baz_test.ml...

View Article

Slower executables with dune

I’m new to dune and experiencing some 20% slowdown with the executables built with dune compared the ones produced with my good old Makefile where I specify options -no_assert -unsafe -inline 100. I...

View Article


Deploy documentation with dune

Dune allows to generate OCamlDoc documentation using dune build @doc. opam has a with-doc target which runs dune build @doc and puts documentation in the .opam folder. Only, it doesn’t put the...

View Article

Is dune just for building targets, or can I also make it organize build output?

Let’s say my source code has the following structure: src |-- bin | |-- main.ml |-- assets |-- icons | |-- pin.svg |-- index.html |-- manifest.json I want dune to spit out an output dir in the default...

View Article


Image may be NSFW.
Clik here to view.

Dependency cycle problem

Hey I am currently working on a prototype for a parser generator in OCaml. If I have a grammar description in a file parser.abc I can generate an .ml file with the actual parser code like so: abc...

View Article

Dune build-info : how to use?

I am trying to display build info via using dune-build-info library. However, it always seems to be None. Looking at the documentation for Build_info.V1.Version.version, I can see it mentioned the...

View Article

Image may be NSFW.
Clik here to view.

Dependency problem with dune

Hi! I have a problem with dune which probably has a very simple solution, but I haven’t been able to figure it out. My current directory setup for defining a simple library looks like this: lib/ |---...

View Article
Browsing all 520 articles
Browse latest View live