diff options
author | NIIBE Yutaka <[email protected]> | 2023-08-17 05:03:09 +0000 |
---|---|---|
committer | NIIBE Yutaka <[email protected]> | 2023-08-17 05:03:09 +0000 |
commit | dacbd51c3f8ae6dafe56b3d4b4d15c8d62254230 (patch) | |
tree | d03640f87382c55ec877dedd8a9755436febadcc /configure.ac | |
parent | qt: Clean up after failure or cancel of sign/encrypt archive operation (diff) | |
download | gpgme-dacbd51c3f8ae6dafe56b3d4b4d15c8d62254230.tar.gz gpgme-dacbd51c3f8ae6dafe56b3d4b4d15c8d62254230.zip |
build: New configure option --with-libtool-modification.
* Makefile.am (EXTRA_DIST): Add build-aux/libtool-patch.sed.
* build-aux/libtool-patch.sed: New.
* configure.ac (--with-libtool-modification): New.
* build-aux/ltmain.sh: Revert our own local modification.
--
Fixes-commit: e622e36f1f32641c66b28a0de95c75ae35f6ca05
GnuPG-bug-id: 6619
Signed-off-by: NIIBE Yutaka <[email protected]>
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac index d7396a27..7ddb1b4f 100644 --- a/configure.ac +++ b/configure.ac @@ -206,6 +206,44 @@ esac AM_CONDITIONAL(HAVE_LD_VERSION_SCRIPT, test "$have_ld_version_script" = "yes") +# +# Specify how we support our local modification of libtool for Windows +# 64-bit. Options are: +# +# (1) apply: when appying patch fails, it results failure of entire build +# (2) never: never apply the patch (no try) +# (3) try: use patched if it goes well, use original if fails +# +AC_ARG_WITH([libtool-modification], + AS_HELP_STRING([--with-libtool-modification=apply|never|try], + [how to handle libtool modification (default=apply)]), + build_libtool_modification=$withval, + build_libtool_modification=apply) + +# +# Apply a patch (locally maintained one of ours) to libtool +# +case $host in + x86_64-*mingw32*) +AC_CONFIG_COMMANDS([libtool-patch],[[ + if test "$build_selection" = never; then + echo "patch not applied" + elif (mv -f libtool libtool.orig; \ + sed -f $srcdir/build-aux/libtool-patch.sed libtool.orig >libtool); then + echo "applied successfully" + elif test "$build_selection" = try; then + mv -f libtool.orig libtool + echo "patch failed, thus, using original" + else + echo "patch failed" + as_fn_exit 1 + fi +]],[build_selection=$build_libtool_modification]) + ;; + *) + ;; +esac + GPG_DEFAULT=no GPGSM_DEFAULT=no GPGCONF_DEFAULT=no |