Centos6 3 原始碼級別編譯Caffe庫筆記

2021-07-30 17:45:11 字數 1982 閱讀 1372

編譯環境是:

[[email protected] caffe_prj]$ cat /etc/issue

centos release 6.3 (final)

kernel \r on an \m

[email protected] caffe_prj]$ gcc --version

gcc (gcc) 4.4.7 20120313 (red hat 4.4.7-18)

完成此次編譯需要的包見截圖:

編譯的流程參考:

因為我只需 cpu模式,所以直接從文中的  《6、安裝blas》開始執行

這裡首先一定要參考 說明書,確定要安裝的每個依賴包的版本問題!

問題之一:遇到安裝cmake的問題

問題之二:遇到安裝opencv的問題:

問題之三:遇到依賴atlas的問題:

還因為安裝了 yum install gcc-gfortran 解決gfortran問題,但是最後還是出現了:

.build_release/lib/libcaffe.so: undefined reference to `dgemm_'

.build_release/lib/libcaffe.so: undefined reference to `dscal_'

.build_release/lib/libcaffe.so: undefined reference to `sscal_'

.build_release/lib/libcaffe.so: undefined reference to `sdot_'

.build_release/lib/libcaffe.so: undefined reference to `daxpy_'

.build_release/lib/libcaffe.so: undefined reference to `dcopy_'

.build_release/lib/libcaffe.so: undefined reference to `sasum_'

.build_release/lib/libcaffe.so: undefined reference to `saxpy_'

.build_release/lib/libcaffe.so: undefined reference to `sgemm_'

.build_release/lib/libcaffe.so: undefined reference to `dasum_'

.build_release/lib/libcaffe.so: undefined reference to `ddot_'

.build_release/lib/libcaffe.so: undefined reference to `sgemv_'

.build_release/lib/libcaffe.so: undefined reference to `scopy_'

.build_release/lib/libcaffe.so: undefined reference to `dgemv_'

最後怎麼解決的呢,一行命令,與修改caffe-master/makefile:

sudo yum install atlas-devel

針對makefile:

針對makefile.config,做如下修改:

最後成功編譯完caffe:

centos6 3下編譯安裝MySQL

linux centos6.3下編譯安裝mysql具體步驟如下 2.解壓縮tar檔案至當前目錄mysql 5.5.28 tar zxvf mysql 5.5.28.tar.gz 3.安裝編譯工具及依賴庫 yum y install gcc gcc c cmake bison 4.新增mysql使用者...

在CentOS6 3上編譯gcc4 9

先安裝依賴專案 主要需要編譯gmp mpfr mpc isl glibc glibc與gcc一樣,不能在原始碼目錄下直接編譯。所以應該新建乙個目錄如obj,然後呼叫.src configure yum install flex bison 設定環境變數ld library path usr loca...

CentOS 6 3 安裝mongoDB隨筆

centos 6.3 安裝mongodb隨筆 全新centos 安裝 vi etc yum.repos.d 10gen.repo 10gen name 10gen repository baseurl gpgcheck 0 enabled 1 yum y install mongo 10gen mo...