forked from pool/glibc
Accepting request 509776 from home:Andreas_Schwab:Factory
Reorganize spec file OBS-URL: https://build.opensuse.org/request/show/509776 OBS-URL: https://build.opensuse.org/package/show/Base:System/glibc?expand=0&rev=459
This commit is contained in:
parent
fede245d46
commit
fcaf5acc9a
95
glibc.spec
95
glibc.spec
@ -23,28 +23,25 @@
|
|||||||
%define crypt_bf_version 1.3
|
%define crypt_bf_version 1.3
|
||||||
%define build_snapshot 0
|
%define build_snapshot 0
|
||||||
|
|
||||||
%define utils_build ("@BUILD_FLAVOR@" == "utils")
|
%bcond_with all
|
||||||
%define testsuite_build ("@BUILD_FLAVOR@" == "testsuite")
|
%define build_main 1
|
||||||
%define normal_build !(%utils_build || %testsuite_build)
|
%define build_utils %{with all}
|
||||||
|
%define build_testsuite %{with all}
|
||||||
|
%if "@BUILD_FLAVOR@" == "utils"
|
||||||
|
%define build_main 0
|
||||||
|
%define build_utils 1
|
||||||
|
%define build_testsuite 0
|
||||||
|
%endif
|
||||||
|
%if "@BUILD_FLAVOR@" == "testsuite"
|
||||||
|
%define build_main 0
|
||||||
|
%define build_utils 0
|
||||||
|
%define build_testsuite 1
|
||||||
|
%endif
|
||||||
|
|
||||||
%if %normal_build
|
|
||||||
Name: glibc
|
Name: glibc
|
||||||
Summary: Standard Shared Libraries (from the GNU C Library)
|
Summary: Standard Shared Libraries (from the GNU C Library)
|
||||||
License: LGPL-2.1+ and SUSE-LGPL-2.1+-with-GCC-exception and GPL-2.0+
|
License: LGPL-2.1+ and SUSE-LGPL-2.1+-with-GCC-exception and GPL-2.0+
|
||||||
Group: System/Libraries
|
Group: System/Libraries
|
||||||
%endif
|
|
||||||
%if %utils_build
|
|
||||||
Name: glibc-utils
|
|
||||||
Summary: Development utilities from the GNU C Library
|
|
||||||
License: LGPL-2.1+
|
|
||||||
Group: Development/Languages/C and C++
|
|
||||||
%endif
|
|
||||||
%if %testsuite_build
|
|
||||||
Name: glibc-testsuite
|
|
||||||
Summary: Testsuite results from the GNU C Library
|
|
||||||
License: LGPL-2.1+
|
|
||||||
Group: Development/Languages/C and C++
|
|
||||||
%endif
|
|
||||||
BuildRequires: audit-devel
|
BuildRequires: audit-devel
|
||||||
BuildRequires: fdupes
|
BuildRequires: fdupes
|
||||||
BuildRequires: libcap-devel
|
BuildRequires: libcap-devel
|
||||||
@ -53,14 +50,14 @@ BuildRequires: makeinfo
|
|||||||
BuildRequires: pwdutils
|
BuildRequires: pwdutils
|
||||||
BuildRequires: systemd-rpm-macros
|
BuildRequires: systemd-rpm-macros
|
||||||
BuildRequires: xz
|
BuildRequires: xz
|
||||||
%if %{testsuite_build}
|
%if %{build_testsuite}
|
||||||
BuildRequires: gcc-c++
|
BuildRequires: gcc-c++
|
||||||
BuildRequires: gdb
|
BuildRequires: gdb
|
||||||
BuildRequires: glibc-devel-static
|
BuildRequires: glibc-devel-static
|
||||||
BuildRequires: libstdc++-devel
|
BuildRequires: libstdc++-devel
|
||||||
BuildRequires: python-pexpect
|
BuildRequires: python-pexpect
|
||||||
%endif
|
%endif
|
||||||
%if %{utils_build}
|
%if %{build_utils}
|
||||||
BuildRequires: gd-devel
|
BuildRequires: gd-devel
|
||||||
%endif
|
%endif
|
||||||
%if "@BUILD_FLAVOR@" == "i686"
|
%if "@BUILD_FLAVOR@" == "i686"
|
||||||
@ -77,7 +74,7 @@ BuildArch: i686
|
|||||||
%define build_locales 1
|
%define build_locales 1
|
||||||
%define build_html 0
|
%define build_html 0
|
||||||
%else
|
%else
|
||||||
%if %{with fast_build} || %{utils_build}
|
%if %{with fast_build} || %{build_utils} && %{without all}
|
||||||
%define build_profile 0
|
%define build_profile 0
|
||||||
%define build_locales 0
|
%define build_locales 0
|
||||||
%define build_html 0
|
%define build_html 0
|
||||||
@ -89,7 +86,7 @@ BuildArch: i686
|
|||||||
%endif
|
%endif
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%define build_variants %{normal_build}
|
%define build_variants %{build_main}
|
||||||
|
|
||||||
%define disable_assert 0
|
%define disable_assert 0
|
||||||
%define enable_stackguard_randomization 1
|
%define enable_stackguard_randomization 1
|
||||||
@ -151,7 +148,6 @@ Source50: http://www.openwall.com/crypt/crypt_blowfish-%{crypt_bf_version}
|
|||||||
# The sign key uses MD5 which is no longer accepted by gpg
|
# The sign key uses MD5 which is no longer accepted by gpg
|
||||||
#Source51: http://www.openwall.com/crypt/crypt_blowfish-%{crypt_bf_version}.tar.gz.sign
|
#Source51: http://www.openwall.com/crypt/crypt_blowfish-%{crypt_bf_version}.tar.gz.sign
|
||||||
|
|
||||||
%if %{normal_build}
|
|
||||||
# ngpt was used in 8.1 and SLES8
|
# ngpt was used in 8.1 and SLES8
|
||||||
Obsoletes: ngpt < 2.2.2
|
Obsoletes: ngpt < 2.2.2
|
||||||
Obsoletes: ngpt-devel < 2.2.2
|
Obsoletes: ngpt-devel < 2.2.2
|
||||||
@ -173,10 +169,6 @@ Provides: ld-linux.so.3(GLIBC_2.4)
|
|||||||
Requires(pre): filesystem
|
Requires(pre): filesystem
|
||||||
Recommends: glibc-extra
|
Recommends: glibc-extra
|
||||||
Provides: rtld(GNU_HASH)
|
Provides: rtld(GNU_HASH)
|
||||||
%endif # %{normal_build}
|
|
||||||
%if %{utils_build}
|
|
||||||
Requires: glibc = %{version}
|
|
||||||
%endif
|
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||||
%ifarch i686
|
%ifarch i686
|
||||||
# We need to avoid to have only the src rpm from i686 on the media,
|
# We need to avoid to have only the src rpm from i686 on the media,
|
||||||
@ -298,22 +290,31 @@ Patch2008: reinitialize-dl_load_write_lock.patch
|
|||||||
Patch3000: manpages.patch
|
Patch3000: manpages.patch
|
||||||
|
|
||||||
%description
|
%description
|
||||||
%if %{normal_build}
|
|
||||||
The GNU C Library provides the most important standard libraries used
|
The GNU C Library provides the most important standard libraries used
|
||||||
by nearly all programs: the standard C library, the standard math
|
by nearly all programs: the standard C library, the standard math
|
||||||
library, and the POSIX thread library. A system is not functional
|
library, and the POSIX thread library. A system is not functional
|
||||||
without these libraries.
|
without these libraries.
|
||||||
%endif
|
|
||||||
%if %{utils_build}
|
%package utils
|
||||||
|
Summary: Development utilities from the GNU C Library
|
||||||
|
License: LGPL-2.1+
|
||||||
|
Group: Development/Languages/C and C++
|
||||||
|
Requires: glibc = %{version}
|
||||||
|
|
||||||
|
%description utils
|
||||||
The glibc-utils package contains mtrace, a memory leak tracer and
|
The glibc-utils package contains mtrace, a memory leak tracer and
|
||||||
xtrace, a function call tracer which can be helpful during program
|
xtrace, a function call tracer which can be helpful during program
|
||||||
debugging.
|
debugging.
|
||||||
|
|
||||||
If you are unsure if you need this, do not install this package.
|
If you are unsure if you need this, do not install this package.
|
||||||
%endif
|
|
||||||
%if %{testsuite_build}
|
%package testsuite
|
||||||
This package runs the testsuite from the GNU C Library.
|
Summary: Testsuite results from the GNU C Library
|
||||||
%endif
|
License: LGPL-2.1+
|
||||||
|
Group: Development/Languages/C and C++
|
||||||
|
|
||||||
|
%description testsuite
|
||||||
|
This package contains the testsuite results from the GNU C Library.
|
||||||
|
|
||||||
%package info
|
%package info
|
||||||
Summary: Info Files for the GNU C Library
|
Summary: Info Files for the GNU C Library
|
||||||
@ -782,7 +783,7 @@ popd
|
|||||||
#######################################################################
|
#######################################################################
|
||||||
|
|
||||||
%check
|
%check
|
||||||
%if %{testsuite_build}
|
%if %{build_testsuite}
|
||||||
# The testsuite will fail if asneeded is used
|
# The testsuite will fail if asneeded is used
|
||||||
export SUSE_ASNEEDED=0
|
export SUSE_ASNEEDED=0
|
||||||
# Increase timeout
|
# Increase timeout
|
||||||
@ -824,7 +825,7 @@ make %{?_smp_mflags} -C cc-base check-abi
|
|||||||
#######################################################################
|
#######################################################################
|
||||||
|
|
||||||
%install
|
%install
|
||||||
%if %{normal_build}
|
%if %{build_main}
|
||||||
# We don't want to strip the .symtab from our libraries in find-debuginfo.sh,
|
# We don't want to strip the .symtab from our libraries in find-debuginfo.sh,
|
||||||
# certainly not from libpthread.so.* because it is used by libthread_db to find
|
# certainly not from libpthread.so.* because it is used by libthread_db to find
|
||||||
# some non-exported symbols in order to detect if threading support
|
# some non-exported symbols in order to detect if threading support
|
||||||
@ -1025,6 +1026,7 @@ ln -s ld-%{libversion}.so %{buildroot}/lib/ld-linux.so.3
|
|||||||
mv %{buildroot}%{_bindir}/getconf %{buildroot}%{_libexecdir}/getconf/getconf
|
mv %{buildroot}%{_bindir}/getconf %{buildroot}%{_libexecdir}/getconf/getconf
|
||||||
ln -s %{_libexecdir}/getconf/getconf %{buildroot}%{_bindir}/getconf
|
ln -s %{_libexecdir}/getconf/getconf %{buildroot}%{_bindir}/getconf
|
||||||
|
|
||||||
|
%if !%{build_utils}
|
||||||
# Remove unwanted files (packaged in glibc-utils)
|
# Remove unwanted files (packaged in glibc-utils)
|
||||||
rm -f %{buildroot}/%{_lib}/libmemusage*
|
rm -f %{buildroot}/%{_lib}/libmemusage*
|
||||||
rm -f %{buildroot}/%{_lib}/libpcprofile*
|
rm -f %{buildroot}/%{_lib}/libpcprofile*
|
||||||
@ -1042,6 +1044,7 @@ rm -rf %{buildroot}%{_infodir} %{buildroot}%{_prefix}/share/i18n
|
|||||||
rm -f %{buildroot}%{_bindir}/makedb %{buildroot}/var/lib/misc/Makefile
|
rm -f %{buildroot}%{_bindir}/makedb %{buildroot}/var/lib/misc/Makefile
|
||||||
rm -f %{buildroot}%{_sbindir}/nscd
|
rm -f %{buildroot}%{_sbindir}/nscd
|
||||||
%endif # i686
|
%endif # i686
|
||||||
|
%endif # !utils
|
||||||
|
|
||||||
# LSB
|
# LSB
|
||||||
%ifarch %ix86
|
%ifarch %ix86
|
||||||
@ -1063,9 +1066,9 @@ ln -sf /%{_lib}/ld.so.1 $RPM_BUILD_ROOT/%{_lib}/ld-lsb-s390.so.3
|
|||||||
ln -sf /%{_lib}/ld64.so.1 $RPM_BUILD_ROOT/%{_lib}/ld-lsb-s390x.so.3
|
ln -sf /%{_lib}/ld64.so.1 $RPM_BUILD_ROOT/%{_lib}/ld-lsb-s390x.so.3
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%endif # %{normal_build}
|
%else # !main
|
||||||
|
|
||||||
%if %{utils_build}
|
%if %{build_utils}
|
||||||
|
|
||||||
make %{?_smp_mflags} install_root=%{buildroot} install -C cc-base \
|
make %{?_smp_mflags} install_root=%{buildroot} install -C cc-base \
|
||||||
subdirs='malloc debug elf'
|
subdirs='malloc debug elf'
|
||||||
@ -1078,7 +1081,9 @@ rm -f %{buildroot}%{_bindir}/{catchsegv,ldd*,sprof}
|
|||||||
rm -rf %{buildroot}%{_mandir}/man*
|
rm -rf %{buildroot}%{_mandir}/man*
|
||||||
rm -rf %{buildroot}/sbin %{buildroot}%{_includedir}
|
rm -rf %{buildroot}/sbin %{buildroot}%{_includedir}
|
||||||
|
|
||||||
%endif # %{utils_build}
|
%endif # utils
|
||||||
|
|
||||||
|
%endif # !main
|
||||||
|
|
||||||
#######################################################################
|
#######################################################################
|
||||||
###
|
###
|
||||||
@ -1086,13 +1091,9 @@ rm -rf %{buildroot}/sbin %{buildroot}%{_includedir}
|
|||||||
###
|
###
|
||||||
#######################################################################
|
#######################################################################
|
||||||
|
|
||||||
%if %{normal_build}
|
|
||||||
%post -p %{_sbindir}/glibc_post_upgrade
|
%post -p %{_sbindir}/glibc_post_upgrade
|
||||||
|
|
||||||
%postun -p /sbin/ldconfig
|
%postun -p /sbin/ldconfig
|
||||||
|
|
||||||
%endif # %{normal_build}
|
|
||||||
|
|
||||||
%post locale
|
%post locale
|
||||||
for l in /usr/share/locale/locale.alias %{_libdir}/gconv/gconv-modules; do
|
for l in /usr/share/locale/locale.alias %{_libdir}/gconv/gconv-modules; do
|
||||||
[ -d "$l.d" ] || continue
|
[ -d "$l.d" ] || continue
|
||||||
@ -1129,7 +1130,7 @@ exit 0
|
|||||||
%service_del_postun nscd.service
|
%service_del_postun nscd.service
|
||||||
exit 0
|
exit 0
|
||||||
|
|
||||||
%if %{normal_build}
|
%if %{build_main}
|
||||||
%files
|
%files
|
||||||
#######################################################################
|
#######################################################################
|
||||||
###
|
###
|
||||||
@ -1412,10 +1413,10 @@ exit 0
|
|||||||
/var/lib/misc/Makefile
|
/var/lib/misc/Makefile
|
||||||
%endif # !i686
|
%endif # !i686
|
||||||
|
|
||||||
%endif # %{normal_build}
|
%endif # main
|
||||||
|
|
||||||
%if %{utils_build}
|
%if %{build_utils}
|
||||||
%files
|
%files utils
|
||||||
%defattr(-,root,root)
|
%defattr(-,root,root)
|
||||||
/%{_lib}/libmemusage.so
|
/%{_lib}/libmemusage.so
|
||||||
/%{_lib}/libpcprofile.so
|
/%{_lib}/libpcprofile.so
|
||||||
@ -1428,6 +1429,6 @@ exit 0
|
|||||||
%{_bindir}/sotruss
|
%{_bindir}/sotruss
|
||||||
%{_bindir}/xtrace
|
%{_bindir}/xtrace
|
||||||
%{_bindir}/pldd
|
%{_bindir}/pldd
|
||||||
%endif # %{utils_build}
|
%endif # utils
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
Loading…
x
Reference in New Issue
Block a user