Changeset 9999


Ignore:
Timestamp:
10/03/11 11:00:30 (13 years ago)
Author:
Eric.Larour
Message:

Modified macro for metis: can now accept 4.0 and 5.0 versions.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk/m4/issm_options.m4

    r9971 r9999  
    298298                AC_MSG_CHECKING(for Metis headers and libraries in $METIS_ROOT)
    299299
     300                dnl first figure out version of metis: does the VERSION file exist?
     301                if test -e "$METIS_ROOT/VERSION"; then
     302                        METIS_VERSION=4
     303                else
     304                        METIS_VERSION=5
     305                fi
     306
    300307                dnl defaults
    301308                HAVE_METIS=yes
    302309               
    303                 case "${host_os}" in
    304                         *cygwin*)
    305                         METISLIB="-LIBPATH:\"$METIS_ROOT\" libmetis.lib"
    306                         ;;
    307                         *linux*)
    308                         METISLIB=-L"$METIS_ROOT/ -lmetis"
    309                         ;;
    310                         *darwin*)
    311                         METISLIB=-L"$METIS_ROOT/ -lmetis"
    312                         ;;
    313                 esac
    314                                                  
    315                 METISINCL=-I"$METIS_ROOT/Lib"
     310                                                                 
     311                if test "$METIS_VERSION" = "4" ; then
     312
     313                        case "${host_os}" in
     314                                *cygwin*)
     315                                METISLIB="-LIBPATH:\"$METIS_ROOT\" libmetis.lib"
     316                                ;;
     317                                *linux*)
     318                                METISLIB=-L"$METIS_ROOT/ -lmetis"
     319                                ;;
     320                                *darwin*)
     321                                METISLIB=-L"$METIS_ROOT/ -lmetis"
     322                                ;;
     323                        esac
     324
     325                        METISINCL=-I"$METIS_ROOT/Lib"
     326                        AC_DEFINE([_METIS_VERSION_],[4],[ Metis version number])
     327                fi
     328                if test "$METIS_VERSION" = "5" ; then
     329       
     330                        case "${host_os}" in
     331                                *cygwin*)
     332                                METISLIB="-LIBPATH:\"$METIS_ROOT\" libmetis.lib"
     333                                ;;
     334                                *linux*)
     335                                METISLIB=-L"$METIS_ROOT/lib -lmetis"
     336                                ;;
     337                                *darwin*)
     338                                METISLIB=-L"$METIS_ROOT/lib -lmetis"
     339                                ;;
     340                        esac
     341       
     342                        METISINCL=-I"$METIS_ROOT/include"
     343                        AC_DEFINE([_METIS_VERSION_],[5],[ Metis version number])
     344                fi
     345
    316346
    317347                AC_DEFINE([_HAVE_METIS_],[1],[with Metis in ISSM src])
Note: See TracChangeset for help on using the changeset viewer.