-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Package manager: Build needs to include dynamic libraries as dependencies as Step #16172
Comments
Suggestion: Change title to ".. include dynamic libraries as dependencies as Step".
|
Thank you. Done. Changed the Title. |
I was told by @InKryption that #14731 might fix this. |
So my problem statement is simple. I’d like to be able to incorporate the dynamic library in my build but separate the dynamic library and the wrapper in their respective packages separate from the main project. If I separate them into 3 projects, then libduckdb.so doesn’t get exposed to the next layer using either artifact nor module. |
Project A, libduckdb needs to expose libduckdb.so In addition, for project A, there should be a way to not require either a source code or a linking step in order to create an artifact. An artifact can also be a set of steps that “copies” over files to destination directory. For project C, the dynamic library libduckdb.so needs to be part of the artifact of project C to be part of the destination directory. |
Run into the same issue when trying to fit libpcre.zig into zon's ecosystem. I would like to help, could you provide some instructions? Thanks. |
Zig Version
0.11.0-dev.3777+64f0059cd
Steps to Reproduce and Observed Behavior
Currently where is no way to install the dependencies (let's say A) of a package B as part of package C if C depends on B.
Say package A is a library written in another language and that exposes a dynamic library A.so.
Let's say B is a Zig wrapper for A so B needs A.so to work. B build ok with build.zig. B even installs A.so as part of the install step.
Now, say C is using the B wrapper but C cannot build because it will need A.so but by using the package manager, it can only use things such as Artifact or Module which are Compile.Step not Install.Step so there is no way for C to compile or install A.so (since C cannot touch anything other than the artifact of B) as part of C output.
right now we can do
C.installLibraryHeaders(dep.artifact("B"))
but notC.installLibrary(dep.install("B"))
if A.so is part of B's install step.Expected Behavior
I think there are two things:
The text was updated successfully, but these errors were encountered: