Skip to content

Commit

Permalink
fix build on ubuntu 18.04
Browse files Browse the repository at this point in the history
  • Loading branch information
wangg12 authored Feb 18, 2023
1 parent e101928 commit 4331d82
Showing 1 changed file with 14 additions and 2 deletions.
16 changes: 14 additions & 2 deletions src/ch5/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,15 @@ add_library(${PROJECT_NAME}.ch5
kdtree.cc
octo_tree.cc
)
target_link_libraries(${PROJECT_NAME}.ch5
if (BUILD_WITH_UBUNTU1804)
target_link_libraries(${PROJECT_NAME}.ch5
TBB::tbb
)
else()
target_link_libraries(${PROJECT_NAME}.ch5
tbb
)
endif()

add_executable(linear_fitting linear_fitting.cc)
target_link_libraries(linear_fitting
Expand All @@ -41,6 +47,12 @@ target_link_libraries(linear_fitting
ADD_EXECUTABLE(test_nn test_nn.cc)
ADD_TEST(test_nn test_bfnn)

target_link_libraries(test_nn
if (BUILD_WITH_UBUNTU1804)
target_link_libraries(test_nn
GTest::gtest pthread glog gflags ${PROJECT_NAME}.ch5 ${PROJECT_NAME}.common ${PCL_LIBRARIES} TBB::tbb
)
else()
target_link_libraries(test_nn
gtest pthread glog gflags ${PROJECT_NAME}.ch5 ${PROJECT_NAME}.common ${PCL_LIBRARIES} tbb
)
endif()

0 comments on commit 4331d82

Please sign in to comment.