-
Notifications
You must be signed in to change notification settings - Fork 371
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Defining two packages from the same package description #2497
Comments
Thanks for sharing an interesting use-case. I don't know if you had a more generic way of doing this in mind, but maybe it would be possible to have the |
I guess that would work yes. Would that allow to do this: have the tests in I though of another use case for this feature, which I think could benefit a lot of packages in opam. Right now, it is often the case that optional dependencies are used to build independent part of a package. A typical example is In the case of At the moment we have this frustrating situation:
If we could define several packages from the same opam entry, maybe the opam file for
This would require some work on the build system as well so that you can build Technically what I'm proposing is just a convenient way to merge two directories in |
it's the point, For the On allowing more flexibility with package definitions, I will see the different options. Duplicating the whole package into |
I still don't have a good story on this, but there might be a way using the new So having There may be two issues with this idea, though:
|
Some motivation for this: I'd like to setup running tests in the various Jane Street packages for various reason. However it is pretty much always the case that tests have more dependencies than the library code and adding these dependencies would create circular dependencies. For instance bin_prot tests are using core. Breaking these circular dependencies would be a huge amount of work for very little benefit. Moreover it is natural to want more things for tests.
Right now, we could solve this problem by creating
_test
packages for all our packages:core_test
,async_test
, ... They would use the exact same archive with a slightly different opam file. However maintaining this two parallel set of packages with exactly the same versions and sharing most of the opam file and other patches would be a pain, plus it would pollute the opam repo.The text was updated successfully, but these errors were encountered: