diff --git a/cmake_support/FindOPENSTRUCTURE.cmake b/cmake_support/FindOPENSTRUCTURE.cmake index 7db271fa82e4c3e6360fefaeb673f271a225b3a2..0ce10c04cb581772fb7ee024b3fb18b427541969 100644 --- a/cmake_support/FindOPENSTRUCTURE.cmake +++ b/cmake_support/FindOPENSTRUCTURE.cmake @@ -17,7 +17,7 @@ #------------------------------------------------------------------------------- macro(find_OPENSTRUCTURE OST_ROOT NAMES HEADER_NAMES PYMOD_NAME) - if (NOT OPENSTRUCTURE_FIND_COMPONENTS) + if(NOT OPENSTRUCTURE_FIND_COMPONENTS) message(FATAL_ERROR "Please specify which modules of OpenStructure you " "would like to use after the COMPONENTS keyword.") endif() @@ -32,8 +32,8 @@ macro(find_OPENSTRUCTURE OST_ROOT NAMES HEADER_NAMES PYMOD_NAME) PATH_SUFFIXES lib lib64 NO_SYSTEM_ENVIRONMENT_PATH NO_DEFAULT_PATH ) - if (NOT FOUND_LIB) - if (OPENSTRUCTURE_FIND_REQUIRED) + if(NOT FOUND_LIB) + if(OPENSTRUCTURE_FIND_REQUIRED) message(FATAL_ERROR "Could not find library ost_${LIB}. Please specify" " the location of your OpenStructure installation with" " OST_ROOT") @@ -56,7 +56,7 @@ macro(find_OPENSTRUCTURE OST_ROOT NAMES HEADER_NAMES PYMOD_NAME) PATH_SUFFIXES lib lib64 ) if(NOT OST_PYMOD_PATH) - if (OPENSTRUCTURE_FIND_REQUIRED) + if(OPENSTRUCTURE_FIND_REQUIRED) message(FATAL_ERROR "Could not find Python module of OST. " "Please specify the location of your OST " "installation with OST_ROOT") @@ -65,7 +65,7 @@ macro(find_OPENSTRUCTURE OST_ROOT NAMES HEADER_NAMES PYMOD_NAME) # compounds.chemlib # if no -DCOMPOUND_LIB is given, try to find it in OST_ROOT - if (COMPOUND_LIB) + if(COMPOUND_LIB) if(NOT EXISTS "${COMPOUND_LIB}") message(FATAL_ERROR "Could not find compound library at '${COMPOUND_LIB}'") @@ -73,7 +73,7 @@ macro(find_OPENSTRUCTURE OST_ROOT NAMES HEADER_NAMES PYMOD_NAME) if(NOT IS_ABSOLUTE "${COMPOUND_LIB}") get_filename_component(COMPOUND_LIB "${COMPOUND_LIB}" ABSOLUTE) endif(NOT IS_ABSOLUTE "${COMPOUND_LIB}") - set(OST_COMPOUNDS_CHEMLIB_PATH "${COMPOUND_LIB}") + set(OST_COMPOUNDS_CHEMLIB_PATH "\\\\\\\\\"${COMPOUND_LIB}\\\\\\\\\"") else(COMPOUND_LIB) set(_clib_name "compounds.chemlib") find_path_recursive(OST_COMPOUNDS_CHEMLIB_PATH @@ -93,7 +93,7 @@ macro(find_OPENSTRUCTURE OST_ROOT NAMES HEADER_NAMES PYMOD_NAME) endif(COMPOUND_LIB) set(OPENSTRUCTURE_FOUND 1) -endmacro() +endmacro(find_OPENSTRUCTURE) #------------------------------------------------------------------------------- SET(LIBNAMES @@ -125,11 +125,11 @@ mark_as_advanced( OST_COMPOUNDS_CHEMLIB_PATH ) -if (OPENSTRUCTURE_FOUND) - if (NOT OPENSTRUCTURE_FIND_QUIETLY) - endif () -else (OPENSTRUCTURE_FOUND) - if (OPENSTRUCTURE_FIND_REQUIRED) +if(OPENSTRUCTURE_FOUND) + if(NOT OPENSTRUCTURE_FIND_QUIETLY) + endif() +else(OPENSTRUCTURE_FOUND) + if(OPENSTRUCTURE_FIND_REQUIRED) message(FATAL_ERROR "Could not find OpenStructure") - endif () -endif () + endif() +endif()