Browse Source

lxc-4.0.4-1

git-svn-id: http://trac.vinelinux.org/repos/projects/specs@12461 ec354946-7b23-47d6-9f5a-488ba84defc7
tomop 3 years ago
parent
commit
7a72ad9c4d
1 changed files with 35 additions and 28 deletions
  1. 35 28
      l/lxc/lxc-vl.spec

+ 35 - 28
l/lxc/lxc-vl.spec

@@ -12,11 +12,11 @@
 %define _unpackaged_files_terminate_build 1
 
 Name:           lxc
-Version:        4.0.0
+Version:        4.0.4
 Release:        1%{?_dist_release}%{?with_systemd:.systemd}
 Summary:        Linux Resource Containers
 Summary(ja):    Linux リソースコンテナ
-Group:          Applications/System
+Group:          virtualization
 License:        LGPLv2+ and GPLv2
 URL:            https://linuxcontainers.org
 Vendor:         Project Vine
@@ -70,7 +70,7 @@ overhead of full virtualization.
 %package        libs
 Summary:        Runtime library files for %{name}
 Summary(ja):    %{name}のランタイムライブラリ
-Group:          System Environment/Libraries
+Group:          virtualization
 %if 0%{?with_systemd}
 Requires(post): systemd
 Requires(preun): systemd
@@ -93,7 +93,7 @@ The %{name}-libs package contains libraries for running %{name} applications.
 %package        -n python3-%{name}
 Summary:        Python binding for %{name}
 Summary(ja):    %{name} の Python バインディング
-Group:          System Environment/Libraries
+Group:          programming
 
 %description    -n python3-%{name}
 Linux Resource Containers provide process and resource isolation without the
@@ -107,7 +107,7 @@ The python3-%{name} package contains the Python3 binding for %{name}.
 %package        extra
 Summary:        Extra tools for %{name}
 Summary(ja):    %{name} の追加ツール
-Group:          Applications/System
+Group:          virtualization
 Requires:       python3-%{name} = %{version}-%{release}
 
 %description    extra
@@ -122,7 +122,7 @@ This package contains tools needing the Python3 bindings.
 %package        -n lua-%{name}
 Summary:        Lua binding for %{name}
 Summary(ja):    %{name} の Lua バインディング
-Group:          System Environment/Libraries
+Group:          programming
 
 %description    -n lua-%{name}
 Linux Resource Containers provide process and resource isolation without the
@@ -138,7 +138,7 @@ The lua-%{name} package contains the Lua binding for %{name}.
 %package        templates
 Summary:        Templates for %{name}
 Summary(ja):    %{name} のテンプレート
-Group:          System Environment/Libraries
+Group:          virtualization
 Requires:       %{name}-libs%{?_isa} = %{version}-%{release}
 # Note: Requirements for the template scripts (busybox, dpkg,
 # debootstrap, vbootstrap, rsync, openssh-server, dhclient, apt, pacman, zypper,
@@ -160,7 +160,7 @@ The %{name}-templates package contains templates for creating containers.
 %package        devel
 Summary:        Development files for %{name}
 Summary(ja):    %{name}の開発ファイル
-Group:          Development/Libraries
+Group:          programming
 Requires:       %{name}-libs%{?_isa} = %{version}-%{release}
 Requires:       pkgconfig
 
@@ -175,7 +175,7 @@ developing applications that use %{name}.
 %package        doc
 Summary:        Documentation for %{name}
 Summary(ja):    %{name} のドキュメント
-Group:          Documentation
+Group:          documentation
 BuildArch:      noarch
 
 %description    doc
@@ -216,22 +216,22 @@ This package contains documentation for %{name}.
 %else
            --with-init-script=sysvinit \
 %endif # with_systemd
-# intentionally blank line
+           %{nil}
+
 make %{?_smp_mflags}
 
 
 %install
 %{make_install}
 make DESTDIR=%{buildroot} install
-mkdir -p %{buildroot}%{_sharedstatedir}/%{name}
+mkdir -p %{buildroot}%{_localstatedir}/lib/%{name}
 %if %{with lua}
 chmod -x %{buildroot}%{luapkgdir}/lxc.lua
 %endif
 
