Another mistake a stupid person might make (don’t ask me how I know) during the tutorial, would be to initially
cd Step1_build cmake ../Step1/CMakeLists.txt
which creates the make file and other shiz in the Step1 folder instead of the Step1_build folder, inadvertently polluting the source folder with build artefacts.
Reading the code in cmProjectCommand.cxx I notice it is written in a complicated way in order to accept a more general grammar for project() than the documentation indicates: the clauses after the project name can be in any order, possibly with languages interspersed, so this is accepted:
project(Tutorial LANGUAGES C ASM HOMEPAGE_URL cmake.org DESCRIPTION "cmake tutorial" CXX VERSION 1.0 )
Then someone might add OBJC as another language
project(Tutorial LANGUAGES C ASM HOMEPAGE_URL cmake.org DESCRIPTION "cmake tutorial" CXX OBJC VERSION 1.0 )
and then run
again from the Step1_build directory. No error, cmake saying “Check for working OBJC compiler: /usr/bin/clang - skipped)”.
But then when I was still in Step1_build I cleaned out cmake’s previous workings and ran a fresh cmake
rm -r * cmake ../Step1
and got the error
The Objective-C compiler "/usr/bin/cc" is not able to compile a simple test program.
I don’t have a working OBJC compiler so this is as expected (AFAIK since I was unable to compile hello world .m)