2017-03-07 17:00:56 +03:00
Summary : Hybrid image/package system
2014-01-16 06:54:48 +04:00
Name : rpm-ostree
2017-03-07 17:00:56 +03:00
Version : 2017.3
2014-01-16 06:54:48 +04:00
Release : 1%{?dist}
2014-02-24 02:27:56 +04:00
#VCS: https://github.com/cgwalters/rpm-ostree
# This tarball is generated via "make -f Makefile.dist-packaging dist-snapshot"
2014-01-16 06:54:48 +04:00
Source0 : rpm-ostree-%{version} .tar.xz
License : LGPLv2+
2017-03-07 17:00:56 +03:00
URL : https://github.com/projectatomic/rpm-ostree
2014-01-16 06:54:48 +04:00
# We always run autogen.sh
2017-03-07 17:00:56 +03:00
BuildRequires : autoconf automake libtool git
2014-01-16 06:54:48 +04:00
# For docs
2017-03-07 17:00:56 +03:00
BuildRequires : chrpath
2014-01-16 06:54:48 +04:00
BuildRequires : gtk-doc
2017-03-07 17:00:56 +03:00
BuildRequires : gperf
2014-01-16 06:54:48 +04:00
BuildRequires : gnome-common
2017-03-07 17:00:56 +03:00
BuildRequires : gobject-introspection
# Core requirements
BuildRequires : pkgconfig(ostree-1) >= 2017.2
2014-02-13 03:26:31 +04:00
BuildRequires : pkgconfig(json-glib-1.0)
2014-03-28 03:57:10 +04:00
BuildRequires : pkgconfig(rpm)
2017-03-07 17:00:56 +03:00
BuildRequires : pkgconfig(libarchive)
BuildRequires : pkgconfig(libsystemd)
2014-11-15 02:07:47 +03:00
BuildRequires : libcap-devel
2017-03-07 17:00:56 +03:00
BuildRequires : libattr-devel
# We currently interact directly with librepo
BuildRequires : pkgconfig(librepo)
2014-01-16 07:22:49 +04:00
2017-03-07 17:00:56 +03:00
# libdnf bundling
# We're using RPATH to pick up our bundled version
%global __requires_exclude ^libdnf[.]so[.].*$
BuildRequires : cmake
BuildRequires : pkgconfig(expat)
BuildRequires : pkgconfig(check)
BuildRequires : python-devel
BuildRequires : python-sphinx
%if (0%{?rhel} != 0 && 0%{?rhel} <= 7)
BuildRequires : libsolv-devel
%else
BuildRequires : pkgconfig(libsolv)
%endif
# In CentOS7/RHEL the package is client-only right now, but we can do both
%if 0%{?rhel} != 0 && 0%{?rhel} <= 7
Provides : rpm-ostree-client
%endif
# For now...see https://github.com/projectatomic/rpm-ostree/pull/637
# and https://github.com/fedora-infra/fedmsg-atomic-composer/pull/17
# etc. We'll drop this dependency at some point in the future when
# rpm-ostree wraps more of ostree (such as `ostree admin unlock` etc.)
Requires : ostree
Requires : bubblewrap
Requires : fuse
2014-01-16 06:54:48 +04:00
%description
2017-03-07 17:00:56 +03:00
rpm-ostree is a hybrid image/package system. It supports
" c o m p o s i n g " packages on a build server into an OSTree repository,
which can then be replicated by client systems with atomic upgrades.
Additionally, unlike many " p u r e " image systems, with rpm-ostree
each client system can layer on additional packages, providing
a " b e s t o f b o t h w o r l d s " approach.
2014-01-16 06:54:48 +04:00
2015-04-09 00:20:50 +03:00
%package devel
Summary : Development headers for %{name}
Group : Development/Libraries
Requires : %{name} = %{version} -%{release}
%description devel
The %{name} -devel package includes the header files for the %{name} library.
2014-01-16 06:54:48 +04:00
%prep
2017-03-07 17:00:56 +03:00
%autosetup -Sgit -n %{name} -%{version}
2014-01-16 06:54:48 +04:00
%build
env NOCONFIGURE=1 ./autogen.sh
2015-09-01 00:21:35 +03:00
%configure --disable-silent-rules --enable-gtk-doc
2014-01-16 06:54:48 +04:00
make %{?_smp_mflags}
%install
make install DESTDIR=$RPM_BUILD_ROOT INSTALL=" i n s t a l l - p - c "
2015-04-09 00:20:50 +03:00
find $RPM_BUILD_ROOT -name '*.la' -delete
2014-01-16 06:54:48 +04:00
2017-03-07 17:00:56 +03:00
# I try to do continuous delivery via rpmdistro-gitoverlay while
# reusing the existing spec files. Currently RPM only supports
# mandatory file entries. What this is doing is making each file
# entry optional - if it exists it will be picked up. That
# way the same spec file works more easily across multiple versions where e.g. an
# older version might not have a systemd unit file.
cat > autofiles.py <<EOF
#!/usr/bin/python
import os,sys,glob
os.chdir(os.environ['RPM_BUILD_ROOT' ])
for line in sys.argv[1:]:
if line == '' :
break
if line[0] != '/' :
sys.stdout.write(line + '\n' )
else:
files = glob.glob(line[1:])
if len(files) > 0:
sys.stderr.write('{0} matched {1} files\n' .format(line, len(files)))
sys.stdout.write(line + '\n' )
else:
sys.stderr.write('{0} did not match any files\n' .format(line))
EOF
python autofiles.py > files \
'%{_bindir}/*' \
'%{_libdir}/%{name}' \
'%{_libdir}/*.so.*' \
'%{_mandir}/man*/*' \
'%{_libdir}/girepository-1.0/*.typelib' \
'%{_sysconfdir}/dbus-1/system.d/*' \
'%{_prefix}/lib/systemd/system/*' \
'%{_libexecdir}/rpm-ostree*' \
'%{_datadir}/dbus-1/system-services'
python autofiles.py > files.devel \
'%{_libdir}/lib*.so' \
'%{_includedir}/*' \
'%{_libdir}/pkgconfig/*' \
'%{_datadir}/gtk-doc/html/*' \
'%{_datadir}/gir-1.0/*-1.0.gir'
2015-04-09 00:20:50 +03:00
2017-03-07 17:00:56 +03:00
%files -f files
%doc COPYING README.md
2014-02-24 02:27:56 +04:00
2017-03-07 17:00:56 +03:00
%files devel -f files.devel
2014-03-10 22:19:29 +04:00