From b4e77fc74d12039c3557268cb833d97aa3fd8d57 Mon Sep 17 00:00:00 2001 From: xiaolin-vmware Date: Tue, 6 Oct 2015 14:51:17 -0700 Subject: [PATCH] Disable static lib, move header files, .so and config files to util-linux devel package. Disable static lib, move header files, .so and config files to util- linux devel package. Change-Id: I0fc6d064aa62eb628ed9ecc96ed0a37419a76722 Reviewed-on: http://photon-jenkins.eng.vmware.com/41 Tested-by: jenkins-photon Reviewed-by: Touseef Liaqat --- SPECS/util-linux/util-linux.spec | 24 +++++++++++++++++------ support/package-builder/ToolChainUtils.py | 6 ++++++ support/package-builder/constants.py | 6 +++--- 3 files changed, 27 insertions(+), 9 deletions(-) diff --git a/SPECS/util-linux/util-linux.spec b/SPECS/util-linux/util-linux.spec index 4a16cc8d8f..f5c22fc05a 100644 --- a/SPECS/util-linux/util-linux.spec +++ b/SPECS/util-linux/util-linux.spec @@ -1,7 +1,7 @@ Summary: Utilities for file systems, consoles, partitions, and messages Name: util-linux Version: 2.24.1 -Release: 2%{?dist} +Release: 3%{?dist} URL: http://www.kernel.org/pub/linux/utils/util-linux License: GPLv2+ Group: Applications/System @@ -21,13 +21,21 @@ Requires: util-linux >= 2.24.1 %description lang These are the additional language files of util-linux. +%package devel +Summary: Header and library files for util-linux +Group: Development/Libraries +Requires: util-linux >= 2.24.1 +%description devel +These are the header and library files of util-linux. + %prep %setup -q sed -i -e 's@etc/adjtime@var/lib/hwclock/adjtime@g' $(grep -rl '/etc/adjtime' .) %build ./configure \ --disable-nologin \ - --disable-silent-rules + --disable-silent-rules \ + --disable-static make %{?_smp_mflags} %install install -vdm 755 %{buildroot}%{_sharedstatedir}/hwclock @@ -44,10 +52,6 @@ find %{buildroot} -name '*.la' -delete /lib/*.so.* /sbin/* %{_bindir}/* -%{_libdir}/*.so -%{_libdir}/*.a -%{_libdir}/pkgconfig/*.pc -%{_includedir}/* %{_sbindir}/* %{_mandir}/*/* %{_datadir}/bash-completion/completions/* @@ -56,7 +60,15 @@ find %{buildroot} -name '*.la' -delete %files lang -f %{name}.lang %defattr(-,root,root) +%files devel +%defattr(-,root,root) +%{_libdir}/pkgconfig/*.pc +%{_libdir}/*.so +%{_includedir}/* + %changelog +* Tue Oct 6 2015 Xiaolin Li 2.24.1-3 +- Disable static, move header files, .so and config files to devel package. * Mon May 18 2015 Touseef Liaqat 2.24.1-2 - Update according to UsrMove. * Wed Nov 5 2014 Divya Thaluru 2.24.1-1 diff --git a/support/package-builder/ToolChainUtils.py b/support/package-builder/ToolChainUtils.py index 1e6b5c892c..35f910a1bd 100644 --- a/support/package-builder/ToolChainUtils.py +++ b/support/package-builder/ToolChainUtils.py @@ -90,6 +90,9 @@ def installToolChain(self,chrootID): if rpmFile is None: rpmFile=self.findRPMFileInGivenLocation(package, constants.prevPublishRPMRepo) if rpmFile is None: + if package == "util-linux-devel": + self.logger.info("No old verion of util-linux-devel exists, skip until the new version is built") + continue self.logger.error("Unable to find rpm "+ package +" in current and previous versions") raise "Input Error" rpmFiles += " " + rpmFile @@ -198,6 +201,9 @@ def installToolChainRPMS(self,chrootID): if rpmFile is None: rpmFile=self.findRPMFileInGivenLocation(package, constants.prevPublishRPMRepo) if rpmFile is None: + if package == "util-linux-devel": + self.logger.info("No old verion of util-linux-devel exists, skip until the new version is built") + continue self.logger.error("Unable to find rpm "+ package +" in current and previous versions") raise "Input Error" rpmFiles += " " + rpmFile diff --git a/support/package-builder/constants.py b/support/package-builder/constants.py index 08adb0f06b..dc15f7f1b5 100644 --- a/support/package-builder/constants.py +++ b/support/package-builder/constants.py @@ -16,7 +16,7 @@ class constants(object): noDepsPackageList=["texinfo","bzip2","gettext","man-db","nspr","xz","bison","openjdk","go"] listToolChainPackages=["linux-api-headers", "glibc","zlib", "file", "binutils","gmp","mpfr", "mpc","gcc", "pkg-config", "ncurses", "bash", "bzip2", "sed","procps-ng","coreutils", "m4","grep", - "readline", "diffutils","gawk", "findutils", "gettext", "gzip","make", "patch","util-linux", + "readline", "diffutils","gawk", "findutils", "gettext", "gzip","make", "patch","util-linux", "util-linux-devel", "tar", "xz","libtool", "flex", "bison", "lua","popt","nspr","sqlite-autoconf","nss", "elfutils", "expat","libffi","libpipeline", "gdbm","perl","texinfo","autoconf","automake", "openssl","python2","rpm", "groff", "man-db", "man-pages","cpio"] @@ -31,7 +31,7 @@ class constants(object): "libgcc","libgcc-devel","libstdc++","libstdc++-devel","libgomp","libgomp-devel","gcc", "pkg-config", "ncurses", "bash", "bzip2", "sed","procps-ng","coreutils", "m4","grep", "readline","diffutils","gawk", "findutils", "gettext", "gzip","make", "patch", - "util-linux", "tar", "xz","libtool", "flex", "bison", + "util-linux", "util-linux-devel", "tar", "xz","libtool", "flex", "bison", "lua","popt","nspr","sqlite-autoconf","nss","elfutils-libelf", "libpipeline", "gdbm","perl","texinfo","rpm","rpm-build", "rpm-devel", "autoconf","automake", "groff", "man-db", "man-pages","elfutils","cpio"] @@ -41,7 +41,7 @@ class constants(object): "libgcc","libgcc-devel","libstdc++","libstdc++-devel","libgomp","libgomp-devel","gcc", "pkg-config", "ncurses", "bash", "bzip2", "sed","ncurses-devel","procps-ng","coreutils", "m4","grep", "readline", "diffutils","gawk", "findutils", "gettext", "gzip","make", "patch", - "util-linux", "tar", "xz","libtool", "flex", "bison", + "util-linux", "util-linux-devel", "tar", "xz","libtool", "flex", "bison", "readline-devel", "lua","lua-devel","popt","popt-devel","nspr","sqlite-autoconf","nss","nss-devel", "bzip2-devel","elfutils-libelf","elfutils","elfutils-libelf-devel","elfutils-devel", "expat","libffi","libpipeline", "gdbm","perl","texinfo","autoconf","automake",