-
Notifications
You must be signed in to change notification settings - Fork 410
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Have a variable to point to installed library paths #3379
Comments
There is no way at the moment. We considered it in the past, however it is a bit dodgy as it provides an easy way for users to mess up their build. What is your use case? |
I want my project to install the C flags that users should use when compiling C objects using that library. For instance, I want
And users will just have to write:
Note that |
I see. So you basically want to provide a set of flags as a library? I'm wondering if we shouldn't provide this high-level feature directly. After all, the compiler itself provide a way to distribute link flags with a library. And also, I'm generally not excited by giving too many low-level features as it makes it very easy to mess things up :) |
Installing C flags for a library would be very useful. In my use-case I need to use these to compile a C project, so storing them in the cma/cmxa is not very practical, but having an easier way to handle these would be very useful. Not that you usually 2 sets of flags, one for compile-time, one for link-time. |
Alright, let's look into this then. @voodoos I'm assigning you this issue since this seems useful for Tarides |
Related to #1185 but a bit simpler.
In a few places I would like to get the place of where the current library (or one of the already present libraries) is installed. To do this I have come up with this very inelegant solution, which seems to work fine:
And now other rules could just
(:include install-dir)
when they want to refer to the path where<lib>
is installed.Is there any way to make it simpler? E.g. by expanding
%{lib:<lib>}
to the parent directory of%{lib:<lib>:META}
or%{lib:<lib>:dune-package}
?The text was updated successfully, but these errors were encountered: