diff options
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | README.GIT (renamed from README.SVN) | 24 | ||||
-rwxr-xr-x | autogen.sh | 50 | ||||
-rw-r--r-- | m4/gpg-error.m4 | 28 |
4 files changed, 69 insertions, 37 deletions
@@ -1,3 +1,7 @@ +2011-04-06 Werner Koch <wk@g10code.com> + + * m4/gpg-error.m4: Update from current libgpg-error repo. + 2011-03-28 Werner Koch <wk@g10code.com> * configure.ac (AC_CHECK_HEADERS): Check for sys/select.h which is @@ -1,9 +1,11 @@ -If you are building from Subversion, run the script +If you are building from GIT, run the script ./autogen.sh first, to make sure that you have all the necessary maintainer tools -are installed and to build the actual configuration files. Then run +are installed and to build the actual configuration files. If you +have just checked out from GIT, you should add the option "--force" to +autogen.sh so that meta data is noticed by autom4te.cache. Then run ./configure --enable-maintainer-mode @@ -14,7 +16,7 @@ tools, or the tools are not installed, you may use environment variables to override the default tool names: AUTOMAKE_SUFFIX is used as a suffix for all tools from the automake - package. For example + package. For example AUTOMAKE_SUFFIX="-1.7" ./autogen.sh uses "automake-1.7" and "aclocal-1.7. AUTOMAKE_PREFIX is used as a prefix for all tools from the automake @@ -35,17 +37,13 @@ It is also possible to use the variable name AUTOMAKE, AUTOCONF, ACLOCAL, AUTOHEADER, GETTEXT and MSGMERGE to directly specify the name of the programs to run. It is however better to use the suffix and prefix forms as described above because that does not require -knowledge about the actual tools used by autgen.sh. +knowledge about the actual tools used by autogen.sh. Please don't use autopoint, libtoolize or autoreconf unless you are the current maintainer and want to update the standard configuration -files. All those files should be in the repository and only updated -manually if the maintainer decides that newer versions are required. -The maintainer should also make sure that the required version of -automake et al. are properly indicated at the top of configure.ac and -take care to copy the files and not merely use symlinks. - - - - +files. All those files should be in GIT and only updated manually +if the maintainer decides that newer versions are required. The +maintainer should also make sure that the required version of automake +et al. are properly indicated at the top of configure.ac and take care +to copy the files and not merely use symlinks. @@ -1,5 +1,5 @@ #! /bin/sh -# Run this to generate all the initial makefiles, etc. +# Run this to generate all the initial makefiles, etc. # # Copyright (C) 2003 g10 Code GmbH # @@ -43,7 +43,7 @@ w32ce_toolprefixes= w32ce_extraoptions= amd64_toolprefixes= # End list of optional variables sourced from ~/.gnupg-autogen.rc -# What follows are variables which are sourced but default to +# What follows are variables which are sourced but default to # environment variables or lacking them hardcoded values. #w32root= #w32ce_root= @@ -55,7 +55,7 @@ if [ -f "$HOME/.gnupg-autogen.rc" ]; then fi # Convenience option to use certain configure options for some hosts. -myhost="" +myhost="" myhostsub="" case "$1" in --build-w32) @@ -101,7 +101,7 @@ if [ "$myhost" = "w32" ]; then ;; esac echo "Using $w32root as standard install directory" >&2 - + crossbindir= for host in $toolprefixes; do if ${host}-gcc --version >/dev/null 2>&1 ; then @@ -112,14 +112,14 @@ if [ "$myhost" = "w32" ]; then done if [ -z "$crossbindir" ]; then echo "Cross compiler kit not installed" >&2 - if [ -z "$sub" ]; then + if [ -z "$sub" ]; then echo "Under Debian GNU/Linux, you may install it using" >&2 - echo " apt-get install mingw32 mingw32-runtime mingw32-binutils" >&2 + echo " apt-get install mingw32 mingw32-runtime mingw32-binutils" >&2 fi echo "Stop." >&2 exit 1 fi - + if [ -f "$tsdir/config.log" ]; then if ! head $tsdir/config.log | grep "$host" >/dev/null; then echo "Pease run a 'make distclean' first" >&2 @@ -150,7 +150,7 @@ if [ "$myhost" = "amd64" ]; then [ -z "$amd64root" ] && amd64root="$HOME/amd64root" echo "Using $amd64root as standard install directory" >&2 - + # Locate the cross compiler crossbindir= for host in x86_64-linux-gnu amd64-linux-gnu; do @@ -165,7 +165,7 @@ if [ "$myhost" = "amd64" ]; then echo "Stop." >&2 exit 1 fi - + if [ -f "$tsdir/config.log" ]; then if ! head $tsdir/config.log | grep "$host" >/dev/null; then echo "Please run a 'make distclean' first" >&2 @@ -174,7 +174,7 @@ if [ "$myhost" = "amd64" ]; then fi $tsdir/configure --enable-maintainer-mode --prefix=${amd64root} \ - --host=${host} --build=${build} + --host=${host} --build=${build} rc=$? exit $rc fi @@ -183,19 +183,19 @@ fi # Grep the required versions from configure.ac -autoconf_vers=`sed -n '/^AC_PREREQ(/ { +autoconf_vers=`sed -n '/^AC_PREREQ(/ { s/^.*(\(.*\))/\1/p q }' ${configure_ac}` autoconf_vers_num=`echo "$autoconf_vers" | cvtver` -automake_vers=`sed -n '/^min_automake_version=/ { +automake_vers=`sed -n '/^min_automake_version=/ { s/^.*="\(.*\)"/\1/p q }' ${configure_ac}` automake_vers_num=`echo "$automake_vers" | cvtver` -#gettext_vers=`sed -n '/^AM_GNU_GETTEXT_VERSION(/ { +#gettext_vers=`sed -n '/^AM_GNU_GETTEXT_VERSION(/ { #s/^.*(\(.*\))/\1/p #q #}' ${configure_ac}` @@ -232,13 +232,29 @@ fi if test "$DIE" = "yes"; then cat <<EOF -Note that you may use alternative versions of the tools by setting -the corresponding environment variables; see README.CVS for details. - +Note that you may use alternative versions of the tools by setting +the corresponding environment variables; see README.GIT for details. + EOF exit 1 fi +# Check the git setup. +if [ -d .git ]; then + if [ -f .git/hooks/pre-commit.sample -a ! -f .git/hooks/pre-commit ] ; then + cat <<EOF >&2 +*** Activating trailing whitespace git pre-commit hook. *** + For more information see this thread: + http://mail.gnome.org/archives/desktop-devel-list/2009-May/msg00084html + To deactivate this pre-commit hook again move .git/hooks/pre-commit + and .git/hooks/pre-commit.sample out of the way. +EOF + cp -av .git/hooks/pre-commit.sample .git/hooks/pre-commit + chmod -c +x .git/hooks/pre-commit + fi +fi + + echo "Running aclocal -I m4 ${ACLOCAL_FLAGS:+$ACLOCAL_FLAGS }..." $ACLOCAL -I m4 $ACLOCAL_FLAGS echo "Running autoheader..." @@ -248,6 +264,6 @@ $AUTOMAKE --gnu; echo "Running autoconf${FORCE} ..." $AUTOCONF${FORCE} -echo "You may now run +echo "You may now run ./configure --enable-maintainer-mode && make " diff --git a/m4/gpg-error.m4 b/m4/gpg-error.m4 index e85f511..ef07fd7 100644 --- a/m4/gpg-error.m4 +++ b/m4/gpg-error.m4 @@ -1,5 +1,5 @@ # gpg-error.m4 - autoconf macro to detect libgpg-error. -# Copyright (C) 2002, 2003, 2004 g10 Code GmbH +# Copyright (C) 2002, 2003, 2004, 2011 g10 Code GmbH # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without @@ -14,7 +14,8 @@ dnl [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND ]]]) dnl Test for libgpg-error and define GPG_ERROR_CFLAGS and GPG_ERROR_LIBS dnl AC_DEFUN([AM_PATH_GPG_ERROR], -[ AC_ARG_WITH(gpg-error-prefix, +[ AC_REQUIRE([AC_CANONICAL_HOST]) + AC_ARG_WITH(gpg-error-prefix, AC_HELP_STRING([--with-gpg-error-prefix=PFX], [prefix where GPG Error is installed (optional)]), gpg_error_config_prefix="$withval", gpg_error_config_prefix="") @@ -24,11 +25,12 @@ AC_DEFUN([AM_PATH_GPG_ERROR], fi fi - AC_PATH_PROG(GPG_ERROR_CONFIG, gpg-error-config, no) + AC_PATH_TOOL(GPG_ERROR_CONFIG, gpg-error-config, no) min_gpg_error_version=ifelse([$1], ,0.0,$1) AC_MSG_CHECKING(for GPG Error - version >= $min_gpg_error_version) ok=no - if test "$GPG_ERROR_CONFIG" != "no" ; then + if test "$GPG_ERROR_CONFIG" != "no" \ + && test -f "$GPG_ERROR_CONFIG" ; then req_major=`echo $min_gpg_error_version | \ sed 's/\([[0-9]]*\)\.\([[0-9]]*\)/\1/'` req_minor=`echo $min_gpg_error_version | \ @@ -40,7 +42,7 @@ AC_DEFUN([AM_PATH_GPG_ERROR], sed 's/\([[0-9]]*\)\.\([[0-9]]*\).*/\2/'` if test "$major" -gt "$req_major"; then ok=yes - else + else if test "$major" -eq "$req_major"; then if test "$minor" -ge "$req_minor"; then ok=yes @@ -51,8 +53,21 @@ AC_DEFUN([AM_PATH_GPG_ERROR], if test $ok = yes; then GPG_ERROR_CFLAGS=`$GPG_ERROR_CONFIG $gpg_error_config_args --cflags` GPG_ERROR_LIBS=`$GPG_ERROR_CONFIG $gpg_error_config_args --libs` - AC_MSG_RESULT(yes) + AC_MSG_RESULT([yes ($gpg_error_config_version)]) ifelse([$2], , :, [$2]) + gpg_error_config_host=`$GPG_ERROR_CONFIG $gpg_error_config_args --host 2>/dev/null || echo none` + if test x"$gpg_error_config_host" != xnone ; then + if test x"$gpg_error_config_host" != x"$host" ; then + AC_MSG_WARN([[ +*** +*** The config script $GPG_ERROR_CONFIG was +*** built for $gpg_error_config_host and thus may not match the +*** used host $host. +*** You may want to use the configure option --with-gpg-error-prefix +*** to specify a matching config script. +***]]) + fi + fi else GPG_ERROR_CFLAGS="" GPG_ERROR_LIBS="" @@ -62,4 +77,3 @@ AC_DEFUN([AM_PATH_GPG_ERROR], AC_SUBST(GPG_ERROR_CFLAGS) AC_SUBST(GPG_ERROR_LIBS) ]) - |