1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495 |
- #! /bin/sh
- . test-init.sh
- echo "# Automatically generated by $me." > get.sh
- echo : >> get.sh
- if ver=$(pkg-config --version) && test -n "$ver"; then
- echo "printf 'pkg-config version: %s\\n' '$ver'" >> get.sh
- else
- echo "skip_all_ \"'pkg-config' not available\"" >> get.sh
- fi
- cat > configure.ac <<'END'
- AC_INIT([pkg], [1.0])
- PKG_CHECK_MODULES([GOBJECT], [gobject-2.0 >= 2.4])
- END
- have_pkg_config_macros ()
- {
- $AUTOCONF && ! $FGREP PKG_CHECK_MODULES configure
- }
- if have_pkg_config_macros; then
-
- exit 0
- fi
- XT_ACLOCAL_PATH=/usr/local/share/aclocal:/usr/share/aclocal
- oIFS=$IFS dir=
- IFS=:
- for d in $PATH; do
- IFS=$oIFS
- if test -f $d/pkg-config || test -f $d/pkg-config.exe; then
- dir=$d
- break
- fi
- done
- IFS=$oIFS
- if test -n "$dir"; then
-
- XT_ACLOCAL_PATH=${dir%/bin}/share/aclocal:$XT_ACLOCAL_PATH
- fi
- XT_ACLOCAL_PATH=$XT_ACLOCAL_PATH${ACLOCAL_PATH+":$ACLOCAL_PATH"}
- mkdir m4
- ACLOCAL_PATH=$XT_ACLOCAL_PATH $ACLOCAL -Wno-syntax --install -I m4
- if test -f m4/pkg.m4 && have_pkg_config_macros; then
- echo "ACLOCAL_PATH='$(pwd)/m4':\$ACLOCAL_PATH" >> get.sh
- echo "export ACLOCAL_PATH" >> get.sh
- echo "sed 20q '$(pwd)/m4/pkg.m4' # For debugging." >> get.sh
- else
- echo "skip_all_ \"pkg-config m4 macros not found\"" >> get.sh
- fi
- unset ACLOCAL_PATH
- . ./get.sh
- $ACLOCAL --force -I m4 || cat >> get.sh <<'END'
- ACLOCAL="$ACLOCAL -Wno-syntax"
- END
- keep_testdirs=yes
- :
|