Browse Source

have to cache ansi_cxxflags

Bill Hoffman 23 years ago
parent
commit
c54a86edd6
1 changed files with 2 additions and 1 deletions
  1. 2 1
      Modules/CMakeBackwardCompatibilityCXX.cmake

+ 2 - 1
Modules/CMakeBackwardCompatibilityCXX.cmake

@@ -17,7 +17,8 @@ IF(NOT CMAKE_COMPILER_IS_GNUCXX)
     # if the compiler liked the flag then set CMAKE_ANSI_CXXFLAGS
     # to the flag
     IF(CMAKE_CXX_ACCEPTS_FLAGS)
-      SET(CMAKE_ANSI_CXXFLAGS ${CMAKE_TRY_ANSI_CXX_FLAGS})
+      SET(CMAKE_ANSI_CXXFLAGS ${CMAKE_TRY_ANSI_CXX_FLAGS} CACHE INTERNAL 
+      "What flags are required by the c++ compiler to make it ansi." )
     ENDIF(CMAKE_CXX_ACCEPTS_FLAGS)
   ENDIF( CMAKE_TRY_ANSI_CXX_FLAGS MATCHES ".+")
 ENDIF(NOT CMAKE_COMPILER_IS_GNUCXX)