diff options
author | Peter Breitenlohner <peb@mppmu.mpg.de> | 2011-01-07 11:41:49 +0000 |
---|---|---|
committer | Peter Breitenlohner <peb@mppmu.mpg.de> | 2011-01-07 11:41:49 +0000 |
commit | 4d1718ff4f4ebbc85e009c6c5d53ed3055c84a6b (patch) | |
tree | d172713079440674f796336724df7b931c181812 /Build/source | |
parent | 4cc993f99780b2354b2c07caf4b2bd75dc2019e8 (diff) |
Ignore shell script for WIN32
Check for argv[0] with .exe via strcasecmp()
git-svn-id: svn://tug.org/texlive/trunk@20960 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source')
-rw-r--r-- | Build/source/texk/dvipdfmx/ChangeLog.TL | 8 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/Makefile.in | 1 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/aclocal.m4 | 1 | ||||
-rwxr-xr-x | Build/source/texk/dvipdfmx/configure | 61 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/configure.ac | 3 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/data/Makefile.in | 1 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/src/Makefile.am | 2 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/src/Makefile.in | 6 | ||||
-rw-r--r-- | Build/source/texk/dvipdfmx/src/dvipdfmx.c | 8 |
9 files changed, 86 insertions, 5 deletions
diff --git a/Build/source/texk/dvipdfmx/ChangeLog.TL b/Build/source/texk/dvipdfmx/ChangeLog.TL index 1c7c34e4dad..64a29977942 100644 --- a/Build/source/texk/dvipdfmx/ChangeLog.TL +++ b/Build/source/texk/dvipdfmx/ChangeLog.TL @@ -1,6 +1,14 @@ ChangeLog.TL: TeX Live (TL) changes for dvipdfmx ================================================ +2010-12-30 Peter Breitenlohner <peb@mppmu.mpg.de> + + * src/dvipdfmx.c: Check for argv[0] with .exe via strcasecmp(). + +2010-12-29 Peter Breitenlohner <peb@mppmu.mpg.de> + + * configure.ac, src/Makefile.am: Ignore shell script for WIN32. + 2010-06-10 Peter Breitenlohner <peb@mppmu.mpg.de> Avoid using "%hu" with fscanf/sscanf, for older Solaris. diff --git a/Build/source/texk/dvipdfmx/Makefile.in b/Build/source/texk/dvipdfmx/Makefile.in index e28fa480164..f739e8fb676 100644 --- a/Build/source/texk/dvipdfmx/Makefile.in +++ b/Build/source/texk/dvipdfmx/Makefile.in @@ -53,6 +53,7 @@ am__aclocal_m4_deps = $(top_srcdir)/../../m4/cho-libs.m4 \ $(top_srcdir)/../../m4/kpse-kpathsea-flags.m4 \ $(top_srcdir)/../../m4/kpse-libpng-flags.m4 \ $(top_srcdir)/../../m4/kpse-warnings.m4 \ + $(top_srcdir)/../../m4/kpse-win32.m4 \ $(top_srcdir)/../../m4/kpse-zlib-flags.m4 \ $(top_srcdir)/../../m4/libtool.m4 \ $(top_srcdir)/../../m4/ltoptions.m4 \ diff --git a/Build/source/texk/dvipdfmx/aclocal.m4 b/Build/source/texk/dvipdfmx/aclocal.m4 index 69f564e4779..3415f27bf7f 100644 --- a/Build/source/texk/dvipdfmx/aclocal.m4 +++ b/Build/source/texk/dvipdfmx/aclocal.m4 @@ -994,6 +994,7 @@ m4_include([../../m4/kpse-common.m4]) m4_include([../../m4/kpse-kpathsea-flags.m4]) m4_include([../../m4/kpse-libpng-flags.m4]) m4_include([../../m4/kpse-warnings.m4]) +m4_include([../../m4/kpse-win32.m4]) m4_include([../../m4/kpse-zlib-flags.m4]) m4_include([../../m4/libtool.m4]) m4_include([../../m4/ltoptions.m4]) diff --git a/Build/source/texk/dvipdfmx/configure b/Build/source/texk/dvipdfmx/configure index d9178915bd3..6beb0f5156f 100755 --- a/Build/source/texk/dvipdfmx/configure +++ b/Build/source/texk/dvipdfmx/configure @@ -615,6 +615,8 @@ ac_includes_default="\ ac_subst_vars='am__EXEEXT_FALSE am__EXEEXT_TRUE LTLIBOBJS +WIN32_FALSE +WIN32_TRUE LIBPNG_RULE LIBPNG_DEPEND LIBPNG_LIBS @@ -15303,6 +15305,61 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for native WIN32 or MINGW32" >&5 +$as_echo_n "checking for native WIN32 or MINGW32... " >&6; } +if ${kpse_cv_have_win32+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifndef WIN32 + choke me +#endif +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifndef __MINGW32__ + choke me +#endif +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + kpse_cv_have_win32=mingw32 +else + kpse_cv_have_win32=native +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +else + kpse_cv_have_win32=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $kpse_cv_have_win32" >&5 +$as_echo "$kpse_cv_have_win32" >&6; } + + if test "x$kpse_cv_have_win32" != xno; then + WIN32_TRUE= + WIN32_FALSE='#' +else + WIN32_TRUE='#' + WIN32_FALSE= +fi + + ac_config_files="$ac_config_files Makefile data/Makefile src/Makefile" @@ -15436,6 +15493,10 @@ if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi +if test -z "${WIN32_TRUE}" && test -z "${WIN32_FALSE}"; then + as_fn_error $? "conditional \"WIN32\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi : "${CONFIG_STATUS=./config.status}" ac_write_fail=0 diff --git a/Build/source/texk/dvipdfmx/configure.ac b/Build/source/texk/dvipdfmx/configure.ac index 1c5d8690c26..c8a0c42f428 100644 --- a/Build/source/texk/dvipdfmx/configure.ac +++ b/Build/source/texk/dvipdfmx/configure.ac @@ -76,6 +76,9 @@ if test "x$enable_texlive_build" != xyes || test ! -d $srdir/../kpathsea; then CHO_CHECK_LIBPAPER fi +KPSE_CHECK_WIN32 +AM_CONDITIONAL([WIN32], [test "x$kpse_cv_have_win32" != xno]) + AC_CONFIG_FILES([Makefile data/Makefile src/Makefile]) AC_OUTPUT diff --git a/Build/source/texk/dvipdfmx/data/Makefile.in b/Build/source/texk/dvipdfmx/data/Makefile.in index 3566b8f42e5..b4a201c5f10 100644 --- a/Build/source/texk/dvipdfmx/data/Makefile.in +++ b/Build/source/texk/dvipdfmx/data/Makefile.in @@ -44,6 +44,7 @@ am__aclocal_m4_deps = $(top_srcdir)/../../m4/cho-libs.m4 \ $(top_srcdir)/../../m4/kpse-kpathsea-flags.m4 \ $(top_srcdir)/../../m4/kpse-libpng-flags.m4 \ $(top_srcdir)/../../m4/kpse-warnings.m4 \ + $(top_srcdir)/../../m4/kpse-win32.m4 \ $(top_srcdir)/../../m4/kpse-zlib-flags.m4 \ $(top_srcdir)/../../m4/libtool.m4 \ $(top_srcdir)/../../m4/ltoptions.m4 \ diff --git a/Build/source/texk/dvipdfmx/src/Makefile.am b/Build/source/texk/dvipdfmx/src/Makefile.am index 6dae1185185..d4c5263edef 100644 --- a/Build/source/texk/dvipdfmx/src/Makefile.am +++ b/Build/source/texk/dvipdfmx/src/Makefile.am @@ -8,7 +8,9 @@ AM_CPPFLAGS = AM_CFLAGS = $(WARNING_CFLAGS) bin_PROGRAMS = dvipdfmx +if !WIN32 dist_bin_SCRIPTS = dvipdft +endif !WIN32 dvipdfmx_SOURCES = \ agl.c bmpimage.c cff.c cff_dict.c cid.c cidtype0.c cidtype2.c \ diff --git a/Build/source/texk/dvipdfmx/src/Makefile.in b/Build/source/texk/dvipdfmx/src/Makefile.in index b3db133a4a3..64f8c07dce1 100644 --- a/Build/source/texk/dvipdfmx/src/Makefile.in +++ b/Build/source/texk/dvipdfmx/src/Makefile.in @@ -37,7 +37,7 @@ build_triplet = @build@ host_triplet = @host@ bin_PROGRAMS = dvipdfmx$(EXEEXT) subdir = src -DIST_COMMON = $(dist_bin_SCRIPTS) $(srcdir)/Makefile.am \ +DIST_COMMON = $(am__dist_bin_SCRIPTS_DIST) $(srcdir)/Makefile.am \ $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/../../m4/cho-libs.m4 \ @@ -45,6 +45,7 @@ am__aclocal_m4_deps = $(top_srcdir)/../../m4/cho-libs.m4 \ $(top_srcdir)/../../m4/kpse-kpathsea-flags.m4 \ $(top_srcdir)/../../m4/kpse-libpng-flags.m4 \ $(top_srcdir)/../../m4/kpse-warnings.m4 \ + $(top_srcdir)/../../m4/kpse-win32.m4 \ $(top_srcdir)/../../m4/kpse-zlib-flags.m4 \ $(top_srcdir)/../../m4/libtool.m4 \ $(top_srcdir)/../../m4/ltoptions.m4 \ @@ -86,6 +87,7 @@ am_dvipdfmx_OBJECTS = agl.$(OBJEXT) bmpimage.$(OBJEXT) cff.$(OBJEXT) \ dvipdfmx_OBJECTS = $(am_dvipdfmx_OBJECTS) dvipdfmx_LDADD = $(LDADD) am__DEPENDENCIES_1 = +am__dist_bin_SCRIPTS_DIST = dvipdft am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ @@ -254,7 +256,7 @@ top_srcdir = @top_srcdir@ INCLUDES = $(KPATHSEA_INCLUDES) $(LIBPNG_INCLUDES) $(ZLIB_INCLUDES) AM_CPPFLAGS = AM_CFLAGS = $(WARNING_CFLAGS) -dist_bin_SCRIPTS = dvipdft +@WIN32_FALSE@dist_bin_SCRIPTS = dvipdft dvipdfmx_SOURCES = \ agl.c bmpimage.c cff.c cff_dict.c cid.c cidtype0.c cidtype2.c \ cmap.c cmap_read.c cmap_write.c cs_type2.c \ diff --git a/Build/source/texk/dvipdfmx/src/dvipdfmx.c b/Build/source/texk/dvipdfmx/src/dvipdfmx.c index 5c02000369d..4320bae492b 100644 --- a/Build/source/texk/dvipdfmx/src/dvipdfmx.c +++ b/Build/source/texk/dvipdfmx/src/dvipdfmx.c @@ -837,11 +837,13 @@ main (int argc, char *argv[]) { const char *base = xbasename(argv[0]); - if (!(strcmp(base, "dvipdfm") && strcmp(base, "ebb"))) +#define STRCMP_BASE(s) strcmp(base, s) && strcasecmp(base, s ".exe") + + if (!(STRCMP_BASE("dvipdfm") && STRCMP_BASE("ebb"))) compat_mode = 1; - if (!(strcmp(base, "extractbb") && strcmp(base, "xbb") && - strcmp(base, "ebb"))) + if (!(STRCMP_BASE("extractbb") && STRCMP_BASE("xbb") && + STRCMP_BASE("ebb"))) return extractbb(argc, argv); } |