1

我正在尝试编译一个用 C++ 编写的程序,但我无法解决链接器的问题:

g++ -Wl,--export-dynamic  -Wl,-rpath,/home/*****/omnetpp-4.2.2/lib -Wl,-rpath,. -o ../out/gcc-debug//src/802.11n  ../out/gcc-debug//src/BCJR.o ../out/gcc-debug//src/Calcul_Metric_Checksum.o ../out/gcc-debug//src/Channel_802_11.o ../out/gcc-debug//src/Checksum.o ../out/gcc-debug//src/Deflate.o ../out/gcc-debug//src/Handle_checksum_error.o ../out/gcc-debug//src/Handle_CRC_error.o ../out/gcc-debug//src/Helper.o ../out/gcc-debug//src/Receiver.o ../out/gcc-debug//src/Scrambler_Soft.o ../out/gcc-debug//src/Stackchemin.o ../out/gcc-debug//src/Transmitter.o ../out/gcc-debug//src/Trellis_Calcul_Liste.o ../out/gcc-debug//src/APL_m.o ../out/gcc-debug//src/IPv6_m.o ../out/gcc-debug//src/MAC_m.o ../out/gcc-debug//src/PHY_PLCP_m.o ../out/gcc-debug//src/PHY_PMD_m.o ../out/gcc-debug//src/RTP_m.o ../out/gcc-debug//src/Soft_bits_m.o ../out/gcc-debug//src/UDP_m.o  -Wl,--no-as-needed -Wl,--whole-archive  -Wl,--no-whole-archive -L"/home/gueguet/omnetpp-4.2.2/lib/gcc" -L"/home/gueguet/omnetpp-4.2.2/lib" -loppmaind -u _tkenv_lib -Wl,--no-as-needed -lopptkenvd -loppenvird -lopplayoutd -u _cmdenv_lib -Wl,--no-as-needed -loppcmdenvd -loppenvird  -loppsimd -ldl -lstdc++  `pkg-config --cflags itpp` `pkg-config --libs itpp` 
/usr/bin/ld: ../out/gcc-debug//src/Handle_checksum_error.o: undefined reference to symbol 'dcopy_'
/usr/bin/ld: note: 'dcopy_' is defined in DSO /usr/lib/libblas.so.3gf so try adding it to the linker command line
/usr/lib/libblas.so.3gf: could not read symbols: Invalid operation
collect2: ld a retourné 1 code d'état d'exécution
make: *** [../out/gcc-debug//src/802.11n] Erreur 1

谁能帮帮我?提前非常感谢。

4

1 回答 1

2

我可能会建议仔细阅读您收到的错误报告。他们提供了很好的信息来提供帮助。

Handle_checksum_error.o: undefined reference to symbol 'dcopy_'
note: 'dcopy_' is defined in DSO /usr/lib/libblas.so.3gf 
so try adding it to the linker command line
于 2013-01-26T23:04:25.583 回答