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
Now GCC supports all the c++11 features, but when I use cmake on Ubuntu, I always get this message "Detecting support for c++ feature 'THREADS': false", and I see it try_compile the file oglplus/config/cpp/has_THREADS.cpp
when I use command gcc has_THREADS.cpp -Wall -lstdc++ -std=c++11 -pthread, it's OK.
So I guess try_compile command is missing pthread lib, and finally it works. (What about Windows platform?)
-- Detecting support for c++ feature 'SCOPED_ENUMS': TRUE
-- Detecting support for c++ feature 'SCOPED_ENUM_TEMPLATE_PARAMS': TRUE
-- Detecting support for c++ feature 'VARIADIC_MACROS': TRUE
-- Detecting support for c++ feature 'VARIADIC_TEMPLATES': TRUE
-- Detecting support for c++ feature 'UNIFIED_INITIALIZATION_SYNTAX': TRUE
-- Detecting support for c++ feature 'INITIALIZER_LISTS': TRUE
-- Detecting support for c++ feature 'DEFAULTED_FUNCTIONS': TRUE
-- Detecting support for c++ feature 'DELETED_FUNCTIONS': TRUE
-- Detecting support for c++ feature 'EXPLICIT_CONVERSION_OPERATORS': TRUE
-- Detecting support for c++ feature 'FUNCTION_TEMPLATE_DEFAULT_ARGS': TRUE
-- Detecting support for c++ feature 'UNICODE_LITERALS': TRUE
-- Detecting support for c++ feature 'USER_DEFINED_LITERALS': TRUE
-- Detecting support for c++ feature 'INHERITED_CONSTRUCTORS': TRUE
-- Detecting support for c++ feature 'GENERALIZED_ATTRIBUTES': TRUE
-- Detecting support for c++ feature 'TEMPLATE_ALIASES': TRUE
-- Detecting support for c++ feature 'CONSTEXPR': TRUE
-- Detecting support for c++ feature 'NOEXCEPT': TRUE
-- Detecting support for c++ feature 'OVERRIDE': TRUE
-- Detecting support for c++ feature 'LAMBDAS': TRUE
-- Detecting support for c++ feature 'CHRONO': TRUE
-- Detecting support for c++ feature 'THREADS': FALSE
-- Could NOT find Boost
-- Skipping 'glx_main' because 'THREADS' not implemented properly.
Now GCC supports all the c++11 features, but when I use cmake on Ubuntu, I always get this message "Detecting support for c++ feature 'THREADS': false", and I see it try_compile the file oglplus/config/cpp/has_THREADS.cpp
when I use command
gcc has_THREADS.cpp -Wall -lstdc++ -std=c++11 -pthread
, it's OK.So I guess try_compile command is missing pthread lib, and finally it works. (What about Windows platform?)
try_compile(
OGLPLUS_HAS_${FEATURE_NAME}
${PROJECT_BINARY_DIR}/cpp
${PROJECT_BINARY_DIR}/cpp/has_${FEATURE_NAME}.cpp
COMPILE_DEFINITIONS ${OGLPLUS_CPP_STD_COMPILER_SWITCH}
LINK_LIBRARIES pthread
)
The text was updated successfully, but these errors were encountered: