diff mbox series

[1/3] configure.ac: don't overwrite NO_EXPAT option

Message ID 20230719145211.17854-4-aherrmann@suse.de (mailing list archive)
State Accepted
Commit 0dd79e0d49818e964079c6d45f7f06a385bf2704
Headers show
Series configure.ac: misc configure fixes | expand

Commit Message

Andreas Herrmann July 19, 2023, 2:29 p.m. UTC
Even if 'configure --with-expat=no' was run, expat support is used,
because library detection overwrites it. Avoid this overwrite.
Configure should obey what the user has specified.

Signed-off-by: Andreas Herrmann <aherrmann@suse.de>
---
 configure.ac | 4 ++++
 1 file changed, 4 insertions(+)
diff mbox series

Patch

diff --git a/configure.ac b/configure.ac
index 38ff86678a..62cc8197f8 100644
--- a/configure.ac
+++ b/configure.ac
@@ -581,6 +581,8 @@  fi
 # Define NO_EXPAT if you do not have expat installed.  git-http-push is
 # not built, and you cannot push using http:// and https:// transports.
 
+if test -z "$NO_EXPAT"; then
+
 GIT_STASH_FLAGS($EXPATDIR)
 
 AC_CHECK_LIB([expat], [XML_ParserCreate],
@@ -589,6 +591,8 @@  AC_CHECK_LIB([expat], [XML_ParserCreate],
 
 GIT_UNSTASH_FLAGS($EXPATDIR)
 
+fi
+
 GIT_CONF_SUBST([NO_EXPAT])
 
 #