From: Daniel Jacobowitz <drow@false.org>
To: Thiago Jung Bauermann <bauerman@br.ibm.com>
Cc: gdb-patches <gdb-patches@sourceware.org>,
Baurzhan Ismagulov <ibr@radix50.net>
Subject: Re: [patch] add --with-expat configure option
Date: Mon, 03 Sep 2007 20:47:00 -0000 [thread overview]
Message-ID: <20070903204724.GB26767@caradoc.them.org> (raw)
In-Reply-To: <1176510719.13824.25.camel@localhost.localdomain>
On Fri, Apr 13, 2007 at 09:31:59PM -0300, Thiago Jung Bauermann wrote:
> Hi,
>
> I needed to disable compiling with the expat library even if present in
> the build system, so I created a --with-expat configure option to
> control that. Configuring with --with-expat=no or --without-expat will
> disable the expat test. The default is to use the library if available.
>
> I'm posting here in case you are interested in incorporating the
> change...
Thanks. I decided to check in this version instead; it makes missing
expat a fatal error if --with-expat is given. This is useful for
people who do automated builds and expect them to have consistent
features.
--
Daniel Jacobowitz
CodeSourcery
2007-09-03 Daniel Jacobowitz <dan@codesourcery.com>
* configure.ac: Add --with-expat.
* configure: Regenerated.
Index: configure.ac
===================================================================
RCS file: /cvs/src/src/gdb/configure.ac,v
retrieving revision 1.50
diff -u -p -r1.50 configure.ac
--- configure.ac 3 Sep 2007 19:00:16 -0000 1.50
+++ configure.ac 3 Sep 2007 20:44:18 -0000
@@ -352,15 +352,30 @@ AC_SUBST(READLINE)
AC_SUBST(READLINE_DEPS)
AC_SUBST(READLINE_CFLAGS)
-AC_LIB_HAVE_LINKFLAGS([expat], [], [#include "expat.h"],
- [XML_Parser p = XML_ParserCreate (0);])
-if test "$HAVE_LIBEXPAT" != yes; then
- AC_MSG_WARN([expat is missing or unusable; some features may be disabled.])
+AC_ARG_WITH(expat,
+ AS_HELP_STRING([--with-expat], [include expat support (auto/yes/no)]),
+ [], [with_expat=auto])
+AC_MSG_CHECKING([whether to use expat])
+AC_MSG_RESULT([$with_expat])
+
+if test "${with_expat}" = no; then
+ AC_MSG_WARN([expat support disabled; some features may be unavailable.])
+ HAVE_LIBEXPAT=no
else
- save_LIBS=$LIBS
- LIBS="$LIBS $LIBEXPAT"
- AC_CHECK_FUNCS(XML_StopParser)
- LIBS=$save_LIBS
+ AC_LIB_HAVE_LINKFLAGS([expat], [], [#include "expat.h"],
+ [XML_Parser p = XML_ParserCreate (0);])
+ if test "$HAVE_LIBEXPAT" != yes; then
+ if test "$with_expat" = yes; then
+ AC_MSG_ERROR([expat is missing or unusable])
+ else
+ AC_MSG_WARN([expat is missing or unusable; some features may be unavailable.])
+ fi
+ else
+ save_LIBS=$LIBS
+ LIBS="$LIBS $LIBEXPAT"
+ AC_CHECK_FUNCS(XML_StopParser)
+ LIBS=$save_LIBS
+ fi
fi
# ------------------------- #
prev parent reply other threads:[~2007-09-03 20:47 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-04-14 8:15 Thiago Jung Bauermann
2007-09-03 20:47 ` Daniel Jacobowitz [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20070903204724.GB26767@caradoc.them.org \
--to=drow@false.org \
--cc=bauerman@br.ibm.com \
--cc=gdb-patches@sourceware.org \
--cc=ibr@radix50.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox