-
Notifications
You must be signed in to change notification settings - Fork 627
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
libopenvdb.lib : fatal error LNK1248: #1624
Comments
Please post the full build log, including the reported compiler errors |
Sorry,after change the build config from debug to Release,the error is gone!I don`t know why.But after that i found using vcpkg can not install the third party dependency with static library.Because i build the OpenVDB library for other project,but when i link the libopenvdb.lib,here the error came is could not open tbb12.lib!So i want to ask is there an command that could copy to dependency to install Folder? |
@Idclip Building debug static lib always gives this error on Windows MSVC:
|
@Idclip The same problem occurs when I build a static debug openvdb under vcpkg.
|
Hey folks - that's interesting, it's probably something to do with explicit instantiation creating huge libs. If you're able, can you try and turn off the following cmake option: |
Looking at the linked issue it seems as those turning off explicit instantiation fixed the issues you're seeing? Closing for now but please re-open if necessary |
PS D:\openvdb\build> cmake -DCMAKE_TOOLCHAIN_FILE=D:\vcpkg\scripts\buildsystems\vcpkg.cmake -DOPENVDB_BUILD_NANOVDB=ON ..
-- Building for: Visual Studio 17 2022
-- Selecting Windows SDK version 10.0.22000.0 to target Windows 10.0.19044.
-- The CXX compiler identification is MSVC 19.36.32532.0
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: C:/Program Files/Microsoft Visual Studio/2022/Community/VC/Tools/MSVC/14.36.32532/bin/Hostx64/x64/cl.exe - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Suppressing some noisy MSVC CXX warnings, set OPENVDB_CXX_STRICT=ON to re-enable them.
-- Configuring for OpenVDB Version 10.0.2
-- Configuring for OpenVDB ABI Version 10
-- ------------- Configuring OpenVDBCore --------------
CMake Warning at openvdb/openvdb/CMakeLists.txt:64 (message):
Detected VCPKG toolchain is using a mismatching triplet for OpenVDB build
artifacts. x64-windows is dynamic, but OPENVDB_CORE_STATIC is ON. The
static build of OpenVDB may not build correctly. It it recommended to only
configure either the static or shared library on Windows in a single run of
CMake.
CMake Warning at C:/Program Files/CMake/share/cmake-3.22/Modules/FindBoost.cmake:1384 (message):
New Boost version may have incorrect or missing dependencies and imported
targets
Call Stack (most recent call first):
C:/Program Files/CMake/share/cmake-3.22/Modules/FindBoost.cmake:1507 (_Boost_COMPONENT_DEPENDENCIES)
C:/Program Files/CMake/share/cmake-3.22/Modules/FindBoost.cmake:2117 (_Boost_MISSING_DEPENDENCIES)
D:/vcpkg/installed/x64-windows/share/boost/vcpkg-cmake-wrapper.cmake:11 (_find_package)
D:/vcpkg/scripts/buildsystems/vcpkg.cmake:807 (include)
openvdb/openvdb/CMakeLists.txt:121 (find_package)
CMake Warning at C:/Program Files/CMake/share/cmake-3.22/Modules/FindBoost.cmake:1384 (message):
New Boost version may have incorrect or missing dependencies and imported
targets
Call Stack (most recent call first):
C:/Program Files/CMake/share/cmake-3.22/Modules/FindBoost.cmake:1507 (_Boost_COMPONENT_DEPENDENCIES)
C:/Program Files/CMake/share/cmake-3.22/Modules/FindBoost.cmake:2117 (_Boost_MISSING_DEPENDENCIES)
D:/vcpkg/installed/x64-windows/share/boost/vcpkg-cmake-wrapper.cmake:11 (_find_package)
D:/vcpkg/scripts/buildsystems/vcpkg.cmake:807 (include)
openvdb/openvdb/CMakeLists.txt:121 (find_package)
-- Found Boost: D:/vcpkg/installed/x64-windows/include (found suitable version "1.82.0", minimum required is "1.73") found components: iostreams regex
-- Found TBB: D:/vcpkg/installed/x64-windows/include (found suitable version "2021.9", minimum required is "2020.2") found components: tbb
-- Found Blosc: optimized;D:/vcpkg/installed/x64-windows/lib/blosc.lib;debug;D:/vcpkg/installed/x64-windows/debug/lib/blosc.lib (found suitable version "1.21.3", minimum required is "1.17.0")
-- Found ZLIB: optimized;D:/vcpkg/installed/x64-windows/lib/zlib.lib;debug;D:/vcpkg/installed/x64-windows/debug/lib/zlibd.lib (found suitable version "1.2.13", minimum required is "1.2.7")
-- ----------- Configuring OpenVDBBinaries ------------
-- Found TBB: D:/vcpkg/installed/x64-windows/include (found suitable version "2021.9", minimum required is "2020.2") found components: tbbmalloc
-- The C compiler identification is MSVC 19.36.32532.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: C:/Program Files/Microsoft Visual Studio/2022/Community/VC/Tools/MSVC/14.36.32532/bin/Hostx64/x64/cl.exe - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- --------------- Configuring NanoVDB ----------------
-- Found TBB: D:/vcpkg/installed/x64-windows/include (found version "2021.9") found components: tbb tbbmalloc tbbmalloc_proxy
-- Found Blosc: optimized;D:/vcpkg/installed/x64-windows/lib/blosc.lib;debug;D:/vcpkg/installed/x64-windows/debug/lib/blosc.lib (found version "1.21.3")
-- Found ZLIB: optimized;D:/vcpkg/installed/x64-windows/lib/zlib.lib;debug;D:/vcpkg/installed/x64-windows/debug/lib/zlibd.lib (found version "1.2.13")
-- --------- Configuring NanoVDB Cmd Tools ------------
CMake Warning at nanovdb/nanovdb/cmd/CMakeLists.txt:31 (message):
-- Configuring done
-- Generating done
-- Build files have been written to: D:/openvdb/build
cmake --build .
After a while the compiler cames error
The text was updated successfully, but these errors were encountered: