Changeset 8fa8d0c for m4/ax_check_flag.m4
- Timestamp:
- Jun 26, 2011, 12:40:52 AM (13 years ago)
- Parents:
- bad4496 (diff), af562f5 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
m4/ax_check_flag.m4
rf2a96c0 raf562f5 81 81 CPPFLAGS="$CPPFLAGS $4 $1" 82 82 AC_PREPROC_IFELSE([AC_LANG_PROGRAM()], 83 [AS_VAR_SET( [CACHEVAR],[yes])],84 [AS_VAR_SET( [CACHEVAR],[no])])83 [AS_VAR_SET(CACHEVAR,[yes])], 84 [AS_VAR_SET(CACHEVAR,[no])]) 85 85 CPPFLAGS=$ax_check_save_flags]) 86 AS_ VAR_IF([CACHEVAR], "yes",86 AS_IF([test x"AS_VAR_GET(CACHEVAR)" = xyes], 87 87 [m4_default([$2], :)], 88 88 [m4_default([$3], :)]) … … 97 97 _AC_LANG_PREFIX[]FLAGS="$[]_AC_LANG_PREFIX[]FLAGS $4 $1" 98 98 AC_COMPILE_IFELSE([AC_LANG_PROGRAM()], 99 [AS_VAR_SET( [CACHEVAR],[yes])],100 [AS_VAR_SET( [CACHEVAR],[no])])99 [AS_VAR_SET(CACHEVAR,[yes])], 100 [AS_VAR_SET(CACHEVAR,[no])]) 101 101 _AC_LANG_PREFIX[]FLAGS=$ax_check_save_flags]) 102 AS_ VAR_IF([CACHEVAR], "yes",102 AS_IF([test x"AS_VAR_GET(CACHEVAR)" = xyes], 103 103 [m4_default([$2], :)], 104 104 [m4_default([$3], :)]) … … 112 112 LDFLAGS="$LDFLAGS $4 $1" 113 113 AC_LINK_IFELSE([AC_LANG_PROGRAM()], 114 [AS_VAR_SET( [CACHEVAR],[yes])],115 [AS_VAR_SET( [CACHEVAR],[no])])114 [AS_VAR_SET(CACHEVAR,[yes])], 115 [AS_VAR_SET(CACHEVAR,[no])]) 116 116 LDFLAGS=$ax_check_save_flags]) 117 AS_ VAR_IF([CACHEVAR], "yes",117 AS_IF([test x"AS_VAR_GET(CACHEVAR)" = xyes], 118 118 [m4_default([$2], :)], 119 119 [m4_default([$3], :)]) … … 124 124 AC_DEFUN([AX_APPEND_FLAG], 125 125 [AC_PREREQ(2.59) dnl for _AC_LANG_PREFIX 126 AC_REQUIRE([AC_PROG_GREP]) 127 AS_VAR_PUSHDEF([FLAGS], [m4_default($2,_AC_LANG_PREFIX[]FLAGS)])dnl 128 AS_VAR_SET_IF([FLAGS], 129 [AS_IF([AS_ECHO(" $[]FLAGS ") | $GREP " $1 " 2>&1 >/dev/null], 130 [AC_RUN_LOG([: FLAGS already contains $1])], 131 [AC_RUN_LOG([: FLAGS="$FLAGS $1"]) 132 AS_VAR_APPEND([FLAGS], [" $1"])])], 133 [AS_VAR_SET([FLAGS],[$1])]) 126 AS_VAR_PUSHDEF([FLAGS], [m4_default($2,_AC_LANG_PREFIX[FLAGS])])dnl 127 AS_VAR_SET_IF(FLAGS, 128 [case " AS_VAR_GET(FLAGS) " in 129 *" $1 "*) 130 AC_RUN_LOG([: FLAGS already contains $1]) 131 ;; 132 *) 133 AC_RUN_LOG([: FLAGS="$FLAGS $1"]) 134 AS_VAR_SET(FLAGS, ["AS_VAR_GET(FLAGS) $1"]) 135 ;; 136 esac], 137 [AS_VAR_SET(FLAGS,["$1"])]) 134 138 AS_VAR_POPDEF([FLAGS])dnl 135 139 ])dnl AX_APPEND_FLAG
Note: See TracChangeset
for help on using the changeset viewer.