Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Where is the definition of COIN_DATADIR? #490

Open
jiapei100 opened this issue Oct 3, 2022 · 2 comments
Open

Where is the definition of COIN_DATADIR? #490

jiapei100 opened this issue Oct 3, 2022 · 2 comments

Comments

@jiapei100
Copy link

[ 43%] Building CXX object src/misc/CMakeFiles/misc.dir/CoinResources.cpp.o
cd ....../coin/build_22.04/src/misc && /usr/bin/c++  -I....../coin/build_22.04/data -I....../coin/include/Inventor/annex -I....../coin/src -I....../coin/build_22.04/src -I....../coin/include -I....../coin/build_22.04/include -O3 -DNDEBUG -fPIC -DHAVE_CONFIG_H -DCOIN_INTERNAL -DCOIN_DEBUG=0 -MD -MT src/misc/CMakeFiles/misc.dir/CoinResources.cpp.o -MF CMakeFiles/misc.dir/CoinResources.cpp.o.d -o CMakeFiles/misc.dir/CoinResources.cpp.o -c ....../coin/src/misc/CoinResources.cpp
....../coin/src/misc/CoinResources.cpp: In function ‘SbByteBuffer CoinResources::get(const char*)’:
....../coin/src/misc/CoinResources.cpp:225:48: error: ‘COIN_DATADIR’ was not declared in this scope
  225 |       filename.sprintf("%s/%s/%s", coindirenv, COIN_DATADIR, resloc + 5);
      |                                                ^~~~~~~~~~~~
make[2]: *** [src/misc/CMakeFiles/misc.dir/build.make:541: src/misc/CMakeFiles/misc.dir/CoinResources.cpp.o] Error 1
make[2]: Leaving directory '....../coin/build_22.04'
make[1]: *** [CMakeFiles/Makefile2:1441: src/misc/CMakeFiles/misc.dir/all] Error 2
make[1]: Leaving directory '....../coin/build_22.04'
make: *** [Makefile:149: all] Error 2
@VolkerEnderlein
Copy link
Collaborator

Can you share the build commands you are using to build coin? Please add the information about platform and compiler you're using. When using CMake COIN_DATADIR should be set to the contents of CMAKE_INSTALL_DATADIR when processing the file src\config.h.cmake.in in src\CMakeLists.txt.

@bogdan-neagu-lh
Copy link

bogdan-neagu-lh commented Aug 29, 2023

I get the same error using Visual Studio 2010. I did not run any cmake command.

1> CoinResources.cpp
1>....\src\misc\CoinResources.cpp(225): error C2065: 'COIN_DATADIR' : undeclared identifier

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants