1

我一直在尝试使用以下命令编译我的 C++ 程序:

g++ -g -O0 -fopenmp -L/home/donkokse/development/workspace -o "NS_Solver" $(OBJS) $(USER_OBJS) $(LIBS)

LIBS := -lgomp /usr/lib/liblapack.so /usr/lib/libblas.so /home/harry/development/libpardiso412-GNU443-X86-64.so

在 Ubuntu 13.04 下,64 位。问题是我仍然不断收到以下错误消息:

/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `_gfortran_concat_string'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dtrmm_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `lsame_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dlartg_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dswap_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dgemm_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dger_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `GOMP_loop_dynamic_next'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `GOMP_single_start'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dgels_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dlartv_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `zscal_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `zlaev2_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `sswap_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `GOMP_parallel_end'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `izamax_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `zgetrf_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dsteqr_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `slaswp_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dtrsv_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dsyr_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `omp_get_thread_num_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `zsyr_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `zgeru_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `sscal_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dlaswp_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `zgemm_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dgeev_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `GOMP_atomic_end'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dscal_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `zdscal_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `ilaenv_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `zgemv_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dgetrf_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `isamax_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `zlacgv_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `omp_get_num_threads_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dsyevr_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `zpotf2_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `sgemm_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `omp_get_num_threads'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dsyr2k_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `ssyr_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dsytri_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `sgetrf_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `GOMP_critical_name_start'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dtrsm_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dlascl_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `idamax_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dpotrf_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dorgtr_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `GOMP_loop_end_nowait'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `GOMP_loop_end'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dsytd2_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `GOMP_critical_start'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dsytrf_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `zher_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dggev_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `omp_get_wtime_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `zrot_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `GOMP_critical_name_end'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `_gfortran_exit_i4'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dlatrd_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `GOMP_critical_end'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dlapy2_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `zlaswp_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `GOMP_atomic_start'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `zswap_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `xerbla_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dormqr_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `GOMP_barrier'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dgeqrf_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dgemv_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `sgemv_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dsterf_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `GOMP_parallel_start'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dlamch_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `ztrsm_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `sger_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `strsm_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `_gfortran_os_error'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `omp_get_thread_num'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dgetrs_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `GOMP_loop_dynamic_start'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dgetri_'
/home/harry/development/libpardiso412-GNU443-X86-64.so: undefined reference to `dlansy_'
collect2: error: ld returned 1 exit status
make: *** [NS_Solver] Error 1

它似乎找到了图书馆。我尝试了不同的方法,例如重新安装库、更改库的顺序、检查我是否真的有它们的 64 位版本

objdump -a /usr/lib/libblas.so

以及 http://www.ibm.com/developerworks/aix/library/au-portfortan.html#ur页面上“库的递归引用”中的建议,尽管分组不适用于 g++。还有什么可能是错的?我还尝试为 Theano 安装编译一个优化版本的 openMP(虽然是不同的项目)。难道这会以某种方式弄乱我的openMP吗?我该如何测试呢?我想再次删除该优化版本并从突触包管理器安装一个。我怎样才能做到这一点?

4

0 回答 0