diff options
author | Peter Breitenlohner <peb@mppmu.mpg.de> | 2014-10-22 13:01:50 +0000 |
---|---|---|
committer | Peter Breitenlohner <peb@mppmu.mpg.de> | 2014-10-22 13:01:50 +0000 |
commit | 8e98311e31de87f1f53f0f413708a30c331a5245 (patch) | |
tree | 215e1f882e7d8fb8e63c71a1ea78e8ba8fc0b75b /Build/source/m4/kpse-dll-name.m4 | |
parent | 771d6846ef35854ba72c4ff73b44d8706c50e301 (diff) |
Build lua52 as (possibly shared) Libtool library
git-svn-id: svn://tug.org/texlive/trunk@35423 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/m4/kpse-dll-name.m4')
-rw-r--r-- | Build/source/m4/kpse-dll-name.m4 | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/Build/source/m4/kpse-dll-name.m4 b/Build/source/m4/kpse-dll-name.m4 new file mode 100644 index 00000000000..019cf0b1328 --- /dev/null +++ b/Build/source/m4/kpse-dll-name.m4 @@ -0,0 +1,34 @@ +# Public macros for the TeX Live (TL) tree. +# Copyright (C) 2014 Peter Breitenlohner <tex-live@tug.org> +# +# This file is free software; the copyright holders +# give unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# KPSE_DLL_NAME([M32], [M64], [C32], [C64]) +# ----------------------------------------- +# Specify the DLL name for 32- and/or 64-bit MinGW and/or Cywin. +AC_DEFUN([KPSE_DLL_NAME], [dnl +AC_PROVIDE_IFELSE([LT_INIT], , + [m4_fatal([$0: requires libtool])])[]dnl +AC_PROVIDE_IFELSE([LT_OUTPUT], + [m4_fatal([$0: too late])])[]dnl +AC_CHECK_SIZEOF([void *]) +AS_CASE([$host:$ac_cv_sizeof_void_p], + [*-*-mingw*:4], [kpse_dll_name=$1], + [*-*-mingw*:8], [kpse_dll_name=$2], + [*-*-cygwin:4], [kpse_dll_name=$3], + [*-*-cygwin:8], [kpse_dll_name=$4], + [kpse_dll_name=]) +_LT_CONFIG_SAVE_COMMANDS([## $0: Specify the DLL name +if test "x$kpse_dll_name" != x; then + $SED '/^soname_spec=/a\ +## $0: Specify the DLL name\ +soname_spec='$kpse_dll_name'.dll\ +' "$ofile" >"$cfgfile" + mv "$cfgfile" "$ofile" || + (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") + chmod +x "$ofile" +fi], [kpse_dll_name='$kpse_dll_name']) +]) # KPSE_DLL_NAME + |