You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As far as I understand, the LIBRARY_PATH environment variable is what GCC uses and is supposed to work on Windows, but it doesn't. Apart from that there is really no standard environment variable for libraries for linkers, am I wrong?
My workaround was parsing the environment variable from my build.zig but absolute paths are discouraged.
Expected Behavior
The linker should use the absolute paths present in the LIBRARY_PATH environment variable.
The text was updated successfully, but these errors were encountered:
Guigui220D
changed the title
LIBRARY_PATH is not considered on Windows by the build system
LIBRARY_PATH is not considered by the build system on Windows
Jun 14, 2024
I don't know whether Zig plans to support automatically reading library search paths from a LIBRARY_PATH environment variable. I think this would make the build process more difficult to isolate and keep reproducible, because as it becomes easier for some unexpected interaction to happen.
Note that you can already specify library search paths using the -L/--library-directory CLI options (see zig <command> --help for whatever command you're using in your build process).
With this it should already be possible to manually specify the value of any environment variable to the CLI.
Zig Version
0.14.0-dev.27+0cef727e5
Steps to Reproduce and Observed Behavior
As far as I understand, the LIBRARY_PATH environment variable is what GCC uses and is supposed to work on Windows, but it doesn't. Apart from that there is really no standard environment variable for libraries for linkers, am I wrong?
My workaround was parsing the environment variable from my build.zig but absolute paths are discouraged.
Expected Behavior
The linker should use the absolute paths present in the LIBRARY_PATH environment variable.
The text was updated successfully, but these errors were encountered: