Makefile:138: 在安装TooN、libCVD和Gvars3时,目标'all'的配方出现错误。

问题描述 投票:1回答:1

我正在尝试安装TooN、libCVD和Gvars3,以满足我的需求。PTAM . 这个链接显示了推荐的安装步骤。我从安装

  • freeglut3-dev。
  • liblape-dev。
  • liblapack3。
  • libopenblas-base。
  • libopenblas-dev

使用 sudo apt-get install.

然后我安装了TooN。

git clone [email protected]:edrosten/TooN.git
cd TooN/
./configure && make && sudo make install

然后我用TooN的安装测试 make test 并通过了所有的测试。

slice Passed
vector_resize Passed
gauss_jordan Passed
chol_toon Passed
fill Passed
so3 Passed
complex Passed
gr_svd Passed
diagonal_matrix Passed
gaussian_elimination Passed
zeros Passed
swap Passed
initializer_list Passed
initializer_list_fail_1 Passed
initializer_list_fail_2 Passed
sim3 Passed
eigen-sqrt Passed
chol_lapack Passed
sym_eigen Passed
qr Passed
lu Passed
determinant Passed

然后我尝试安装libCVD。

cd ..
git clone [email protected]:edrosten/libcvd.git
cd libcvd/
./configure

输出的 ./configure 是如下的。

checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables... 
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking how to run the C preprocessor... gcc -E
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for ANSI C header files... yes
checking for gawk... no
checking for mawk... mawk
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking whether g++ supports C++14 features by default... no
checking whether g++ supports C++14 features with -std=gnu++14... yes
checking for a BSD-compatible install... /usr/bin/install -c
checking whether ln -s works... yes
checking for ranlib... ranlib
checking how to run the C++ preprocessor... g++ -E
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking if compiler flag -Wall works... yes
checking if compiler flag -Wextra works... yes
checking if compiler flag -pipe works... yes
checking for main in -lpthread... yes
checking if compiler flag -ggdb works... yes
checking if compiler flag -fPIC works... yes

------------------------------------
Checking processor specific features
------------------------------------

checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking whether byte ordering is bigendian... no
checking for MMX support... yes
checking for MMXEXT support... yes
checking for SSE support... yes
checking for SSE2 support... yes
checking for SSE3 support... yes
checking size of void*... 8
checking for inline asm statement... yes
checking assembler supports .type pseudo-op... yes

-----------------------------------------------
Checking for operating system specific features
-----------------------------------------------
checking dc1394/dc1394.h usability... yes
checking dc1394/dc1394.h presence... yes
checking for dc1394/dc1394.h... yes
checking for main in -ldc1394... yes
checking for v4l2... yes

-------------------------------
Checking for optional libraries
-------------------------------
checking for X... libraries , headers 
checking for glDrawPixels in -lGL... yes
checking GL/glu.h usability... yes
checking GL/glu.h presence... yes
checking for GL/glu.h... yes
checking for gluGetString in -lGLU... yes
checking for TooN... yes
checking libuvc/libuvc.h usability... no
checking libuvc/libuvc.h presence... no
checking for libuvc/libuvc.h... no
checking for uvc_stream_get_frame in -luvc... no
checking png.h usability... yes
checking png.h presence... yes
checking for png.h... yes
checking for png_init_io in -lpng... yes
checking jpeglib.h usability... yes
checking jpeglib.h presence... yes
checking for jpeglib.h... yes
checking for jpeg_destroy_decompress in -ljpeg... yes
checking JPEG read buffer size... 1 (safe reading)
checking tiffio.h usability... yes
checking tiffio.h presence... yes
checking for tiffio.h... yes
checking for TIFFReadRGBAImage in -ltiff... yes
checking for ffmpeg headers... checking for main in -lavutil... yes
checking for avformat_open_input in -lavformat... yes
checking for av_read_frame in -lavformat... yes
checking for avcodec_open2 in -lavcodec... yes
checking for sws_getContext in -lswscale... yes
checking for avdevice_register_all in -lavdevice... no
checking for doxygen... docs

-----------------------------------
Checking for platform compatibility
-----------------------------------
checking whether feenableexcept is declared... yes

--------------------------------
Checking for extra build options
--------------------------------


Options:
inline_asm assembler dc1394v2 v4l2buffer videodisplay toon png jpeg tiff

Missing options for linux-gnu:
ffmpeg libuvc

Dodgy things:



SIMD support:
mmx mmxext sse sse2 sse3

Missing SIMD support for x86_64-pc-linux-gnu:


-g -O2 -std=gnu++14 -Wall -Wextra -pipe -ggdb -fPIC -mmmx -msse -msse -msse2 -msse3

