Closed BSVogler closed 2 years ago
Instead of compiling the application in cmake/, then moving the application and inputfiles/ to bin/, why don't you directly compile inside bin/?
Just FYI, ever since making the move to CMake, I am no longer using the directory bin/. By usual build directory is called build/ nowadays. I assume that you chose bin/ as build directory, because that's where the old Makefile used to place the executable.
The application (if compiled with ABS_RESOURCE_PATH=OFF) will expect inputfiles/ in the current working directory. If you're running the application from the root folder but inputfiles/ is in the build folder, then you would expect to run into issues. However, since the original inputfiles/ is located inside the root folder, you will actually not have any issues.
Instead of compiling the application in cmake/, then moving the application and inputfiles/ to bin/, why don't you directly compile inside bin/?
build
is for building why bin
is for the build result. So compiling should not happen inside bin
.
Every Cmake tutorial I've read (including the official one) places the executable in the build folder. Unless you see a benefit in moving the executable to bin/ after every compilation, I suggest changing the path from bin/ to build/ (or build-web/ for example). As far as I see, keeping a bin folder around is altogether unnecessary and counter to Cmake's philosophy of creating compartmentalised out-of-source builds.
Assuming the inputfile dir is needed alongside the molovol bin and they not included in the binary. If this is wrong I need to modify the file.