Changeset: c5802257c639 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=c5802257c639
Modified Files:
        CMakeLists.txt
Branch: cmake-fun
Log Message:

Missing checks.


diffs (48 lines):

diff --git a/CMakeLists.txt b/CMakeLists.txt
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -298,7 +298,8 @@ endif()
 
 if(MSVC) # Remove existing -Ox flags
        removeCompilerFlag("/O[0-1sS]+[ ]?" "/Ox" "${CMAKE_C_FLAGS_DEBUG}" 
"Debug" CMAKE_C_FLAGS_DEBUG)
-       addCompilerFlag("/O2" "/O2" "${CMAKE_C_FLAGS_RELEASE}" 
CMAKE_C_FLAGS_RELEASE)
+       removeCompilerFlag("/O[0-1sS]+[ ]?" "/Ox" "${CMAKE_C_FLAGS_RELEASE}" 
"Release" CMAKE_C_FLAGS_RELEASE)
+       addCompilerFlag("/O2" "/O2" "${CMAKE_C_FLAGS_RELEASE}" "Release" 
CMAKE_C_FLAGS_RELEASE)
 else()
        removeCompilerFlag("-O[0-2sS]+[ ]?" "-Ox" "${CMAKE_C_FLAGS_DEBUG}" 
"Debug" CMAKE_C_FLAGS_DEBUG)
        removeCompilerFlag("-O[0-2sS]+[ ]?" "-Ox" "${CMAKE_C_FLAGS_RELEASE}" 
"Release" CMAKE_C_FLAGS_RELEASE)
@@ -1135,7 +1136,11 @@ endif()
 
 function(testPythonIntegration HAVE_NUMPY PY_INCLUDES PY_LIBS PY_VERSION 
INTEGRATION_ENABLED INTERPRETER_PATH INTERPRETER_CONFIG)
        if(NOT HAVE_PYTHON${PY_VERSION})
-               message(FATAL_ERROR "A valid python${PY_VERSION} interpreter is 
required")
+               if(${INTEGRATION_ENABLED} STREQUAL "AUTO")
+                       message(WARNING "A valid python${PY_VERSION} 
interpreter is required")
+               else()
+                       message(FATAL_ERROR "A valid python${PY_VERSION} 
interpreter is required")
+               endif()
        endif()
 
        if(${INTERPRETER_CONFIG} STREQUAL "AUTO")
@@ -1147,7 +1152,11 @@ function(testPythonIntegration HAVE_NUMP
        message(STATUS "Checking python${PY_VERSION}-config program")
        exec_program("${PY_CONFIG_FILE}" ARGS "--ldflags" OUTPUT_VARIABLE 
PC_OUTPUT RETURN_VALUE PC_RETURN_CODE)
        if(NOT PC_RETURN_CODE EQUAL 0)
-               message(FATAL_ERROR "python${PY_VERSION}-config library 
required for Python ${PY_VERSION} integration support")
+               if(${INTEGRATION_ENABLED} STREQUAL "AUTO")
+                       message(WARNING " python${PY_VERSION}-config library 
required for Python ${PY_VERSION} integration support")
+               else()
+                       message(FATAL_ERROR "python${PY_VERSION}-config library 
required for Python ${PY_VERSION} integration support")
+               endif()
        endif()
 
        message(STATUS "Checking for numpy version")
@@ -1281,7 +1290,7 @@ if(NOT ${ENABLE_ODBC} STREQUAL "NO")
 
                set(CMAKE_EXTRA_INCLUDE_FILES 
"${CMAKE_EXTRA_INCLUDE_FILES};sql.h")
                check_type_size(SQLWCHAR SIZEOF_SQLWCHAR LANGUAGE C)
-               if(NOT HAVE_SIZEOF_SQLWCHAR OR ${SIZEOF_SQLWCHAR} STREQUAL "0")
+               if(NOT HAVE_SIZEOF_SQLWCHAR OR "${SIZEOF_SQLWCHAR}" STREQUAL 
"0")
                        if(${WITH_UNIXODBC} STREQUAL "YES")
                                message(FATAL_ERROR "could not determine the 
size of SQLWCHAR")
                        else()
_______________________________________________
checkin-list mailing list
checkin-list@monetdb.org
https://www.monetdb.org/mailman/listinfo/checkin-list

Reply via email to