Package init

This commit is contained in:
overweight 2019-09-30 10:58:33 -04:00
commit 2e304da504
8 changed files with 302 additions and 0 deletions

35
libtool-2.4.5-rpath.patch Normal file
View File

@ -0,0 +1,35 @@
From f7e477ec085414991c8160c7394bfaf2b1425c67 Mon Sep 17 00:00:00 2001
From: Karsten Hopp <karsten@fedoraproject.org>
Date: Wed, 29 Oct 2014 13:27:27 +0100
Subject: [PATCH] remove /lib64 and /usr/lib64 rpath
---
m4/libtool.m4 | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/m4/libtool.m4 b/m4/libtool.m4
index f796d7b..41dd20a 100644
--- a/m4/libtool.m4
+++ b/m4/libtool.m4
@@ -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* 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*)
# appending ld.so.conf contents (and includes) to the search path.
if test -f /etc/ld.so.conf; then
lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
- sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
+ sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra"
fi
# We used to test for /lib/ld.so.1 and disable shared libraries on
--
2.1.0

View File

@ -0,0 +1,35 @@
Ensure that $(LIBLTDL) is built first
After Automake upstream commit f4e91bfc490d, the list in 'all-am:' is
reordered for this test-case (*_LTLIBRARIES is before *_PROGRAMS), which
means that linker will fail to link 'old' binary.
Previously (with automake <= 1.16), it was matter of luck -- it worked if
(a) the build was serial (-j1), and/or (b) libtool-ltdl-devel package was
installed on the box so ./configure picked the system version of libltdl.
Users should anyways use system's ltdl, so this has low priority.
diff --git a/tests/old-ltdl-iface.at b/tests/old-ltdl-iface.at
index cee29089..6f9c8001 100644
--- a/tests/old-ltdl-iface.at
+++ b/tests/old-ltdl-iface.at
@@ -62,6 +62,9 @@ MOSTLYCLEANFILES =
include ltdl/Makefile.inc
bin_PROGRAMS = old
old_LDADD = -Lltdl $(LIBLTDL)
+# TODO: if --with-included-ltdl was unused this would
+# generate useless dependency.
+old_DEPENDENCIES = $(LIBLTDL)
]])
AT_DATA([old.c],
@@ -131,7 +134,7 @@ LT_AT_CHECK_LIBTOOLIZE([--ltdl=ltdl --nonrecursive --install], 0, [expout], [exp
AT_CHECK([test -f ltdl/Makefile.inc])
-LT_AT_BOOTSTRAP([ignore], [-I m4], [], [--add-missing], [--force])
+LT_AT_BOOTSTRAP([ignore], [-I m4], [], [--add-missing], [--force], [--with-included-ltdl])
LT_AT_EXEC_CHECK([./old], 0, [[...]])

View File

@ -0,0 +1,34 @@
From 350082b6aa89f9ef603fcebbb4cf33f15a743f2f Mon Sep 17 00:00:00 2001
From: Bert Wesarg <bert.wesarg@googlemail.com>
Date: Mon, 13 Jun 2016 22:28:47 +0200
Subject: [PATCH] libtool: exit verbosely for fatal configure problems
Instead of calling not-existing function and processing subsequent
shell code.
* build-aux/ltmain.in (func_fatal_configuration): Fix typo in
func_fatal_error call.
Copyright-paperwork-exempt: Yes
Upstream: 350082b6aa89f9ef603fcebbb4cf33f15a743f2f
---
build-aux/ltmain.in | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/build-aux/ltmain.in b/build-aux/ltmain.in
index 0ad021db..c3058f21 100644
--- a/build-aux/ltmain.in
+++ b/build-aux/ltmain.in
@@ -212,7 +212,7 @@ fi
# a configuration failure hint, and exit.
func_fatal_configuration ()
{
- func__fatal_error ${1+"$@"} \
+ func_fatal_error ${1+"$@"} \
"See the $PACKAGE documentation for more information." \
"Fatal configuration error."
}
--
2.17.1

View File

@ -0,0 +1,14 @@
diff --git a/Makefile.am b/Makefile.am
index 13dfc63..5c5603a 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -311,6 +311,9 @@ libtool: $(ltmain_sh) $(config_status) $(dotversion)
include libltdl/ltdl.mk
+libltdl_libltdl_la_CPPFLAGS += $(CUSTOM_LTDL_CFLAGS)
+libltdl_libltdl_la_LDFLAGS += $(CUSTOM_LTDL_LDFLAGS)
+
lt_aclocal_m4 = $(srcdir)/$(ltdl_dir)/aclocal.m4
lt_config_h_in = $(srcdir)/$(ltdl_dir)/config-h.in
lt_configure = $(srcdir)/$(ltdl_dir)/configure

37
libtool-2.4.6-specs.patch Normal file
View File

@ -0,0 +1,37 @@
From 702a97fbb09bd7088a50f2b239016d1e32843c24 Mon Sep 17 00:00:00 2001
From: Pavel Raiskup <praiskup@redhat.com>
Date: Fri, 18 Sep 2015 10:36:43 +0200
Subject: libtool: fix GCC linking with -specs=*
References:
https://bugzilla.redhat.com/show_bug.cgi?id=985592
* build-aux/ltmain.in (func_mode_link): Pass -specs=*
to the linker, Fedora uses this option for hardening.
Signed-off-by: Pavel Raiskup <praiskup@redhat.com>
---
build-aux/ltmain.in | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/build-aux/ltmain.in b/build-aux/ltmain.in
index d5cf07a..0c40da0 100644
--- a/build-aux/ltmain.in
+++ b/build-aux/ltmain.in
@@ -5360,10 +5360,12 @@ func_mode_link ()
# -tp=* Portland pgcc target processor selection
# --sysroot=* for sysroot support
# -O*, -g*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization
+ # -specs=* GCC specs files
# -stdlib=* select c++ std lib with clang
-64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \
-t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \
- -O*|-g*|-flto*|-fwhopr*|-fuse-linker-plugin|-fstack-protector*|-stdlib=*)
+ -O*|-g*|-flto*|-fwhopr*|-fuse-linker-plugin|-fstack-protector*|-stdlib=*| \
+ -specs=*)
func_quote_for_eval "$arg"
arg=$func_quote_for_eval_result
func_append compile_command " $arg"
--
cgit v1.0-41-gc330

BIN
libtool-2.4.6.tar.xz Normal file

Binary file not shown.

40
libtool-nodocs.patch Normal file
View File

@ -0,0 +1,40 @@
diff -up libtool-2.4.6/Makefile.in.nodocs libtool-2.4.6/Makefile.in
--- libtool-2.4.6/Makefile.in.nodocs 2017-04-21 12:46:20.704300023 +0200
+++ libtool-2.4.6/Makefile.in 2017-04-21 12:46:42.696840234 +0200
@@ -313,12 +313,11 @@ MAKEINFOHTML = $(MAKEINFO) --html
AM_MAKEINFOHTMLFLAGS = $(AM_MAKEINFOFLAGS)
DVIPS = dvips
RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \
- ctags-recursive dvi-recursive html-recursive info-recursive \
- install-data-recursive install-dvi-recursive \
- install-exec-recursive install-html-recursive \
- install-info-recursive install-pdf-recursive \
- install-ps-recursive install-recursive installcheck-recursive \
- installdirs-recursive pdf-recursive ps-recursive \
+ ctags-recursive \
+ install-data-recursive \
+ install-exec-recursive \
+ install-recursive installcheck-recursive \
+ installdirs-recursive \
tags-recursive uninstall-recursive
am__can_run_installinfo = \
case $$AM_UPDATE_INFO_DIR in \
@@ -361,8 +360,7 @@ am__define_uniq_tagged_files = \
ETAGS = etags
CTAGS = ctags
CSCOPE = cscope
-am__DIST_COMMON = $(dist_man1_MANS) $(doc_libtool_TEXINFOS) \
- $(srcdir)/Makefile.in $(srcdir)/config-h.in \
+am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/config-h.in \
$(srcdir)/libltdl/ltdl.mk $(top_srcdir)/build-aux/compile \
$(top_srcdir)/build-aux/config.guess \
$(top_srcdir)/build-aux/config.sub \
@@ -1973,7 +1971,7 @@ info: info-recursive
info-am: $(INFO_DEPS)
install-data-am: install-data-local install-includeHEADERS \
- install-info-am install-ltdlincludeHEADERS install-man
+ install-ltdlincludeHEADERS
install-dvi: install-dvi-recursive

107
libtool.spec Normal file
View File

@ -0,0 +1,107 @@
%undefine _hardened_build
%global gcc_major 7.3.0
Name: libtool
Version: 2.4.6
Release: 29
License: GPLv2+ and LGPLv2+ and GFDL
Summary: The GNU Portable Library Tool
URL: http://www.gnu.org/software/libtool/
Source0: http://ftp.gnu.org/gnu/libtool/libtool-%{version}.tar.xz
Patch0: libtool-2.4.5-rpath.patch
Patch1: libtool-2.4.6-am-1.16-test.patch
Patch2: libtool-2.4.6-specs.patch
Patch3: libtool-2.4.6-hardening.patch
Patch4: libtool-2.4.6-fatal-handler.patch
Patch5: libtool-nodocs.patch
Requires: gcc(major),autoconf, automake, sed, tar, findutils
BuildRequires: texinfo,autoconf, automake,help2man
BuildRequires: libstdc++-devel, gcc-gfortran,gcc, gcc-c++
Provides: %{name}-ltdl
Obsoletes: %{name}-ltdl
%description
GNU libtool is a generic library support script.
Libtool hides the complexity of using shared libraries behind a consistent, portable interface.
%package devel
Summary: Tools needed for development using the GNU Libtool Dynamic Module Loader
License: LGPLv2+
Requires: automake
Requires: %{name} = %{version}-%{release}
Provides: %{name}-ltdl-devel
Obsoletes: %{name}-ltdl-devel
%description devel
Static libraries and header files for development with ltdl.
%package_help
%prep
%autosetup -n libtool-%{version} -p1
autoreconf -v
%build
export CC=gcc
export CXX=g++
export F77=gfortran
export CFLAGS="$RPM_OPT_FLAGS -fPIC"
export FFLAGS=$(echo "$RPM_OPT_FLAGS -I/usr/lib64/gfortran/modules"| sed 's/-fstack-protector-strong/ /g')
export FCFLAGS=$(echo "$RPM_OPT_FLAGS -I/usr/lib64/gfortran/modules"| sed 's/-fstack-protector-strong/ /g')
%configure
%make_build CUSTOM_LTDL_CFLAGS="%_hardening_cflags" CUSTOM_LTDL_LDFLAGS="%_hardening_ldflags"
%check
make check VERBOSE=yes
%install
%make_install
rm -f %{buildroot}%{_infodir}/dir
rm -f %{buildroot}%{_libdir}/libltdl.{a,la}
%files
%license COPYING
%license libltdl/COPYING.LIB
%doc AUTHORS NEWS THANKS TODO ChangeLog*
%{_bindir}/libtool
%{_bindir}/libtoolize
%{_libdir}/libltdl.so.*
%{_datadir}/aclocal/*.m4
%dir %{_datadir}/libtool
%{_datadir}/libtool/build-aux
%files devel
%license libltdl/COPYING.LIB
%doc libltdl/README
%{_datadir}/libtool
%exclude %{_datadir}/libtool/build-aux
%{_includedir}/ltdl.h
%{_includedir}/libltdl
%{_libdir}/libltdl.so
%files help
%doc README
%{_infodir}/libtool.info*.gz
%{_mandir}/man1/libtool.1*
%{_mandir}/man1/libtoolize.1*
%changelog
* Thu Sep 5 2019 openEuler Buildteam <buildteam@openeuler.org> - 2.4.6-29
- Package init
* Sun Feb 24 2019 zoujing <zoujing13@huawei.com> - 2.4.6-28
- Type:NA
- ID:NA
- SUG:NA
- DESC: change gcc version number on aarch64