On Fri, Oct 21, 2011 at 9:40 AM, Anders Logg <[email protected]> wrote:
> Would it be possible to add -fpermissive only in the case when MTL4 is
> detected?

Yes. Try to add that flag to CMAKE_REQUIRED_FLAGS in FindMTL4.cmake:

=== modified file 'cmake/modules/FindMTL4.cmake'
--- cmake/modules/FindMTL4.cmake        2011-02-04 10:02:55 +0000
+++ cmake/modules/FindMTL4.cmake        2011-10-21 10:49:30 +0000
@@ -33,7 +33,7 @@
   # Set flags for building test program
   set(CMAKE_REQUIRED_INCLUDES  ${MTL4_INCLUDE_DIRS} ${Boost_INCLUDE_DIR})
   set(CMAKE_REQUIRED_LIBRARIES ${MTL4_LIBRARIES})
-  set(CMAKE_REQUIRED_FLAGS ${MTL4_DEFINITIONS})
+  set(CMAKE_REQUIRED_FLAGS ${MTL4_DEFINITIONS} -fpermissive)

   # Build and run test program
   include(CheckCXXSourceRuns)

Johannes

_______________________________________________
Mailing list: https://launchpad.net/~dolfin
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~dolfin
More help   : https://help.launchpad.net/ListHelp

Reply via email to