Hello world Cmake error. The source directory "/work" does not appear to contain CMakeLists.txt.
Following the instructions of the hello-world tutorial. I get the following error:
Not searching for unused variables given on the command line.
CMake Error: The source directory "/work" does not appear to contain CMakeLists.txt.
Specify --help for usage, or press the help button on the CMake GUI.
ninja: fatal: invalid -j parameter
😵 undefined
My system:
- Fedora 42
- Docker 4.37.1
- npm 10.9.2
I am not aware what happens in the Docker images but it doesn't seem to copy the CMakeLists.txt into the docker image?
My directory contains when I run the instructions (setup and build):
-rw-r--r--. 1 89 Jul 30 11:49 CMakeLists.txt
-rw-r--r--. 1 96 Jul 30 11:56 hello.cxx
Hi @cvisl thanks for the report.
Major updates to the hello-world tutorial is a WIP here: https://github.com/InsightSoftwareConsortium/ITK-Wasm/pull/1433
Hey @thewtex thanks for the swift reply!
I tried the create-itk-wasm method but this one also trips over an error, a different one:
/home/****/test/itk-wasm-test/native/ITK/Modules/ThirdParty/MINC/src/libminc/libcommon/ParseArgv.c:330:18: error: too many arguments to function ‘handlerProc’; expected 0, have 4
330 | argc = (*handlerProc)(infoPtr->dst, infoPtr->key,
| ~^~~~~~~~~~~~~ ~~~~~~~~~~~~
Is that something you came across before? Might be a system dependency which is of a different version?
@cvisl sorry for the delayed reply. I will look into this over the coming days.
I tested it on a Ubuntu system as well and I got a bit further but I got the following error there:
CMake Error at test/CMakeLists.txt:1 (add_executable):
The target name "test" is reserved when CTest testing is enabled.
On the configure-native task. This might be related to the cmake version I am using, 3.28.3.
The "old way" (aka the current documentation) seems to work on a Ubuntu system.
@cvisl I just released a new version of create-itk-wasm. Do you still get errors with this new version?