Changeset 24876


Ignore:
Timestamp:
05/19/20 12:02:04 (5 years ago)
Author:
jdquinn
Message:

BUG: Faulty test for macOS.

File:
1 edited

Legend:

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

    r24824 r24876  
    190190                [VENDOR=""]                                                                                                                     dnl action if not given
    191191        )
    192         dnl defaults for host OS related variables
    193         IS_MAC=no
     192
     193        AC_MSG_CHECKING([if this is a Mac build])
     194        case "${host_os}" in
     195                *darwin*)
     196                        IS_MAC=yes
     197                ;;
     198                *)
     199                        IS_MAC=no
     200                ;;
     201        esac
     202        AM_CONDITIONAL([MAC], [test "${IS_MAC}" == "yes"])
     203        AC_MSG_RESULT([${IS_MAC}])
     204
    194205        IS_WINDOWS=no
    195206        AC_MSG_CHECKING([for vendor compilers])
     
    285296        AC_SUBST([OSLIBS])
    286297        AC_MSG_RESULT([done])
    287 
    288         AC_MSG_CHECKING([if this is a Mac build])
    289         dnl TODO: The following test is a POSIX-compliant way of testing for a
    290         dnl               substring, but is not very readable. Perhaps there is a more
    291         dnl               readable method of achieving the same?
    292         if test "${host_os#*\"darwin\"}" == "$host_os"; then
    293                 IS_MAC=yes
    294         fi
    295         AM_CONDITIONAL([MAC], [test "${IS_MAC}" == "yes"])
    296         AC_MSG_RESULT([${IS_MAC}])
    297298
    298299        AC_MSG_CHECKING([if this is a Windows build])
Note: See TracChangeset for help on using the changeset viewer.