!462 在glibc-compat-2.17中增加libpthread_nonshared.a

From: @yang_yanchao 
Reviewed-by: @liqingqing_1229 
Signed-off-by: @liqingqing_1229
This commit is contained in:
openeuler-ci-bot 2022-07-08 00:51:40 +00:00 committed by Gitee
commit fc6739d4ba
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F

View File

@ -66,7 +66,7 @@
############################################################################## ##############################################################################
Name: glibc Name: glibc
Version: 2.34 Version: 2.34
Release: 90 Release: 91
Summary: The GNU libc libraries Summary: The GNU libc libraries
License: %{all_license} License: %{all_license}
URL: http://www.gnu.org/software/glibc/ URL: http://www.gnu.org/software/glibc/
@ -516,7 +516,8 @@ Summary: provides pthread library with glibc-2.17
%description compat-2.17 %description compat-2.17
This subpackage to provide the function of the glibc-2.17 pthread library. This subpackage to provide the function of the glibc-2.17 pthread library.
Currently, provide pthread_condition function.. Currently, provide pthread_condition function.
To keep older applications compatible, glibc-compat-2.17 provides libpthread_nonshared.a
%endif %endif
############################################################################## ##############################################################################
@ -713,6 +714,9 @@ install -p -m 644 %{SOURCE2} $RPM_BUILD_ROOT/etc/nsswitch.conf
# This is for compat-2.17 # This is for compat-2.17
%if %{with compat_2_17} %if %{with compat_2_17}
install -p -m 755 build-%{target}/nptl/libpthread-2.17.so $RPM_BUILD_ROOT%{_libdir} install -p -m 755 build-%{target}/nptl/libpthread-2.17.so $RPM_BUILD_ROOT%{_libdir}
# Build an empty libpthread_nonshared.a for compatiliby with applications
# that have old linker scripts that reference this file.
ar cr $RPM_BUILD_ROOT/%{_prefix}/%{_lib}/libpthread_nonshared.a
%endif %endif
# This is for ncsd - in glibc 2.2 # This is for ncsd - in glibc 2.2
@ -850,6 +854,7 @@ touch compat-2.17.filelist
-e '\,.*%{_libdir}/lib\(pcprofile\|memusage\)\.so,d' \ -e '\,.*%{_libdir}/lib\(pcprofile\|memusage\)\.so,d' \
%if %{with compat_2_17} %if %{with compat_2_17}
-e '\,.*%{_libdir}/libpthread-2.17.so,d' \ -e '\,.*%{_libdir}/libpthread-2.17.so,d' \
-e '\,.*%{_libdir}/libpthread_nonshared.a,d' \
%endif %endif
-e '\,.*/bin/\(memusage\|mtrace\|xtrace\|pcprofiledump\),d' -e '\,.*/bin/\(memusage\|mtrace\|xtrace\|pcprofiledump\),d'
} | sort > master.filelist } | sort > master.filelist
@ -985,6 +990,7 @@ echo "%{_prefix}/libexec/glibc-benchtests/validate_benchout.py*" >> benchtests.f
# glibc compat-2.17 sub-package # glibc compat-2.17 sub-package
############################################################################## ##############################################################################
echo "%{_libdir}/libpthread-2.17.so" >> compat-2.17.filelist echo "%{_libdir}/libpthread-2.17.so" >> compat-2.17.filelist
echo "%{_libdir}/libpthread_nonshared.a" >> compat-2.17.filelist
%endif %endif
reliantlib="" reliantlib=""
@ -1401,6 +1407,9 @@ fi
%endif %endif
%changelog %changelog
* Wed Jul 6 2022 Yang Yanchao <yangyanchao6@huawei.com> - 2.34-91
- add libpthread_nonshared.a in glibc-compat-2.17 for old applications
* Wed Jul 6 2022 Qingqing Li <liqingqing3@huawei.com> - 2.34-90 * Wed Jul 6 2022 Qingqing Li <liqingqing3@huawei.com> - 2.34-90
- enable -werror by default - enable -werror by default