-mkdir -p %{buildroot}%{_pkgdocdir}
-cp -a AUTHORS COPYING README %{buildroot}%{_pkgdocdir}
-mkdir -p %{buildroot}%{_pkgdocdir}/api
-cp -a doc/api/html/* %{buildroot}%{_pkgdocdir}/api/
+rm -rf rpmdoc
+mkdir -p rpmdoc/api
+cp -a doc/api/html/* rpmdoc/api/
 
 # cache dir
 mkdir -p %{buildroot}%{_localstatedir}/cache/%{name}
@@ -253,7 +253,9 @@ make check
 %post libs
 /sbin/ldconfig
 %if 0%{?with_systemd}
+%systemd_post %{name}-net.service
 %systemd_post %{name}.service
+%systemd_post %{name}@.service
 %else
 /sbin/chkconfig --add %{name}
 %endif # with_systemd
@@ -261,9 +263,11 @@ make check
 
 %preun libs
 %if 0%{?with_systemd}
+%systemd_preun %{name}-net.service
 %systemd_preun %{name}.service
+%systemd_preun %{name}@.service
 %else
-if [ $1 -eq 0 ]; then
+if [ $1 -eq 0 -o -x /bin/systemctl ]; then
         /sbin/service %{name} stop > /dev/null 2>&1
         /sbin/chkconfig --del %{name}
 fi
@@ -273,7 +277,10 @@ fi
 %postun libs
 /sbin/ldconfig
 %if 0%{?with_systemd}
+%systemd_postun %{name}-net.service
 %systemd_postun %{name}.service
+%systemd_postun %{name}@.service
+
 %else
 if [ $1 -ge 1 ]; then
         /sbin/service %{name} condrestart > /dev/null 2>&1 || :
@@ -282,10 +289,10 @@ fi
 
 
 %files
-%license COPYING
-%doc README*
+%license COPYING LICENSE*
+%doc AUTHORS MAINTAINERS README*
+%doc rpmdoc/api
 %{_bindir}/%{name}-*
-%{_bindir}/run-coccinelle.sh
 %{_mandir}/man1/%{name}*
 %{_mandir}/*/man1/%{name}*
 # in lxc-libs:
@@ -319,7 +326,7 @@ fi
 %{_sbindir}/init.%{name}
 %{_sbindir}/init.%{name}.static
 %{_bindir}/%{name}-autostart
-%{_sharedstatedir}/%{name}
+%{_localstatedir}/lib/%{name}
 %dir %{_sysconfdir}/%{name}
 %config(noreplace) %{_sysconfdir}/%{name}/default.conf
 %config(noreplace) %{_sysconfdir}/sysconfig/%{name}
@@ -331,12 +338,10 @@ fi
 %{_mandir}/man7/%{name}*
 %{_mandir}/*/man5/%{name}*
 %{_mandir}/*/man7/%{name}*
-%dir %{_pkgdocdir}
-%{_pkgdocdir}/AUTHORS
-%{_pkgdocdir}/COPYING
-%{_pkgdocdir}/README
 %if 0%{?with_systemd}
 %{_unitdir}/%{name}.service
+%{_unitdir}/%{name}@.service
+%{_unitdir}/%{name}-net.service
 %else
 %{_sysconfdir}/rc.d/init.d/%{name}
 %{_sysconfdir}/rc.d/init.d/%{name}-net
@@ -378,13 +383,15 @@ fi
 
 
 %files doc
-%dir %{_pkgdocdir}
-# README, AUTHORS and COPYING intentionally duplicated because -doc
-# can be installed on its own.
-%{_pkgdocdir}/*
+%doc COPYING LICENSE* AUTHORS MAINTAINERS README*
+%doc rpmdoc/api
 
 
 %changelog
+* Mon Aug 10 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 4.0.4-1
+- new upstream release,
+- added systemd support (disabled as default).
+
 * Sat Apr 04 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 4.0.0-1
 - updated to 4.0.0.
 - updated lxc-vinelinux.