1
0
mirror of https://git.zap.org.au/git/trader.git synced 2024-12-04 14:46:45 -05:00

Update ax_append_flag.m4 to the latest version

This commit is contained in:
John Zaitseff 2015-08-18 07:56:30 +10:00
parent 25d233c7fb
commit 79ac3636ae

View File

@ -49,21 +49,23 @@
# modified version of the Autoconf Macro, you may extend this special # modified version of the Autoconf Macro, you may extend this special
# exception to the GPL to apply to your modified version as well. # exception to the GPL to apply to your modified version as well.
#serial 2 #serial 6
AC_DEFUN([AX_APPEND_FLAG], AC_DEFUN([AX_APPEND_FLAG],
[AC_PREREQ(2.59)dnl for _AC_LANG_PREFIX [dnl
AS_VAR_PUSHDEF([FLAGS], [m4_default($2,_AC_LANG_PREFIX[FLAGS])])dnl AC_PREREQ(2.64)dnl for _AC_LANG_PREFIX and AS_VAR_SET_IF
AS_VAR_SET_IF(FLAGS, AS_VAR_PUSHDEF([FLAGS], [m4_default($2,_AC_LANG_PREFIX[FLAGS])])
[case " AS_VAR_GET(FLAGS) " in AS_VAR_SET_IF(FLAGS,[
*" $1 "*) AS_CASE([" AS_VAR_GET(FLAGS) "],
AC_RUN_LOG([: FLAGS already contains $1]) [*" $1 "*], [AC_RUN_LOG([: FLAGS already contains $1])],
;; [
*) AS_VAR_APPEND(FLAGS,[" $1"])
AC_RUN_LOG([: FLAGS="$FLAGS $1"]) AC_RUN_LOG([: FLAGS="$FLAGS"])
AS_VAR_SET(FLAGS, ["AS_VAR_GET(FLAGS) $1"]) ])
;; ],
esac], [
[AS_VAR_SET(FLAGS,["$1"])]) AS_VAR_SET(FLAGS,[$1])
AC_RUN_LOG([: FLAGS="$FLAGS"])
])
AS_VAR_POPDEF([FLAGS])dnl AS_VAR_POPDEF([FLAGS])dnl
])dnl AX_APPEND_FLAG ])dnl AX_APPEND_FLAG