Re: How to add to PATH from user-config.jam?
Mateusz Loskot via Boost-build <[email protected]> Tue, 17 Dec 2019 23:33:58 +0100
| Newsgroups | gmane.comp.lib.boost.build |
|---|---|
| Message-ID | <CABUeae_fJPWM8sen02XhQ53=8dPNMmfvHR2O+e34AQ=8m_L=xw@mail.gmail.com> |
On Tue, 17 Dec 2019 at 21:02, Edward Diener via Boost-build <[email protected]> wrote: > On 12/17/2019 6:14 AM, Mateusz Loskot via Boost-build wrote: > > On Mon, 16 Dec 2019 at 22:35, Mateusz Loskot <[email protected]> wrote: > >> > >> On Windows, I'm building tests of Boost.GIL using > >> dependencies like libpng, libjpeg, etc. installed with vcpkg. > >> > >> In my user-config.jam I have entries like this: > >> > >> using libjpeg > >> : > >> : <include>C:/vcpkg/installed/x86-windows/include > >> <search>C:/vcpkg/installed/x86-windows/lib > >> : <address-model>32 > >> ; > >> > >> using libjpeg > >> : > >> : <include>C:/vcpkg/installed/x64-windows/include > >> <search>C:/vcpkg/installed/x64-windows/lib > >> : <address-model>64 > >> ; > >> > >> > >> At build time, everything works fine. > >> > >> For run-time, GIL tests need to load DLLs in C:\vcpkg\installed\x86-windows\bin > >> If I add this location to PATH manually, everything works at run-time fine. > >> > >> I'm looking for a way to add that location to PATH from user-config.jam. > >> Is it possible? How? > > > > I approached the problem differently and added this at the top of my > > user-config.jam > > > > project > > : requirements > > <address-model>32:<dll-path>C:/vcpkg/installed/x86-windows/bin > > <address-model>64:<dll-path>C:/vcpkg/installed/x64-windows/bin > > ; > > > > > > Now all the DLLs of libjpeg, libpng, etc. can be found when I run > > either of these two: > > > > b2.exe toolset=msvc-14.2 address-model=32 libs/gil/test/extension/io//simple > > b2.exe toolset=msvc-14.2 address-model=64 libs/gil/test/extension/io//simple > > > > Spectacular success of mine! ;) > > According to the Boost Build docs the dll-path feature only affects Unix > compilers. Perhaps the docs are incorrect regarding this feature. I missed that bit in the docs on the dll-path being Unix-only feature. I am certain the dll-path works with MSVC on Windows, so the docs must be out of date. I have reported it showing that dll-path works with MSVC: https://github.com/boostorg/build/issues/516 Best regards, -- Mateusz Loskot, http://mateusz.loskot.net _______________________________________________ Unsubscribe & other changes: https://lists.boost.org/mailman/listinfo.cgi/boost-build