%global distro CentOS Stream %global major 9 %global minor 0 Name: centos-stream-release Version: %{major}.%{minor} Release: 1%{?dist} Summary: %{distro} release files License: GPLv2 URL: https://centos.org BuildArch: noarch Requires: centos-repos(%{major}) Provides: centos-release = %{version}-%{release} # Required for a lorax run (to generate install media) Provides: centos-release-eula Provides: redhat-release-eula # upgrade path from old release packages # Obsoletes: centos-release < 8.2-3 # Obsoletes: centos-release-stream < 8.3-4 # Obsoletes: centos-repos < 8.2-3 # Obsoletes: centos-userland-release < 8.2-3 # upgrade path from CentOS Linux Obsoletes: centos-linux-release < %{version}-%{release} # required by epel-release Provides: redhat-release = %{version}-%{release} # required by dnf # https://github.com/rpm-software-management/dnf/blob/4.2.23/dnf/const.py.in#L26 Provides: system-release = %{version}-%{release} Provides: system-release(releasever) = %{major} # required by libdnf # https://github.com/rpm-software-management/libdnf/blob/0.48.0/libdnf/module/ModulePackage.cpp#L472 Provides: base-module(platform:el%{major}) Source200: EULA Source201: LICENSE Source202: Contributors Source300: 85-display-manager.preset Source301: 90-default.preset Source302: 99-default-disable.preset %description %{distro} release files. %install # copy license and contributors doc here for %%license and %%doc macros cp %{SOURCE201} %{SOURCE202} . # create /etc/system-release and /etc/redhat-release install -d -m 0755 %{buildroot}%{_sysconfdir} echo "%{distro} release %{major}" > %{buildroot}%{_sysconfdir}/centos-release ln -s centos-release %{buildroot}%{_sysconfdir}/system-release ln -s centos-release %{buildroot}%{_sysconfdir}/redhat-release # Create the os-release file install -d -m 0755 %{buildroot}%{_prefix}/lib cat > %{buildroot}%{_prefix}/lib/os-release << EOF NAME="%{distro}" VERSION="%{major}" ID="centos" ID_LIKE="rhel fedora" VERSION_ID="%{major}" PLATFORM_ID="platform:el%{major}" PRETTY_NAME="%{distro} %{major}" ANSI_COLOR="0;31" CPE_NAME="cpe:/o:centos:centos:%{major}" HOME_URL="https://centos.org/" BUG_REPORT_URL="https://bugzilla.redhat.com/" REDHAT_SUPPORT_PRODUCT="Red Hat Enterprise Linux %{major}" REDHAT_SUPPORT_PRODUCT_VERSION="%{distro}" EOF # Create the symlink for /etc/os-release ln -s ../usr/lib/os-release %{buildroot}%{_sysconfdir}/os-release # write cpe to /etc/system/release-cpe echo "cpe:/o:centos:centos:%{major}" > %{buildroot}%{_sysconfdir}/system-release-cpe # create /etc/issue and /etc/issue.net echo '\S' > %{buildroot}%{_sysconfdir}/issue echo 'Kernel \r on an \m' >> %{buildroot}%{_sysconfdir}/issue cp %{buildroot}%{_sysconfdir}/issue{,.net} echo >> %{buildroot}%{_sysconfdir}/issue # set up the dist tag macros install -d -m 0755 %{buildroot}%{_sysconfdir}/rpm cat > %{buildroot}%{_sysconfdir}/rpm/macros.dist << EOF # dist macros. %%centos_ver %{major} %%centos %{major} %%rhel %{major} %%dist .el%{major} %%el%{major} 1 EOF # use unbranded datadir install -d -m 0755 %{buildroot}%{_datadir}/centos-release ln -s centos-release %{buildroot}%{_datadir}/redhat-release install -p -m 0644 %{SOURCE200} %{buildroot}%{_datadir}/centos-release/ # copy systemd presets install -d -m 0755 %{buildroot}%{_prefix}/lib/systemd/system-preset/ install -p -m 0644 %{_sourcedir}/*.preset %{buildroot}%{_prefix}/lib/systemd/system-preset/ %files %license LICENSE %doc Contributors %{_sysconfdir}/redhat-release %{_sysconfdir}/system-release %{_sysconfdir}/centos-release %config(noreplace) %{_sysconfdir}/os-release %config %{_sysconfdir}/system-release-cpe %config(noreplace) %{_sysconfdir}/issue %config(noreplace) %{_sysconfdir}/issue.net %{_sysconfdir}/rpm/macros.dist %{_datadir}/redhat-release %{_datadir}/centos-release %{_prefix}/lib/os-release %{_prefix}/lib/systemd/system-preset/* %ifarch %{arm} aarch64 %attr(0755,root,root) %{_bindir}/rootfs-expand %endif %changelog * Wed Mar 03 2021 Michal Konecny - 9.0-1 - Update to version 9.0 * Mon Sep 28 2020 Carl George - 8.4-1 - Update to version 8.4 * Wed Sep 02 2020 Carl George - 8.3-1 - Convert to centos-stream-release * Fri May 15 2020 Pablo Greco - 8-2.0.1 - Relax dependency for centos-repos - Remove update_boot, it was never used in 8 - Add rootfs_expand to aarch64 - Bump release for 8.2 * Thu Mar 12 2020 bstinson@centosproject.org - 8-1.0.9 - Add the Devel repo to centos-release - Install os-release(5) content to /usr/lib and have /etc/os-release be a symlink (ngompa)pr#9 * Thu Jan 02 2020 Brian Stinson - 8-1.0.8 - Add base module platform Provides so DNF can auto-discover modular platform (ngompa)pr#6 - Switched CR repo to mirrorlist to spread the load (arrfab)pr#5 * Thu Dec 19 2019 bstinson@centosproject.org - 8-1.0.7 - Typo fixes - Disable the HA repo by default * Wed Dec 18 2019 Pablo Greco - 8-1.el8 - Fix requires in armhfp * Tue Dec 17 2019 bstinson@centosproject.org - 8-1.el8 - Add the HighAvailability repository * Wed Aug 14 2019 Neal Gompa 8-1.el8 - Split repositories and GPG keys out into subpackages * Sat Aug 10 2019 Fabian Arrotin 8-0.el8 - modified baseurl paths, even if disabled * Sat Aug 10 2019 Fabian Arrotin 8-0.el8 - Enabled Extras by default. - Fixed sources paths for BaseOS/AppStream * Sat Aug 10 2019 Brian Stinson 8-0.el7 - Update Debuginfo and fasttrack to use releasever - Fix CentOS-media.repo to include appstream * Wed May 08 2019 Pablo Greco 8-0.el7 - Initial setup for CentOS-8