Open EricCousineau-TRI opened 4 years ago
Still fine to improve the documentation, but a general tip: if you're not sure how to pass options to cmake
, run ccmake
instead and browse through the user interface. It works well.
Even updating the existing documentation would help, perhaps with a note that it will be improved later. I just got bit by this issue and was totally puzzled until I finally came accross this issue. A small note in the documentation would have helped.
This just bit me again today. Was following the instructions for building bindings and got the same error as Hongkai.
Relates to #12306 somewhat, as well.
I ran into this issue today
I also ran into this issue now!
Just ran into this issue as well.
It appears that the CMake file sets SNOPT_PATH to "SNOPT_PATH-NOTFOUND", like the string literal (unless I'm misunderstanding both the set
function and the error message).
I was able to fix it with a 1-line change to CMakeLists.txt (see patch below) that pulls from the environment variable instead (as per the documentation).
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -484,7 +484,7 @@ if(WITH_ROBOTLOCOMOTION_SNOPT OR WITH_SNOPT)
if(WITH_ROBOTLOCOMOTION_SNOPT)
string(APPEND BAZEL_REPO_ENV " --repo_env=SNOPT_PATH=git")
else()
- set(SNOPT_PATH SNOPT_PATH-NOTFOUND CACHE FILEPATH
+ set(SNOPT_PATH "$ENV{SNOPT_PATH}" CACHE FILEPATH
"Path to SNOPT source archive"
)
if(NOT EXISTS "${SNOPT_PATH}")
Per slack convo: https://drakedevelopers.slack.com/archives/C3YB3EV5W/p1570643928005400
\cc @jamiesnape