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

catkin_make failed #14

Open
nirajreginald opened this issue Mar 31, 2021 · 3 comments
Open

catkin_make failed #14

nirajreginald opened this issue Mar 31, 2021 · 3 comments

Comments

@nirajreginald
Copy link

Im trying build the code_utils in my catkin workspace and getting the below errors. Not sure how to move forward from here? Thanks for any help

`niraj@niraj-ThinkPad-L380-Yoga:~/imu_cam_calib$ catkin_make
Base path: /home/niraj/imu_cam_calib
Source space: /home/niraj/imu_cam_calib/src
Build space: /home/niraj/imu_cam_calib/build
Devel space: /home/niraj/imu_cam_calib/devel
Install space: /home/niraj/imu_cam_calib/install

Running command: "make cmake_check_build_system" in "/home/niraj/imu_cam_calib/build"

-- Using CATKIN_DEVEL_PREFIX: /home/niraj/imu_cam_calib/devel
-- Using CMAKE_PREFIX_PATH: /home/niraj/catkin_ws/devel;/opt/ros/kinetic
-- This workspace overlays: /home/niraj/catkin_ws/devel;/opt/ros/kinetic
-- Found PythonInterp: /usr/bin/python2 (found suitable version "2.7.12", minimum required is "2")
-- Using PYTHON_EXECUTABLE: /usr/bin/python2
-- Using Debian Python package layout
-- Using empy: /usr/bin/empy
-- Using CATKIN_ENABLE_TESTING: ON
-- Call enable_testing()
-- Using CATKIN_TEST_RESULTS_DIR: /home/niraj/imu_cam_calib/build/test_results
-- Found gtest sources under '/usr/src/gmock': gtests will be built
-- Found gmock sources under '/usr/src/gmock': gmock will be built
-- Found PythonInterp: /usr/bin/python2 (found version "2.7.12")
-- Using Python nosetests: /usr/bin/nosetests-2.7
-- catkin 0.7.29
-- BUILD_SHARED_LIBS is on
-- BUILD_SHARED_LIBS is on
-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-- ~~ traversing 1 packages in topological order:
-- ~~ - code_utils
-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-- +++ processing catkin package: 'code_utils'
-- ==> add_subdirectory(code_utils)
-- Found required Ceres dependency: Eigen version 3.3.4 in /usr/include/eigen3
-- Found required Ceres dependency: glog
-- Found Ceres version: 2.0.0 installed in: /usr/local with components: [EigenSparse, SparseLinearAlgebraLibrary, LAPACK, SuiteSparse, CXSparse, SchurSpecializations, Multithreading]
-- Configuring done
-- Generating done
-- Build files have been written to: /home/niraj/imu_cam_calib/build

Running command: "make -j8 -l8" in "/home/niraj/imu_cam_calib/build"

[ 7%] Building CXX object code_utils/CMakeFiles/polynomial.dir/src/math_utils/Polynomial.cpp.o
[ 23%] Building CXX object code_utils/CMakeFiles/cv_utils.dir/src/cv_utils.cc.o
[ 23%] Building CXX object code_utils/CMakeFiles/matIO_test.dir/src/mat_io_test.cpp.o
[ 30%] Building CXX object code_utils/CMakeFiles/sumpixel_test.dir/src/sumpixel_test.cpp.o
[ 38%] Building CXX object code_utils/CMakeFiles/pnp.dir/src/cv_utils/dlt/dlt.cpp.o
[ 46%] Building CXX object code_utils/CMakeFiles/pnp.dir/src/cv_utils/pnp/nonlinearpnp.cpp.o
[ 53%] Building CXX object code_utils/CMakeFiles/pnp.dir/src/cv_utils/pnp/linearpnp.cpp.o
[ 61%] Building CXX object code_utils/CMakeFiles/pnp.dir/src/cv_utils/pnp/pnp.cpp.o
In file included from /usr/local/include/ceres/internal/array_selector.h:38:0,
from /usr/local/include/ceres/internal/autodiff.h:148,
from /usr/local/include/ceres/autodiff_cost_function.h:130,
from /usr/local/include/ceres/ceres.h:37,
from /home/niraj/imu_cam_calib/src/code_utils/include/code_utils/cv_utils/pnp/nonlinearpnp.h:4,
from /home/niraj/imu_cam_calib/src/code_utils/src/cv_utils/pnp/nonlinearpnp.cpp:1:
/usr/local/include/ceres/internal/fixed_array.h: In static member function ‘static constexpr bool ceres::internal::FixedArray<T, N, A>::DefaultConstructorIsNonTrivial()’:
/usr/local/include/ceres/internal/fixed_array.h:101:13: error: ‘is_trivially_default_constructible’ is not a member of ‘std’
return !std::is_trivially_default_constructible::value;
^
/usr/local/include/ceres/internal/fixed_array.h:101:67: error: expected primary-expression before ‘>’ token
return !std::is_trivially_default_constructible::value;
^
/usr/local/include/ceres/internal/fixed_array.h:101:68: error: ‘::value’ has not been declared
return !std::is_trivially_default_constructible::value;
^
[ 69%] Linking CXX static library /home/niraj/imu_cam_calib/devel/lib/libcv_utils.a
[ 69%] Built target cv_utils
In file included from /usr/local/include/ceres/internal/array_selector.h:38:0,
from /usr/local/include/ceres/internal/autodiff.h:148,
from /usr/local/include/ceres/autodiff_cost_function.h:130,
from /usr/local/include/ceres/ceres.h:37,
from /home/niraj/imu_cam_calib/src/code_utils/include/code_utils/cv_utils/pnp/nonlinearpnp.h:4,
from /home/niraj/imu_cam_calib/src/code_utils/include/code_utils/cv_utils/pnp/pnp.h:6,
from /home/niraj/imu_cam_calib/src/code_utils/src/cv_utils/pnp/pnp.cpp:1:
/usr/local/include/ceres/internal/fixed_array.h: In static member function ‘static constexpr bool ceres::internal::FixedArray<T, N, A>::DefaultConstructorIsNonTrivial()’:
/usr/local/include/ceres/internal/fixed_array.h:101:13: error: ‘is_trivially_default_constructible’ is not a member of ‘std’
return !std::is_trivially_default_constructible::value;
^
/usr/local/include/ceres/internal/fixed_array.h:101:67: error: expected primary-expression before ‘>’ token
return !std::is_trivially_default_constructible::value;
^
/usr/local/include/ceres/internal/fixed_array.h:101:68: error: ‘::value’ has not been declared
return !std::is_trivially_default_constructible::value;
^
code_utils/CMakeFiles/pnp.dir/build.make:134: recipe for target 'code_utils/CMakeFiles/pnp.dir/src/cv_utils/pnp/nonlinearpnp.cpp.o' failed
make[2]: *** [code_utils/CMakeFiles/pnp.dir/src/cv_utils/pnp/nonlinearpnp.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
[ 76%] Linking CXX executable /home/niraj/imu_cam_calib/devel/lib/code_utils/matIO_test
[ 84%] Linking CXX executable /home/niraj/imu_cam_calib/devel/lib/code_utils/sumpixel_test
[ 84%] Built target matIO_test
[ 84%] Built target sumpixel_test
/home/niraj/imu_cam_calib/src/code_utils/src/math_utils/Polynomial.cpp: In member function ‘double math_utils::Polynomial::getOneRealRoot(double, double, double)’:
/home/niraj/imu_cam_calib/src/code_utils/src/math_utils/Polynomial.cpp:91:1: warning: control reaches end of non-void function [-Wreturn-type]
}
^
code_utils/CMakeFiles/pnp.dir/build.make:86: recipe for target 'code_utils/CMakeFiles/pnp.dir/src/cv_utils/pnp/pnp.cpp.o' failed
make[2]: *** [code_utils/CMakeFiles/pnp.dir/src/cv_utils/pnp/pnp.cpp.o] Error 1
[ 92%] Linking CXX static library /home/niraj/imu_cam_calib/devel/lib/libpolynomial.a
[ 92%] Built target polynomial
CMakeFiles/Makefile2:531: recipe for target 'code_utils/CMakeFiles/pnp.dir/all' failed
make[1]: *** [code_utils/CMakeFiles/pnp.dir/all] Error 2
Makefile:138: recipe for target 'all' failed
make: *** [all] Error 2
Invoking "make -j8 -l8" failed
niraj@niraj-ThinkPad-L380-Yoga:~/imu_cam_calib$
`

@geturin
Copy link

geturin commented Oct 19, 2021

same problem

1 similar comment
@shuaixSu
Copy link

same problem

@GoldenBoylife
Copy link

GoldenBoylife commented Mar 29, 2023

me too

I recommend
in CMakeLists.txt

Change
set(CMAKE_CXX_FLAGS "-std=c++11")
to
set(CMAKE_CXX_STANDARD 14)

I solved

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

4 participants