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

error occurs when trying to cmake a new project #349

Open
LMozart opened this issue Aug 7, 2019 · 3 comments
Open

error occurs when trying to cmake a new project #349

LMozart opened this issue Aug 7, 2019 · 3 comments

Comments

@LMozart
Copy link

LMozart commented Aug 7, 2019

I was trying to follow the tutorial to create a new plugin project. After generating a project by using script in the scripts folder, I started to cmake, but errors occurred.
`
CMake Error at CMakeLists.txt:79 (include):
include could not find load file:

GenerateSetEnv

CMake Error at CMakeLists.txt:80 (GenerateSetEnv):
Unknown CMake command "GenerateSetEnv".
`
Any suggestion?

@SyllogismRXS
Copy link
Contributor

Are you using Ubuntu? Were you able to build the core scrimmage project?

GenerateSetEnv is a CMake macro provided by the core scrimmage project (https://github.com/gtri/scrimmage/blob/master/share/cmake/scrimmage/GenerateSetEnv.cmake). When you run CMake in the core scrimmage project, it will make the GenerateSetEnv available to other CMake projects that first all find_package(scrimmage).

@SyllogismRXS
Copy link
Contributor

By default, when you run "cmake" in the scrimmage, the cmake project will create a folder at "~/.cmake/packages/scrimmage", which contains a file that points at your scrimmage build directory. This is how other scrimmage/cmake projects find the original scrimmage project.

@LMozart
Copy link
Author

LMozart commented Aug 8, 2019

Thanks for answering. I am able to build the core scrimmage and I am using Ubuntu. I followed the tutorial below: $ cd /path/to/scrimmage/scripts $ mkdir ~/scrimmage $ ./create-scrimmage-project.py my-scrimmage-plugins ~/scrimmage
http://www.scrimmagesim.org/sphinx/html/tutorials/create-project.html
So here is the problem. I think the cmake process in my new project has already found the scrimmage core code. But still can not use GenerateSetEnv.

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

2 participants