しばらくの間this codeをコンパイルしようとしています。具体的には、指定されたmacを使用してavx2コードをコンパイルしようとしています。しかし、私はいつも次のエラーが発生しています。 私は多くを見上げましたが、解決策を見つけることができませんでした。私が解決策を見つける手助けをすれば、私はとてもうれしく思います。リンカーエラー:/ usr/bin/ld:-lcが見つかりません
/usr/bin/ld: cannot find -lc
collect2: error: ld returned 1 exit status
make: *** [test/test_kyber] Error 1
gccのバージョン
gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-11)
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
クランバージョン:makeコマンドを実行している
clang version 3.4.2 (tags/RELEASE_34/dot2-final)
Target: x86_64-redhat-linux-gnu
Thread model: posix
出力。
/usr/bin/gcc -Wall -Wextra -O3 -fomit-frame-pointer -msse2avx -mavx2 -march=native -static -o test/test_kyber kyber.c poly.c polyvec.c fips202.o fips202x4.c precomp.c ntt.c verify.c indcpa.c consts.c kex.c nttlevels0t4.s nttlevels5t7.s mul_coefficients.s polyvec_pointwise_acc.s poly_add.s poly_sub.s cbd.s poly_freeze.s crypto_stream_aes256ctr.c keccak4x/KeccakP-1600-times4-SIMD256.o randombytes.c test/test_kyber.c
/usr/bin/ld: cannot find -lc
collect2: error: ld returned 1 exit status
make: *** [test/test_kyber] Error 1
まあ、それは失敗です。 * scnr * ...しかし深刻なことに、 'llc'はあなたのtoolchainのインストールで深刻な問題のように聞こえます...あなたは**そのマシンで**何かをコンパイルすることさえできますか? –
通常、gccを使用します。そして、それは常に働いています。 – Rick
さて、あなたのリンクされたプロジェクトのMakefileは、特定の入力ファイルのセットに対して 'clang'するように配線されています(理由は分かりません)。 –