@aiueo_aiueo (nakata fumiya)

Are you sure you want to delete the question?

If your question is resolved, you may close it.

Leaving a resolved question undeleted may help others!

We hope you find it useful!

MacOS M1でのC言語のエラーについて

MacOS M1でのC言語のエラーについて

C言語のコンパイルが通らなく困っています。
助けてください。
エラーは調べたのですが難しく優しく教えていただければと思います。
M1だからなのかなとも思いましたが、一人で考えていても解決しないので協力していただけると幸いです。

発生している問題・エラー

Undefined symbols for architecture arm64:
  "_createEnv", referenced from:
      _main in main-67057a.o
  "_createRewardFunction", referenced from:
      _main in main-67057a.o
  "_destroyEnv", referenced from:
      _main in main-67057a.o
  "_destroyRewardFunction", referenced from:
      _main in main-67057a.o
  "_judgeGoalPos", referenced from:
      _main in main-67057a.o
  "_move", referenced from:
      _main in main-67057a.o
  "_perceptive", referenced from:
      _main in main-67057a.o
  "_rewardFunction", referenced from:
      _main in main-67057a.o
  "_setStartPos", referenced from:
      _main in main-67057a.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

自分で試したこと

homebrewをインストールし、gccをインストールしました。
コードはvscodeで書いています。
コンパイルはターミナルでしています。
ぜひよろしくお願いいたします。

0 likes

No Answers yet.

Your answer might help someone💌