xcodebuild failure clang:error no such file or directory:

前端 未结 9 2229
伪装坚强ぢ
伪装坚强ぢ 2021-01-01 21:50

Having a problem when building with xcodebuild. My project/app builds fine with the Xcode - gui. It simply isn\'t finding/building the libcryptopp library which is part of t

9条回答
  •  再見小時候
    2021-01-01 22:51

    In Xcode Version 9.2 (9C40b) this happened when I drug a bunch of files into the project, some of which were duplicate. Rather than simply not adding the duplicates, it added them again and only the name, not the path.

    In Target > Build Phases > Compile Sources each of the duplicates showed with no "...in" after them. Each one caused the clang error.

    After removing all of the duplicates that Xcode collected, the project compiled and ran.

    It makes you use the Project Navigator instead of managing your source files in the Finder. Then the Project Navigator can't replace duplicates like any decent file management system (ahem Finder).

提交回复
热议问题