Closed grim-yawn closed 8 years ago
Well, actually it's not supposed to be installed at the moment. The most common use scenario is the following:
mkdir -p build
cd build
cmake ..
make
cd -
./build/gcm3d ...
This
fls.addPath("./src/launcher/");
provides a way to load standard log4cxx configuration file when using described scenario.
But anyway I do not see any problem with CONFIG_SHARE_GCM:
❯ rm -rf build
❯ mkdir build
❯ cd build
build❯ cmake ..
-- The C compiler identification is GNU 6.1.1
-- The CXX compiler identification is GNU 6.1.1
...
-- Configuring done
-- Generating done
-- Build files have been written to: /home/lx/work/mipt/gcm-3d/build
build❯ grep SHARE generated_sources/libgcm/config.hpp#define CONFIG_SHARE_GCM
"/usr/local/share/gcm3d"
Yes, CONFIG_SHARE_GCM is not empty string, but directory /usr/local/share/gcm3d does not exist.
P.S. It's working only when program working directory is 'gcm-3d'.
fls.addPath("./src/launcher/");
Yes, CONFIG_SHARE_GCM is not empty string, but directory /usr/local/share/gcm3d does not exist.
Exactly. Because this path should be created when make install
is invoked, but as I said earlier installation is not working at the moment (or at least is completely untested).
P.S. It's working only when program working directory is 'gcm-3d'. fls.addPath("./src/launcher/");
That's why I said about most common use scenario. gcm3d searches for log4cxx configuration at following paths:
CUR_DIR
/src/launcher ;So, to sum things up: it's done this way because it covers the most common usage scenario. I'm not saying it's perfect, but it works. Feel free to send a pull request if you're ready to get rid of this (to tell the truth) hardcoded path.
I understood. Thank you!