2017-04-08 11:50:44 +00:00
|
|
|
%define dist_version 4.0
|
2012-11-15 18:59:36 +00:00
|
|
|
%define release_name R%{dist_version}
|
2014-04-02 17:11:07 +00:00
|
|
|
%define fedora_base_version %{fedora}
|
2011-01-11 19:34:00 +00:00
|
|
|
|
2013-03-19 03:16:30 +00:00
|
|
|
%if 0%{?qubes_builder}
|
|
|
|
%define _builddir %(pwd)/qubes-release
|
|
|
|
%endif
|
|
|
|
|
2011-01-11 19:34:00 +00:00
|
|
|
Summary: Qubes release files
|
|
|
|
Name: qubes-release
|
2012-11-15 18:15:57 +00:00
|
|
|
Version: %{dist_version}
|
2017-10-08 22:04:51 +00:00
|
|
|
Release: 0.3
|
2011-01-11 19:34:00 +00:00
|
|
|
License: GPLv2
|
|
|
|
Group: System Environment/Base
|
|
|
|
Source: %{name}-%{version}.tar.bz2
|
2013-02-08 22:01:34 +00:00
|
|
|
Source1: Qubes-comps.xml
|
2011-01-11 19:34:00 +00:00
|
|
|
Obsoletes: fedora-release
|
|
|
|
Obsoletes: redhat-release
|
|
|
|
Provides: fedora-release = %{fedora_base_version}-%{release}
|
|
|
|
Provides: redhat-release = %{fedora_base_version}-%{release}
|
2016-03-16 00:45:52 +00:00
|
|
|
Provides: system-release = %{fedora_base_version}-%{release}
|
2016-05-18 22:27:19 +00:00
|
|
|
Obsoletes: qubes-dom0-dist-upgrade <= 3.2
|
2011-01-11 19:34:00 +00:00
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
|
|
|
BuildArch: noarch
|
|
|
|
|
|
|
|
%description
|
|
|
|
Qubes release files such as yum configs and various /etc/ files that
|
|
|
|
define the release.
|
|
|
|
|
|
|
|
%package notes
|
|
|
|
Summary: Release Notes
|
|
|
|
License: Open Publication
|
|
|
|
Group: System Environment/Base
|
|
|
|
Provides: system-release-notes = %{version}-%{release}
|
|
|
|
Conflicts: fedora-release-notes
|
|
|
|
|
|
|
|
%description notes
|
|
|
|
Qubes release notes package.
|
|
|
|
|
|
|
|
|
|
|
|
%prep
|
2013-03-19 03:16:30 +00:00
|
|
|
%if ! 0%{?qubes_builder}
|
2011-01-11 19:34:00 +00:00
|
|
|
%setup -q
|
2013-03-19 03:16:30 +00:00
|
|
|
%endif
|
2011-01-11 19:34:00 +00:00
|
|
|
|
|
|
|
%build
|
|
|
|
|
|
|
|
%install
|
|
|
|
rm -rf $RPM_BUILD_ROOT
|
|
|
|
install -d $RPM_BUILD_ROOT/etc
|
|
|
|
echo "Qubes release %{version} (%{release_name})" > $RPM_BUILD_ROOT/etc/qubes-release
|
2013-02-13 22:53:03 +00:00
|
|
|
echo "cpe:/o:ITL:qubes:%{version}" > $RPM_BUILD_ROOT/etc/system-release-cpe
|
2011-01-11 19:34:00 +00:00
|
|
|
cp -p $RPM_BUILD_ROOT/etc/qubes-release $RPM_BUILD_ROOT/etc/issue
|
|
|
|
echo "Kernel \r on an \m (\l)" >> $RPM_BUILD_ROOT/etc/issue
|
|
|
|
cp -p $RPM_BUILD_ROOT/etc/issue $RPM_BUILD_ROOT/etc/issue.net
|
|
|
|
echo >> $RPM_BUILD_ROOT/etc/issue
|
|
|
|
ln -s qubes-release $RPM_BUILD_ROOT/etc/fedora-release
|
|
|
|
ln -s qubes-release $RPM_BUILD_ROOT/etc/redhat-release
|
|
|
|
ln -s qubes-release $RPM_BUILD_ROOT/etc/system-release
|
|
|
|
|
2013-02-13 22:53:03 +00:00
|
|
|
cat << EOF >>$RPM_BUILD_ROOT/etc/os-release
|
|
|
|
NAME=Qubes
|
|
|
|
VERSION="%{version} (%{release_name})"
|
|
|
|
ID=qubes
|
|
|
|
VERSION_ID=%{version}
|
|
|
|
PRETTY_NAME="Qubes %{version} (%{release_name})"
|
|
|
|
ANSI_COLOR="0;31"
|
|
|
|
CPE_NAME="cpe:/o:ITL:qubes:%{version}"
|
|
|
|
EOF
|
|
|
|
|
2011-01-11 19:34:00 +00:00
|
|
|
install -d -m 755 $RPM_BUILD_ROOT/etc/pki/rpm-gpg
|
|
|
|
|
|
|
|
install -m 644 RPM-GPG-KEY* $RPM_BUILD_ROOT/etc/pki/rpm-gpg/
|
|
|
|
|
|
|
|
install -d -m 755 $RPM_BUILD_ROOT/etc/yum.repos.d
|
2014-04-02 17:11:07 +00:00
|
|
|
sed -e "s/%%DIST%%/fc%{fedora_base_version}/" qubes-dom0.repo.in > $RPM_BUILD_ROOT/etc/yum.repos.d/qubes-dom0.repo
|
2014-04-04 22:47:09 +00:00
|
|
|
sed -e "s/%%FCREL%%/%{fedora_base_version}/" fedora.repo.in > $RPM_BUILD_ROOT/etc/yum.repos.d/fedora.repo
|
|
|
|
sed -e "s/%%FCREL%%/%{fedora_base_version}/" fedora-updates.repo.in > $RPM_BUILD_ROOT/etc/yum.repos.d/fedora-updates.repo
|
2014-04-15 02:03:58 +00:00
|
|
|
install -m 644 qubes-templates.repo $RPM_BUILD_ROOT/etc/yum.repos.d
|
2011-01-11 19:34:00 +00:00
|
|
|
|
2013-02-08 22:01:34 +00:00
|
|
|
install -d -m 755 $RPM_BUILD_ROOT/usr/share/qubes
|
2013-03-19 03:16:30 +00:00
|
|
|
%if 0%{?qubes_builder}
|
|
|
|
install -m 644 ../conf/comps-qubes.xml $RPM_BUILD_ROOT/usr/share/qubes/Qubes-comps.xml
|
|
|
|
%else
|
2013-02-08 22:01:34 +00:00
|
|
|
install -m 644 %{SOURCE1} $RPM_BUILD_ROOT/usr/share/qubes/Qubes-comps.xml
|
2013-03-19 03:16:30 +00:00
|
|
|
%endif
|
2013-02-08 22:01:34 +00:00
|
|
|
|
2011-01-11 19:34:00 +00:00
|
|
|
# Set up the dist tag macros
|
|
|
|
install -d -m 755 $RPM_BUILD_ROOT/etc/rpm
|
|
|
|
cat >> $RPM_BUILD_ROOT/etc/rpm/macros.dist << EOF
|
|
|
|
# dist macros.
|
|
|
|
|
|
|
|
%%qubes %{dist_version}
|
2011-03-02 15:27:34 +00:00
|
|
|
%%dist .qbs%{dist_version}
|
2011-01-11 19:34:00 +00:00
|
|
|
%%fedora %{fedora_base_version}
|
2015-04-03 09:32:30 +00:00
|
|
|
%%qbs3 1
|
2011-01-11 19:34:00 +00:00
|
|
|
%%fc%{fedora_base_version} 1
|
|
|
|
EOF
|
|
|
|
|
2017-02-14 01:31:48 +00:00
|
|
|
%posttrans
|
2013-01-26 21:45:00 +00:00
|
|
|
# Import all keys b/c rpm won't do it automatically (as opposite to yum)
|
|
|
|
rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-* || true
|
2012-03-31 18:15:15 +00:00
|
|
|
|
|
|
|
|
2011-01-11 19:34:00 +00:00
|
|
|
%clean
|
|
|
|
rm -rf $RPM_BUILD_ROOT
|
|
|
|
|
|
|
|
%files
|
|
|
|
%defattr(-,root,root,-)
|
|
|
|
%doc GPL
|
2013-02-13 22:53:03 +00:00
|
|
|
%config %attr(0644,root,root) /etc/os-release
|
2011-01-11 19:34:00 +00:00
|
|
|
%config %attr(0644,root,root) /etc/qubes-release
|
|
|
|
%config %attr(0644,root,root) /etc/fedora-release
|
|
|
|
/etc/redhat-release
|
|
|
|
/etc/system-release
|
|
|
|
%config %attr(0644,root,root) /etc/system-release-cpe
|
|
|
|
%dir /etc/yum.repos.d
|
|
|
|
%config(noreplace) /etc/yum.repos.d/fedora.repo
|
2011-04-06 08:45:05 +00:00
|
|
|
%config(noreplace) /etc/yum.repos.d/fedora-updates.repo
|
2014-04-02 17:11:07 +00:00
|
|
|
%config(noreplace) /etc/yum.repos.d/qubes-dom0.repo
|
2014-04-15 02:03:58 +00:00
|
|
|
%config(noreplace) /etc/yum.repos.d/qubes-templates.repo
|
2011-01-11 19:34:00 +00:00
|
|
|
%config(noreplace) %attr(0644,root,root) /etc/issue
|
|
|
|
%config(noreplace) %attr(0644,root,root) /etc/issue.net
|
|
|
|
%config %attr(0644,root,root) /etc/rpm/macros.dist
|
|
|
|
%dir /etc/pki/rpm-gpg
|
|
|
|
/etc/pki/rpm-gpg/*
|
2013-02-08 22:01:34 +00:00
|
|
|
/usr/share/qubes/Qubes-comps.xml
|
2011-01-11 19:34:00 +00:00
|
|
|
|
|
|
|
%files notes
|
|
|
|
%defattr(-,root,root,-)
|
|
|
|
%doc README.Qubes-Release-Notes
|
|
|
|
|
|
|
|
%changelog
|
2013-08-26 12:00:34 +00:00
|
|
|
* Wed Jan 13 2010 Tomasz Sterna <smoku@xiaoka.com> - 1
|
2011-01-11 19:34:00 +00:00
|
|
|
- Initial Qubes 1 Release package
|