source: projects/specs/trunk/c/cgmanager/cgmanager-vl.spec @ 11165

Revision 11165, 4.0 KB checked in by tomop, 7 years ago (diff)

cgmanager-0.41-1

Line 
1#
2# cgmanager: cgroup manager daemon
3#
4# Copyright (C) 2013 Oracle
5#
6# Authors:
7# Dwight Engen <dwight.engen@oracle.com>
8#
9# This library is free software; you can redistribute it and/or
10# modify it under the terms of the GNU Lesser General Public
11# License as published by the Free Software Foundation; either
12# version 2.1 of the License, or (at your option) any later version.
13#
14# This library is distributed in the hope that it will be useful,
15# but WITHOUT ANY WARRANTY; without even the implied warranty of
16# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
17# Lesser General Public License for more details.
18#
19# You should have received a copy of the GNU Lesser General Public
20# License along with this library; if not, write to the Free Software
21# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
22
23Name: cgmanager
24Version: 0.41
25Release: 1%{?_dist_release}
26URL: http://cgmanager.linuxcontainers.org
27Source: http://cgmanager.linuxcontainers.org/downloads/%{name}-%{version}.tar.gz
28Summary: Linux cgroup manager
29Group: Applications/System
30License: LGPLv2+
31BuildRoot: %{_tmppath}/%{name}-%{version}-build
32Requires: dbus libnih
33BuildRequires: libnih-devel dbus-devel pam-devel help2man
34
35%description
36CGManager is a central privileged daemon that manages all your cgroups for
37you through a simple DBus API.  It's designed to work with nested LXC
38containers as well as accepting unprivileged requests including resolving
39user namespaces UIDs/GIDs.
40
41%package        libs
42Summary:        Shared library files for %{name}
43Group:          System Environment/Libraries
44%description    libs
45The %{name}-libs package contains libraries for running %{name} applications.
46
47%package        devel
48Summary:        Development library for %{name}
49Group:          Development/Libraries
50Requires:       %{name} = %{version}-%{release}, pkgconfig
51%description    devel
52The %{name}-devel package contains header files and library needed for
53development with %{name}.
54
55%prep
56%setup -q -n %{name}-%{version}
57
58%build
59%configure --with-init-script=upstart
60
61make %{?_smp_mflags}
62
63perl -pi -e 's|/sbin/cgmanager|/usr/sbin/cgmanager|' config/init/upstart/cgmanager.conf
64perl -pi -e 's|^start on.*$|start on runlevel [345]|' config/init/upstart/cgmanager.conf
65
66perl -pi -e 's|/sbin/cgproxy|/usr/sbin/cgproxy|' config/init/upstart/cgproxy.conf
67
68%install
69rm -rf %{buildroot}
70make install DESTDIR=%{buildroot}
71find %{buildroot} -type f -name '*.la' -exec rm -f {} ';'
72
73rm -f %{buildroot}/%{_libdir}/*.a
74
75#mkdir -p %{buildroot}/%{_sysconfdir}/init
76#mkdir -p %{buildroot}/%{_datadir}/upstart/sessions
77
78#install -m 644 config/init/upstart/cgmanager.conf %{buildroot}/%{_sysconfdir}/init/cgmanager.conf
79#install -m 644 config/init/upstart/cgproxy.conf %{buildroot}/%{_sysconfdir}/init/cgproxy.conf
80#install -m 644 config/init/upstart/sessions/cgmanager.conf %{buildroot}/%{_datadir}/upstart/sessions/cgmanager.conf
81
82
83%check
84make check
85
86%clean
87rm -rf %{buildroot}
88
89%preun
90if [ $1 -eq 0 ]; then
91  /sbin/stop cgproxy >/dev/null 2>&1 ||:
92  /sbin/stop cgmanager >/dev/null 2>&1 ||:
93else
94  /sbin/restart cgproxy >/dev/null 2>&1 ||:
95  /sbin/restart cgmanager >/dev/null 2>&1 ||:
96fi
97
98%post   libs -p /sbin/ldconfig
99%postun libs -p /sbin/ldconfig
100
101%files
102%defattr(-,root,root)
103%doc AUTHORS COPYING ChangeLog INSTALL NEWS README TODO
104%config(noreplace) %{_sysconfdir}/init/*.conf
105%config(noreplace) %{_datadir}/upstart/sessions/*.conf
106%{_mandir}/man1/cgm.1*
107%{_bindir}/*
108%{_sbindir}/*
109%{_libexecdir}/%{name}
110/%{_lib}/security/pam_cgm.so
111%{_mandir}/man8/*
112%{_datadir}/%{name}
113
114%files libs
115%defattr(-,root,root)
116%{_libdir}/*.so.*
117
118%files devel
119%defattr(-,root,root)
120%{_includedir}/%{name}/*
121%{_libdir}/*.so
122%{_libdir}/pkgconfig/*
123
124%changelog
125* Mon Sep 04 2017 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 0.41-1
126- initial build for Vine Linux.
127
128* Mon Mar 24 2014 Dwight Engen <dwight.engen@oracle.com> - 0.23
129remove libnih-dbus Requires since there is no such package, libnih is sufficient
130
131* Mon Mar 24 2014 Dwight Engen <dwight.engen@oracle.com> - 0.22
132add cgm script
133
134* Tue Feb 04 2014 Dwight Engen <dwight.engen@oracle.com> - 0.19
135- created
Note: See TracBrowser for help on using the repository browser.