HyperPose icon indicating copy to clipboard operation
HyperPose copied to clipboard

CMake Error when setting BUILD_PACKAGE=ON

Open orestis-z opened this issue 4 years ago • 1 comments

When building with

cmake .. \
-DCMAKE_BUILD_TYPE=Release \
-DBUILD_EXAMPLES=OFF \
-DBUILD_TESTS=OFF \
-DBUILD_PACKAGE=ON \
-DBUILD_CLI=OFF \
-DBUILD_USER_CODES=OFF
cmake --build .

I get the following output / error:

-- The C compiler identification is GNU 7.5.0
-- The CXX compiler identification is GNU 7.5.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
[HyperPose] BUILD_LIB is ON.
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Failed
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Found CUDA: /usr/local/cuda (found version "11.2")
-- Found OpenCV: /usr/local (found version "4.5.3")
-- Create target hyperpose for export HyperPose. Install INCLUDEDIR: include. Install LIBDIR: lib
-- Configuring done
CMake Error: install(EXPORT "HyperPose" ...) includes target "hyperpose" which requires target "stdtracer" that is not in any export set.
CMake Error in CMakeLists.txt:
  export called with target "hyperpose" which requires target "stdtracer"
  that is not in any export set.


-- Generating done
CMake Generate step failed.  Build files cannot be regenerated correctly.

I debugged it and figured out that setting BUILD_PACKAGE=ON causes the error. Is this a known bug?

orestis-z avatar Oct 13 '21 11:10 orestis-z

@orestis-z Sorry for the late reply. It seems that you did not have stdtracer successfully installed (should be installed via CMake directly). However, stdtracer is not necessarily required. You can use -DWITH_TRACE=0 to disable stdtracer. (Remember to remove cmake cache first.)

ganler avatar Oct 24 '21 03:10 ganler