Comments (6)
I have the same problem
from vcpkg.
Also having this issue. Full logs:
[4/9] /home/rj/dev/emsdk/upstream/emscripten/em++ -DBOOST_CONTAINER_NO_LIB -DBOOST_CONTAINER_STATIC_LINK -I/home/rj/dev/vcpkg/buildtrees/boost-container/src/ost-1.85.0-b589bd4c0b.clean/libs/container/include -isystem /home/rj/dev/kiseki/aya/build/vcpkg_installed/wasm32-emscripten/include -g -fvisibility=hidden -fvisibility-inlines-hidden -MD -MT libs/container/CMakeFiles/boost_container.dir/src/synchronized_pool_resource.cpp.o -MF libs/container/CMakeFiles/boost_container.dir/src/synchronized_pool_resource.cpp.o.d -o libs/container/CMakeFiles/boost_container.dir/src/synchronized_pool_resource.cpp.o -c /home/rj/dev/vcpkg/buildtrees/boost-container/src/ost-1.85.0-b589bd4c0b.clean/libs/container/src/synchronized_pool_resource.cpp
FAILED: libs/container/CMakeFiles/boost_container.dir/src/synchronized_pool_resource.cpp.o
/home/rj/dev/emsdk/upstream/emscripten/em++ -DBOOST_CONTAINER_NO_LIB -DBOOST_CONTAINER_STATIC_LINK -I/home/rj/dev/vcpkg/buildtrees/boost-container/src/ost-1.85.0-b589bd4c0b.clean/libs/container/include -isystem /home/rj/dev/kiseki/aya/build/vcpkg_installed/wasm32-emscripten/include -g -fvisibility=hidden -fvisibility-inlines-hidden -MD -MT libs/container/CMakeFiles/boost_container.dir/src/synchronized_pool_resource.cpp.o -MF libs/container/CMakeFiles/boost_container.dir/src/synchronized_pool_resource.cpp.o.d -o libs/container/CMakeFiles/boost_container.dir/src/synchronized_pool_resource.cpp.o -c /home/rj/dev/vcpkg/buildtrees/boost-container/src/ost-1.85.0-b589bd4c0b.clean/libs/container/src/synchronized_pool_resource.cpp
In file included from /home/rj/dev/vcpkg/buildtrees/boost-container/src/ost-1.85.0-b589bd4c0b.clean/libs/container/src/synchronized_pool_resource.cpp:14:
/home/rj/dev/vcpkg/buildtrees/boost-container/src/ost-1.85.0-b589bd4c0b.clean/libs/container/include/boost/container/detail/thread_mutex.hpp:109:12: error: '__declspec' attributes are not enabled; use '-fdeclspec' or '-fms-extensions' to enable support for __declspec attributes
109 | extern "C" __declspec(dllimport) void __stdcall InitializeCriticalSection(::_RTL_CRITICAL_SECTION *);
| ^
/home/rj/dev/vcpkg/buildtrees/boost-container/src/ost-1.85.0-b589bd4c0b.clean/libs/container/include/boost/container/detail/thread_mutex.hpp:109:39: warning: '__stdcall' calling convention is not supported for this target [-Wignored-attributes]
109 | extern "C" __declspec(dllimport) void __stdcall InitializeCriticalSection(::_RTL_CRITICAL_SECTION *);
| ^
/home/rj/dev/vcpkg/buildtrees/boost-container/src/ost-1.85.0-b589bd4c0b.clean/libs/container/include/boost/container/detail/thread_mutex.hpp:111:12: error: '__declspec' attributes are not enabled; use '-fdeclspec' or '-fms-extensions' to enable support for __declspec attributes
111 | extern "C" __declspec(dllimport) void __stdcall EnterCriticalSection(::_RTL_CRITICAL_SECTION *);
| ^
/home/rj/dev/vcpkg/buildtrees/boost-container/src/ost-1.85.0-b589bd4c0b.clean/libs/container/include/boost/container/detail/thread_mutex.hpp:111:39: warning: '__stdcall' calling convention is not supported for this target [-Wignored-attributes]
111 | extern "C" __declspec(dllimport) void __stdcall EnterCriticalSection(::_RTL_CRITICAL_SECTION *);
| ^
/home/rj/dev/vcpkg/buildtrees/boost-container/src/ost-1.85.0-b589bd4c0b.clean/libs/container/include/boost/container/detail/thread_mutex.hpp:112:12: error: '__declspec' attributes are not enabled; use '-fdeclspec' or '-fms-extensions' to enable support for __declspec attributes
112 | extern "C" __declspec(dllimport) void __stdcall LeaveCriticalSection(::_RTL_CRITICAL_SECTION *);
| ^
/home/rj/dev/vcpkg/buildtrees/boost-container/src/ost-1.85.0-b589bd4c0b.clean/libs/container/include/boost/container/detail/thread_mutex.hpp:112:39: warning: '__stdcall' calling convention is not supported for this target [-Wignored-attributes]
112 | extern "C" __declspec(dllimport) void __stdcall LeaveCriticalSection(::_RTL_CRITICAL_SECTION *);
| ^
/home/rj/dev/vcpkg/buildtrees/boost-container/src/ost-1.85.0-b589bd4c0b.clean/libs/container/include/boost/container/detail/thread_mutex.hpp:113:12: error: '__declspec' attributes are not enabled; use '-fdeclspec' or '-fms-extensions' to enable support for __declspec attributes
113 | extern "C" __declspec(dllimport) void __stdcall DeleteCriticalSection(::_RTL_CRITICAL_SECTION *);
| ^
/home/rj/dev/vcpkg/buildtrees/boost-container/src/ost-1.85.0-b589bd4c0b.clean/libs/container/include/boost/container/detail/thread_mutex.hpp:113:39: warning: '__stdcall' calling convention is not supported for this target [-Wignored-attributes]
113 | extern "C" __declspec(dllimport) void __stdcall DeleteCriticalSection(::_RTL_CRITICAL_SECTION *);
| ^
4 warnings and 4 errors generated.
Adding -fdeclspec
/-fms-extensions
to my CMAKE_CXX_COMPILER_FLAGS, either in my configure settings or through my CMakeLists (using add_compile_options) doesn't seem to work either.
from vcpkg.
It seems like either you or Boost.Container (or both) forgot to link to Threads::Threads
.
from vcpkg.
It seems like either you or Boost.Container (or both) forgot to link to
Threads::Threads
.
I am not sure how this would be the source of the problem. In my case, I am installing "boost" entirely in my vcpkg JSON manifest, and in my app's CMakeLists I run find_package(Boost COMPONENTS filesystem system iostreams thread exception program_options REQUIRED)
. I am convinced it is a problem with Boost itself -- however, if that is the case, then it is more likely because of the __declspec
keyword not being recognized by the compiler since it is not being run with the -fms-extensions
flag.
from vcpkg.
It seems like either you or Boost.Container (or both) forgot to link to
Threads::Threads
.I am not sure how this would be the source of the problem. In my case, I am installing "boost" entirely in my vcpkg JSON manifest, and in my app's CMakeLists I run
find_package(Boost COMPONENTS filesystem system iostreams thread exception program_options REQUIRED)
. I am convinced it is a problem with Boost itself -- however, if that is the case, then it is more likely because of the__declspec
keyword not being recognized by the compiler since it is not being run with the-fms-extensions
flag.
Because Boost.Container code is structured the way that windows platform specific code is a 'fallback' - when pthreads wasn't enabled (emscripten is not windows, it doesn't have winapi) you are getting these errors. Emscripten shouldn't get in that code path in the first place.
from vcpkg.
Duplicates #38469.
from vcpkg.
Related Issues (20)
- Prompt "A suitable version of 7zip was not found (required v24.6.0)" when installing HOT 3
- [<osg>] build failure on android HOT 7
- [openvdb] Build error HOT 6
- [opencv4] Build failure on x64-windows HOT 2
- [shiftmedia-libgnutls] Add release dll on debug when compile with ngtcp2 and gnutls HOT 11
- crashpad build failure HOT 2
- [freeimage] Build error on x64-linux HOT 3
- [freetype] Build error on x64-linux HOT 1
- [mysql-connector-cpp] Build error on x64-windows HOT 8
- opencv:x86-windows-static-md HOT 1
- [libdatachannel] Link failure in global mode HOT 7
- [opencv4] Build error on x86-windows-static-md HOT 4
- [grpc] Build failure on arm64-osx HOT 2
- [magic-enum] v 0.9.6 build failure HOT 1
- [7zip] update to <24.08>
- [vcpkg] Repository description uses incorrect capitalization for macOS HOT 1
- [curl] curl-config doesn't work correctly without setting $prefix variable on Linux HOT 4
- The find_package directive using cmake in vs2022 cannot find the package HOT 3
- openms
- [glaze] update to 3.2.5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vcpkg.