diff --git a/.gitignore b/.gitignore index 7ceefad..997938c 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,2 @@ redhat-lsb-4.0-1.tar.bz2 /redhat-lsb-4.1-1.tar.bz2 -/redhat-lsb-20231006git92f8ab57.tar.gz -/redhat-lsb-20231006gita9c49411.tar.gz -/redhat-lsb-20231006git8d00acdc.tar.gz diff --git a/lsb-release-2.0-disable-etc-lsb-release.patch b/lsb-release-2.0-disable-etc-lsb-release.patch new file mode 100644 index 0000000..49db48d --- /dev/null +++ b/lsb-release-2.0-disable-etc-lsb-release.patch @@ -0,0 +1,26 @@ +--- lsb-release-2.0.orig/lsb_release 2004-07-01 03:30:34.000000000 +1000 ++++ lsb-release-2.0/lsb_release 2005-08-03 23:31:58.000000000 +1000 +@@ -188,15 +188,6 @@ + + # Get/Init LSB infos (maybe Distrib infos too) + GetLSBInfo() { +- if [ -f "$INFO_ROOT/$INFO_LSB_FILE" ] +- then +- # should init at least LSB_VERSION +- . "$INFO_ROOT/$INFO_LSB_FILE" +- fi +- if [ -z "$LSB_VERSION" ] +- then +- LSB_VERSION=$MSG_NA +- else + # if we found LSB_VERSION, continue to look in directory + if [ -d "$INFO_ROOT/$INFO_LSB_DIR" ] + then +@@ -205,7 +196,6 @@ + LSB_VERSION=$LSB_VERSION:`basename $tag` + done + fi +- fi + } + + # Get the whole distrib information string (from ARG $1 file) diff --git a/lsb-release-3.1-update-init-functions.patch b/lsb-release-3.1-update-init-functions.patch new file mode 100644 index 0000000..1211cb7 --- /dev/null +++ b/lsb-release-3.1-update-init-functions.patch @@ -0,0 +1,32 @@ +diff -urN redhat-lsb-3.1/init-functions redhat-lsb-3.1.mod/init-functions +--- redhat-lsb-3.1/init-functions 2006-12-06 12:24:29.000000000 +1000 ++++ redhat-lsb-3.1.mod/init-functions 2007-06-26 15:41:35.000000000 +1000 +@@ -1,6 +1,10 @@ + #!/bin/sh + + # LSB initscript functions, as defined in the LSB Spec 1.1.0 ++# ++# Lawrence Lim - Tue, 26 June 2007 ++# Updated to the latest LSB 3.1 spec ++# http://refspecs.freestandards.org/LSB_3.1.0/LSB-Core-generic/LSB-Core-generic_lines.txt + + start_daemon () { + /etc/redhat-lsb/lsb_start_daemon "$@" +@@ -10,7 +14,7 @@ + /etc/redhat-lsb/lsb_killproc "$@" + } + +-pidofprof () { ++pidofproc () { + /etc/redhat-lsb/lsb_pidofproc "$@" + } + +@@ -22,7 +26,7 @@ + /etc/redhat-lsb/lsb_log_message failure "$@" + } + +-log_warning_message () { ++log_warning_msg () { + /etc/redhat-lsb/lsb_log_message warning "$@" + } + diff --git a/redhat-lsb-lsb_start_daemon-fix.patch b/redhat-lsb-lsb_start_daemon-fix.patch new file mode 100644 index 0000000..69f5f28 --- /dev/null +++ b/redhat-lsb-lsb_start_daemon-fix.patch @@ -0,0 +1,43 @@ +diff -up redhat-lsb-3.1/lsb_start_daemon.orig redhat-lsb-3.1/lsb_start_daemon +--- redhat-lsb-3.1/lsb_start_daemon.orig 2009-05-15 11:20:17.000000000 -0400 ++++ redhat-lsb-3.1/lsb_start_daemon 2009-05-15 11:33:03.000000000 -0400 +@@ -4,6 +4,9 @@ + + nice= + force= ++pidfile= ++user= ++check= + RETVAL= + while [ "$1" != "${1##[-+]}" ]; do + case $1 in +@@ -15,7 +18,28 @@ while [ "$1" != "${1##[-+]}" ]; do + nice=$2 + shift 2 + ;; ++ -p) ++ pidfile="--pidfile $2" ++ shift 2 ++ ;; ++ -u) ++ user="--user $2" ++ shift 2 ++ ;; ++ -c) ++ check="--check $2" ++ shift 2 ++ ;; ++ *) ++ echo "Unknown Option $1" ++ echo "Options are:" ++ echo "-f" ++ echo "-p {pidfile}" ++ echo "-n [+/-nicelevel]" ++ echo "-u {user}" ++ echo "-c {base}" ++ exit 1;; + esac + done +-LSB=LSB-1.1 daemon ${force:-} ${nice:-} $* ++LSB=LSB-1.1 daemon ${force:-} ${nice:-} ${pidfile:-} ${user:-} ${check:-} $* + exit $? diff --git a/redhat-lsb-snapshot.sh b/redhat-lsb-snapshot.sh deleted file mode 100755 index f2e8df7..0000000 --- a/redhat-lsb-snapshot.sh +++ /dev/null @@ -1,25 +0,0 @@ -package=redhat-lsb -branch=main -commit=HEAD - -if [ ! -d redhat-lsb.pagure ]; then - git clone ssh://git@pagure.io/redhat-lsb.git redhat-lsb.pagure -fi - -pushd redhat-lsb.pagure -tag=$(git rev-list HEAD -n 1 | cut -c 1-8) -date=$(git log -1 --format=%cd --date=short | tr -d \-) -git archive --prefix="${package}-${date}git${tag}/" --format=tar ${branch} | gzip > ../${package}-${date}git${tag}.tar.gz -popd - -echo \# globals for ${package}-${date}git${tag}.tar.gz -echo %global gitdate ${date} -echo %global gitversion ${tag} - -sed -i "s|^# globals for .*|# globals for ${package}-${date}git${tag}.tar.gz|" redhat-lsb.spec -sed -i "s|^%global gitdate .*|%global gitdate ${date}|" redhat-lsb.spec -sed -i "s|^%global gitversion .*|%global gitversion ${tag}|" redhat-lsb.spec - -echo fedpkg new-sources $(spectool -l --sources redhat-lsb.spec | sed 's/.*: //;s/.*\///') -echo \MSG="\"Update README.md with actual status\"" -echo rpmdev-bumpspec -c \"\$MSG\" $(basename $(pwd)).spec diff --git a/redhat-lsb.spec b/redhat-lsb.spec index f7e51a2..fc165f2 100644 --- a/redhat-lsb.spec +++ b/redhat-lsb.spec @@ -1,168 +1,719 @@ -# globals for redhat-lsb-20231006git8d00acdc.tar.gz -%global gitdate 20231006 -%global gitversion 8d00acdc +# Define this to link to which library version eg. /lib64/ld-lsb-x86-64.so.3 +%global lsbsover 3 -%global snapshot %{gitdate}git%{gitversion} -%global gver .%{gitdate}git%{gitversion} +%ifarch %{ix86} +%global ldso ld-linux.so.2 +%global lsbldso ld-lsb.so +%endif + +%ifarch ia64 +%global ldso ld-linux-ia64.so.2 +%global lsbldso ld-lsb-ia64.so +%endif + +%ifarch ppc +%global ldso ld.so.1 +%global lsbldso ld-lsb-ppc32.so +%endif + +%ifarch ppc64 +%global ldso ld64.so.1 +%global lsbldso ld-lsb-ppc64.so +%endif + +%ifarch ppc64le +%global ldso ld64.so.2 +%global lsbldso ld-lsb-ppc64le.so +%endif + +%ifarch s390 +%global ldso ld.so.1 +%global lsbldso ld-lsb-s390.so +%endif + +%ifarch s390x +%global ldso ld64.so.1 +%global lsbldso ld-lsb-s390x.so +%endif + +%ifarch x86_64 +%global ldso ld-linux-x86-64.so.2 +%global lsbldso ld-lsb-x86-64.so +%endif + +%ifarch %{arm} +%global ldso ld-linux.so.2 +%global lsbldso ld-lsb-arm.so +%endif + +%ifarch aarch64 +%global ldso ld-linux-aarch64.so.1 +%global lsbldso ld-lsb-aarch64.so +%endif %global upstreamlsbrelver 2.0 -%global lsbrelver 5.0 -%global disclaimer This package is not compliance with LSB, because various \ -components are missing from Fedora or EPEL, so compliance is not possible. \ -Fedora or EPEL explicitly declines add support the missing components from LSB \ -5.0 or earlier because these components are very outdated and have been \ -removed from the repositories and possibly replaced with new ones. \ -This package tries its best to comply with the LSB. Hoping to be helpful and \ -continue to support the LSB project and software that uses it +%global lsbrelver 4.1 +%global srcrelease 1 -Summary: Partial implementation of Linux Standard Base specification +# for >= f28, __brp_ldconfig is added in __os_install_post, it removes the symlink %%{lsbldso} +# and thus leading to the FTBS. +%global __brp_ldconfig %{nil} + +# The packages are architecture-specific, but do not contain any ELF +# binaries with debuginfo to extract. +%undefine _enable_debug_packages + +Summary: Implementation of Linux Standard Base specification Name: redhat-lsb -Version: 5.0 -Release: 0.17%{gver}%{?dist} -URL: https://wiki.linuxfoundation.org/lsb/start -# https://github.com/LinuxStandardBase/lsb-samples/ -Source0: redhat-lsb-%{snapshot}.tar.gz -# Automatically converted from old format: GPLv2 - review is highly recommended. -License: GPL-2.0-only +Version: 4.1 +Release: 56%{?dist} +URL: http://www.linuxfoundation.org/collaborate/workgroups/lsb +Source0: https://fedorahosted.org/releases/r/e/redhat-lsb/%{name}-%{version}-%{srcrelease}.tar.bz2 +Patch0: lsb-release-3.1-update-init-functions.patch +Patch1: redhat-lsb-lsb_start_daemon-fix.patch +License: GPLv2 BuildRequires: make -BuildRequires: help2man -Requires: util-linux +BuildRequires: perl-generators +BuildRequires: perl(Getopt::Long) + +%ifarch %{ix86} +%global archname ia32 +%endif +%ifarch ia64 +%global archname ia64 +%endif +%ifarch ppc +%global archname ppc32 +%endif +%ifarch ppc64 +%global archname ppc64 +%endif +%ifarch ppc64le +%global archname ppc64le +%endif +%ifarch s390 +%global archname s390 +%endif +%ifarch s390x +%global archname s390x +%endif +%ifarch x86_64 +%global archname amd64 +%endif +%ifarch %{arm} +%global archname arm +%endif +%ifarch aarch64 +%global archname aarch64 +%endif + +Requires: redhat-lsb-core%{?_isa} = %{version}-%{release} +Requires: redhat-lsb-cxx%{?_isa} = %{version}-%{release} +Requires: redhat-lsb-desktop%{?_isa} = %{version}-%{release} +Requires: redhat-lsb-languages = %{version}-%{release} +Requires: redhat-lsb-printing = %{version}-%{release} +#Requires: redhat-lsb-trialuse = %%{version}-%%{release} Provides: lsb = %{version}-%{release} +Provides: lsb-%{archname} = %{version}-%{release} Provides: lsb-noarch = %{version}-%{release} -Obsoletes: redhat-lsb-trialuse < 5 -Obsoletes: redhat-lsb-submod-multimedia < 5 -Obsoletes: redhat-lsb-submod-security < 5 -Obsoletes: redhat-lsb-core <= 5.0-0.12 -Obsoletes: redhat-lsb-cxx <= 5.0-0.12 -Obsoletes: redhat-lsb-desktop <= 5.0-0.12 -Obsoletes: redhat-lsb-languages <= 5.0-0.12 -Obsoletes: redhat-lsb-printing <= 5.0-0.12 -Obsoletes: redhat-lsb-supplemental <= 5.0-0.12 -Conflicts: lsb_release - -BuildArch: noarch %description The Linux Standard Base (LSB) is an attempt to develop a set of standards that -will increase compatibility among Linux distributions. It is designed to be +will increase compatibility among Linux distributions. It is designed to be binary-compatible and produce a stable application binary interface (ABI) for independent software vendors. +The lsb package provides utilities, libraries etc. needed for LSB Compliant +Applications. It also contains requirements that will ensure that all +components required by the LSB are installed on the system. -%{disclaimer} +%package submod-security +Summary: LSB Security submodule support +Requires: nspr%{?_isa} +# Requires: nspr-devel +Requires: nss%{?_isa} -The lsb package provides utilities, libraries etc. needed for LSB Compliant -Applications. +Provides: lsb-submod-security-%{archname} = %{version}-%{release} +Provides: lsb-submod-security-noarch = %{version}-%{release} +%description submod-security +The Linux Standard Base (LSB) Security submodule specifications define +components that are required to be present on an LSB conforming system. + +%package submod-multimedia +Summary: LSB Multimedia submodule support +Requires: alsa-lib%{?_isa} + +Provides: lsb-submod-multimedia-%{archname} = %{version}-%{release} +Provides: lsb-submod-multimedia-noarch = %{version}-%{release} + +%description submod-multimedia +The Linux Standard Base (LSB) Multimedia submodule specifications define +components that are required to be present on an LSB conforming system. + +%package core +Summary: LSB Core module support +# gLSB Library +Requires: glibc%{?_isa} +Requires: glibc-common +Requires: libgcc%{?_isa} +#LSB requires libncurses.so.5 for some reason +Requires: ncurses-compat-libs%{?_isa} +Requires: pam%{?_isa} +Requires: zlib%{?_isa} + +# gLSB Command and Utilities +Requires: /usr/bin/[ +Requires: /usr/bin/ar +Requires: /usr/bin/at +Requires: /usr/bin/awk +Requires: /usr/bin/basename +Requires: /usr/bin/batch +Requires: /usr/bin/bc +Requires: /usr/bin/cat +Requires: /usr/bin/chfn +Requires: /usr/bin/chgrp +Requires: /usr/bin/chmod +Requires: /usr/bin/chown +Requires: /usr/bin/chsh +Requires: /usr/bin/cksum +Requires: /usr/bin/cmp +Requires: /usr/bin/col +Requires: /usr/bin/comm +Requires: /usr/bin/cp +Requires: /usr/bin/cpio +Requires: /usr/bin/crontab +Requires: /usr/bin/csplit +Requires: /usr/bin/cut +Requires: /usr/bin/date +Requires: /usr/bin/dd +Requires: /usr/bin/df +Requires: /usr/bin/diff +Requires: /usr/bin/dirname +Requires: /usr/bin/dmesg +Requires: /usr/bin/du +Requires: /usr/bin/echo +Requires: /usr/bin/ed +Requires: /usr/bin/egrep +Requires: /usr/bin/env +Requires: /usr/bin/expand +Requires: /usr/bin/expr +Requires: /usr/bin/false +Requires: /usr/bin/fgrep +Requires: /usr/bin/file +Requires: /usr/bin/find +Requires: /usr/bin/fold +Requires: /usr/sbin/fuser +Requires: /usr/bin/gencat +Requires: /usr/bin/getconf +Requires: /usr/bin/gettext +Requires: /usr/bin/grep +Requires: /usr/sbin/groupadd +Requires: /usr/sbin/groupdel +Requires: /usr/sbin/groupmod +Requires: /usr/bin/groups +Requires: /usr/bin/gunzip +Requires: /usr/bin/gzip +Requires: /usr/bin/head +Requires: /usr/bin/hostname +Requires: /usr/bin/iconv +Requires: /usr/bin/id +Requires: /usr/bin/install +Requires: /usr/bin/ipcrm +Requires: /usr/bin/ipcs +Requires: /usr/bin/join +Requires: /usr/bin/kill +Requires: /usr/bin/killall +Requires: /usr/bin/ln +Requires: /usr/bin/locale +Requires: /usr/bin/localedef +Requires: /usr/bin/logger +Requires: /usr/bin/logname +Requires: /usr/bin/lp +Requires: /usr/bin/lpr +Requires: /usr/bin/ls +Requires: /usr/bin/m4 +Requires: /bin/mailx +Requires: /usr/bin/make +Requires: /usr/bin/man +Requires: /usr/bin/md5sum +Requires: /usr/bin/mkdir +Requires: /usr/bin/mkfifo +Requires: /usr/bin/mknod +Requires: /usr/bin/mktemp +Requires: /usr/bin/more +Requires: /usr/bin/mount +Requires: /usr/bin/msgfmt +Requires: /usr/bin/mv +Requires: /usr/bin/newgrp +Requires: /usr/bin/nice +Requires: /usr/bin/nl +Requires: /usr/bin/nohup +Requires: /usr/bin/od +Requires: /usr/bin/passwd +Requires: /usr/bin/paste +Requires: /usr/bin/patch +Requires: /usr/bin/pathchk +#better POSIX conformance of /usr/bin/pax +Requires: spax +Requires: /usr/bin/pidof +Requires: /usr/bin/pr +Requires: /usr/bin/printf +Requires: /usr/bin/ps +Requires: /usr/bin/pwd +Requires: /usr/bin/renice +Requires: /usr/bin/rm +Requires: /usr/bin/rmdir +Requires: /usr/bin/sed +Requires: /usr/sbin/sendmail +Requires: /usr/bin/seq +Requires: /usr/bin/sh +Requires: /usr/sbin/shutdown +Requires: /usr/bin/sleep +Requires: /usr/bin/sort +Requires: /usr/bin/split +Requires: /usr/bin/strings +Requires: /usr/bin/strip +Requires: /usr/bin/stty +Requires: /usr/bin/su +Requires: /usr/bin/sync +Requires: /usr/bin/tail +Requires: /usr/bin/tar +Requires: /usr/bin/tee +Requires: /usr/bin/test +Requires: /usr/bin/time +Requires: /usr/bin/touch +Requires: /usr/bin/tr +Requires: /usr/bin/true +Requires: /usr/bin/tsort +Requires: /usr/bin/tty +Requires: /usr/bin/umount +Requires: /usr/bin/uname +Requires: /usr/bin/unexpand +Requires: /usr/bin/uniq +Requires: /usr/sbin/useradd +Requires: /usr/sbin/userdel +Requires: /usr/sbin/usermod +Requires: /usr/bin/wc +Requires: /usr/bin/xargs +Requires: /usr/bin/zcat +Requires: redhat-lsb-submod-security%{?_isa} = %{version}-%{release} + +Provides: lsb-core-%{archname} = %{version}-%{release} +Provides: lsb-core-noarch = %{version}-%{release} +#Obsoletes: redhat-lsb < %%{version}-%%{release} + +%description core +The Linux Standard Base (LSB) Core module support provides the fundamental +system interfaces, libraries, and runtime environment upon which all conforming +applications and libraries depend. + +%package cxx +Summary: LSB CXX module support +Requires: libstdc++%{?_isa} +Requires: redhat-lsb-core%{?_isa} = %{version}-%{release} + +Provides: lsb-cxx-%{archname} = %{version}-%{release} +Provides: lsb-cxx-noarch = %{version}-%{release} + +%description cxx +The Linux Standard Base (LSB) CXX module supports the core interfaces by +providing system interfaces, libraries, and a runtime environment for +applications built using the C++ programming language. These interfaces +provide low-level support for the core constructs of the language, and +implement the standard base C++ libraries. + +%package desktop +Summary: LSB Desktop module support +Requires: xdg-utils +# LSB_Graphics library +Requires: libICE%{?_isa} +Requires: libSM%{?_isa} +Requires: libX11%{?_isa} +Requires: libXext%{?_isa} +Requires: libXi%{?_isa} +Requires: libXt%{?_isa} +Requires: libXtst%{?_isa} +Requires: mesa-libGL%{?_isa} +Requires: mesa-libGLU%{?_isa} +# gLSB Graphics and gLSB Graphics Ext Command and Utilities +Requires: /usr/bin/fc-cache +Requires: /usr/bin/fc-list +Requires: /usr/bin/fc-match +# gLSB Graphics Ext library +Requires: cairo%{?_isa} +Requires: freetype%{?_isa} +Requires: libjpeg-turbo%{?_isa} + +%ifarch %{ix86} ppc s390 arm +Requires: libpng12.so.0 +%endif +%ifarch x86_64 ppc64 s390x aarch64 ppc64le +Requires: libpng12.so.0()(64bit) +%endif +Requires: libpng%{?_isa} +Requires: libXft%{?_isa} +Requires: libXrender%{?_isa} +# toolkit-gtk +Requires: atk%{?_isa} +Requires: gdk-pixbuf2%{?_isa} +Requires: glib2%{?_isa} +Requires: gtk2%{?_isa} +Requires: pango%{?_isa} +# toolkit-qt +Requires: qt%{?_isa} +Requires: qt-x11%{?_isa} +# toolkit-qt3 +Requires: qt3%{?_isa} +# xml +Requires: libxml2%{?_isa} +Requires: redhat-lsb-submod-multimedia%{?_isa} = %{version}-%{release} +Requires: redhat-lsb-core%{?_isa} = %{version}-%{release} + +Provides: lsb-desktop-%{archname} = %{version}-%{release} +Provides: lsb-desktop-noarch = %{version}-%{release} +Provides: lsb-graphics-%{archname} = %{version}-%{release} +Provides: lsb-graphics-noarch = %{version}-%{release} +Obsoletes: redhat-lsb-graphics < %{version}-%{release} + +%description desktop +The Linux Standard Base (LSB) Desktop Specifications define components that are +required to be present on an LSB conforming system. + +%package languages +Summary: LSB Languages module support +# Perl and Perl non-builtin modules +Requires: /usr/bin/perl +Requires: perl(CGI) +Requires: perl(Class::ISA) +Requires: perl(CPAN) +# Locale::Constants has been Locale::Codes::Costants, so we need +# create a /usr/share/perl5/vendor_perl/Constants.pm manually. +# Requires: perl(Locale::Constants) +# perl(Locale::Constants) requires perl(Locale::Codes) +# DB module is a builtin module, but perl package doesn't contain this provide. +# Requires: perl(DB) +# we also need perl(Pod::Plainer), we need to rpm this package ourself +Requires: perl(Locale::Codes) +Requires: perl(File::Spec) +Requires: perl(Scalar::Util) +Requires: perl(Test::Harness) +Requires: perl(Test::Simple) +Requires: perl(ExtUtils::MakeMaker) +Requires: perl(Pod::Plainer) +Requires: perl(XML::LibXML) +Requires: perl(Pod::LaTeX) +Requires: perl(Pod::Checker) +Requires: perl(B::Lint) +Requires: perl(Text::Soundex) +Requires: perl(Env) +Requires: perl(Time::HiRes) +Requires: perl(Locale::Maketext) +Requires: perl(Fatal) +Requires: perl(File::CheckTree) +Requires: perl(Sys::Syslog) +Requires: perl(Getopt::Long) + +# python +Requires: /usr/bin/python +# java +Requires: redhat-lsb-core%{?_isa} = %{version}-%{release} + +Provides: lsb-languages-%{archname} = %{version}-%{release} +Provides: lsb-languages-noarch = %{version}-%{release} + +%description languages +The Linux Standard Base (LSB) Languages module supports components for runtime +languages which are found on an LSB conforming system. + +%package printing +Summary: LSB Printing module support +# gLSB Printing Libraries +Requires: cups-libs +# gLSB Printing Command and Utilities +Requires: /usr/bin/foomatic-rip +Requires: /usr/bin/gs +Requires: redhat-lsb-core%{?_isa} = %{version}-%{release} + +Provides: lsb-printing-%{archname} = %{version}-%{release} +Provides: lsb-printing-noarch = %{version}-%{release} +Obsoletes: redhat-lsb-printing < %{version}-%{release} + +%description printing +The Linux Standard Base (LSB) Printing specifications define components that +are required to be present on an LSB conforming system. + +%package trialuse +Summary: LSB Trialuse module support +Requires: redhat-lsb-submod-multimedia%{?_isa} = %{version}-%{release} +Requires: redhat-lsb-submod-security%{?_isa} = %{version}-%{release} +Requires: redhat-lsb-core%{?_isa} = %{version}-%{release} + +Provides: lsb-trialuse-%{archname} = %{version}-%{release} +Provides: lsb-trialuse-noarch = %{version}-%{release} + +%description trialuse +The Linux Standard Base (LSB) Trialuse module support defines components +which are not required parts of the LSB Specification. + +%package supplemental +Summary: LSB supplemental dependencies required by LSB certification tests +Requires: net-tools +Requires: xorg-x11-fonts-ISO8859-1-75dpi +Requires: xorg-x11-fonts-ISO8859-1-100dpi +Requires: abattis-cantarell-fonts +Requires: sil-abyssinica-fonts +Requires: xorg-x11-server-Xvfb + +%description supplemental +This subpackage brings in supplemental dependencies for components required for +passing LSB (Linux Standard Base) certification testsuite, but not directly required +to be on LSB conforming system. %prep -%setup -q -n redhat-lsb-%{snapshot} +%setup -q +%patch0 -p1 +%patch1 -p1 %build -cd lsb_release/src +cd lsb-release-%{upstreamlsbrelver} %make_build -%install -pushd redhat-lsb -%make_install -popd +%pre +# remove the extra symlink /bin/mailx -> /bin/mail +if [ -e /bin/mailx ]; then + if [ -L /bin/mailx ]; then + rm -f /bin/mailx + fi +fi -pushd lsb_release/src -make mandir=%{buildroot}%{_mandir} prefix=%{buildroot}%{_prefix} install -popd +%install +# LSB uses /usr/lib rather than /usr/lib64 even for 64bit OS +mkdir -p $RPM_BUILD_ROOT%{_sysconfdir} $RPM_BUILD_ROOT/%{_lib} $RPM_BUILD_ROOT%{_mandir} \ + $RPM_BUILD_ROOT%{_bindir} $RPM_BUILD_ROOT/usr/lib/lsb \ + $RPM_BUILD_ROOT%{_sysconfdir}/lsb-release.d/ $RPM_BUILD_ROOT%{_sbindir} \ + $RPM_BUILD_ROOT%{_datadir}/lsb/%{lsbrelver} + +# manually add Locale::Constants. This module is just an alias of Locale::Codes::Constants +mkdir -p $RPM_BUILD_ROOT%{perl_vendorlib}/Locale +cp -p Constants.pm $RPM_BUILD_ROOT%{perl_vendorlib}/Locale +cp -p Constants.pod $RPM_BUILD_ROOT%{perl_vendorlib}/Locale + +make install DESTDIR=$RPM_BUILD_ROOT INSTALL="install -p" +cd lsb-release-%{upstreamlsbrelver} +make mandir=$RPM_BUILD_ROOT/%{_mandir} prefix=$RPM_BUILD_ROOT/%{_prefix} install +cd .. +# we keep more lsb information in /usr/share/lsb +mkdir -p $RPM_BUILD_ROOT%{_datadir}/lsb/%{lsbrelver}/modules +mkdir -p $RPM_BUILD_ROOT%{_datadir}/lsb/%{lsbrelver}/submodules #prepare installation of doc -cp -p lsb_release/src/COPYING . -cp -p lsb_release/src/README README.lsb_release +cp -p lsb-release-2.0/COPYING . +cp -p lsb-release-2.0/README README.lsb_release + +# relations between modules and submodules +modules="core cxx desktop languages printing trialuse" +submodules="core perl python cpp toolkit-gtk toolkit-qt toolkit-qt3" +submodules="${submodules} xml multimedia security desktop-misc graphics graphics-ext" +submodules="${submodules} printing" + +core="core security" +cxx="cpp" +desktop="desktop-misc graphics graphics-ext multimedia toolkit-gtk toolkit-qt toolkit-qt3" +desktop="${desktop} xml" +languages="perl python" +printing="printing" +trialuse="security multimedia" + +for mod in ${modules};do + touch $RPM_BUILD_ROOT%{_sysconfdir}/lsb-release.d/${mod}-%{lsbrelver}-%{archname} + touch $RPM_BUILD_ROOT%{_sysconfdir}/lsb-release.d/${mod}-%{lsbrelver}-noarch +done + +for submod in ${submodules};do + touch $RPM_BUILD_ROOT%{_datadir}/lsb/%{lsbrelver}/submodules/${submod}-%{lsbrelver}-%{archname} + touch $RPM_BUILD_ROOT%{_datadir}/lsb/%{lsbrelver}/submodules/${submod}-%{lsbrelver}-noarch +done +for moddir in ${modules};do + mkdir -p $RPM_BUILD_ROOT%{_datadir}/lsb/%{lsbrelver}/modules/${moddir} +done + +for submod in ${core};do + ln -snf ../../submodules/${submod}-%{lsbrelver}-%{archname} \ +$RPM_BUILD_ROOT%{_datadir}/lsb/%{lsbrelver}/modules/core/${submod}-%{lsbrelver}-%{archname} + ln -snf ../../submodules/${submod}-%{lsbrelver}-noarch \ +$RPM_BUILD_ROOT%{_datadir}/lsb/%{lsbrelver}/modules/core/${submod}-%{lsbrelver}-noarch +done +for submod in ${cxx};do + ln -snf ../../submodules/${submod}-%{lsbrelver}-%{archname} \ +$RPM_BUILD_ROOT%{_datadir}/lsb/%{lsbrelver}/modules/cxx/${submod}-%{lsbrelver}-%{archname} + ln -snf ../../submodules/${submod}-%{lsbrelver}-noarch \ +$RPM_BUILD_ROOT%{_datadir}/lsb/%{lsbrelver}/modules/cxx/${submod}-%{lsbrelver}-noarch +done +for submod in ${desktop};do + ln -snf ../../submodules/${submod}-%{lsbrelver}-%{archname} \ +$RPM_BUILD_ROOT%{_datadir}/lsb/%{lsbrelver}/modules/desktop/${submod}-%{lsbrelver}-%{archname} + ln -snf ../../submodules/${submod}-%{lsbrelver}-noarch \ +$RPM_BUILD_ROOT%{_datadir}/lsb/%{lsbrelver}/modules/desktop/${submod}-%{lsbrelver}-noarch +done +for submod in ${languages};do + ln -snf ../../submodules/${submod}-%{lsbrelver}-%{archname} \ +$RPM_BUILD_ROOT%{_datadir}/lsb/%{lsbrelver}/modules/languages/${submod}-%{lsbrelver}-%{archname} + ln -snf ../../submodules/${submod}-%{lsbrelver}-noarch \ +$RPM_BUILD_ROOT%{_datadir}/lsb/%{lsbrelver}/modules/languages/${submod}-%{lsbrelver}-noarch +done +for submod in ${printing};do + ln -snf ../../submodules/${submod}-%{lsbrelver}-%{archname} \ +$RPM_BUILD_ROOT%{_datadir}/lsb/%{lsbrelver}/modules/printing/${submod}-%{lsbrelver}-%{archname} + ln -snf ../../submodules/${submod}-%{lsbrelver}-noarch \ +$RPM_BUILD_ROOT%{_datadir}/lsb/%{lsbrelver}/modules/printing/${submod}-%{lsbrelver}-noarch +done +for submod in ${trialuse};do + ln -snf ../../submodules/${submod}-%{lsbrelver}-%{archname} \ +$RPM_BUILD_ROOT%{_datadir}/lsb/%{lsbrelver}/modules/trialuse/${submod}-%{lsbrelver}-%{archname} + ln -snf ../../submodules/${submod}-%{lsbrelver}-noarch \ +$RPM_BUILD_ROOT%{_datadir}/lsb/%{lsbrelver}/modules/trialuse/${submod}-%{lsbrelver}-noarch +done + +for LSBVER in %{lsbsover}; do + ln -snf %{ldso} $RPM_BUILD_ROOT/%{_lib}/%{lsbldso}.$LSBVER +done + +mkdir -p $RPM_BUILD_ROOT/bin + +# LSB uses /usr/lib rather than /usr/lib64 even for 64bit OS +# According to the lsb-core documentation provided by +# http://refspecs.linux-foundation.org/LSB_3.2.0/LSB-Core-generic/LSB-Core-generic.pdf +# it's OK to put non binary in /usr/lib. +ln -snf ../../../sbin/chkconfig $RPM_BUILD_ROOT/usr/lib/lsb/install_initd +ln -snf ../../../sbin/chkconfig $RPM_BUILD_ROOT/usr/lib/lsb/remove_initd +#ln -snf mail $RPM_BUILD_ROOT/bin/mailx + +#mkdir -p $RPM_BUILD_ROOT/usr/X11R6/lib/X11/xserver +#ln -snf /usr/%{_lib}/xserver/SecurityPolicy $RPM_BUILD_ROOT/usr/X11R6/lib/X11/xserver/SecurityPolicy +#ln -snf /usr/share/X11/fonts $RPM_BUILD_ROOT/usr/X11R6/lib/X11/fonts +#ln -snf /usr/share/X11/rgb.txt $RPM_BUILD_ROOT/usr/X11R6/lib/X11/rgb.txt + +cp -p redhat_lsb_init $RPM_BUILD_ROOT/bin/redhat_lsb_init + +%postun submod-security -p +os.remove("%{_datadir}/lsb/%{lsbrelver}/submodules") +os.remove("%{_datadir}/lsb/%{lsbrelver}/modules") +os.remove("%{_datadir}/lsb/%{lsbrelver}") +os.remove("%{_datadir}/lsb") +%postun submod-multimedia -p +os.remove("%{_datadir}/lsb/%{lsbrelver}/submodules") +os.remove("%{_datadir}/lsb/%{lsbrelver}/modules") +os.remove("%{_datadir}/lsb/%{lsbrelver}") +os.remove("%{_datadir}/lsb") +%postun core -p +os.remove("%{_datadir}/lsb/%{lsbrelver}/submodules") +os.remove("%{_datadir}/lsb/%{lsbrelver}/modules") +os.remove("%{_datadir}/lsb/%{lsbrelver}") +os.remove("%{_datadir}/lsb") +%postun cxx -p +os.remove("%{_datadir}/lsb/%{lsbrelver}/submodules") +os.remove("%{_datadir}/lsb/%{lsbrelver}/modules") +os.remove("%{_datadir}/lsb/%{lsbrelver}") +os.remove("%{_datadir}/lsb") +%postun desktop -p +os.remove("%{_datadir}/lsb/%{lsbrelver}/submodules") +os.remove("%{_datadir}/lsb/%{lsbrelver}/modules") +os.remove("%{_datadir}/lsb/%{lsbrelver}") +os.remove("%{_datadir}/lsb") +%postun languages -p +os.remove("%{_datadir}/lsb/%{lsbrelver}/submodules") +os.remove("%{_datadir}/lsb/%{lsbrelver}/modules") +os.remove("%{_datadir}/lsb/%{lsbrelver}") +os.remove("%{_datadir}/lsb") +%postun printing -p +os.remove("%{_datadir}/lsb/%{lsbrelver}/submodules") +os.remove("%{_datadir}/lsb/%{lsbrelver}/modules") +os.remove("%{_datadir}/lsb/%{lsbrelver}") +os.remove("%{_datadir}/lsb") +%postun trialuse -p +os.remove("%{_datadir}/lsb/%{lsbrelver}/submodules") +os.remove("%{_datadir}/lsb/%{lsbrelver}/modules") +os.remove("%{_datadir}/lsb/%{lsbrelver}") +os.remove("%{_datadir}/lsb") %files -%doc README.md README.lsb_release +%{_datadir}/lsb/ + +%files submod-security +%{_datadir}/lsb/%{lsbrelver}/submodules/security-%{lsbrelver}-%{archname} +%{_datadir}/lsb/%{lsbrelver}/submodules/security-%{lsbrelver}-noarch + +%files submod-multimedia +%{_datadir}/lsb/%{lsbrelver}/submodules/multimedia-%{lsbrelver}-%{archname} +%{_datadir}/lsb/%{lsbrelver}/submodules/multimedia-%{lsbrelver}-noarch + +%files core +%doc README README.lsb_release %license COPYING %{_sysconfdir}/redhat-lsb -%{_mandir}/*/lsb_release* -%{_bindir}/lsb_release +%dir %{_sysconfdir}/lsb-release.d +%{_mandir}/*/* +%{_bindir}/* +#/bin/mailx +/bin/redhat_lsb_init /usr/lib/lsb +/%{_lib}/*so* +/lib/lsb* +%{_datadir}/lsb/%{lsbrelver}/modules/core +%{_sysconfdir}/lsb-release.d/core* +%{_datadir}/lsb/%{lsbrelver}/submodules/core-%{lsbrelver}-%{archname} +%{_datadir}/lsb/%{lsbrelver}/submodules/core-%{lsbrelver}-noarch + +%files cxx +%{_sysconfdir}/lsb-release.d/cxx* +%{_datadir}/lsb/%{lsbrelver}/modules/cxx +%{_datadir}/lsb/%{lsbrelver}/submodules/cpp-%{lsbrelver}-%{archname} +%{_datadir}/lsb/%{lsbrelver}/submodules/cpp-%{lsbrelver}-noarch + +%files desktop +%{_sysconfdir}/lsb-release.d/desktop* +%{_datadir}/lsb/%{lsbrelver}/modules/desktop +%{_datadir}/lsb/%{lsbrelver}/submodules/toolkit-gtk-%{lsbrelver}-%{archname} +%{_datadir}/lsb/%{lsbrelver}/submodules/toolkit-gtk-%{lsbrelver}-noarch +%{_datadir}/lsb/%{lsbrelver}/submodules/toolkit-qt-%{lsbrelver}-%{archname} +%{_datadir}/lsb/%{lsbrelver}/submodules/toolkit-qt-%{lsbrelver}-noarch +%{_datadir}/lsb/%{lsbrelver}/submodules/toolkit-qt3-%{lsbrelver}-%{archname} +%{_datadir}/lsb/%{lsbrelver}/submodules/toolkit-qt3-%{lsbrelver}-noarch +%{_datadir}/lsb/%{lsbrelver}/submodules/xml-%{lsbrelver}-%{archname} +%{_datadir}/lsb/%{lsbrelver}/submodules/xml-%{lsbrelver}-noarch +%{_datadir}/lsb/%{lsbrelver}/submodules/desktop-misc-%{lsbrelver}-%{archname} +%{_datadir}/lsb/%{lsbrelver}/submodules/desktop-misc-%{lsbrelver}-noarch +%{_datadir}/lsb/%{lsbrelver}/submodules/graphics-%{lsbrelver}-%{archname} +%{_datadir}/lsb/%{lsbrelver}/submodules/graphics-%{lsbrelver}-noarch +%{_datadir}/lsb/%{lsbrelver}/submodules/graphics-ext-%{lsbrelver}-%{archname} +%{_datadir}/lsb/%{lsbrelver}/submodules/graphics-ext-%{lsbrelver}-noarch + +%files languages +%{_sysconfdir}/lsb-release.d/languages* +%{_datadir}/lsb/%{lsbrelver}/modules/languages +%{_datadir}/lsb/%{lsbrelver}/submodules/perl-%{lsbrelver}-%{archname} +%{_datadir}/lsb/%{lsbrelver}/submodules/perl-%{lsbrelver}-noarch +%{perl_vendorlib}/Locale/Constants.pm +%{perl_vendorlib}/Locale/Constants.pod +%{_datadir}/lsb/%{lsbrelver}/submodules/python-%{lsbrelver}-%{archname} +%{_datadir}/lsb/%{lsbrelver}/submodules/python-%{lsbrelver}-noarch + +%files printing +%{_sysconfdir}/lsb-release.d/printing* +%{_datadir}/lsb/%{lsbrelver}/modules/printing +%{_datadir}/lsb/%{lsbrelver}/submodules/printing-%{lsbrelver}-%{archname} +%{_datadir}/lsb/%{lsbrelver}/submodules/printing-%{lsbrelver}-noarch + +%files trialuse +%{_sysconfdir}/lsb-release.d/trialuse* +%{_datadir}/lsb/%{lsbrelver}/modules/trialuse + +%files supplemental +#no files, just dependencies %changelog -* Fri Jul 25 2025 Fedora Release Engineering - 5.0-0.17.20231006git8d00acdc -- Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild - -* Wed Apr 16 2025 Sérgio Basto - 5.0-0.16.20231006git8d00acdc -- Require util-linux -- Modification of sumamry and description to express that is not compliant with LSB - -* Sat Jan 18 2025 Fedora Release Engineering - 5.0-0.15.20231006git8d00acdc -- Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild - -* Sat Dec 07 2024 Sérgio Basto - 5.0-0.14.20231006git8d00acdc -- (#2330590) Fix Unexpadned macro - -* Thu Nov 28 2024 Sérgio Basto - 5.0-0.13.20231006git8d00acdc -- Remove sub-pacakges: redhat-lsb-core, redhat-lsb-cxx, redhat-lsb-desktop, - redhat-lsb-languages and redhat-lsb-printing aren't useful for a long time -- Switch to a noarch package - -* Mon Jul 29 2024 Miroslav Suchý - 5.0-0.12.20231006git8d00acdc -- convert license to SPDX - -* Fri Jul 19 2024 Fedora Release Engineering - 5.0-0.11.20231006git8d00acdc -- Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild - -* Tue Jun 04 2024 Sérgio Basto - 5.0-0.10.20231006git8d00acdc -- The packages are architecture-specific, but do not contain any ELF - binaries with debuginfo to extract, so we need disable debuginfo. - -* Sat Mar 02 2024 Sérgio Basto - 5.0-0.9.20231006git8d00acdc -- Add conflicts required by Fedora package guidelines - -* Sat Feb 17 2024 Sérgio Basto - 5.0-0.8.20231006git8d00acdc -- Globalize disclamer -- Add Requires of ncurses which includes infocmp, tic and tput - -* Tue Feb 06 2024 Sérgio Basto - 5.0-0.7.20231006git8d00acdc -- Remove require of libpng12.so.0, lsb-desktop already require libpng -- redhat-lsb now provides lsb_release, in future maybe we can remove the rest since LSB 5.0 is out of date -- more cleanups -- Report that is not LSB compliance, because various components are missing from Fedora, so compliance is not possible - -* Fri Jan 26 2024 Fedora Release Engineering - 5.0-0.6.20231006git8d00acdc -- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild - -* Mon Jan 22 2024 Fedora Release Engineering - 5.0-0.5.20231006git8d00acdc -- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild - -* Wed Oct 25 2023 Sérgio Basto - 5.0-0.4.20231006git8d00acdc -- Recommends the software which is not available on epel - -* Sat Oct 07 2023 Sérgio Basto - 5.0-0.3.20231006git8d00acdc -- Fix some requires mostly on epel9 - -* Fri Oct 06 2023 Sérgio Basto - 5.0-0.2.20231006gita9c49411 -- Update README.md with actual status - -* Fri Oct 06 2023 Sérgio Basto - 5.0-0.1.20231006git92f8ab57 -- redhat-lsb 5.0 with new source location - -* Fri Jul 21 2023 Fedora Release Engineering - 4.1-62 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild - -* Mon Apr 10 2023 Sérgio Basto - 4.1-61 -- Remove "Trial Use" specs, because LSB 5.0 Trial Use is completely outdated - -* Fri Jan 20 2023 Fedora Release Engineering - 4.1-60 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild - -* Sat Jul 23 2022 Fedora Release Engineering - 4.1-59 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild - -* Sat Jul 02 2022 Sérgio Basto - 4.1-58 -- Require libxcrypt-compat in core, as libcrypt.so.1 is mandatory (rhbz#2055953) - -* Mon Jun 27 2022 Sérgio Basto - 4.1-57 -- ncurses-compat-libs was dropped in F37, to workaround and fix FTI (fails to - install), since F37 we use ncurses-libs - * Fri Jan 21 2022 Fedora Release Engineering - 4.1-56 - Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild diff --git a/redhat-lsb.spec-arch-alpha.patch b/redhat-lsb.spec-arch-alpha.patch new file mode 100644 index 0000000..fe09c49 --- /dev/null +++ b/redhat-lsb.spec-arch-alpha.patch @@ -0,0 +1,72 @@ +Diff against 3.1-22: +Index: redhat-lsb.spec +=================================================================== +RCS file: /cvs/pkgs/devel/redhat-lsb/redhat-lsb.spec,v +retrieving revision 1.38 +diff -u -p -r1.38 redhat-lsb.spec +--- redhat-lsb.spec 7 Aug 2008 08:46:31 -0000 1.38 ++++ redhat-lsb.spec 11 Aug 2008 10:34:20 -0000 +@@ -36,6 +36,11 @@ + %define lsbldso ld-lsb-x86-64.so + %endif + ++%ifarch alpha ++%define ldso ld-linux-alpha.so.2 ++%define lsbldso ld-lsb-alpha.so ++%endif ++ + %ifarch ia64 ppc64 s390x x86_64 + %define qual ()(64bit) + %else +@@ -82,12 +87,15 @@ Provides: lsb = %{version} + %ifarch x86_64 + %define archname amd64 + %endif ++%ifarch alpha ++%define archname alpha ++%endif + Provides: lsb-core-%{archname} = %{version} + Provides: lsb-graphics-%{archname} = %{version} + Provides: lsb-core-noarch = %{version} + Provides: lsb-graphics-noarch = %{version} + +-ExclusiveArch: i386 ia64 x86_64 ppc ppc64 s390 s390x ++ExclusiveArch: i386 ia64 x86_64 ppc ppc64 s390 s390x alpha + + %ifarch %{ix86} + # archLSB IA32 Base Libraries +@@ -187,16 +195,34 @@ Requires: libc.so.6()(64bit) + Requires: libstdc++.so.6()(64bit) + %endif + ++%ifarch alpha ++# archLSB Alpha Base Libraries ++Requires: libz.so.1 ++Requires: libutil.so.1.1 ++Requires: libpthread.so.0 ++Requires: libncurses.so.5 ++Requires: libm.so.6.1 ++Requires: libgcc_s.so.1 ++Requires: libdl.so.2.1 ++Requires: libcrypt.so.1.1 ++Requires: libc.so.6.1 ++Requires: libstdc++.so.6 ++%endif ++ + # gLSB Base/Utility/Stdc++/Graphics Libraries + Requires: libz.so.1%{qual} ++%ifnarch alpha + Requires: libutil.so.1%{qual} ++%endif + Requires: librt.so.1%{qual} + Requires: libpthread.so.0%{qual} + Requires: libpam.so.0%{qual} + Requires: libncurses.so.5%{qual} + Requires: libgcc_s.so.1%{qual} ++%ifnarch alpha + Requires: libdl.so.2%{qual} + Requires: libcrypt.so.1%{qual} ++%endif + Requires: libstdc++.so.6%{qual} + Requires: libXt.so.6%{qual} + Requires: libXi.so.6%{qual} diff --git a/sources b/sources index 1202e62..c24d88d 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (redhat-lsb-20231006git8d00acdc.tar.gz) = c6c357c48fbc7805fd40a69c08f0a64589d57a9c25e9afff6b5a5e7d215ded6a6f16feefd3d5cd79d6ef39e0c2d1a2699860e3feeab37e5349e9cb1fe407b5a6 +9c1e474cb81c0ee1941c3129e0e50ea1 redhat-lsb-4.1-1.tar.bz2