diff --git a/CMakeLists.txt b/CMakeLists.txt index a9966f5d3..f5b9c5e22 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -455,10 +455,8 @@ if (GTSAM_INSTALL_CYTHON_TOOLBOX) set(GTSAM_INSTALL_CYTHON_TOOLBOX 1) # Set up cache options # Cython install path appended with Build type (e.g. cython, cythonDebug, etc). - set(GTSAM_CYTHON_INSTALL_PATH "" CACHE PATH "Cython toolbox destination, blank defaults to PROJECT_BINARY_DIR/cython") - if(NOT GTSAM_CYTHON_INSTALL_PATH) - set(GTSAM_CYTHON_INSTALL_PATH "${PROJECT_BINARY_DIR}/cython${GTSAM_BUILD_TAG}" CACHE PATH "") - endif() + # This does not override custom values set from the command line + set(GTSAM_CYTHON_INSTALL_PATH "${PROJECT_BINARY_DIR}/cython${GTSAM_BUILD_TAG}" CACHE PATH "Cython toolbox destination, blank defaults to PROJECT_BINARY_DIR/cython") set(GTSAM_EIGENCY_INSTALL_PATH ${GTSAM_CYTHON_INSTALL_PATH}/gtsam_eigency) add_subdirectory(cython ${GTSAM_CYTHON_INSTALL_PATH}) else()