diff --git a/cmake/modules/FindOASES.cmake b/cmake/modules/FindOASES.cmake deleted file mode 100644 index bcddfd3..0000000 --- a/cmake/modules/FindOASES.cmake +++ /dev/null @@ -1,62 +0,0 @@ -# Find the OASES includes and libraries. -# The following variables are set if OASES is found. If OASES is not -# found, OASES_FOUND is set to false. -# OASES_FOUND - True when the OASES include directory is found. -# OASES_INCLUDE_DIRS - the path to where the OASES include files are. -# OASES_LIBRARY_DIRS - The path to where the OASES library files are. -# OASES_LIBRARIES - The libraries to link against OASES - -# One may want to use a specific OASES Library by setting -# OASES_LIBRARY_DIRECTORY before FIND_PACKAGE(OASES) -INCLUDE(FindPackageHandleStandardArgs) - -IF(APPLE) - set (extension ".dylib") -ELSEIF(WIN32) - set (extension ".lib") #On Windows, load-time dynamic linking links to the .lib before using the dll at runtime -ELSE(WIN32) - set (extension ".so") -ENDIF(APPLE) - -IF(OASES_LIBRARY_DIRECTORY) - MESSAGE(STATUS "Looking for OASES library libqpOASES${extension} in ${OASES_LIBRARY_DIRECTORY}bin/") - FIND_LIBRARY(OASES_LIBRARY libqpOASES${extension} PATHS "${OASES_LIBRARY_DIRECTORY}bin/" NO_DEFAULT_PATH) - IF(OASES_LIBRARY) - MESSAGE(STATUS "Found : OASES_LIBRARY") - ENDIF(OASES_LIBRARY) -ELSE(OASES_LIBRARY_DIRECTORY) - FIND_LIBRARY(OASES_LIBRARY libqpOASES${extension} PATHS ENV LD_LIBRARY_PATH ENV DYLD_LIBRARY_PATH) -ENDIF(OASES_LIBRARY_DIRECTORY) - -FIND_PACKAGE_HANDLE_STANDARD_ARGS(qpOASES - REQUIRED_VARS OASES_LIBRARY) - - -IF(OASES_LIBRARY) - SET(OASES_LIBRARIES ${OASES_LIBRARY}) - GET_FILENAME_COMPONENT(OASES_LIBRARY_NAME ${OASES_LIBRARY} NAME) - GET_FILENAME_COMPONENT(OASES_LIBRARY_DIRS ${OASES_LIBRARY} PATH) - GET_FILENAME_COMPONENT(OASES_LIBRARY_DIRS_DIR ${OASES_LIBRARY_DIRS} PATH) - GET_FILENAME_COMPONENT(OASES_LIBRARY_DIRS_DIR_DIR ${OASES_LIBRARY_DIRS_DIR} PATH) - - FIND_PATH(OASES_INCLUDE_DIRS qpOASES.hpp - HINTS ${OASES_LIBRARY_DIRS_DIR} ${OASES_LIBRARY_DIRS_DIR_DIR} - ENV PATH - PATH_SUFFIXES include) - - IF(NOT OASES_INCLUDE_DIRS) - IF(OASES_FIND_REQUIRED) - MESSAGE(FATAL_ERROR - "Required OASES headers not found. Please specify headers location in CMAKE_INCLUDE_PATH") - ENDIF(OASES_FIND_REQUIRED) - ELSE(NOT OASES_INCLUDE_DIRS) - SET(OASES_FOUND TRUE) - ENDIF(NOT OASES_INCLUDE_DIRS) - -ELSE(OASES_LIBRARY) - SET(OASES_FOUND FALSE) - IF(OASES_FIND_REQUIRED) - MESSAGE(FATAL_ERROR - "Required OASES library not found. Please specify library location in OASES_LIBRARY_DIRECTORY") - ENDIF(OASES_FIND_REQUIRED) -ENDIF(OASES_LIBRARY)