revert to use pie links and change position of bash.relocation

This commit is contained in:
lw 2023-08-09 16:51:14 +08:00
parent 21a2fc53a5
commit e45fabed9d

View File

@ -1,12 +1,12 @@
%global ENABLE_RELOC 1
%if %{ENABLE_RELOC}
%global ldflags_options -Wl,--emit-relocs
%global ldflags_options -Wl,--emit-relocs,-pie
%endif
Name: bash
Version: 5.2.15
Release: 1
Release: 3
Summary: It is the Bourne Again Shell
License: GPLv3
URL: https://www.gnu.org/software/bash
@ -96,7 +96,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
%if %{?ENABLE_RELOC}
install -pD $RPM_BUILD_DIR/%{name}-%{version}/bash.relocation %{buildroot}%{_bindir}/bash.relocation
mkdir -p ${RPM_BUILD_ROOT}/usr/lib/relocation%{_libdir}
install -pD $RPM_BUILD_DIR/%{name}-%{version}/bash.relocation ${RPM_BUILD_ROOT}/usr/lib/relocation%{_libdir}
%endif
# bug #820192, need to add execable alternatives for regular built-ins
@ -126,7 +127,7 @@ make check
%files relocation
%defattr(400,root,root,-)
%dir %attr(500, root, root) %{_bindir}
%attr(400, root, root) %{_bindir}/bash.relocation
%attr(400, root, root) /usr/lib/relocation%{_libdir}/bash.relocation
%endif
%files devel
@ -146,6 +147,12 @@ make check
%exclude %{_infodir}/dir
%changelog
* Mon Aug 8 2023 longwei <longwei27@huawei.com> -5.2.15-3
- Type:enhancement
- ID:NA
- SUG:NA
- DESC:revert to use pie links and change position of bash.relocation
* Fri Aug 4 2023 longwei <longwei27@huawei.com> -5.2.15-2
- Type:enhancement
- ID:NA