summaryrefslogtreecommitdiff
path: root/Build/source
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2021-06-20 01:06:32 +0000
committerKarl Berry <karl@freefriends.org>2021-06-20 01:06:32 +0000
commitbdb9eaba6ce50bf9717119650ec415d86e2dcbbe (patch)
treeed5069f02b6ae113a52d657c8194184c1e592f7c /Build/source
parent425df02cf472a278ad44d86cc95b9c8dc3db20a3 (diff)
pthread needed for bibtexu
git-svn-id: svn://tug.org/texlive/trunk@59649 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source')
-rw-r--r--Build/source/texk/bibtex-x/ChangeLog7
-rw-r--r--Build/source/texk/bibtex-x/Makefile.am4
-rw-r--r--Build/source/texk/bibtex-x/Makefile.in7
-rw-r--r--Build/source/texk/bibtex-x/aclocal.m41
-rwxr-xr-xBuild/source/texk/bibtex-x/configure72
-rw-r--r--Build/source/texk/bibtex-x/configure.ac9
-rw-r--r--Build/source/texk/upmendex/ChangeLog9
-rw-r--r--Build/source/texk/upmendex/configure.ac8
8 files changed, 106 insertions, 11 deletions
diff --git a/Build/source/texk/bibtex-x/ChangeLog b/Build/source/texk/bibtex-x/ChangeLog
index 717b4a58ce4..de349ca24de 100644
--- a/Build/source/texk/bibtex-x/ChangeLog
+++ b/Build/source/texk/bibtex-x/ChangeLog
@@ -1,3 +1,10 @@
+2021-06-19 Karl Berry <karl@freefriends.org>
+
+ * configure.ac [enable_bibtexu]: also check for -lpthread.
+ * Makefile.am (bibtexu_LDADD): include $(PTHREAD_LIB).
+ Report and fix from Dmitry Zheleznyakov:
+ https://tug.org/pipermail/tex-k/2021-June/003591.html
+
2021-02-06 TANAKA Takuji <ttk@t-lab.opal.ne.jp>
* utils.c, configure.ac:
diff --git a/Build/source/texk/bibtex-x/Makefile.am b/Build/source/texk/bibtex-x/Makefile.am
index 9c1317f03ee..0ed7887e9de 100644
--- a/Build/source/texk/bibtex-x/Makefile.am
+++ b/Build/source/texk/bibtex-x/Makefile.am
@@ -1,7 +1,7 @@
## $Id$
## Makefile.am for the TeX Live subdirectory texk/bibtex-x/
##
-## Copyright 2017-2019 Karl Berry <tex-live@tug.org>
+## Copyright 2017-2021 Karl Berry <tex-live@tug.org>
## Copyright 2009-2015 Peter Breitenlohner <tex-live@tug.org>
## You may freely use, modify and/or distribute this file.
##
@@ -44,7 +44,7 @@ bibtexu_SOURCES = $(common_sources)
nodist_EXTRA_bibtexu_SOURCES = dummy.cxx
bibtexu_CPPFLAGS = $(AM_CPPFLAGS) $(ICU_INCLUDES) -DUTF_8
$(bibtexu_OBJECTS): $(KPATHSEA_DEPEND) $(ICU_DEPEND)
-bibtexu_LDADD = $(KPATHSEA_LIBS) $(ICU_LIBS) $(ICU_LIBS_EXTRA)
+bibtexu_LDADD = $(KPATHSEA_LIBS) $(ICU_LIBS) $(PTHREAD_LIB) $(ICU_LIBS_EXTRA)
dist_man1_MANS = bibtex8.1 bibtexu.1
diff --git a/Build/source/texk/bibtex-x/Makefile.in b/Build/source/texk/bibtex-x/Makefile.in
index bbccd8d5609..54ecc0b23b4 100644
--- a/Build/source/texk/bibtex-x/Makefile.in
+++ b/Build/source/texk/bibtex-x/Makefile.in
@@ -101,6 +101,7 @@ am__aclocal_m4_deps = $(top_srcdir)/../../m4/kpse-common.m4 \
$(top_srcdir)/../../m4/kpse-cxx-hack.m4 \
$(top_srcdir)/../../m4/kpse-icu-flags.m4 \
$(top_srcdir)/../../m4/kpse-kpathsea-flags.m4 \
+ $(top_srcdir)/../../m4/kpse-search-libs.m4 \
$(top_srcdir)/../../m4/kpse-warnings.m4 \
$(top_srcdir)/../../m4/libtool.m4 \
$(top_srcdir)/../../m4/ltoptions.m4 \
@@ -141,7 +142,8 @@ am__objects_2 = bibtexu-bibtex-1.$(OBJEXT) bibtexu-bibtex-2.$(OBJEXT) \
bibtexu-bibtex.$(OBJEXT) bibtexu-utils.$(OBJEXT)
am_bibtexu_OBJECTS = $(am__objects_2)
bibtexu_OBJECTS = $(am_bibtexu_OBJECTS)
-bibtexu_DEPENDENCIES = $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1)
+bibtexu_DEPENDENCIES = $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \
+ $(am__DEPENDENCIES_1)
AM_V_P = $(am__v_P_@AM_V@)
am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
am__v_P_0 = false
@@ -544,6 +546,7 @@ PACKAGE_URL = @PACKAGE_URL@
PACKAGE_VERSION = @PACKAGE_VERSION@
PATH_SEPARATOR = @PATH_SEPARATOR@
PKG_CONFIG = @PKG_CONFIG@
+PTHREAD_LIB = @PTHREAD_LIB@
RANLIB = @RANLIB@
SED = @SED@
SET_MAKE = @SET_MAKE@
@@ -629,7 +632,7 @@ bibtexu_SOURCES = $(common_sources)
# Force Automake to use CXXLD for linking
nodist_EXTRA_bibtexu_SOURCES = dummy.cxx
bibtexu_CPPFLAGS = $(AM_CPPFLAGS) $(ICU_INCLUDES) -DUTF_8
-bibtexu_LDADD = $(KPATHSEA_LIBS) $(ICU_LIBS) $(ICU_LIBS_EXTRA)
+bibtexu_LDADD = $(KPATHSEA_LIBS) $(ICU_LIBS) $(PTHREAD_LIB) $(ICU_LIBS_EXTRA)
dist_man1_MANS = bibtex8.1 bibtexu.1
csfdir = $(datarootdir)/texmf-dist/bibtex/csf/base
dist_csf_DATA = \
diff --git a/Build/source/texk/bibtex-x/aclocal.m4 b/Build/source/texk/bibtex-x/aclocal.m4
index 3b9931e6f89..560991a71f6 100644
--- a/Build/source/texk/bibtex-x/aclocal.m4
+++ b/Build/source/texk/bibtex-x/aclocal.m4
@@ -1170,6 +1170,7 @@ m4_include([../../m4/kpse-common.m4])
m4_include([../../m4/kpse-cxx-hack.m4])
m4_include([../../m4/kpse-icu-flags.m4])
m4_include([../../m4/kpse-kpathsea-flags.m4])
+m4_include([../../m4/kpse-search-libs.m4])
m4_include([../../m4/kpse-warnings.m4])
m4_include([../../m4/libtool.m4])
m4_include([../../m4/ltoptions.m4])
diff --git a/Build/source/texk/bibtex-x/configure b/Build/source/texk/bibtex-x/configure
index 791f947bc2d..d50f9e3a036 100755
--- a/Build/source/texk/bibtex-x/configure
+++ b/Build/source/texk/bibtex-x/configure
@@ -645,6 +645,7 @@ ICU_DEPEND
ICU_LIBS
ICU_INCLUDES
ICU_CONFIG
+PTHREAD_LIB
KPATHSEA_RULE
KPATHSEA_DEPEND
KPATHSEA_LIBS
@@ -17646,6 +17647,9 @@ if test "$ac_res" != no; then :
fi
+if test "x$enable_bibtexu" != xno; then
+ # As of ICU 65.1, ICU requires -lpthread on x86_64-linux and, most
+ # likely, on other platforms. See upmendex/configure.ac for more info.
kpse_save_CPPFLAGS=$CPPFLAGS
kpse_save_LIBS=$LIBS
@@ -19372,6 +19376,73 @@ if test "x$kpse_cv_kpse_debug" != xyes; then :
KPATHSEA_INCLUDES="$KPATHSEA_INCLUDES -DNO_DEBUG"
fi
+kpse_search_save_LIBS=$LIBS
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing pthread_create" >&5
+$as_echo_n "checking for library containing pthread_create... " >&6; }
+if ${ac_cv_search_pthread_create+:} false; then :
+ $as_echo_n "(cached) " >&6
+else
+ ac_func_search_save_LIBS=$LIBS
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+
+/* Override any GCC internal prototype to avoid an error.
+ Use char because int might match the return type of a GCC
+ builtin and then its argument prototype would still apply. */
+#ifdef __cplusplus
+extern "C"
+#endif
+char pthread_create ();
+int
+main ()
+{
+return pthread_create ();
+ ;
+ return 0;
+}
+_ACEOF
+for ac_lib in '' pthread; do
+ if test -z "$ac_lib"; then
+ ac_res="none required"
+ else
+ ac_res=-l$ac_lib
+ LIBS="-l$ac_lib $ac_func_search_save_LIBS"
+ fi
+ if ac_fn_c_try_link "$LINENO"; then :
+ ac_cv_search_pthread_create=$ac_res
+fi
+rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext
+ if ${ac_cv_search_pthread_create+:} false; then :
+ break
+fi
+done
+if ${ac_cv_search_pthread_create+:} false; then :
+
+else
+ ac_cv_search_pthread_create=no
+fi
+rm conftest.$ac_ext
+LIBS=$ac_func_search_save_LIBS
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_pthread_create" >&5
+$as_echo "$ac_cv_search_pthread_create" >&6; }
+ac_res=$ac_cv_search_pthread_create
+if test "$ac_res" != no; then :
+ test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
+
+fi
+
+LIBS=$kpse_search_save_LIBS
+case $ac_cv_search_pthread_create in #(
+ "none required") :
+ ;; #(
+ no) :
+ as_fn_error $? "Sorry, did not find pthread_create()" "$LINENO" 5 ;; #(
+ *) :
+ PTHREAD_LIB=$ac_cv_search_pthread_create ;;
+esac
+
echo 'tldbg:KPSE_ICU_FLAGS called: more-icu-libs=icuio icui18n, icu-config-args=--ldflags-icuio.' >&5
##tldbg _KPSE_LIB_FLAGS: Setup icu (-licuxxx) flags.
echo 'tldbg:_KPSE_LIB_FLAGS called: libdir=icu, libname=icuxxx, options=, tlincl=-DU_STATIC_IMPLEMENTATION -IBLD/libs/icu/include, tllib=BLD/libs/icu/icu-build/lib/libicuio.a BLD/libs/icu/icu-build/lib/libicui18n.a BLD/libs/icu/icu-build/lib/libicuuc.a BLD/libs/icu/icu-build/lib/libicudata.a, tlextra=, rebuildsrcdeps=, rebuildblddeps=${top_builddir}/../../libs/icu/include/unicode/uversion.h.' >&5
@@ -19591,6 +19662,7 @@ openbsd*)
;;
esac
+fi
if test "x$enable_bibtex8" != xno; then
BIBTEX8_TRUE=
diff --git a/Build/source/texk/bibtex-x/configure.ac b/Build/source/texk/bibtex-x/configure.ac
index 0143f200842..80f874a6266 100644
--- a/Build/source/texk/bibtex-x/configure.ac
+++ b/Build/source/texk/bibtex-x/configure.ac
@@ -1,6 +1,8 @@
+dnl $Id$
dnl Process this file with autoconf to produce a configure script.
dnl
-dnl Copyright (C) 2009-2013 Peter Breitenlohner <tex-live@tug.org>
+dnl Copyright 2015-2021 Karl Berry <tex-live@tug.org>
+dnl Copyright 2009-2015 Peter Breitenlohner <tex-live@tug.org>
dnl
dnl This file is free software; the copyright holder
dnl gives unlimited permission to copy and/or distribute it,
@@ -28,8 +30,13 @@ KPSE_CXX_HACK
AC_SEARCH_LIBS([pow], [m])
+if test "x$enable_bibtexu" != xno; then
+ dnl As of ICU 65.1, ICU requires -lpthread on x86_64-linux and, most
+ dnl likely, on other platforms. See upmendex/configure.ac for more info.
KPSE_KPATHSEA_FLAGS
+KPSE_SEARCH_LIBS([PTHREAD_LIB], [pthread_create], [pthread])
KPSE_ICU_FLAGS([icuio icui18n], [--ldflags-icuio])
+fi
AM_CONDITIONAL([BIBTEX8], [test "x$enable_bibtex8" != xno])
AM_CONDITIONAL([BIBTEXU], [test "x$enable_bibtexu" != xno])
diff --git a/Build/source/texk/upmendex/ChangeLog b/Build/source/texk/upmendex/ChangeLog
index 89f4dc8a52a..237babbc68a 100644
--- a/Build/source/texk/upmendex/ChangeLog
+++ b/Build/source/texk/upmendex/ChangeLog
@@ -1,9 +1,14 @@
+2021-06-19 Karl Berry <karl@freefriends.org>
+
+ * configure.ac: pthread doc update; also needed in bibtexu (q.v.).
+
2021-06-19 TANAKA Takuji <ttk@t-lab.opal.ne.jp>
- * configure.ac: Avoid error of C++ compiler detection
- in some envirionment.
+ * configure.ac: variadic checks before AC_PROG_CXX, to avoid error
+ of C++ compiler detection in some environments.
Report from Vadim Kantorov,
https://github.com/t-tk/upmendex-package/issues/1
+
* main.c: Add ICU version to banner.
2021-06-13 TANAKA Takuji <ttk@t-lab.opal.ne.jp>
diff --git a/Build/source/texk/upmendex/configure.ac b/Build/source/texk/upmendex/configure.ac
index 38d5f03c833..8278d39ddf8 100644
--- a/Build/source/texk/upmendex/configure.ac
+++ b/Build/source/texk/upmendex/configure.ac
@@ -1,7 +1,7 @@
dnl $Id$
dnl Process this file with autoconf to produce a configure script.
dnl
-dnl Copyright 2015-2020 Karl Berry <tex-live@tug.org>
+dnl Copyright 2015-2021 Karl Berry <tex-live@tug.org>
dnl Copyright 2010-2015 Peter Breitenlohner <tex-live@tug.org>
dnl
dnl This file is free software; the copyright holder
@@ -40,9 +40,9 @@ KPSE_CXX_HACK
dnl As of ICU 65.1, ICU requires -lpthread on x86_64-linux and, most
dnl likely, on other platforms. Otherwise there is a crash in
dnl std::call_once, as shown in ChangeLog. OpenBSD already has to link
-dnl with -lpthread on all platforms (see m4/kpse-icu-flags.m4), but so
-dnl far it seems only upmendex requires it elsewhere. The double
-dnl inclusion of -lpthread on obsd should be harmless.
+dnl with -lpthread on all platforms (see m4/kpse-icu-flags.m4), but the
+dnl double inclusion of -lpthread on obsd should be harmless. bibtexu
+dnl also needs pthread to avoid failures.
dnl
dnl The autoconf-archive ax_pthread macro (used in asymptote) goes to
dnl much greater lengths to find the best thread library and support all