1. Ruben Martinez-Cantin
  2. BayesOpt

Commits

Ruben Martinez-Cantin  committed 613cc95

Fixing problem in UseDoxygen.cmake with CMake greater than 3.0

  • Participants
  • Parent commits c209ea9
  • Branches default

Comments (0)

Files changed (2)

File CMakeLists.txt

View file
     SET_TARGET_PROPERTIES(esopt PROPERTIES PREFIX "libbay" SUFFIX ".dll")
   ENDIF()
 
+  #Find where to install Python libs
+  execute_process ( COMMAND 
+         python -c "from distutils.sysconfig import get_python_lib; print get_python_lib()" 
+         OUTPUT_VARIABLE PYTHON_SITE_PACKAGES OUTPUT_STRIP_TRAILING_WHITESPACE)
+
   INSTALL(
     TARGETS esopt
-    LIBRARY DESTINATION lib
-    ARCHIVE DESTINATION lib
+    LIBRARY DESTINATION ${PYTHON_SITE_PACKAGES}
+    ARCHIVE DESTINATION ${PYTHON_SITE_PACKAGES}
   )
 ENDIF(BAYESOPT_PYTHON_INTERFACE)

File cmake/UseDoxygen.cmake

View file
 
 	configure_file("${DOXYFILE_IN}" "${DOXYFILE}" @ONLY)
 
-	get_target_property(DOC_TARGET doc TYPE)
-	if(NOT DOC_TARGET)
-		add_custom_target(doc)
+	IF(NOT TARGET doc)
+	       add_custom_target(doc)
 	endif()
 
 	add_dependencies(doc doxygen)