Merge pull request #193 from robertodr/fix-empty-extra-flags
Managing EXTRA_<LANG>FLAGS
This commit is contained in:
commit
011669838e
@ -36,7 +36,9 @@ if(NOT CMAKE_C_COMPILER_WORKS)
|
||||
endif()
|
||||
|
||||
if(DEFINED EXTRA_CFLAGS)
|
||||
if(NOT EXTRA_CFLAGS STREQUAL "")
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${EXTRA_CFLAGS}")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(DEFINED ENV{CFLAGS})
|
||||
|
@ -36,7 +36,9 @@ if(NOT CMAKE_C_COMPILER_WORKS)
|
||||
endif()
|
||||
|
||||
if(DEFINED EXTRA_CXXFLAGS)
|
||||
if(NOT EXTRA_CXXFLAGS STREQUAL "")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${EXTRA_CXXFLAGS}")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(DEFINED ENV{CXXFLAGS})
|
||||
|
@ -43,7 +43,9 @@ if(NOT CMAKE_Fortran_COMPILER_WORKS)
|
||||
endif()
|
||||
|
||||
if(DEFINED EXTRA_FCFLAGS)
|
||||
if(NOT EXTRA_FCFLAGS STREQUAL "")
|
||||
set(CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} ${EXTRA_FCFLAGS}")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(DEFINED ENV{FCFLAGS})
|
||||
|
@ -54,7 +54,9 @@ if(ENABLE_FC_SUPPORT)
|
||||
endif()
|
||||
|
||||
if(DEFINED EXTRA_FCFLAGS)
|
||||
if(NOT EXTRA_FCFLAGS STREQUAL "")
|
||||
set(CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} ${EXTRA_FCFLAGS}")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(DEFINED ENV{FCFLAGS})
|
||||
|
Loading…
x
Reference in New Issue
Block a user