summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authoraksr2016-04-24 11:54:40 +0200
committeraksr2016-04-24 11:54:40 +0200
commit9fe112b293553c23ed85f39848049cef07d27ee5 (patch)
tree769bbe72fb32b347129b32cfa27373949f3c1586
parent446d63f978935100b2b8a77ad0c162204549d3e5 (diff)
downloadaur-9fe112b293553c23ed85f39848049cef07d27ee5.tar.gz
A few changes...
-rw-r--r--.SRCINFO16
-rw-r--r--PKGBUILD82
-rw-r--r--acme.desktop11
-rw-r--r--acme.pngbin0 -> 13793 bytes
-rw-r--r--acme.sh3
-rw-r--r--plan9.install4
6 files changed, 80 insertions, 36 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 1fbde831da3..488910aad5a 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,6 +1,8 @@
+# Generated by mksrcinfo v8
+# Sun Apr 24 09:54:05 UTC 2016
pkgbase = plan9port-git
- pkgdesc = port of many Plan 9 programs to Unix-like operating systems
- pkgver = 5d86ecd
+ pkgdesc = A port of many Plan 9 libraries and programs to Unix.
+ pkgver = r3479.35d4392
pkgrel = 1
url = http://swtch.com/plan9port/
install = plan9.install
@@ -13,15 +15,21 @@ pkgbase = plan9port-git
depends = libxext
depends = fuse
optdepends = python2: for the codereview script
- provides = plan9
+ provides = plan9port
conflicts = 9base
conflicts = plan9port
options = !zipman
options = staticlibs
- source = git+https://github.com/9fans/plan9port
+ source = plan9port-git::git+https://github.com/9fans/plan9port
source = plan9.sh
+ source = acme.sh
+ source = acme.png
+ source = acme.desktop
md5sums = SKIP
md5sums = c884c3c90a107f1a178718c304c67d30
+ md5sums = 0a3d8aaabd7cac1b8189a5551515d63f
+ md5sums = 266d160d71a2b4f1ec9859b5232c36da
+ md5sums = 682e9acb44074a4b49b3c2552d6a0a39
pkgname = plan9port-git
diff --git a/PKGBUILD b/PKGBUILD
index 0a39e21be36..01bff8547a3 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,12 +2,12 @@
# Contributor: Calvin McAnarney <csm@gmx.us>
# Contributor: Julien Pecqueur <jpec@julienpecqueur.com>
# Contributor: Sergiusz Urbaniak <sergiusz.urbaniak@gmail.com>
-
pkgname=plan9port-git
-pkgver=5d86ecd
+pkgver=r3479.35d4392
pkgrel=1
-pkgdesc="port of many Plan 9 programs to Unix-like operating systems"
+pkgdesc="A port of many Plan 9 libraries and programs to Unix."
arch=('i686' 'x86_64')
+url="https://github.com/9fans/plan9port"
url="http://swtch.com/plan9port/"
license=('custom')
depends=('xorg-server' 'libxt' 'libxext' 'fuse')
@@ -17,39 +17,53 @@ provides=('plan9port')
install='plan9.install'
conflicts=('9base' 'plan9port')
options=('!zipman' 'staticlibs')
-source=('git+https://github.com/9fans/plan9port'
- 'plan9.sh')
+source=("$pkgname::git+https://github.com/9fans/plan9port"
+ plan9.sh acme.sh acme.png acme.desktop)
md5sums=('SKIP'
- 'c884c3c90a107f1a178718c304c67d30')
+ 'c884c3c90a107f1a178718c304c67d30'
+ '0a3d8aaabd7cac1b8189a5551515d63f'
+ '266d160d71a2b4f1ec9859b5232c36da'
+ '682e9acb44074a4b49b3c2552d6a0a39')
+
+pkgver() {
+ cd "$srcdir/$pkgname"
+ printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
+}
+
+prepare() {
+ cd "$srcdir/"
+ # Generate a desktop shortcut for the Acme editor
+ gendesk -f \
+ --pkgname acme \
+ --name Acme \
+ --genericname Editor \
+ --comment 'Editor from Plan9' \
+ --categories 'Application;Development;TextEditor'
+
+ # Use _DEFAULT_SOURCE instead of _BSD_SOURCE
+ grep -rl _BSD_SOURCE "$pkgname" | xargs sed -i s':_BSD_SOURCE:_DEFAULT_SOURCE:g'
+}
package() {
- cd "$srcdir/plan9port"
+ cd "$srcdir/$pkgname"
# Try the gentoo way for fixing hardcoded paths
PLAN9=/usr/lib/plan9
- grep --null -l -r '/usr/local/plan9' | xargs --null sed -i "s!/usr/local/plan9!${PLAN9}!g"
-
- d=usr/lib
+ grep --null -l -r '/usr/local/plan9' | xargs --null sed -i "s!/usr/local/plan9!/usr/lib/plan9!g"
./INSTALL -b
- install -Dm755 ../../plan9.sh "$pkgdir/etc/profile.d/plan9.sh"
- install -d "$pkgdir/$d"
- install -d "$pkgdir/usr/share/doc/$pkgname"
- cp -r "$srcdir/plan9port" "$pkgdir/$d/plan9"
- cd "$pkgdir/$d/plan9"
- ./INSTALL -c -r "$pkgdir/$d/plan9"
- install -Dm644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
+ install -Dm755 ../plan9.sh "$pkgdir/etc/profile.d/plan9.sh"
- # Clean up
- rm -rf .git/
- rm -f .gitignore
- rm -f config install.log install.sum install.txt configure Makefile INSTALL \
- LICENSE
+ mkdir -p $pkgdir/usr/{lib,share/doc/$pkgname}
+
+ cp -r "$srcdir/$pkgname" "$pkgdir/usr/lib/plan9"
+ cd "$pkgdir/usr/lib/plan9"
+ ./INSTALL -c -r "$pkgdir/usr/lib/plan9"
+ install -Dm644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
# Fix python scripts
- find "$pkgdir" -name '*.py' -print0 |xargs -0 \
- sed -i -e 's,^#!/usr/bin/env python$,#!/usr/bin/python2,' \
- -e 's,^#!/usr/bin/python$,#!/usr/bin/python2,'
+ find "$pkgdir" -name '*.py' -print0 | xargs -0 \
+ sed -i -e 's@^#!/usr/bin/env python$@#!/usr/bin/python2@' -e 's@^#!/usr/bin/python$@#!/usr/bin/python2@'
# Package text files
for i in CHANGES CONTRIBUTORS README.md TODO; do
@@ -58,14 +72,24 @@ package() {
done
# Decompress the plan9 man pages
- for i in `find $pkgdir/$d/plan9/man -type f`; do
+ for i in $(find $pkgdir/usr/lib/plan9/man -type f); do
if [ ${i##*.} = "gz" ]; then
gunzip "$i"
fi
done
- # Once more
- grep --null -l -r "$pkgdir$PLAN9" | xargs --null sed -i "s!$pkgdir$PLAN9!${PLAN9}!g" || true
- grep --null -l -r "/build/plan9port/pkg/plan9port/$PLAN9" | xargs --null sed -i "s!/build/plan9port/pkg/plan9port/$PLAN9!${PLAN9}!g" || true
+ grep --null -l -r "$pkgdir/usr/lib/plan9" | xargs --null sed -i "s@$pkgdir/usr/lib/plan9@/usr/lib/plan9@g" || true
+ grep --null -l -r "/build/plan9port/pkg/$pkgname/usr/lib/plan9" | xargs --null \
+ sed -i "s!/build/plan9port/pkg/$pkgname/usr/lib/plan9!/usr/lib/plan9!g" || true
+
+ cd "$srcdir/"
+ install -Dm755 acme.sh $pkgdir/usr/bin/acme
+ install -Dm644 acme.png $pkgdir/usr/share/pixmaps/acme.png
+ install -Dm644 acme.desktop $pkgdir/usr/share/applications/acme.desktop
+
+ # Clean up
+ cd "$pkgdir/usr/lib/plan9"
+ rm -rf .git .gitignore config install.log install.sum configure Makefile INSTALL LICENSE
+ find . -name '.cvsignore' -print0 | xargs -0 rm -f
}
diff --git a/acme.desktop b/acme.desktop
new file mode 100644
index 00000000000..6d132d89434
--- /dev/null
+++ b/acme.desktop
@@ -0,0 +1,11 @@
+[Desktop Entry]
+Encoding=UTF-8
+Type=Application
+Name=Acme
+GenericName=Editor
+Comment=Editor from Plan9
+Exec=acme
+Icon=acme
+Terminal=false
+StartupNotify=false
+Categories=Application;Development;TextEditor;
diff --git a/acme.png b/acme.png
new file mode 100644
index 00000000000..b46ae33d99b
--- /dev/null
+++ b/acme.png
Binary files differ
diff --git a/acme.sh b/acme.sh
new file mode 100644
index 00000000000..f3f8dd989d8
--- /dev/null
+++ b/acme.sh
@@ -0,0 +1,3 @@
+#!/bin/sh
+. /etc/profile.d/plan9.sh
+9 acme "$@"
diff --git a/plan9.install b/plan9.install
index 1d361127ffe..3ec4ed18ea9 100644
--- a/plan9.install
+++ b/plan9.install
@@ -1,7 +1,5 @@
post_install() {
- echo ""
- echo "==> In order to use Plan9 specific apps, run them"
- echo " as arguments to the '9' script, i.e. '9 date'"
+ echo "==> In order to use Plan9 specific apps, run them as arguments to the '9' script, i.e. '9 date'"
echo "==> Please log off or 'source /etc/profile.d/plan9.sh'"
echo "==> Run '9 man 1 intro | less' to begin"
source /etc/profile.d/plan9.sh