Compare commits

..

2 Commits

Author SHA1 Message Date
openeuler-ci-bot 03b8a345e1 !26 [sync] PR-22: pass -Wl,xxx options before libraries
From: @openeuler-sync-bot 
Reviewed-by: @gaoruoshu 
Signed-off-by: @gaoruoshu
2024-10-25 02:02:10 +00:00
Funda Wang b4d3244b98 pass -Wl,xxx options before libraries
(cherry picked from commit 50fc2e7ba9)
2024-10-24 11:45:34 +08:00
7 changed files with 40 additions and 95 deletions
-39
View File
@@ -1,39 +0,0 @@
From 80ff97af5d5686e071816af16f65d98af5116238 Mon Sep 17 00:00:00 2001
From: Hailiang <mahailiang@uniontech.com>
Date: Tue, 11 Mar 2025 13:43:07 +0800
Subject: [PATCH] add sw_64 support
---
build-aux/config.guess | 3 +++
build-aux/config.sub | 1 +
2 files changed, 4 insertions(+)
diff --git a/build-aux/config.guess b/build-aux/config.guess
index 48a6846..a5fa853 100755
--- a/build-aux/config.guess
+++ b/build-aux/config.guess
@@ -1186,6 +1186,9 @@ EOF
sparc:Linux:*:* | sparc64:Linux:*:*)
GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
;;
+ sw_64*:Linux:*:*)
+ GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
+ ;;
tile*:Linux:*:*)
GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
;;
diff --git a/build-aux/config.sub b/build-aux/config.sub
index 4aaae46..ada8a42 100755
--- a/build-aux/config.sub
+++ b/build-aux/config.sub
@@ -1432,6 +1432,7 @@ case $cpu-$vendor in
| spu \
| sv1 \
| sx* \
+ | sw_64 \
| tahoe \
| thumbv7* \
| tic30 \
--
2.20.1
@@ -0,0 +1,31 @@
From 1e13a1944f725ccc24bce1a2fa6f9009ba8a2270 Mon Sep 17 00:00:00 2001
From: Andreas Stieger <Andreas.Stieger@gmx.de>
Date: Sun, 4 Sep 2022 22:24:41 +0200
Subject: [PATCH] tests/link-order.at: avoid warning and test failure with GNU
grep 3.8
---
tests/link-order.at | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/tests/link-order.at b/tests/link-order.at
index 3f01a00..a145347 100644
--- a/tests/link-order.at
+++ b/tests/link-order.at
@@ -99,12 +99,12 @@ aix* | interix*) ;; # These systems have different path syntax
case $hardcode_direct$hardcode_direct_absolute in
yesno)
AT_CHECK([if $EGREP relinking stderr; then
- $EGREP " .*\/new\/lib/libb$shared_ext .*\/old\/lib/libcee$shared_ext" stdout
+ $EGREP " .*/new/lib/libb$shared_ext .*/old/lib/libcee$shared_ext" stdout
else :; fi], [0], [ignore], [], [echo "wrong link order"])
;;
*)
AT_CHECK([if $EGREP relinking stderr; then
- $EGREP " -L.*\/new\/lib -lb -L.*\/old\/lib -lcee" stdout
+ $EGREP " -L.*/new/lib -lb -L.*/old/lib -lcee" stdout
else :; fi], [0], [ignore], [], [echo "wrong link order"])
;;
esac
--
2.27.0
@@ -11,14 +11,14 @@ diff --git a/m4/libtool.m4 b/m4/libtool.m4
index f796d7b..41dd20a 100644
--- a/m4/libtool.m4
+++ b/m4/libtool.m4
@@ -2930,6 +2930,9 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
@@ -2866,6 +2866,9 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
# before this can be enabled.
hardcode_into_libs=yes
+ # Add ABI-specific directories to the system library path.
+ sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib"
+
# Ideally, we could use ldconfig to report *all* directories which are
# Ideally, we could use ldconfig to report *all* directores which are
# searched for libraries, however this is still not possible. Aside from not
# being certain /sbin/ldconfig is available, command
@@ -2874,7 +2877,7 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
@@ -1,17 +0,0 @@
diff -up ./m4/ltdl.m4.orig ./m4/ltdl.m4
--- ./m4/ltdl.m4.orig 2016-02-11 20:40:28.013253981 +0200
+++ ./m4/ltdl.m4 2016-02-11 20:41:07.142760471 +0200
@@ -282,8 +282,11 @@ AC_ARG_WITH([ltdl_lib],
[use the libltdl.la installed in DIR])])
if test -n "$with_ltdl_lib"; then
- if test -f "$with_ltdl_lib/libltdl.la"; then :
- else
+ # check for the existence of "$with_ltdl_lib/libltdl.la" while
+ # allowing people to delete the libtool archive file (which isn't
+ # useful in this case in many common platforms.)
+ with_ltdl_lib_libname=`echo "$with_ltdl_lib"/libltdl.*`
+ if test "x$with_ltdl_lib_libname" = "x$with_ltdl_lib/libltdl.*"; then
AC_MSG_ERROR([invalid ltdl library directory: '$with_ltdl_lib'])
fi
else
Binary file not shown.
Binary file not shown.
+7 -37
View File
@@ -2,17 +2,16 @@
%global gcc_major 7.3.0
Name: libtool
Version: 2.5.4
Release: 3
Version: 2.4.7
Release: 4
License: GPL-2.0-or-later AND LGPL-2.0-or-later and GFDL-1.3-or-later
Summary: The GNU Portable Library Tool
URL: https://www.gnu.org/software/libtool/
Source0: https://ftp.gnu.org/gnu/libtool/libtool-%{version}.tar.xz
Patch0: libtool-2.5.3-rpath.patch
Patch0: libtool-2.4.5-rpath.patch
Patch1: libtool-2.4.6-disable-lto-link-order2.patch
Patch2: add-sw_64-support.patch
Patch3: libtool-2.4.6-fix-building-without-libltdl.la.patch
Patch6000: backport-tests-link-order.at-avoid-warning-and-test-failure.patch
Requires: gcc(major),autoconf, automake, sed, tar, findutils
@@ -99,26 +98,8 @@ rm -f %{buildroot}%{_infodir}/dir
%files devel
%license libltdl/COPYING.LIB
%doc libltdl/README
%{_datadir}/libtool/COPYING.LIB
%{_datadir}/libtool/Makefile.am
%{_datadir}/libtool/Makefile.in
%{_datadir}/libtool/README
%{_datadir}/libtool/aclocal.m4
%{_datadir}/libtool/config-h.in
%{_datadir}/libtool/configure
%{_datadir}/libtool/configure.ac
%{_datadir}/libtool/libltdl
%{_datadir}/libtool/loaders
%{_datadir}/libtool/lt__alloc.c
%{_datadir}/libtool/lt__argz.c
%{_datadir}/libtool/lt__dirent.c
%{_datadir}/libtool/lt__strl.c
%{_datadir}/libtool/lt_dlloader.c
%{_datadir}/libtool/lt_error.c
%{_datadir}/libtool/ltdl.c
%{_datadir}/libtool/ltdl.h
%{_datadir}/libtool/ltdl.mk
%{_datadir}/libtool/slist.c
%{_datadir}/libtool
%exclude %{_datadir}/libtool/build-aux
%{_includedir}/ltdl.h
%{_includedir}/libltdl
%{_libdir}/libltdl.so
@@ -129,19 +110,8 @@ rm -f %{buildroot}%{_infodir}/dir
%{_mandir}/man1/libtool.1*
%{_mandir}/man1/libtoolize.1*
%changelog
* Fri Apr 04 2025 Funda Wang <fundawang@yeah.net> - 2.5.4-3
- fix building packages without libltdl.la
* Tue Mar 11 2025 mahailiang <mahailiang@uniontech.com> - 2.5.4-2
- add sw_64 support
* Thu Nov 21 2024 Funda Wang <fundawang@yeah.net> - 2.5.4-1
- update to 2.5.4
* Tue Oct 08 2024 Funda Wang <fundawang@yeah.net> - 2.5.3-1
- update to 2.5.3
* Thu Sep 26 2024 Funda Wang <fundawang@yeah.net> - 2.4.7-4
- pass -Wl,xxx options before libraries
- disable LTO for link-order2 test