[arch-commits] Commit in snapd/repos (16 files)
Timothy Redaelli
tredaelli at archlinux.org
Tue Feb 21 15:32:51 UTC 2017
Date: Tuesday, February 21, 2017 @ 15:32:51
Author: tredaelli
Revision: 213341
archrelease: copy trunk to community-i686, community-x86_64
Added:
snapd/repos/community-i686/0001-debian-ARCHLINUX-use-alternate-snap-mount-directory.patch
(from rev 213340, snapd/trunk/0001-debian-ARCHLINUX-use-alternate-snap-mount-directory.patch)
snapd/repos/community-i686/0001-dirs-FEDORA-use-alternate-snap-mount-directory.patch
(from rev 213340, snapd/trunk/0001-dirs-FEDORA-use-alternate-snap-mount-directory.patch)
snapd/repos/community-i686/PKGBUILD
(from rev 213340, snapd/trunk/PKGBUILD)
snapd/repos/community-i686/snapd.install
(from rev 213340, snapd/trunk/snapd.install)
snapd/repos/community-i686/snapd.sh
(from rev 213340, snapd/trunk/snapd.sh)
snapd/repos/community-x86_64/0001-debian-ARCHLINUX-use-alternate-snap-mount-directory.patch
(from rev 213340, snapd/trunk/0001-debian-ARCHLINUX-use-alternate-snap-mount-directory.patch)
snapd/repos/community-x86_64/0001-dirs-FEDORA-use-alternate-snap-mount-directory.patch
(from rev 213340, snapd/trunk/0001-dirs-FEDORA-use-alternate-snap-mount-directory.patch)
snapd/repos/community-x86_64/PKGBUILD
(from rev 213340, snapd/trunk/PKGBUILD)
snapd/repos/community-x86_64/snapd.install
(from rev 213340, snapd/trunk/snapd.install)
snapd/repos/community-x86_64/snapd.sh
(from rev 213340, snapd/trunk/snapd.sh)
Deleted:
snapd/repos/community-i686/PKGBUILD
snapd/repos/community-i686/snapd.install
snapd/repos/community-i686/snapd.sh
snapd/repos/community-x86_64/PKGBUILD
snapd/repos/community-x86_64/snapd.install
snapd/repos/community-x86_64/snapd.sh
---------------------------------------------------------------------------------+
/PKGBUILD | 232 ++++++++++
/snapd.install | 30 +
/snapd.sh | 20
community-i686/0001-debian-ARCHLINUX-use-alternate-snap-mount-directory.patch | 26 +
community-i686/0001-dirs-FEDORA-use-alternate-snap-mount-directory.patch | 26 +
community-i686/PKGBUILD | 80 ---
community-i686/snapd.install | 15
community-i686/snapd.sh | 10
community-x86_64/0001-debian-ARCHLINUX-use-alternate-snap-mount-directory.patch | 26 +
community-x86_64/0001-dirs-FEDORA-use-alternate-snap-mount-directory.patch | 26 +
community-x86_64/PKGBUILD | 80 ---
community-x86_64/snapd.install | 15
community-x86_64/snapd.sh | 10
13 files changed, 386 insertions(+), 210 deletions(-)
Copied: snapd/repos/community-i686/0001-debian-ARCHLINUX-use-alternate-snap-mount-directory.patch (from rev 213340, snapd/trunk/0001-debian-ARCHLINUX-use-alternate-snap-mount-directory.patch)
===================================================================
--- community-i686/0001-debian-ARCHLINUX-use-alternate-snap-mount-directory.patch (rev 0)
+++ community-i686/0001-debian-ARCHLINUX-use-alternate-snap-mount-directory.patch 2017-02-21 15:32:51 UTC (rev 213341)
@@ -0,0 +1,26 @@
+From 529c77918eab0742e645db3d97b62b55e9f6888a Mon Sep 17 00:00:00 2001
+From: Timothy Redaelli <tredaelli at archlinux.info>
+Date: Tue, 21 Feb 2017 11:38:00 +0000
+Subject: [PATCH] debian: ARCHLINUX: use alternate snap mount directory
+
+Signed-off-by: Timothy Redaelli <tredaelli at archlinux.info>
+---
+ debian/snapd.refresh.service | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/debian/snapd.refresh.service b/debian/snapd.refresh.service
+index 4c3375786..dda02de0e 100644
+--- a/debian/snapd.refresh.service
++++ b/debian/snapd.refresh.service
+@@ -2,7 +2,7 @@
+ Description=Automatically refresh installed snaps
+ After=network-online.target snapd.socket
+ Requires=snapd.socket
+-ConditionPathExistsGlob=/snap/*/current
++ConditionPathExistsGlob=/var/lib/snapd/snap/*/current
+ Documentation=man:snap(1)
+
+ [Service]
+--
+2.11.1
+
Copied: snapd/repos/community-i686/0001-dirs-FEDORA-use-alternate-snap-mount-directory.patch (from rev 213340, snapd/trunk/0001-dirs-FEDORA-use-alternate-snap-mount-directory.patch)
===================================================================
--- community-i686/0001-dirs-FEDORA-use-alternate-snap-mount-directory.patch (rev 0)
+++ community-i686/0001-dirs-FEDORA-use-alternate-snap-mount-directory.patch 2017-02-21 15:32:51 UTC (rev 213341)
@@ -0,0 +1,26 @@
+From 6738583e77ca2f52760be8887c9aefebe8e89b3b Mon Sep 17 00:00:00 2001
+From: Zygmunt Krynicki <me at zygoon.pl>
+Date: Thu, 20 Oct 2016 10:14:21 +0200
+Subject: [PATCH] dirs: FEDORA: use alternate snap mount directory
+
+Signed-off-by: Zygmunt Krynicki <me at zygoon.pl>
+---
+ dirs/dirs.go | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/dirs/dirs.go b/dirs/dirs.go
+index 36e3b54..315df32 100644
+--- a/dirs/dirs.go
++++ b/dirs/dirs.go
+@@ -103,7 +103,7 @@ func SetRootDir(rootdir string) {
+ }
+ GlobalRootDir = rootdir
+
+- SnapMountDir = filepath.Join(rootdir, "/snap")
++ SnapMountDir = filepath.Join(rootdir, "/var/lib/snapd/snap")
+ SnapDataDir = filepath.Join(rootdir, "/var/snap")
+ SnapDataHomeGlob = filepath.Join(rootdir, "/home/*/snap/")
+ SnapAppArmorDir = filepath.Join(rootdir, snappyDir, "apparmor", "profiles")
+--
+2.7.4
+
Deleted: community-i686/PKGBUILD
===================================================================
--- community-i686/PKGBUILD 2017-02-21 15:32:38 UTC (rev 213340)
+++ community-i686/PKGBUILD 2017-02-21 15:32:51 UTC (rev 213341)
@@ -1,80 +0,0 @@
-# $Id$
-# Maintainer: Timothy Redaelli <timothy.redaelli at gmail.com>
-# Contributor: Zygmunt Krynicki <me at zygoon dot pl>
-
-pkgname=snapd
-pkgver=2.16
-pkgrel=1
-pkgdesc="Service and tools for management of snap packages."
-arch=('i686' 'x86_64')
-url="https://github.com/snapcore/snapd"
-license=('GPL3')
-depends=('snap-confine' 'squashfs-tools')
-makedepends=('git' 'go' 'go-tools' 'bzr')
-checkdepends=('python')
-options=('!strip' 'emptydirs')
-install=snapd.install
-source=("git+https://github.com/snapcore/$pkgname.git#tag=$pkgver"
- 'snapd.sh')
-md5sums=('SKIP'
- '1d841a1d09ba86945551dfc5c5658b2e')
-
-_gourl=github.com/snapcore/snapd
-
-prepare() {
- cd "$pkgname"
-
- # Use $srcdir/go as our GOPATH
- export GOPATH="$srcdir/go"
- mkdir -p "$GOPATH"
- # Have snapd checkout appear in a place suitable for subsequent GOPATH This
- # way we don't have to go get it again and it is exactly what the tag/hash
- # above describes.
- mkdir -p "$(dirname "$GOPATH/src/${_gourl}")"
- ln --no-target-directory -fs "$srcdir/$pkgname" "$GOPATH/src/${_gourl}"
-}
-
-build() {
- export GOPATH="$srcdir/go"
- # Use get-deps.sh provided by upstream to fetch go dependencies using the
- # godeps tool and dependencies.tsv (maintained upstream).
- cd "$GOPATH/src/${_gourl}"
- ./get-deps.sh
- # Build/install snap and snapd
- go install "${_gourl}/cmd/snap"
- go install "${_gourl}/cmd/snapd"
-}
-
-check() {
- export GOPATH="$srcdir/go"
- cd "$GOPATH/src/${_gourl}"
- # FIXME lp:1611706
- env -u SUDO_COMMAND -u SUDO_GID -u SUDO_UID -u SUDO_USER ./run-checks --unit
-
- ./run-checks --static
-}
-
-package() {
- export GOPATH="$srcdir/go"
- # Ensure that we have /var/lib/snapd/{hostfs,lib/gl}/ as they are required by snap-confine
- # for constructing some bind mounts around.
- install -d -m 755 "$pkgdir/var/lib/snapd/hostfs/" "$pkgdir/var/lib/snapd/lib/gl/"
- # Install the refresh timer and service for updating snaps
- install -d -m 755 "$pkgdir/usr/lib/systemd/system/"
- install -m 644 "$GOPATH/src/${_gourl}/debian/snapd.refresh.service" "$pkgdir/usr/lib/systemd/system"
- install -m 644 "$GOPATH/src/${_gourl}/debian/snapd.refresh.timer" "$pkgdir/usr/lib/systemd/system"
- # Install the snapd socket and service for the main daemon
- install -m 644 "$GOPATH/src/${_gourl}/debian/snapd.service" "$pkgdir/usr/lib/systemd/system"
- install -m 644 "$GOPATH/src/${_gourl}/debian/snapd.socket" "$pkgdir/usr/lib/systemd/system"
- # Install legacy "frameworks" units
- # TODO: drop those when they go away upstream
- install -m 644 "$GOPATH/src/${_gourl}/debian/snapd.frameworks-pre.target" "$pkgdir/usr/lib/systemd/system"
- install -m 644 "$GOPATH/src/${_gourl}/debian/snapd.frameworks.target" "$pkgdir/usr/lib/systemd/system"
- # Install snap and snapd executables
- install -d -m 755 "$pkgdir/usr/bin/"
- install -m 755 "$GOPATH/bin/snap" "$pkgdir/usr/bin/"
- install -d -m 755 "$pkgdir/usr/lib/snapd"
- install -m 755 "$GOPATH/bin/snapd" "$pkgdir/usr/lib/snapd/"
- # Install script to export binaries paths of snaps
- install -Dm 755 "$srcdir/snapd.sh" "$pkgdir/etc/profile.d/apps-bin-path.sh"
-}
Copied: snapd/repos/community-i686/PKGBUILD (from rev 213340, snapd/trunk/PKGBUILD)
===================================================================
--- community-i686/PKGBUILD (rev 0)
+++ community-i686/PKGBUILD 2017-02-21 15:32:51 UTC (rev 213341)
@@ -0,0 +1,116 @@
+# $Id$
+# Maintainer: Timothy Redaelli <timothy.redaelli at gmail.com>
+# Contributor: Zygmunt Krynicki <me at zygoon dot pl>
+
+pkgbase=snapd
+pkgname=(snapd snap-confine)
+pkgver=2.21
+pkgrel=1
+arch=('i686' 'x86_64')
+url="https://github.com/snapcore/snapd"
+license=('GPL3')
+makedepends=('git' 'go' 'go-tools' 'bzr')
+checkdepends=('python')
+
+# snap-confine
+makedepends+=('python-docutils' 'systemd')
+checkdepends+=('indent' 'shellcheck')
+
+options=('!strip' 'emptydirs')
+install=snapd.install
+source=("git+https://github.com/snapcore/$pkgname.git#tag=$pkgver"
+ '0001-dirs-FEDORA-use-alternate-snap-mount-directory.patch'
+ '0001-debian-ARCHLINUX-use-alternate-snap-mount-directory.patch'
+ 'snapd.sh')
+md5sums=('SKIP'
+ '01f4f8f0f201eb965164a6d129869868'
+ 'a793de7726448ecc279b3ac1705e1734'
+ '1d841a1d09ba86945551dfc5c5658b2e')
+
+_gourl=github.com/snapcore/snapd
+
+prepare() {
+ cd "$pkgname"
+
+ # Use $srcdir/go as our GOPATH
+ export GOPATH="$srcdir/go"
+ mkdir -p "$GOPATH"
+ # Have snapd checkout appear in a place suitable for subsequent GOPATH This
+ # way we don't have to go get it again and it is exactly what the tag/hash
+ # above describes.
+ mkdir -p "$(dirname "$GOPATH/src/${_gourl}")"
+ ln --no-target-directory -fs "$srcdir/$pkgname" "$GOPATH/src/${_gourl}"
+
+ patch -Np1 -i "$srcdir/0001-dirs-FEDORA-use-alternate-snap-mount-directory.patch"
+ patch -Np1 -i "$srcdir/0001-debian-ARCHLINUX-use-alternate-snap-mount-directory.patch"
+
+ # https://github.com/niemeyer/gopkg/issues/50
+ mkdir -p "$srcdir/git/"
+ git config --file "$srcdir/git/config" http.https://gopkg.in.followRedirects true
+}
+
+build() {
+ export GOPATH="$srcdir/go"
+ # Use get-deps.sh provided by upstream to fetch go dependencies using the
+ # godeps tool and dependencies.tsv (maintained upstream).
+ cd "$GOPATH/src/${_gourl}"
+ XDG_CONFIG_HOME="$srcdir" ./get-deps.sh
+ # Build/install snap and snapd
+ go install "${_gourl}/cmd/snap"
+ go install "${_gourl}/cmd/snapd"
+
+ # Build snap-confine
+ ./mkversion.sh
+ cd cmd
+ autoreconf -i -f
+ ./configure \
+ --prefix=/usr \
+ --libexecdir=/usr/lib/snapd \
+ --with-snap-mount-dir=/var/lib/snapd/snap \
+ --disable-apparmor \
+ --enable-nvidia-arch \
+ --enable-merged-usr
+ make
+}
+
+# FIXME
+check() {
+ export GOPATH="$srcdir/go"
+ cd "$GOPATH/src/${_gourl}"
+#
+# ./run-checks --unit
+# ./run-checks --static
+
+ cd cmd
+ make -k check
+}
+
+package_snapd() {
+ pkgdesc="Service and tools for management of snap packages."
+ depends=('snap-confine' 'squashfs-tools')
+
+ export GOPATH="$srcdir/go"
+ # Ensure that we have /var/lib/snapd/{hostfs,lib/gl}/ as they are required by snap-confine
+ # for constructing some bind mounts around.
+ install -d -m 755 "$pkgdir/var/lib/snapd/hostfs/" "$pkgdir/var/lib/snapd/lib/gl/"
+ # Install the refresh timer and service for updating snaps
+ install -d -m 755 "$pkgdir/usr/lib/systemd/system/"
+ install -m 644 "$GOPATH/src/${_gourl}/debian/snapd.refresh.service" "$pkgdir/usr/lib/systemd/system"
+ install -m 644 "$GOPATH/src/${_gourl}/debian/snapd.refresh.timer" "$pkgdir/usr/lib/systemd/system"
+ # Install the snapd socket and service for the main daemon
+ install -m 644 "$GOPATH/src/${_gourl}/debian/snapd.service" "$pkgdir/usr/lib/systemd/system"
+ install -m 644 "$GOPATH/src/${_gourl}/debian/snapd.socket" "$pkgdir/usr/lib/systemd/system"
+ # Install snap and snapd executables
+ install -d -m 755 "$pkgdir/usr/bin/"
+ install -m 755 "$GOPATH/bin/snap" "$pkgdir/usr/bin/"
+ install -d -m 755 "$pkgdir/usr/lib/snapd"
+ install -m 755 "$GOPATH/bin/snapd" "$pkgdir/usr/lib/snapd/"
+ # Install script to export binaries paths of snaps
+ install -Dm 755 "$srcdir/snapd.sh" "$pkgdir/etc/profile.d/apps-bin-path.sh"
+}
+
+package_snap-confine() {
+ pkgdesc="Confinement system for snap applications"
+ depends=('libseccomp' 'libsystemd')
+ make -C "$srcdir/$pkgbase/cmd" install DESTDIR="$pkgdir/"
+}
Deleted: community-i686/snapd.install
===================================================================
--- community-i686/snapd.install 2017-02-21 15:32:38 UTC (rev 213340)
+++ community-i686/snapd.install 2017-02-21 15:32:51 UTC (rev 213341)
@@ -1,15 +0,0 @@
-## arg 1: the new package version
-post_install() {
- echo
- echo 'To use snapd start/enable the snapd.socket'
- echo
- echo 'If you want your apps to be automatically updated'
- echo 'from the store start/enable the snapd.refresh.timer'
- echo
- echo 'NOTE: Desktop entries show up after logging in again'
- echo ' or rebooting after snapd installation'
- echo
- echo 'For more informations, see https://wiki.archlinux.org/index.php/Snapd'
-}
-
-# vim:set ts=2 sw=2 et:
Copied: snapd/repos/community-i686/snapd.install (from rev 213340, snapd/trunk/snapd.install)
===================================================================
--- community-i686/snapd.install (rev 0)
+++ community-i686/snapd.install 2017-02-21 15:32:51 UTC (rev 213341)
@@ -0,0 +1,15 @@
+## arg 1: the new package version
+post_install() {
+ echo
+ echo 'To use snapd start/enable the snapd.socket'
+ echo
+ echo 'If you want your apps to be automatically updated'
+ echo 'from the store start/enable the snapd.refresh.timer'
+ echo
+ echo 'NOTE: Desktop entries show up after logging in again'
+ echo ' or rebooting after snapd installation'
+ echo
+ echo 'For more informations, see https://wiki.archlinux.org/index.php/Snapd'
+}
+
+# vim:set ts=2 sw=2 et:
Deleted: community-i686/snapd.sh
===================================================================
--- community-i686/snapd.sh 2017-02-21 15:32:38 UTC (rev 213340)
+++ community-i686/snapd.sh 2017-02-21 15:32:51 UTC (rev 213341)
@@ -1,10 +0,0 @@
-# Expand the $PATH to include /snaps/bin which is what snappy applications
-# use
-PATH=$PATH:/snap/bin
-
-if [ -z "$XDG_DATA_DIRS" ]; then
- XDG_DATA_DIRS=/usr/local/share/:/usr/share/:/var/lib/snapd/desktop
-else
- XDG_DATA_DIRS="$XDG_DATA_DIRS":/var/lib/snapd/desktop
-fi
-export XDG_DATA_DIRS
Copied: snapd/repos/community-i686/snapd.sh (from rev 213340, snapd/trunk/snapd.sh)
===================================================================
--- community-i686/snapd.sh (rev 0)
+++ community-i686/snapd.sh 2017-02-21 15:32:51 UTC (rev 213341)
@@ -0,0 +1,10 @@
+# Expand the $PATH to include /snaps/bin which is what snappy applications
+# use
+PATH=$PATH:/snap/bin
+
+if [ -z "$XDG_DATA_DIRS" ]; then
+ XDG_DATA_DIRS=/usr/local/share/:/usr/share/:/var/lib/snapd/desktop
+else
+ XDG_DATA_DIRS="$XDG_DATA_DIRS":/var/lib/snapd/desktop
+fi
+export XDG_DATA_DIRS
Copied: snapd/repos/community-x86_64/0001-debian-ARCHLINUX-use-alternate-snap-mount-directory.patch (from rev 213340, snapd/trunk/0001-debian-ARCHLINUX-use-alternate-snap-mount-directory.patch)
===================================================================
--- community-x86_64/0001-debian-ARCHLINUX-use-alternate-snap-mount-directory.patch (rev 0)
+++ community-x86_64/0001-debian-ARCHLINUX-use-alternate-snap-mount-directory.patch 2017-02-21 15:32:51 UTC (rev 213341)
@@ -0,0 +1,26 @@
+From 529c77918eab0742e645db3d97b62b55e9f6888a Mon Sep 17 00:00:00 2001
+From: Timothy Redaelli <tredaelli at archlinux.info>
+Date: Tue, 21 Feb 2017 11:38:00 +0000
+Subject: [PATCH] debian: ARCHLINUX: use alternate snap mount directory
+
+Signed-off-by: Timothy Redaelli <tredaelli at archlinux.info>
+---
+ debian/snapd.refresh.service | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/debian/snapd.refresh.service b/debian/snapd.refresh.service
+index 4c3375786..dda02de0e 100644
+--- a/debian/snapd.refresh.service
++++ b/debian/snapd.refresh.service
+@@ -2,7 +2,7 @@
+ Description=Automatically refresh installed snaps
+ After=network-online.target snapd.socket
+ Requires=snapd.socket
+-ConditionPathExistsGlob=/snap/*/current
++ConditionPathExistsGlob=/var/lib/snapd/snap/*/current
+ Documentation=man:snap(1)
+
+ [Service]
+--
+2.11.1
+
Copied: snapd/repos/community-x86_64/0001-dirs-FEDORA-use-alternate-snap-mount-directory.patch (from rev 213340, snapd/trunk/0001-dirs-FEDORA-use-alternate-snap-mount-directory.patch)
===================================================================
--- community-x86_64/0001-dirs-FEDORA-use-alternate-snap-mount-directory.patch (rev 0)
+++ community-x86_64/0001-dirs-FEDORA-use-alternate-snap-mount-directory.patch 2017-02-21 15:32:51 UTC (rev 213341)
@@ -0,0 +1,26 @@
+From 6738583e77ca2f52760be8887c9aefebe8e89b3b Mon Sep 17 00:00:00 2001
+From: Zygmunt Krynicki <me at zygoon.pl>
+Date: Thu, 20 Oct 2016 10:14:21 +0200
+Subject: [PATCH] dirs: FEDORA: use alternate snap mount directory
+
+Signed-off-by: Zygmunt Krynicki <me at zygoon.pl>
+---
+ dirs/dirs.go | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/dirs/dirs.go b/dirs/dirs.go
+index 36e3b54..315df32 100644
+--- a/dirs/dirs.go
++++ b/dirs/dirs.go
+@@ -103,7 +103,7 @@ func SetRootDir(rootdir string) {
+ }
+ GlobalRootDir = rootdir
+
+- SnapMountDir = filepath.Join(rootdir, "/snap")
++ SnapMountDir = filepath.Join(rootdir, "/var/lib/snapd/snap")
+ SnapDataDir = filepath.Join(rootdir, "/var/snap")
+ SnapDataHomeGlob = filepath.Join(rootdir, "/home/*/snap/")
+ SnapAppArmorDir = filepath.Join(rootdir, snappyDir, "apparmor", "profiles")
+--
+2.7.4
+
Deleted: community-x86_64/PKGBUILD
===================================================================
--- community-x86_64/PKGBUILD 2017-02-21 15:32:38 UTC (rev 213340)
+++ community-x86_64/PKGBUILD 2017-02-21 15:32:51 UTC (rev 213341)
@@ -1,80 +0,0 @@
-# $Id$
-# Maintainer: Timothy Redaelli <timothy.redaelli at gmail.com>
-# Contributor: Zygmunt Krynicki <me at zygoon dot pl>
-
-pkgname=snapd
-pkgver=2.16
-pkgrel=1
-pkgdesc="Service and tools for management of snap packages."
-arch=('i686' 'x86_64')
-url="https://github.com/snapcore/snapd"
-license=('GPL3')
-depends=('snap-confine' 'squashfs-tools')
-makedepends=('git' 'go' 'go-tools' 'bzr')
-checkdepends=('python')
-options=('!strip' 'emptydirs')
-install=snapd.install
-source=("git+https://github.com/snapcore/$pkgname.git#tag=$pkgver"
- 'snapd.sh')
-md5sums=('SKIP'
- '1d841a1d09ba86945551dfc5c5658b2e')
-
-_gourl=github.com/snapcore/snapd
-
-prepare() {
- cd "$pkgname"
-
- # Use $srcdir/go as our GOPATH
- export GOPATH="$srcdir/go"
- mkdir -p "$GOPATH"
- # Have snapd checkout appear in a place suitable for subsequent GOPATH This
- # way we don't have to go get it again and it is exactly what the tag/hash
- # above describes.
- mkdir -p "$(dirname "$GOPATH/src/${_gourl}")"
- ln --no-target-directory -fs "$srcdir/$pkgname" "$GOPATH/src/${_gourl}"
-}
-
-build() {
- export GOPATH="$srcdir/go"
- # Use get-deps.sh provided by upstream to fetch go dependencies using the
- # godeps tool and dependencies.tsv (maintained upstream).
- cd "$GOPATH/src/${_gourl}"
- ./get-deps.sh
- # Build/install snap and snapd
- go install "${_gourl}/cmd/snap"
- go install "${_gourl}/cmd/snapd"
-}
-
-check() {
- export GOPATH="$srcdir/go"
- cd "$GOPATH/src/${_gourl}"
- # FIXME lp:1611706
- env -u SUDO_COMMAND -u SUDO_GID -u SUDO_UID -u SUDO_USER ./run-checks --unit
-
- ./run-checks --static
-}
-
-package() {
- export GOPATH="$srcdir/go"
- # Ensure that we have /var/lib/snapd/{hostfs,lib/gl}/ as they are required by snap-confine
- # for constructing some bind mounts around.
- install -d -m 755 "$pkgdir/var/lib/snapd/hostfs/" "$pkgdir/var/lib/snapd/lib/gl/"
- # Install the refresh timer and service for updating snaps
- install -d -m 755 "$pkgdir/usr/lib/systemd/system/"
- install -m 644 "$GOPATH/src/${_gourl}/debian/snapd.refresh.service" "$pkgdir/usr/lib/systemd/system"
- install -m 644 "$GOPATH/src/${_gourl}/debian/snapd.refresh.timer" "$pkgdir/usr/lib/systemd/system"
- # Install the snapd socket and service for the main daemon
- install -m 644 "$GOPATH/src/${_gourl}/debian/snapd.service" "$pkgdir/usr/lib/systemd/system"
- install -m 644 "$GOPATH/src/${_gourl}/debian/snapd.socket" "$pkgdir/usr/lib/systemd/system"
- # Install legacy "frameworks" units
- # TODO: drop those when they go away upstream
- install -m 644 "$GOPATH/src/${_gourl}/debian/snapd.frameworks-pre.target" "$pkgdir/usr/lib/systemd/system"
- install -m 644 "$GOPATH/src/${_gourl}/debian/snapd.frameworks.target" "$pkgdir/usr/lib/systemd/system"
- # Install snap and snapd executables
- install -d -m 755 "$pkgdir/usr/bin/"
- install -m 755 "$GOPATH/bin/snap" "$pkgdir/usr/bin/"
- install -d -m 755 "$pkgdir/usr/lib/snapd"
- install -m 755 "$GOPATH/bin/snapd" "$pkgdir/usr/lib/snapd/"
- # Install script to export binaries paths of snaps
- install -Dm 755 "$srcdir/snapd.sh" "$pkgdir/etc/profile.d/apps-bin-path.sh"
-}
Copied: snapd/repos/community-x86_64/PKGBUILD (from rev 213340, snapd/trunk/PKGBUILD)
===================================================================
--- community-x86_64/PKGBUILD (rev 0)
+++ community-x86_64/PKGBUILD 2017-02-21 15:32:51 UTC (rev 213341)
@@ -0,0 +1,116 @@
+# $Id$
+# Maintainer: Timothy Redaelli <timothy.redaelli at gmail.com>
+# Contributor: Zygmunt Krynicki <me at zygoon dot pl>
+
+pkgbase=snapd
+pkgname=(snapd snap-confine)
+pkgver=2.21
+pkgrel=1
+arch=('i686' 'x86_64')
+url="https://github.com/snapcore/snapd"
+license=('GPL3')
+makedepends=('git' 'go' 'go-tools' 'bzr')
+checkdepends=('python')
+
+# snap-confine
+makedepends+=('python-docutils' 'systemd')
+checkdepends+=('indent' 'shellcheck')
+
+options=('!strip' 'emptydirs')
+install=snapd.install
+source=("git+https://github.com/snapcore/$pkgname.git#tag=$pkgver"
+ '0001-dirs-FEDORA-use-alternate-snap-mount-directory.patch'
+ '0001-debian-ARCHLINUX-use-alternate-snap-mount-directory.patch'
+ 'snapd.sh')
+md5sums=('SKIP'
+ '01f4f8f0f201eb965164a6d129869868'
+ 'a793de7726448ecc279b3ac1705e1734'
+ '1d841a1d09ba86945551dfc5c5658b2e')
+
+_gourl=github.com/snapcore/snapd
+
+prepare() {
+ cd "$pkgname"
+
+ # Use $srcdir/go as our GOPATH
+ export GOPATH="$srcdir/go"
+ mkdir -p "$GOPATH"
+ # Have snapd checkout appear in a place suitable for subsequent GOPATH This
+ # way we don't have to go get it again and it is exactly what the tag/hash
+ # above describes.
+ mkdir -p "$(dirname "$GOPATH/src/${_gourl}")"
+ ln --no-target-directory -fs "$srcdir/$pkgname" "$GOPATH/src/${_gourl}"
+
+ patch -Np1 -i "$srcdir/0001-dirs-FEDORA-use-alternate-snap-mount-directory.patch"
+ patch -Np1 -i "$srcdir/0001-debian-ARCHLINUX-use-alternate-snap-mount-directory.patch"
+
+ # https://github.com/niemeyer/gopkg/issues/50
+ mkdir -p "$srcdir/git/"
+ git config --file "$srcdir/git/config" http.https://gopkg.in.followRedirects true
+}
+
+build() {
+ export GOPATH="$srcdir/go"
+ # Use get-deps.sh provided by upstream to fetch go dependencies using the
+ # godeps tool and dependencies.tsv (maintained upstream).
+ cd "$GOPATH/src/${_gourl}"
+ XDG_CONFIG_HOME="$srcdir" ./get-deps.sh
+ # Build/install snap and snapd
+ go install "${_gourl}/cmd/snap"
+ go install "${_gourl}/cmd/snapd"
+
+ # Build snap-confine
+ ./mkversion.sh
+ cd cmd
+ autoreconf -i -f
+ ./configure \
+ --prefix=/usr \
+ --libexecdir=/usr/lib/snapd \
+ --with-snap-mount-dir=/var/lib/snapd/snap \
+ --disable-apparmor \
+ --enable-nvidia-arch \
+ --enable-merged-usr
+ make
+}
+
+# FIXME
+check() {
+ export GOPATH="$srcdir/go"
+ cd "$GOPATH/src/${_gourl}"
+#
+# ./run-checks --unit
+# ./run-checks --static
+
+ cd cmd
+ make -k check
+}
+
+package_snapd() {
+ pkgdesc="Service and tools for management of snap packages."
+ depends=('snap-confine' 'squashfs-tools')
+
+ export GOPATH="$srcdir/go"
+ # Ensure that we have /var/lib/snapd/{hostfs,lib/gl}/ as they are required by snap-confine
+ # for constructing some bind mounts around.
+ install -d -m 755 "$pkgdir/var/lib/snapd/hostfs/" "$pkgdir/var/lib/snapd/lib/gl/"
+ # Install the refresh timer and service for updating snaps
+ install -d -m 755 "$pkgdir/usr/lib/systemd/system/"
+ install -m 644 "$GOPATH/src/${_gourl}/debian/snapd.refresh.service" "$pkgdir/usr/lib/systemd/system"
+ install -m 644 "$GOPATH/src/${_gourl}/debian/snapd.refresh.timer" "$pkgdir/usr/lib/systemd/system"
+ # Install the snapd socket and service for the main daemon
+ install -m 644 "$GOPATH/src/${_gourl}/debian/snapd.service" "$pkgdir/usr/lib/systemd/system"
+ install -m 644 "$GOPATH/src/${_gourl}/debian/snapd.socket" "$pkgdir/usr/lib/systemd/system"
+ # Install snap and snapd executables
+ install -d -m 755 "$pkgdir/usr/bin/"
+ install -m 755 "$GOPATH/bin/snap" "$pkgdir/usr/bin/"
+ install -d -m 755 "$pkgdir/usr/lib/snapd"
+ install -m 755 "$GOPATH/bin/snapd" "$pkgdir/usr/lib/snapd/"
+ # Install script to export binaries paths of snaps
+ install -Dm 755 "$srcdir/snapd.sh" "$pkgdir/etc/profile.d/apps-bin-path.sh"
+}
+
+package_snap-confine() {
+ pkgdesc="Confinement system for snap applications"
+ depends=('libseccomp' 'libsystemd')
+ make -C "$srcdir/$pkgbase/cmd" install DESTDIR="$pkgdir/"
+}
Deleted: community-x86_64/snapd.install
===================================================================
--- community-x86_64/snapd.install 2017-02-21 15:32:38 UTC (rev 213340)
+++ community-x86_64/snapd.install 2017-02-21 15:32:51 UTC (rev 213341)
@@ -1,15 +0,0 @@
-## arg 1: the new package version
-post_install() {
- echo
- echo 'To use snapd start/enable the snapd.socket'
- echo
- echo 'If you want your apps to be automatically updated'
- echo 'from the store start/enable the snapd.refresh.timer'
- echo
- echo 'NOTE: Desktop entries show up after logging in again'
- echo ' or rebooting after snapd installation'
- echo
- echo 'For more informations, see https://wiki.archlinux.org/index.php/Snapd'
-}
-
-# vim:set ts=2 sw=2 et:
Copied: snapd/repos/community-x86_64/snapd.install (from rev 213340, snapd/trunk/snapd.install)
===================================================================
--- community-x86_64/snapd.install (rev 0)
+++ community-x86_64/snapd.install 2017-02-21 15:32:51 UTC (rev 213341)
@@ -0,0 +1,15 @@
+## arg 1: the new package version
+post_install() {
+ echo
+ echo 'To use snapd start/enable the snapd.socket'
+ echo
+ echo 'If you want your apps to be automatically updated'
+ echo 'from the store start/enable the snapd.refresh.timer'
+ echo
+ echo 'NOTE: Desktop entries show up after logging in again'
+ echo ' or rebooting after snapd installation'
+ echo
+ echo 'For more informations, see https://wiki.archlinux.org/index.php/Snapd'
+}
+
+# vim:set ts=2 sw=2 et:
Deleted: community-x86_64/snapd.sh
===================================================================
--- community-x86_64/snapd.sh 2017-02-21 15:32:38 UTC (rev 213340)
+++ community-x86_64/snapd.sh 2017-02-21 15:32:51 UTC (rev 213341)
@@ -1,10 +0,0 @@
-# Expand the $PATH to include /snaps/bin which is what snappy applications
-# use
-PATH=$PATH:/snap/bin
-
-if [ -z "$XDG_DATA_DIRS" ]; then
- XDG_DATA_DIRS=/usr/local/share/:/usr/share/:/var/lib/snapd/desktop
-else
- XDG_DATA_DIRS="$XDG_DATA_DIRS":/var/lib/snapd/desktop
-fi
-export XDG_DATA_DIRS
Copied: snapd/repos/community-x86_64/snapd.sh (from rev 213340, snapd/trunk/snapd.sh)
===================================================================
--- community-x86_64/snapd.sh (rev 0)
+++ community-x86_64/snapd.sh 2017-02-21 15:32:51 UTC (rev 213341)
@@ -0,0 +1,10 @@
+# Expand the $PATH to include /snaps/bin which is what snappy applications
+# use
+PATH=$PATH:/snap/bin
+
+if [ -z "$XDG_DATA_DIRS" ]; then
+ XDG_DATA_DIRS=/usr/local/share/:/usr/share/:/var/lib/snapd/desktop
+else
+ XDG_DATA_DIRS="$XDG_DATA_DIRS":/var/lib/snapd/desktop
+fi
+export XDG_DATA_DIRS
More information about the arch-commits
mailing list