# # spec file for package SLES # # Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via http://bugs.opensuse.org/ # # old location was /etc/YaST2/licenses/, see jsc#SLE-3067 %define product_license_dir /usr/share/licenses/product/ Name: sles-release Summary: SUSE Linux Enterprise Server 15 SP3 License: MIT Group: System/Fhs Version: 15.3 Release: 0 BuildRequires: skelcd-EULA-sles Recommends: branding # in rare cases, 'ln' is not found... Requires(post): coreutils Recommends: issue-generator # bsc#1078737#c7 Recommends: release-notes-sles Recommends: (yast2-vm if patterns-yast-yast2_basis) Provides: distribution-release Provides: product(SUSE_SLE) = %{version}-%{release} Provides: product(SUSE_SLE-SP3) = %{version}-%{release} # used by yast to show where the product will be shown during installation. # lowest number will be top-most Provides: displayorder(200) # bsc#1055299 Conflicts: otherproviders(distribution-release) # bsc#1049164 Obsoletes: leanos-release #bsc#1071720 Obsoletes: sles-release-DVD < 15 Obsoletes: sles-release-MINI < 15 Obsoletes: sles-release-POOL < 15 #bsc#1089031 migration from Leap 15 to SLES 15 Obsoletes: openSUSE-release <= 15.3 Obsoletes: product:Leap <= 15.3 Obsoletes: product:openSUSE <= 15.3 Obsoletes: openSUSE-release-dvd <= 15.3 Obsoletes: openSUSE-release-ftp <= 15.3 Obsoletes: openSUSE-release-appliance-custom <= 15.3 Provides: %name-%version Provides: product() = SLES Provides: product(SLES) = 15.3-0 %ifarch x86_64 Provides: product-register-target() = sle%2D15%2Dx86_64 %endif %ifarch s390x Provides: product-register-target() = sle%2D15%2Ds390x %endif %ifarch ppc64le Provides: product-register-target() = sle%2D15%2Dppc64le %endif %ifarch aarch64 Provides: product-register-target() = sle%2D15%2Daarch64 %endif Provides: product-label() = SLES15%2DSP3 Provides: product-cpeid() = cpe%3A%2Fo%3Asuse%3Asles%3A15%3Asp3 Provides: product-url(releasenotes) = https%3A%2F%2Fwww.suse.com%2Freleasenotes%2F%{_target_cpu}%2FSUSE%2DSLES%2F15%2DSP3%2Frelease%2Dnotes%2Dsles.rpm %ifarch x86_64 Provides: product-updates-repoid() = obsrepository%3A%2F%2Fbuild.suse.de%2FSUSE%3AUpdates%3ASLE%2DProduct%2DSLES%3A15%2DSP3%3Ax86_64%2Fupdate %endif %ifarch s390x Provides: product-updates-repoid() = obsrepository%3A%2F%2Fbuild.suse.de%2FSUSE%3AUpdates%3ASLE%2DProduct%2DSLES%3A15%2DSP3%3As390x%2Fupdate %endif %ifarch ppc64le Provides: product-updates-repoid() = obsrepository%3A%2F%2Fbuild.suse.de%2FSUSE%3AUpdates%3ASLE%2DProduct%2DSLES%3A15%2DSP3%3Appc64le%2Fupdate %endif %ifarch aarch64 Provides: product-updates-repoid() = obsrepository%3A%2F%2Fbuild.suse.de%2FSUSE%3AUpdates%3ASLE%2DProduct%2DSLES%3A15%2DSP3%3Aaarch64%2Fupdate %endif %ifarch x86_64 Provides: product-updates-repoid() = obsrepository%3A%2F%2Fbuild.suse.de%2FSUSE%3AUpdates%3ASLE%2DProduct%2DSLES%3A15%2DSP3%3Ax86_64%2Fupdate_debug %endif %ifarch s390x Provides: product-updates-repoid() = obsrepository%3A%2F%2Fbuild.suse.de%2FSUSE%3AUpdates%3ASLE%2DProduct%2DSLES%3A15%2DSP3%3As390x%2Fupdate_debug %endif %ifarch ppc64le Provides: product-updates-repoid() = obsrepository%3A%2F%2Fbuild.suse.de%2FSUSE%3AUpdates%3ASLE%2DProduct%2DSLES%3A15%2DSP3%3Appc64le%2Fupdate_debug %endif %ifarch aarch64 Provides: product-updates-repoid() = obsrepository%3A%2F%2Fbuild.suse.de%2FSUSE%3AUpdates%3ASLE%2DProduct%2DSLES%3A15%2DSP3%3Aaarch64%2Fupdate_debug %endif %ifarch x86_64 Provides: product-updates-repoid() = obsrepository%3A%2F%2Fbuild.suse.de%2FSUSE%3AUpdates%3ASLE%2DINSTALLER%3A15%2DSP3%3Ax86_64%2Fupdate %endif %ifarch s390x Provides: product-updates-repoid() = obsrepository%3A%2F%2Fbuild.suse.de%2FSUSE%3AUpdates%3ASLE%2DINSTALLER%3A15%2DSP3%3As390x%2Fupdate %endif %ifarch ppc64le Provides: product-updates-repoid() = obsrepository%3A%2F%2Fbuild.suse.de%2FSUSE%3AUpdates%3ASLE%2DINSTALLER%3A15%2DSP3%3Appc64le%2Fupdate %endif %ifarch aarch64 Provides: product-updates-repoid() = obsrepository%3A%2F%2Fbuild.suse.de%2FSUSE%3AUpdates%3ASLE%2DINSTALLER%3A15%2DSP3%3Aaarch64%2Fupdate %endif Provides: product-endoflife() Provides: product(SLES-SP3) = %version-%release Obsoletes: SLES-SP3-migration Obsoletes: product:SLES-SP3-migration Provides: product(SUSE_SLE) = 15.3 Provides: product(SUSE_SLE-SP3) = 15.3 # Make sure we are at SLES15 level # TBD PreReq: glibc >= 2.22 Conflicts: kernel < 4.4 Conflicts: perl-Bootloader < 0.904 # help packagelist generator to pick -default flavor instead of vanilla, when in doubt Suggests: kernel-default # old package obsoletes removed. If we support 11 SP4 migration to 15, we may # need to re-add some. # ./. BuildRoot: %{_tmppath}/%{name}-%{version}-build # this package should only be available for the "basearchs" of a product # i586 added as installation-images-SLES reequires it. ExclusiveArch: i586 x86_64 ppc64le s390x aarch64 Source100: weakremovers.inc %include %{SOURCE100} %description SUSE Linux Enterprise offers a comprehensive suite of products built on a single code base. The platform addresses business needs from the smallest thin-client devices to the world's most powerful high-performance computing and mainframe servers. SUSE Linux Enterprise offers common management tools and technology certifications across the platform, and each product is enterprise-class. %prep %build %install mkdir -p $RPM_BUILD_ROOT/etc mkdir -p $RPM_BUILD_ROOT/usr/lib/issue.d # Create set-up for issue-generator echo -e "\nWelcome to SUSE Linux Enterprise Server 15 SP3 (%{_target_cpu}) - Kernel \\\r (\\\l).\n" > $RPM_BUILD_ROOT/usr/lib/issue.d/10-SUSE echo -e "\n" > $RPM_BUILD_ROOT/usr/lib/issue.d/90-SUSE # create /etc/SuSE-release - deprecated, FATE#316268 # no longer build, in case you wonder touch $RPM_BUILD_ROOT/etc/motd # Setup rpm macros mkdir -p $RPM_BUILD_ROOT/etc/rpm/ echo "#" > $RPM_BUILD_ROOT/etc/rpm/macros.sle echo "# RPM macros to identify SLE distribution" >> $RPM_BUILD_ROOT/etc/rpm/macros.sle echo "#" >> $RPM_BUILD_ROOT/etc/rpm/macros.sle echo "#==================================================" >> $RPM_BUILD_ROOT/etc/rpm/macros.sle echo "" >> $RPM_BUILD_ROOT/etc/rpm/macros.sle echo "%%sle_version %sle_version" >> $RPM_BUILD_ROOT/etc/rpm/macros.sle # Put EULA into correct place mkdir -p $RPM_BUILD_ROOT/%{product_license_dir}SLES cd $RPM_BUILD_ROOT/%{product_license_dir}SLES tar -xf /usr/lib/skelcd/CD1/license-SLES.tar.gz # --overwrite echo "directory.yast" > directory.yast ls lic* > directory.yast mkdir -p $RPM_BUILD_ROOT/etc cat >$RPM_BUILD_ROOT/etc/os-release << EOF NAME="SLES" VERSION="15-SP3%{?betaversion: }%{?betaversion}" VERSION_ID="%{version}" PRETTY_NAME="SUSE Linux Enterprise Server 15 SP3%{?betaversion: (}%{?betaversion}%{?betaversion:)}" ID="sles" ID_LIKE="suse" ANSI_COLOR="0;32" CPE_NAME="cpe:/o:suse:sles:15:sp3" EOF cat << EOF >> $RPM_BUILD_ROOT/etc/os-release DOCUMENTATION_URL="https://documentation.suse.com/" EOF mkdir -p $RPM_BUILD_ROOT/etc/products.d cat >$RPM_BUILD_ROOT/etc/products.d/SLES.prod << EOF SUSE SLES 15.3 15 3 0 %{_target_cpu} cpe:/o:suse:sles:15:sp3 sles SUSE Linux Enterprise Server 15 2028-07-31 %ifarch x86_64 sle-15-x86_64 %endif %ifarch s390x sle-15-s390x %endif %ifarch ppc64le sle-15-ppc64le %endif %ifarch aarch64 sle-15-aarch64 %endif %ifarch x86_64 %endif %ifarch s390x %endif %ifarch ppc64le %endif %ifarch aarch64 %endif %ifarch x86_64 %endif %ifarch s390x %endif %ifarch ppc64le %endif %ifarch aarch64 %endif %ifarch x86_64 %endif %ifarch s390x %endif %ifarch ppc64le %endif %ifarch aarch64 %endif %ifarch x86_64 %endif %ifarch s390x %endif %ifarch ppc64le %endif %ifarch aarch64 %endif SUSE Linux Enterprise Server 15 SP3 SLES15-SP3 SUSE Linux Enterprise offers a comprehensive suite of products built on a single code base. The platform addresses business needs from the smallest thin-client devices to the world's most powerful high-performance computing and mainframe servers. SUSE Linux Enterprise offers common management tools and technology certifications across the platform, and each product is enterprise-class. cs da de en en_GB en_US es fi fr hu it ja nb nl pl pt pt_BR ru sv zh zh_CN zh_TW https://www.suse.com/releasenotes/%{_target_cpu}/SUSE-SLES/15-SP3/release-notes-sles.rpm SLES en_US SUSE_SLE EOF %post if [ -L /etc/products.d/baseproduct ] ; then PRODLINK=`readlink -f /etc/products.d/baseproduct` PRODLINK=`basename $PRODLINK` # bsc#1091952 if [ $PRODLINK == "SUSE_SLES.prod" -o $PRODLINK == "openSUSE.prod" ]; then ln -sf SLES.prod /etc/products.d/baseproduct fi # bsc#1057321 elif [ ! -e /etc/products.d/baseproduct ]; then ln -sf SLES.prod /etc/products.d/baseproduct fi # bsc#942519, #bsc#1036000, bsc#1107040, bsc#1099521: remove SLE hardcoded default value if [ -f /etc/default/grub ] ; then sed -i -e 's|GRUB_DISTRIBUTOR="\?SLES12.*|GRUB_DISTRIBUTOR=|g' -e 's|GRUB_DISTRIBUTOR="\?SLE-12.*|GRUB_DISTRIBUTOR=|g' /etc/default/grub ||: fi # Put EULA into correct place if [ ! -e %{product_license_dir}base ] ; then ln -sf SLES %{product_license_dir}base fi %files %defattr(644,root,root,755) %config /etc/os-release %dir /etc/products.d %ghost /etc/products.d/baseproduct /etc/products.d/* %config /etc/rpm/macros.sle %config(noreplace) /etc/motd %dir %{product_license_dir} %dir %{product_license_dir}SLES/ %dir /usr/lib/issue.d/ /usr/lib/issue.d/*-SUSE %license %{product_license_dir}SLES/license*txt %{product_license_dir}SLES/directory.yast %changelog