Skip to content
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

Linker error in Ubuntu #259

Open
Makogan opened this issue Dec 11, 2023 · 4 comments
Open

Linker error in Ubuntu #259

Makogan opened this issue Dec 11, 2023 · 4 comments

Comments

@Makogan
Copy link

Makogan commented Dec 11, 2023

Problem summary:

When trying to build IFC++ on Ubuntu a linker error occurs.

System:

Ubuntu 22.04
cmake version 3.22.1
gcc (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0
Ubuntu clang version 14.0.0-1ubuntu1.1

Steps to reproduce:

git clone https://github.com/ifcquery/ifcplusplus.git
cd ifcpluplus
cmake -S . -B build
cmake --build build --config Release

Error message:

cmake --build build --config Release
[ 91%] Built target IfcPlusPlus
[ 93%] Linking CXX executable ../../Release/CreateIfcWallAndWriteFile
/usr/bin/ld: ../../Release/libIfcPlusPlus.a(WriterSTEP.cpp.o): in function `tbb::detail::d1::task_arena_function<__pstl::__tbb_backend::__parallel_for<__pstl::execution::v1::parallel_policy const&, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, __pstl::__internal::__pattern_walk1<__pstl::execution::v1::parallel_policy const&, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, WriterSTEP::writeModelToStream(std::__cxx11::basic_stringstream<char, std::char_traits<char>, std::allocator<char> >&, std::shared_ptr<BuildingModel>)::{lambda(std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >&)#1}, std::integral_constant<bool, false> >(__pstl::execution::v1::parallel_policy const&, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, WriterSTEP::writeModelToStream(std::__cxx11::basic_stringstream<char, std::char_traits<char>, std::allocator<char> >&, std::shared_ptr<BuildingModel>)::{lambda(std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >&)#1}, std::integral_constant<bool, false>, std::integral_constant<bool, true>)::{lambda()#1}::operator()() const::{lambda(__gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >)#1}>(__pstl::execution::v1::parallel_policy const&, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, __pstl::__internal::__pattern_walk1<__pstl::execution::v1::parallel_policy const&, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, WriterSTEP::writeModelToStream(std::__cxx11::basic_stringstream<char, std::char_traits<char>, std::allocator<char> >&, std::shared_ptr<BuildingModel>)::{lambda(std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >&)#1}, std::integral_constant<bool, false> >(__pstl::execution::v1::parallel_policy const&, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, WriterSTEP::writeModelToStream(std::__cxx11::basic_stringstream<char, std::char_traits<char>, std::allocator<char> >&, std::shared_ptr<BuildingModel>)::{lambda(std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >&)#1}, std::integral_constant<bool, false>, std::integral_constant<bool, true>)::{lambda()#1}::operator()() const::{lambda(__gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >)#1})::{lambda()#1}, void>::operator()() const':
WriterSTEP.cpp:(.text+0xd1): undefined reference to `tbb::detail::r1::initialize(tbb::detail::d1::task_group_context&)'
/usr/bin/ld: WriterSTEP.cpp:(.text+0xde): undefined reference to `tbb::detail::r1::destroy(tbb::detail::d1::task_group_context&)'
/usr/bin/ld: WriterSTEP.cpp:(.text+0x124): undefined reference to `tbb::detail::r1::allocate(tbb::detail::d1::small_object_pool*&, unsigned long)'
/usr/bin/ld: WriterSTEP.cpp:(.text+0x18c): undefined reference to `tbb::detail::r1::max_concurrency(tbb::detail::d1::task_arena_base const*)'
/usr/bin/ld: WriterSTEP.cpp:(.text+0x200): undefined reference to `tbb::detail::r1::execute_and_wait(tbb::detail::d1::task&, tbb::detail::d1::task_group_context&, tbb::detail::d1::wait_context&, tbb::detail::d1::task_group_context&)'
/usr/bin/ld: ../../Release/libIfcPlusPlus.a(WriterSTEP.cpp.o): in function `tbb::detail::d1::start_for<tbb::detail::d1::blocked_range<__gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > > >, __pstl::__tbb_backend::__parallel_for_body<__gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, __pstl::__internal::__pattern_walk1<__pstl::execution::v1::parallel_policy const&, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, WriterSTEP::writeModelToStream(std::__cxx11::basic_stringstream<char, std::char_traits<char>, std::allocator<char> >&, std::shared_ptr<BuildingModel>)::{lambda(std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >&)#1}, std::integral_constant<bool, false> >(__pstl::execution::v1::parallel_policy const&, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, WriterSTEP::writeModelToStream(std::__cxx11::basic_stringstream<char, std::char_traits<char>, std::allocator<char> >&, std::shared_ptr<BuildingModel>)::{lambda(std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >&)#1}, std::integral_constant<bool, false>, std::integral_constant<bool, true>)::{lambda()#1}::operator()() const::{lambda(__gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >)#1}>, tbb::detail::d1::auto_partitioner const>::cancel(tbb::detail::d1::execution_data&)':
WriterSTEP.cpp:(.text+0x25d): undefined reference to `tbb::detail::r1::deallocate(tbb::detail::d1::small_object_pool&, void*, unsigned long, tbb::detail::d1::execution_data const&)'
/usr/bin/ld: WriterSTEP.cpp:(.text+0x284): undefined reference to `tbb::detail::r1::deallocate(tbb::detail::d1::small_object_pool&, void*, unsigned long, tbb::detail::d1::execution_data const&)'
/usr/bin/ld: WriterSTEP.cpp:(.text+0x2a5): undefined reference to `tbb::detail::r1::notify_waiters(unsigned long)'
/usr/bin/ld: ../../Release/libIfcPlusPlus.a(WriterSTEP.cpp.o): in function `WriterSTEP::writeModelToStream(std::__cxx11::basic_stringstream<char, std::char_traits<char>, std::allocator<char> >&, std::shared_ptr<BuildingModel>)':
WriterSTEP.cpp:(.text+0x7c5): undefined reference to `tbb::detail::r1::isolate_within_arena(tbb::detail::d1::delegate_base&, long)'
/usr/bin/ld: ../../Release/libIfcPlusPlus.a(WriterSTEP.cpp.o): in function `void tbb::detail::d1::dynamic_grainsize_mode<tbb::detail::d1::adaptive_mode<tbb::detail::d1::auto_partition_type> >::work_balance<tbb::detail::d1::start_for<tbb::detail::d1::blocked_range<__gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > > >, __pstl::__tbb_backend::__parallel_for_body<__gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, __pstl::__internal::__pattern_walk1<__pstl::execution::v1::parallel_policy const&, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, WriterSTEP::writeModelToStream(std::__cxx11::basic_stringstream<char, std::char_traits<char>, std::allocator<char> >&, std::shared_ptr<BuildingModel>)::{lambda(std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >&)#1}, std::integral_constant<bool, false> >(__pstl::execution::v1::parallel_policy const&, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, WriterSTEP::writeModelToStream(std::__cxx11::basic_stringstream<char, std::char_traits<char>, std::allocator<char> >&, std::shared_ptr<BuildingModel>)::{lambda(std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >&)#1}, std::integral_constant<bool, false>, std::integral_constant<bool, true>)::{lambda()#1}::operator()() const::{lambda(__gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >)#1}>, tbb::detail::d1::auto_partitioner const>, tbb::detail::d1::blocked_range<__gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > > > >(__pstl::execution::v1::parallel_policy const&, tbb::detail::d1::blocked_range<__gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > > >&, tbb::detail::d1::execution_data&)':
WriterSTEP.cpp:(.text+0x1e5d): undefined reference to `tbb::detail::r1::is_group_execution_cancelled(tbb::detail::d1::task_group_context&)'
/usr/bin/ld: WriterSTEP.cpp:(.text+0x254c): undefined reference to `tbb::detail::r1::allocate(tbb::detail::d1::small_object_pool*&, unsigned long, tbb::detail::d1::execution_data const&)'
/usr/bin/ld: WriterSTEP.cpp:(.text+0x2630): undefined reference to `tbb::detail::r1::allocate(tbb::detail::d1::small_object_pool*&, unsigned long, tbb::detail::d1::execution_data const&)'
/usr/bin/ld: WriterSTEP.cpp:(.text+0x266b): undefined reference to `tbb::detail::r1::spawn(tbb::detail::d1::task&, tbb::detail::d1::task_group_context&)'
/usr/bin/ld: ../../Release/libIfcPlusPlus.a(WriterSTEP.cpp.o): in function `tbb::detail::d1::start_for<tbb::detail::d1::blocked_range<__gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > > >, __pstl::__tbb_backend::__parallel_for_body<__gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, __pstl::__internal::__pattern_walk1<__pstl::execution::v1::parallel_policy const&, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, WriterSTEP::writeModelToStream(std::__cxx11::basic_stringstream<char, std::char_traits<char>, std::allocator<char> >&, std::shared_ptr<BuildingModel>)::{lambda(std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >&)#1}, std::integral_constant<bool, false> >(__pstl::execution::v1::parallel_policy const&, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, WriterSTEP::writeModelToStream(std::__cxx11::basic_stringstream<char, std::char_traits<char>, std::allocator<char> >&, std::shared_ptr<BuildingModel>)::{lambda(std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >&)#1}, std::integral_constant<bool, false>, std::integral_constant<bool, true>)::{lambda()#1}::operator()() const::{lambda(__gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >)#1}>, tbb::detail::d1::auto_partitioner const>::execute(tbb::detail::d1::execution_data&)':
WriterSTEP.cpp:(.text+0x2d55): undefined reference to `tbb::detail::r1::allocate(tbb::detail::d1::small_object_pool*&, unsigned long, tbb::detail::d1::execution_data const&)'
/usr/bin/ld: WriterSTEP.cpp:(.text+0x2e33): undefined reference to `tbb::detail::r1::allocate(tbb::detail::d1::small_object_pool*&, unsigned long, tbb::detail::d1::execution_data const&)'
/usr/bin/ld: WriterSTEP.cpp:(.text+0x2e6c): undefined reference to `tbb::detail::r1::spawn(tbb::detail::d1::task&, tbb::detail::d1::task_group_context&)'
/usr/bin/ld: WriterSTEP.cpp:(.text+0x2ef1): undefined reference to `tbb::detail::r1::deallocate(tbb::detail::d1::small_object_pool&, void*, unsigned long, tbb::detail::d1::execution_data const&)'
/usr/bin/ld: WriterSTEP.cpp:(.text+0x2f18): undefined reference to `tbb::detail::r1::deallocate(tbb::detail::d1::small_object_pool&, void*, unsigned long, tbb::detail::d1::execution_data const&)'
/usr/bin/ld: WriterSTEP.cpp:(.text+0x2f4c): undefined reference to `tbb::detail::r1::execution_slot(tbb::detail::d1::execution_data const*)'
/usr/bin/ld: WriterSTEP.cpp:(.text+0x2f5d): undefined reference to `tbb::detail::r1::execution_slot(tbb::detail::d1::execution_data const*)'
/usr/bin/ld: WriterSTEP.cpp:(.text+0x2f7d): undefined reference to `tbb::detail::r1::notify_waiters(unsigned long)'
/usr/bin/ld: WriterSTEP.cpp:(.text+0x2f97): undefined reference to `tbb::detail::r1::execution_slot(tbb::detail::d1::execution_data const*)'
/usr/bin/ld: ../../Release/libIfcPlusPlus.a(WriterSTEP.cpp.o): in function `tbb::detail::d1::task_arena_function<__pstl::__tbb_backend::__parallel_for<__pstl::execution::v1::parallel_policy const&, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, __pstl::__internal::__pattern_walk1<__pstl::execution::v1::parallel_policy const&, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, WriterSTEP::writeModelToStream(std::__cxx11::basic_stringstream<char, std::char_traits<char>, std::allocator<char> >&, std::shared_ptr<BuildingModel>)::{lambda(std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >&)#1}, std::integral_constant<bool, false> >(__pstl::execution::v1::parallel_policy const&, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, WriterSTEP::writeModelToStream(std::__cxx11::basic_stringstream<char, std::char_traits<char>, std::allocator<char> >&, std::shared_ptr<BuildingModel>)::{lambda(std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >&)#1}, std::integral_constant<bool, false>, std::integral_constant<bool, true>)::{lambda()#1}::operator()() const::{lambda(__gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >)#1}>(__pstl::execution::v1::parallel_policy const&, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, __pstl::__internal::__pattern_walk1<__pstl::execution::v1::parallel_policy const&, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, WriterSTEP::writeModelToStream(std::__cxx11::basic_stringstream<char, std::char_traits<char>, std::allocator<char> >&, std::shared_ptr<BuildingModel>)::{lambda(std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >&)#1}, std::integral_constant<bool, false> >(__pstl::execution::v1::parallel_policy const&, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, WriterSTEP::writeModelToStream(std::__cxx11::basic_stringstream<char, std::char_traits<char>, std::allocator<char> >&, std::shared_ptr<BuildingModel>)::{lambda(std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >&)#1}, std::integral_constant<bool, false>, std::integral_constant<bool, true>)::{lambda()#1}::operator()() const::{lambda(__gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >, __gnu_cxx::__normal_iterator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >*, std::vector<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::tuple<int, std::shared_ptr<BuildingEntity>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > >)#1})::{lambda()#1}, void>::operator()() const [clone .cold]':
WriterSTEP.cpp:(.text.unlikely+0x4): undefined reference to `tbb::detail::r1::destroy(tbb::detail::d1::task_group_context&)'
collect2: error: ld returned 1 exit status
gmake[2]: *** [examples/CreateIfcWallAndWriteFile/CMakeFiles/CreateIfcWallAndWriteFile.dir/build.make:98: Release/CreateIfcWallAndWriteFile] Error 1
gmake[1]: *** [CMakeFiles/Makefile2:160: examples/CreateIfcWallAndWriteFile/CMakeFiles/CreateIfcWallAndWriteFile.dir/all] Error 2
gmake: *** [Makefile:136: all] Error 2
@Makogan
Copy link
Author

Makogan commented Dec 11, 2023

It seems that if I add this to the cmake it links?

find_package(TBB REQUIRED)
target_link_libraries(IfcPlusPlus PUBLIC TBB::tbb)

@Makogan
Copy link
Author

Makogan commented Dec 11, 2023

Piggy backing off of this issue, it seems the example examples/SimpleViewerExampleQt is not properly formed?

I tried using cmake -DIFCPP_SOURCE_DIR=../../ .. under a standard build directory, it yields this:

/usr/include/oneapi/tbb/profiling.h:229:15: error: expected unqualified-id before ‘)’ token
  229 |     void emit() { }
      |               ^
/usr/include/oneapi/tbb/profiling.h:231:22: error: expected unqualified-id before ‘const’
  231 |     static void emit(const std::string &) { }
      |                      ^~~~~
/usr/include/oneapi/tbb/profiling.h:231:22: error: expected ‘)’ before ‘const’
  231 |     static void emit(const std::string &) { }
      |                     ~^~~~~
      |                      )

This is the error under clang:

/usr/include/tbb/../oneapi/tbb/detail/../profiling.h:229:15: error: expected member name or ';' after declaration specifiers
    void emit() { }
    ~~~~      ^

So something about the way tbb is included seems to be erroneous?

@ifcquery
Copy link
Owner

I just ran a cmake build on Ubuntu 22.04 without any errors.
Can you check with current version?

@gdamiand
Copy link

I confirm the same error on a fresh install of the last version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants