mirror of
https://github.com/crosstool-ng/crosstool-ng.git
synced 2024-12-18 20:37:56 +00:00
Fix build of glibc 2.29 on systems with obsolete host programs
- Force building make as a companion tool if host make is older than 4.0 (CentOS 7 currently has 3.82) - Disable 2.29 as a choice if host python is older than 3.4 (CentOS 7 has 2.6 unless python from EPEL is installed) - Python2 emits its version information to STDERR. Ugh. While there, also use the detected host Python for GDB configuration. Signed-off-by: Alexey Neyman <stilor@att.net>
This commit is contained in:
parent
c4126d9397
commit
862c35457d
@ -3,6 +3,7 @@
|
|||||||
## default y if !CONFIGURE_has_make_3_81_or_newer
|
## default y if !CONFIGURE_has_make_3_81_or_newer
|
||||||
|
|
||||||
config MAKE_GMAKE_SYMLINK
|
config MAKE_GMAKE_SYMLINK
|
||||||
bool
|
bool "Create 'gmake' symlink"
|
||||||
prompt "Add gmake symlink to companion gnu/make"
|
|
||||||
depends on COMP_TOOLS_MAKE
|
config MAKE_GNUMAKE_SYMLINK
|
||||||
|
bool "Create 'gnumake' symlink"
|
||||||
|
@ -15,6 +15,9 @@ config CONFIGURE_has_curl
|
|||||||
config CONFIGURE_has_make_3_81_or_newer
|
config CONFIGURE_has_make_3_81_or_newer
|
||||||
@KCONFIG_make_3_81_or_newer@
|
@KCONFIG_make_3_81_or_newer@
|
||||||
|
|
||||||
|
config CONFIGURE_has_make_4_0_or_newer
|
||||||
|
@KCONFIG_make_4_0_or_newer@
|
||||||
|
|
||||||
config CONFIGURE_has_libtool_2_4_or_newer
|
config CONFIGURE_has_libtool_2_4_or_newer
|
||||||
@KCONFIG_libtool_2_4_or_newer@
|
@KCONFIG_libtool_2_4_or_newer@
|
||||||
|
|
||||||
@ -33,6 +36,12 @@ config CONFIGURE_has_automake_1_15_or_newer
|
|||||||
config CONFIGURE_has_gnu_m4_1_4_12_or_newer
|
config CONFIGURE_has_gnu_m4_1_4_12_or_newer
|
||||||
@KCONFIG_gnu_m4_1_4_12_or_newer@
|
@KCONFIG_gnu_m4_1_4_12_or_newer@
|
||||||
|
|
||||||
|
config CONFIGURE_has_python_3_4_or_newer
|
||||||
|
@KCONFIG_python_3_4_or_newer@
|
||||||
|
|
||||||
|
config CONFIGURE_has_python
|
||||||
|
@KCONFIG_python@
|
||||||
|
|
||||||
config CONFIGURE_has_dtc
|
config CONFIGURE_has_dtc
|
||||||
@KCONFIG_dtc@
|
@KCONFIG_dtc@
|
||||||
|
|
||||||
|
@ -35,6 +35,19 @@ config GLIBC_DEP_BINUTILS
|
|||||||
select BINUTILS_REQUIRE_2_25_or_later if GLIBC_2_26_or_later
|
select BINUTILS_REQUIRE_2_25_or_later if GLIBC_2_26_or_later
|
||||||
select BINUTILS_REQUIRE_older_than_2_30 if GLIBC_older_than_2_26 && ARCH_ARM && ARCH_64
|
select BINUTILS_REQUIRE_older_than_2_30 if GLIBC_older_than_2_26 && ARCH_ARM && ARCH_64
|
||||||
|
|
||||||
|
# Glibc 2.29 now requires Python 3.4 or later, and make 4.0 or later. Ensure
|
||||||
|
# we build 'make' as a companion tool if host's make isn't new enough.
|
||||||
|
config GLIBC_DEP_PYTHON
|
||||||
|
def_bool y
|
||||||
|
select GLIBC_REQUIRE_older_than_2_29 if !CONFIGURE_has_python_3_4_or_newer
|
||||||
|
|
||||||
|
config GLIBC_DEP_MAKE_4_0
|
||||||
|
def_bool y
|
||||||
|
depends on GLIBC_2_29_or_later && !CONFIGURE_has_make_4_0_or_newer
|
||||||
|
select COMP_TOOLS_MAKE
|
||||||
|
select MAKE_REQUIRE_4_0_or_later
|
||||||
|
select MAKE_GNUMAKE_SYMLINK # Override old host make in .build/tools/bin
|
||||||
|
|
||||||
config GLIBC_DEP_GCC
|
config GLIBC_DEP_GCC
|
||||||
def_bool y
|
def_bool y
|
||||||
select GCC_REQUIRE_4_9_or_later if GLIBC_2_26_or_later
|
select GCC_REQUIRE_4_9_or_later if GLIBC_2_26_or_later
|
||||||
|
22
configure.ac
22
configure.ac
@ -182,6 +182,13 @@ CTNG_PROG_VERSION_REQ_ANY([MAKE],
|
|||||||
[^GNU Make (3\.8[1-9]|3\.9[0-9]|[4-9]\.)],
|
[^GNU Make (3\.8[1-9]|3\.9[0-9]|[4-9]\.)],
|
||||||
[make_3_81_or_newer])
|
[make_3_81_or_newer])
|
||||||
|
|
||||||
|
CTNG_PROG_VERSION_REQ_ANY([MAKE],
|
||||||
|
[GNU make >= 4.0],
|
||||||
|
[make],
|
||||||
|
[gmake make],
|
||||||
|
[^GNU Make [4-9]\.],
|
||||||
|
[make_4_0_or_newer])
|
||||||
|
|
||||||
# Check other companion tools that we may or may not build.
|
# Check other companion tools that we may or may not build.
|
||||||
CTNG_PROG_VERSION_REQ_ANY([LIBTOOL],
|
CTNG_PROG_VERSION_REQ_ANY([LIBTOOL],
|
||||||
[GNU libtool >= 2.4],
|
[GNU libtool >= 2.4],
|
||||||
@ -225,6 +232,21 @@ CTNG_PROG_VERSION([M4],
|
|||||||
[\(GNU M4\) ([2-9]\.|1\.[5-9]|1\.[1-4][0-9]|1\.4\.[2-9][0-9]|1\.4\.1[2-9])],
|
[\(GNU M4\) ([2-9]\.|1\.[5-9]|1\.[1-4][0-9]|1\.4\.[2-9][0-9]|1\.4\.1[2-9])],
|
||||||
[gnu_m4_1_4_12_or_newer])
|
[gnu_m4_1_4_12_or_newer])
|
||||||
|
|
||||||
|
CTNG_PROG_VERSION([PYTHON],
|
||||||
|
[Python],
|
||||||
|
[python],
|
||||||
|
[python37 python3.7 python36 python3.6 python35 python3.5 python34 python3.4 python33 python3.3 python32 python3.2 python31 python3.1 python3 python27 python2.7 python26 python2.6 python2 python],
|
||||||
|
[^Python [23]\.],
|
||||||
|
[python])
|
||||||
|
|
||||||
|
CTNG_PROG_VERSION([PYTHON],
|
||||||
|
[Python >= 3.4],
|
||||||
|
[python],
|
||||||
|
[python37 python3.7 python36 python3.6 python35 python3.5 python34 python3.4 python3 python],
|
||||||
|
[^Python 3\.([4-9]|[1-9][0-9]+)\.],
|
||||||
|
[python_3_4_or_newer])
|
||||||
|
|
||||||
|
|
||||||
AC_SUBST([kconfig_options])
|
AC_SUBST([kconfig_options])
|
||||||
|
|
||||||
AC_CHECK_PROGS([dtc], [dtc])
|
AC_CHECK_PROGS([dtc], [dtc])
|
||||||
|
@ -18,7 +18,7 @@ AC_DEFUN([CTNG_PROG_VERSION],
|
|||||||
[ac_cv_path_$1="$$1"
|
[ac_cv_path_$1="$$1"
|
||||||
CTNG_PATH_ABSNAME([ac_cv_path_$1])
|
CTNG_PATH_ABSNAME([ac_cv_path_$1])
|
||||||
CTNG_MSG_LOG_ENVVAR([ac_cv_path_$1])
|
CTNG_MSG_LOG_ENVVAR([ac_cv_path_$1])
|
||||||
ver=$(eval $ac_cv_path_$1 --version 2>/dev/null)
|
ver=$(eval $ac_cv_path_$1 --version 2>&1)
|
||||||
CTNG_MSG_LOG([looking for '[$5]' regexp in])
|
CTNG_MSG_LOG([looking for '[$5]' regexp in])
|
||||||
CTNG_MSG_LOG_ENVVAR([ver], [version info for $ac_cv_path_$1])
|
CTNG_MSG_LOG_ENVVAR([ver], [version info for $ac_cv_path_$1])
|
||||||
ver=$(AS_ECHO(["$ver"]) | $EGREP '[$5]')
|
ver=$(AS_ECHO(["$ver"]) | $EGREP '[$5]')
|
||||||
@ -26,7 +26,7 @@ AC_DEFUN([CTNG_PROG_VERSION],
|
|||||||
[AC_CACHE_CHECK([for $3], [ac_cv_path_$1],
|
[AC_CACHE_CHECK([for $3], [ac_cv_path_$1],
|
||||||
[AC_PATH_PROGS_FEATURE_CHECK([$1], [$4],
|
[AC_PATH_PROGS_FEATURE_CHECK([$1], [$4],
|
||||||
[CTNG_MSG_LOG_ENVVAR([ac_path_$1], [checking $1 at])
|
[CTNG_MSG_LOG_ENVVAR([ac_path_$1], [checking $1 at])
|
||||||
ver=$($ac_path_$1 --version 2>/dev/null)
|
ver=$($ac_path_$1 --version 2>&1)
|
||||||
CTNG_MSG_LOG([looking for '[$5]' regexp in])
|
CTNG_MSG_LOG([looking for '[$5]' regexp in])
|
||||||
CTNG_MSG_LOG_ENVVAR([ver], [version info])
|
CTNG_MSG_LOG_ENVVAR([ver], [version info])
|
||||||
ver=$(AS_ECHO(["$ver"]) | $EGREP '[$5]')
|
ver=$(AS_ECHO(["$ver"]) | $EGREP '[$5]')
|
||||||
|
@ -3,6 +3,6 @@ repository='git git://sourceware.org/git/glibc.git'
|
|||||||
mirrors='$(CT_Mirrors GNU glibc)'
|
mirrors='$(CT_Mirrors GNU glibc)'
|
||||||
# Cannot use MAJOR.MINOR as the releant part because of 2.12: 2.12.2 was the most recent
|
# Cannot use MAJOR.MINOR as the releant part because of 2.12: 2.12.2 was the most recent
|
||||||
# bugfix release, but it didn't have glibc-ports released alongside it.
|
# bugfix release, but it didn't have glibc-ports released alongside it.
|
||||||
milestones='2.14 2.17 2.20 2.23 2.24 2.25 2.26 2.27'
|
milestones='2.14 2.17 2.20 2.23 2.24 2.25 2.26 2.27 2.29'
|
||||||
archive_formats='.tar.xz .tar.bz2 .tar.gz'
|
archive_formats='.tar.xz .tar.bz2 .tar.gz'
|
||||||
signature_format='packed/.sig'
|
signature_format='packed/.sig'
|
||||||
|
@ -4,3 +4,4 @@ mirrors='$(CT_Mirrors GNU make)'
|
|||||||
relevantpattern='*.*|.'
|
relevantpattern='*.*|.'
|
||||||
archive_formats='.tar.bz2 .tar.gz'
|
archive_formats='.tar.bz2 .tar.gz'
|
||||||
signature_format='packed/.sig'
|
signature_format='packed/.sig'
|
||||||
|
milestones='4.0'
|
||||||
|
@ -6,6 +6,7 @@ export grep="@GREP@"
|
|||||||
export gmake="@MAKE@"
|
export gmake="@MAKE@"
|
||||||
export gnumake="@MAKE@"
|
export gnumake="@MAKE@"
|
||||||
export make="@MAKE@"
|
export make="@MAKE@"
|
||||||
|
export python="@PYTHON@"
|
||||||
export sed="@SED@"
|
export sed="@SED@"
|
||||||
export libtool="@LIBTOOL@"
|
export libtool="@LIBTOOL@"
|
||||||
export libtoolize="@LIBTOOLIZE@"
|
export libtoolize="@LIBTOOLIZE@"
|
||||||
|
@ -23,6 +23,9 @@ do_companion_tools_make_for_build()
|
|||||||
if [ "${CT_MAKE_GMAKE_SYMLINK}" = "y" ]; then
|
if [ "${CT_MAKE_GMAKE_SYMLINK}" = "y" ]; then
|
||||||
CT_DoExecLog ALL ln -sv make "${CT_BUILD_COMPTOOLS_DIR}/bin/gmake"
|
CT_DoExecLog ALL ln -sv make "${CT_BUILD_COMPTOOLS_DIR}/bin/gmake"
|
||||||
fi
|
fi
|
||||||
|
if [ "${CT_MAKE_GNUMAKE_SYMLINK}" = "y" ]; then
|
||||||
|
CT_DoExecLog ALL ln -sv make "${CT_BUILD_COMPTOOLS_DIR}/bin/gnumake"
|
||||||
|
fi
|
||||||
CT_EndStep
|
CT_EndStep
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -39,6 +42,9 @@ do_companion_tools_make_for_host()
|
|||||||
if [ "${CT_MAKE_GMAKE_SYMLINK}" = "y" ]; then
|
if [ "${CT_MAKE_GMAKE_SYMLINK}" = "y" ]; then
|
||||||
CT_DoExecLog ALL ln -sv make "${CT_PREFIX_DIR}/bin/gmake"
|
CT_DoExecLog ALL ln -sv make "${CT_PREFIX_DIR}/bin/gmake"
|
||||||
fi
|
fi
|
||||||
|
if [ "${CT_MAKE_GNUMAKE_SYMLINK}" = "y" ]; then
|
||||||
|
CT_DoExecLog ALL ln -sv make "${CT_PREFIX_DIR}/bin/gnumake"
|
||||||
|
fi
|
||||||
CT_EndStep
|
CT_EndStep
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -64,15 +64,12 @@ do_debug_gdb_build() {
|
|||||||
|
|
||||||
if [ "${CT_GDB_CROSS_PYTHON}" = "y" ]; then
|
if [ "${CT_GDB_CROSS_PYTHON}" = "y" ]; then
|
||||||
if [ -z "${CT_GDB_CROSS_PYTHON_BINARY}" ]; then
|
if [ -z "${CT_GDB_CROSS_PYTHON_BINARY}" ]; then
|
||||||
for p in python python3 python2; do
|
if [ "${CT_CANADIAN}" = "y" -o "${CT_CROSS_NATIVE}" = "y" ]; then
|
||||||
_p=$( which "${p}" || true )
|
CT_Abort "For canadian build, Python wrapper runnable on the build machine must be provided. Set CT_GDB_CROSS_PYTHON_BINARY."
|
||||||
if [ -n "${_p}" ]; then
|
elif [ "${CT_CONFIGURE_has_python}" = "y" ]; then
|
||||||
cross_extra_config+=("--with-python=${_p}")
|
cross_extra_config+=("--with-python=${python}")
|
||||||
break
|
else
|
||||||
fi
|
CT_Abort "Python support requested in GDB, but Python not found. Set CT_GDB_CROSS_PYTHON_BINARY."
|
||||||
done
|
|
||||||
if [ -z "${_p}" ]; then
|
|
||||||
CT_Abort "Python support requested in cross-gdb, but Python not found. Set CT_GDB_CROSS_PYTHON_BINARY in your config."
|
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
cross_extra_config+=("--with-python=${CT_GDB_CROSS_PYTHON_BINARY}")
|
cross_extra_config+=("--with-python=${CT_GDB_CROSS_PYTHON_BINARY}")
|
||||||
|
Loading…
Reference in New Issue
Block a user