[patch 33/39] fix configuration of distributed stand-alone subdirs
Robert Schwebel <[email protected]> Sun, 04 Feb 2007 03:31:53 +0100
| Newsgroups | gmane.comp.gnu.dotgnu.developer |
|---|---|
| Message-ID | <[email protected]> |
pnet-20070203-optionallibraries-cleanup.diff
(application/octet-stream, 4.2 KB)
The autotools handle subdirs which contains their own configure script in a correct way, so we remove all the uggly hand-made tweaks here and just let the magic happen. We may find out reason why somebody thought that it would not work before applying this patch. Signed-off-by: Robert Schwebel <[email protected]> --- auto_gen.sh | 11 +++++++-- configure.in | 71 ++++++++--------------------------------------------------- 2 files changed, 19 insertions(+), 63 deletions(-) Index: configure.in =================================================================== --- configure.in.orig +++ configure.in @@ -679,6 +679,14 @@ else fi AM_CONDITIONAL(USING_LIBGC, test x$withgc = xyes) +if test x$withffi = xyes; then + AC_CONFIG_SUBDIRS(libffi) +fi + +if test x$withgc = xyes; then + AC_CONFIG_SUBDIRS(libgc) +fi + AC_OUTPUT([ Makefile include/Makefile @@ -714,67 +722,8 @@ coremul/Makefile samples/Makefile doc/Makefile tests/Makefile -pnet.spec]) - -dnl Configure libffi and libgc. We do these manually to avoid -dnl some issues with different versions of autotools, and so that -dnl we can pass specific options to the packages. -if test "x$no_recursion" != "xyes"; then - - export CC - - dnl Figure out how to find the source directory for directories - dnl under $srcdir from a subdirectory of the build tree. This is - dnl different depending on whether $srcdir is absolute or relative. - if echo $srcdir | grep '^[[~/]]'; then - ffisrcdir=$srcdir/libffi - gcsrcdir=$srcdir/libgc - else - ffisrcdir=../$srcdir/libffi - gcsrcdir=../$srcdir/libgc - fi - if test x$withffi = xyes ; then - if test ! -d libffi ; then - mkdir libffi - fi - cd "libffi" - ${CONFIG_SHELL-/bin/sh} ${ffisrcdir}/configure --disable-shared \ - --enable-multilib=no \ - --disable-dependency-tracking \ - --host="${host}" --build="${build}" --target="${target}" \ - --disable-fast-install --prefix="${prefix}" \ - --exec-prefix="${exec_prefix}" --bindir="${bindir}" \ - --sbindir="${sbindir}" --libexecdir="${libexecdir}" \ - --datadir="${datadir}" --sysconfdir="${sysconfdir}" \ - --sharedstatedir="${sharedstatedir}" \ - --localstatedir="${localstatedir}" --libdir="${libdir}/pnet" \ - --includedir="${includedir}/pnet" \ - --oldincludedir="${oldincludedir}/pnet" --infodir="${infodir}" \ - --mandir="${mandir}" --srcdir="${ffisrcdir}" || exit 1 - cd .. - fi - - if test x$withgc = xyes ; then - if test ! -d libgc ; then - mkdir libgc - fi - cd libgc - ${CONFIG_SHELL-/bin/sh} ${gcsrcdir}/configure \ - --enable-threads=$THREADS --host="${host}" \ - --build="${build}" --target="${target}" --disable-fast-install \ - --prefix="${prefix}" \ - --exec-prefix="${exec_prefix}" --bindir="${bindir}" \ - --sbindir="${sbindir}" --libexecdir="${libexecdir}" \ - --datadir="${datadir}" --sysconfdir="${sysconfdir}" \ - --sharedstatedir="${sharedstatedir}" \ - --localstatedir="${localstatedir}" --libdir="${libdir}/pnet" \ - --includedir="${includedir}/pnet" \ - --oldincludedir="${oldincludedir}/pnet" \ - --infodir="${infodir}" --mandir="${mandir}" \ - --srcdir="${gcsrcdir}" || exit 1 - cd .. - fi -fi +pnet.spec +profiles/Makefile]) dnl Local variables: dnl tab-width: 4 Index: auto_gen.sh =================================================================== --- auto_gen.sh.orig +++ auto_gen.sh @@ -18,6 +18,7 @@ # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + # Run aclocal to update the macros. aclocal @@ -28,10 +29,16 @@ autoheader AM_VERSION=`automake --version` case "$AM_VERSION" in automake*1.4*) AM_FLAGS="" ;; - *) AM_FLAGS="--ignore-deps" ;; + *) AM_FLAGS="--ignore-deps" ;; esac # Run automake and autoconf. automake --add-missing --copy $AM_FLAGS autoconf -exit 0 + +for dir in libffi libgc; do + pushd $dir + sh autogen.sh + popd +done + -- Dipl.-Ing. Robert Schwebel | http://www.pengutronix.de Pengutronix - Linux Solutions for Science and Industry Handelsregister: Amtsgericht Hildesheim, HRA 2686 Hannoversche Str. 2, 31134 Hildesheim, Germany Phone: +49-5121-206917-0 | Fax: +49-5121-206917-9