!83 Generate available relocations for sysboost

From: @ironictwist 
Reviewed-by: @overweight 
Signed-off-by: @overweight
This commit is contained in:
openeuler-ci-bot 2023-05-12 10:36:14 +00:00 committed by Gitee
commit d0261965fe
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F

View File

@ -1,6 +1,6 @@
Name: bash
Version: 5.1.8
Release: 7
Release: 8
Summary: It is the Bourne Again Shell
License: GPLv3
URL: https://www.gnu.org/software/bash
@ -56,6 +56,14 @@ Requires: pkgconf-pkg-config
%description devel
This package contains development files for %{name}.
%package reloc
Summary: Relocations for %{name}
Requires: %{name} = %{version}-%{release}
BuildRequires: sysboost-devel
%description reloc
This package contains relocations for %{name}.
%package help
Summary: Documents for %{name}
Buildarch: noarch
@ -71,12 +79,14 @@ Man pages and other related documents for %{name}.
%build
autoconf
%configure --with-bash-malloc=no --with-afs
%configure --with-bash-malloc=no --with-afs LDFLAGS="-Wl,--emit-relocs"
MFLAGS="CPPFLAGS=-D_GNU_SOURCE -DRECYCLES_PIDS -DDEFAULT_PATH_VALUE='\"/usr/local/bin:/usr/bin\"' `getconf LFS_CFLAGS`"
make "$MFLAGS" version.h
make "$MFLAGS" -C builtins
%make_build "$MFLAGS"
objreloc $RPM_BUILD_DIR/%{name}-%{version}/bash
%install
%make_install install-headers
ln -sf bash %{buildroot}%{_bindir}/sh
@ -85,6 +95,8 @@ install -pDm 644 %SOURCE2 %{buildroot}/etc/skel/.bash_profile
install -pDm 644 %SOURCE3 %{buildroot}/etc/skel/.bash_logout
install -pDm 644 ./configs/alias.sh %{buildroot}%{_sysconfdir}/profile.d/alias.sh
install -pDm 750 $RPM_BUILD_DIR/%{name}-%{version}/bash.relocation %{buildroot}%{_bindir}/bash.relocation
# bug #820192, need to add execable alternatives for regular built-ins
for ea in alias bg cd command fc fg getopts hash jobs read type ulimit umask unalias wait
do
@ -108,6 +120,10 @@ make check
%{_bindir}/{hash,getopts,jobs,read,type,ulimit,umask,unalias}
%config(noreplace) %{_sysconfdir}/profile.d/alias.sh
%files reloc
%defattr(744,root,root)
%{_bindir}/bash.relocation
%files devel
%defattr(-,root,root)
%{_includedir}/%{name}
@ -125,6 +141,12 @@ make check
%exclude %{_infodir}/dir
%changelog
* Sat May 6 2023 liutie <liutie4@huawei.com> -5.1.8-8
- Type:enhancement
- ID:NA
- SUG:NA
- DESC: Generate available relocations for sysboost
* Mon Jan 16 2023 wangyuhang <wangyuhang27@huawei.com> -5.1.8-7
- Type:bugfix
- ID:NA
@ -290,4 +312,4 @@ make check
- DESC:1000 Forbidden non root user to clear history
* Mon Oct 08 2018 licunlong <licunlong@huawei.com> - 4.4.23-5
- Package Initialization
- Package Initialization