Opam pin and modify extra-files

I’m working on a package and could use some advice on an opam workflow and publishing problem.

The opam package is not in the source dev repo, but in the opam-repository, and includes some extra-files. I would like to pin my local checkout of the source repo, but for the install to succeed, the contents of one of the extra files needs to be modified.

Am I overlooking some mechanism to e.g. copy the opam and extra files from the opam-repository into the local source checkout in a way that opam pin will use them instead of getting them from the opam-repo? Is there an advised / best-practice workflow for making this sort of change? Also, it would be troublesome if I can’t do something like push the modified package somewhere so that others can pin the modified package. (That is, I’d really like to avoid just clobbering files somewhere in OPAMROOT, or needing to fork the opam-repo.)

FWIW, the package in question is the llvm ocaml bindings, and to install the opam package with my local changes I need to modify files/META.patch.

This sounds like it might just be a bug with opam 2’s handling of extra-files. There have been some related issues fixed in the 2.0.x branch so an issue on the tracker would probably be best to track this one.

1 Like

Thanks, done: opam#3833

1 Like