HyperSLAM icon indicating copy to clipboard operation
HyperSLAM copied to clipboard

target_sources may only set INTERFACE properties on INTERFACE targets

Open SharineLee opened this issue 2 years ago • 1 comments

`sharine@sharine-MS-7B98:~/LXX/MyResearch/HyperSLAM/build$ cmake .. -- The CXX compiler identification is GNU 10.3.0 -- Check for working CXX compiler: /usr/bin/c++ -- Check for working CXX compiler: /usr/bin/c++ -- works -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Detecting CXX compile features -- Detecting CXX compile features - done -- Found GTest: /usr/local/lib/libgtest.a
-- Found OpenCV: /usr (found version "3.2.0") CMake Error at build/_deps/hypersensors-src/CMakeLists.txt:85 (target_sources): target_sources may only set INTERFACE properties on INTERFACE targets

-- Found Threads: TRUE
-- Found CXSparse: /usr/include/suitesparse (found suitable version "3.1.9", minimum required is "3.1.9") -- Found BLAS: /usr/lib/x86_64-linux-gnu/libf77blas.so;/usr/lib/x86_64-linux-gnu/libatlas.so
-- Found AMD headers in: /usr/include/suitesparse -- Found AMD library: /usr/lib/x86_64-linux-gnu/libamd.so -- Found CAMD headers in: /usr/include/suitesparse -- Found CAMD library: /usr/lib/x86_64-linux-gnu/libcamd.so -- Found CCOLAMD headers in: /usr/include/suitesparse -- Found CCOLAMD library: /usr/lib/x86_64-linux-gnu/libccolamd.so -- Found CHOLMOD headers in: /usr/include/suitesparse -- Found CHOLMOD library: /usr/lib/x86_64-linux-gnu/libcholmod.so -- Found COLAMD headers in: /usr/include/suitesparse -- Found COLAMD library: /usr/lib/x86_64-linux-gnu/libcolamd.so -- Found SPQR headers in: /usr/include/suitesparse -- Found SPQR library: /usr/lib/x86_64-linux-gnu/libspqr.so -- Found Config headers in: /usr/include/suitesparse -- Found Config library: /usr/lib/x86_64-linux-gnu/libsuitesparseconfig.so -- Did not find Intel TBB library, assuming SuiteSparseQR was not compiled with TBB. -- Looking for shm_open in rt -- Looking for shm_open in rt - found -- Adding librt to SuiteSparse_config libraries (required on Linux & Unix [not OSX] if SuiteSparse is compiled with timing). -- Could NOT find METIS (missing: METIS_INCLUDE_DIR METIS_LIBRARY) -- Found SuiteSparse: /usr/include/suitesparse (found suitable version "5.1.2", minimum required is "5.1.2") found components: AMD CAMD CCOLAMD CHOLMOD COLAMD SPQR Config -- Found required Ceres dependency: Eigen version 3.3.4 in /usr/lib/cmake/eigen3 -- Found required Ceres dependency: glog -- Found required Ceres dependency: gflags -- Found Ceres version: 2.1.0 installed in: /usr/local with components: [EigenSparse, SparseLinearAlgebraLibrary, LAPACK, SuiteSparse, CXSparse, SchurSpecializations, Multithreading] -- Configuring incomplete, errors occurred! See also "/home/sharine/LXX/MyResearch/HyperSLAM/build/CMakeFiles/CMakeOutput.log". See also "/home/sharine/LXX/MyResearch/HyperSLAM/build/CMakeFiles/CMakeError.log".`

SharineLee avatar Feb 22 '23 10:02 SharineLee

As hinted, we change the PUBLIC property to INTERFACE. Then the package can be compiled.

JzHuai0108 avatar May 17 '24 04:05 JzHuai0108

Agree with @JzHuai0108. Must have been an oversight from our side given that we never encountered the same issue. In general, this might be caused by the selection of the exact GCC/G++ version and the used C++ standard.

McEmzi avatar Jul 22 '24 08:07 McEmzi