-ltiff -ljpeg -lpng -lGLU -lGL -ldc1394 -lpthread -lX11 -lXext
configure: creating ./config.status
config.status: creating Makefile
config.status: creating cvd/config.h
config.status: creating cvd_src/config_internal.h

然后我在运行时收到以下错误 make

g++  -I. -I.  -g -O2 -std=gnu++14 -Wall -Wextra -pipe -ggdb -fPIC -mmmx -msse -msse -msse2 -msse3 -c cvd_src/diskbuffer2.cc -o cvd_src/diskbuffer2.o -MMD -MP -MF cvd_src/diskbuffer2.d
In file included from ./cvd/image_ref.h:185:0,
                 from ./cvd/image.h:17,
                 from ./cvd/videoframe.h:13,
                 from ./cvd/localvideoframe.h:18,
                 from ./cvd/localvideobuffer.h:4,
                 from ./cvd/diskbuffer2.h:10,
                 from cvd_src/diskbuffer2.cc:2:
./cvd/internal/image_ref_implementation.hh: In member function ‘constexpr int& CVD::ImageRef::operator[](int)’:
./cvd/internal/image_ref_implementation.hh:194:1: error: expression ‘<throw-expression>’ is not a constant-expression
 }
 ^
./cvd/internal/image_ref_implementation.hh: In member function ‘constexpr int CVD::ImageRef::operator[](int) const’:
./cvd/internal/image_ref_implementation.hh:204:1: error: expression ‘<throw-expression>’ is not a constant-expression
 }
 ^
Makefile:271: recipe for target 'cvd_src/diskbuffer2.o' failed
make: *** [cvd_src/diskbuffer2.o] Error 1

我知道libCVD的主分支现在是libCVD-2.0,它是测试版,需要C++14。这个 ./congifure 显示 g++ supports C++14 features by default... no 是这个问题吗?

我也试着用CMAKE.NET来构建,但这次我又收到了一个错误:"我不知道该怎么做"。

mkdir build
cd build
cmake -DCMAKE_BUILD_TYPE=Release .. 
make 

这次我又收到了一个错误。

Scanning dependencies of target CVD
[  0%] Building CXX object CMakeFiles/CVD.dir/cvd_src/bayer.cxx.o
In file included from /home/csgurel/svo_install_overlay_ws/src/libcvd/cvd/image_ref.h:185:0,
                 from /home/csgurel/svo_install_overlay_ws/src/libcvd/cvd/image.h:17,
                 from /home/csgurel/svo_install_overlay_ws/src/libcvd/cvd/image_convert_fwd.h:4,
                 from /home/csgurel/svo_install_overlay_ws/src/libcvd/cvd/colourspace_convert.h:3,
                 from /home/csgurel/svo_install_overlay_ws/src/libcvd/cvd_src/bayer.cxx:3:
/home/csgurel/svo_install_overlay_ws/src/libcvd/cvd/internal/image_ref_implementation.hh: In member function ‘constexpr int& CVD::ImageRef::operator[](int)’:
/home/csgurel/svo_install_overlay_ws/src/libcvd/cvd/internal/image_ref_implementation.hh:194:1: error: expression ‘<throw-expression>’ is not a constant-expression
 }
 ^
/home/csgurel/svo_install_overlay_ws/src/libcvd/cvd/internal/image_ref_implementation.hh: In member function ‘constexpr int CVD::ImageRef::operator[](int) const’:
/home/csgurel/svo_install_overlay_ws/src/libcvd/cvd/internal/image_ref_implementation.hh:204:1: error: expression ‘<throw-expression>’ is not a constant-expression
 }
 ^
CMakeFiles/CVD.dir/build.make:62: recipe for target 'CMakeFiles/CVD.dir/cvd_src/bayer.cxx.o' failed
make[2]: *** [CMakeFiles/CVD.dir/cvd_src/bayer.cxx.o] Error 1
CMakeFiles/Makefile2:67: recipe for target 'CMakeFiles/CVD.dir/all' failed
make[1]: *** [CMakeFiles/CVD.dir/all] Error 2
Makefile:138: recipe for target 'all' failed
make: *** [all] Error 2

我知道这是一个很长的问题,但我试图提供尽可能多的信息,使其更容易排除故障。

linux installation ubuntu-16.04 linear-algebra
1个回答
0
投票

这不是问题的直接答案,这是不同的解决方案,也许会对未来的人有所帮助。

gptam这个项目基于PTAM,但不依赖TooN, libCVD和Gvars3,而是使用openCV。

© www.soinside.com 2019 - 2024. All rights reserved.