我正在尝试在ubuntu 18.04下安装Oce。当我尝试构建时;cmake";一切正常,
-- The C compiler identification is GNU 7.5.0
-- The CXX compiler identification is GNU 7.5.0
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- 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
-- Info. Detecting doxygen
-- Found Doxygen: /usr/bin/doxygen (found suitable version "1.8.13", minimum required is "1.8.4") found components: doxygen
-- Info. Doxygen is found and can be used
-- Info. Overview building is turned on
-- Info: TCL is used by OCCT
-- Found Tclsh: /usr/bin/tclsh (found version "8.6")
-- Info: TCL version isn't found
-- Info: TK is used by OCCT
-- Info: TK version isn't found
-- Info: Freetype is used by OCCT
-- Found Freetype: /usr/lib/x86_64-linux-gnu/libfreetype.so (found version "2.8.1")
-- Info: TKIVtk and TKIVtkDraw toolkits excluded due to VTK usage is disabled
-- Info: The directories of 3rdparty headers:
/usr/include/tcl
/usr/include/freetype2
-- Info: The directories of 3rdparty libraries:
/usr/lib/x86_64-linux-gnu
--
Info: (16:40:22) Start collecting all OCCT header files into /scratch/rsayoud/Documents/Software_Packages/oce_folder/build/oce-last/inc ...
-- Info: (16:40:22) Compare FILES with files in package directories...
-- Info: (16:40:28) Create header-links in inc folder...
-- Info: (16:40:29) Checking headers in inc folder...
-- Info: (16:40:30) End the collecting
-- Info: (16:40:30) OCCT toolkits processed
-- Info: (16:40:30) OCCT configuration files prepared
-- Configuring done
-- Generating done
-- Build files have been written to: /scratch/rsayoud/Documents/Software_Packages/oce_folder/build/oce-last
然后当我运行"make"时,它开始很好,直到17%,我认为有些文件存在链接问题,
[ 17%] Building CXX object src/TKService/CMakeFiles/TKService.dir/__/Font/Font_SystemFont.cxx.o
[ 17%] Building CXX object src/TKService/CMakeFiles/TKService.dir/__/Font/Font_TextFormatter.cxx.o
[ 17%] Linking CXX shared library ../../lin64/gcc/lib/libTKG3d.so
[ 17%] Built target TKG3d
Scanning dependencies of target TKGeomBase
[ 17%] Linking CXX shared library ../../lin64/gcc/lib/libTKService.so
/usr/bin/ld : cannot find -lXi
collect2: error: ld returned 1 exit status
src/TKService/CMakeFiles/TKService.dir/build.make:2568: recipe for target 'lin64/gcc/lib/libTKService.so.7.6.0' failed
make[2]: *** [lin64/gcc/lib/libTKService.so.7.6.0] Error 1
CMakeFiles/Makefile2:1188: recipe for target 'src/TKService/CMakeFiles/TKService.dir/all' failed
make[1]: *** [src/TKService/CMakeFiles/TKService.dir/all] Error 2
你知道怎么解决这个问题吗?提前谢谢。
您可能缺少一个提供libXi.so
库的包。你可以用apt-file
找到你需要的包裹,即:
$ apt-file search libXi.so
libxi-dev: /usr/lib/x86_64-linux-gnu/libXi.so
在这种情况下,安装libxi-dev
软件包应该可以解决此问题。
问题是我需要安装丢失的libxi-dev包(该软件的要求中没有描述(。