summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorAndres Mejia <amejia004@gmail.com>2013-02-22 20:02:40 -0500
committerAndres Mejia <amejia004@gmail.com>2013-02-22 20:02:40 -0500
commit64b3cefbdbc0d6deef1dd3bcde890e273c323168 (patch)
treef36f7e9e313a7d7ba01499cf6975fa55f6b6fa53 /configure.ac
parent9feba94f1a15e2726ab98d76cbf3d5a07e9bf45f (diff)
downloadlibarchive-64b3cefbdbc0d6deef1dd3bcde890e273c323168.tar.gz
Allow adding extra CFLAGS with a configure option.
This is a convenience option to pass in extra CFLAGS without overriding other CFLAGS.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac7
1 files changed, 7 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index 73944d3e..8a4afd75 100644
--- a/configure.ac
+++ b/configure.ac
@@ -190,6 +190,12 @@ esac
AM_CONDITIONAL([BUILD_BSDCPIO], [ test "$build_bsdcpio" = yes ])
AM_CONDITIONAL([STATIC_BSDCPIO], [ test "$static_bsdcpio" = yes ])
+AC_ARG_WITH([extra-cflags],
+ [AS_HELP_STRING([--with-extra-cflags=CFLAGS], [use extra CFLAGS])],
+ [], [enable_extra_cflags= ])
+
+EXTRA_CFLAGS=$with_extra_cflags
+
# Set up defines needed before including any headers
case $host in
*mingw* | *cygwin* )
@@ -785,4 +791,5 @@ case "$host_os" in
;;
esac
+AC_SUBST(EXTRA_CFLAGS)
AC_OUTPUT