forked from ilius/starcal
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathinstall-archlinux
executable file
·69 lines (55 loc) · 1.71 KB
/
install-archlinux
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
#!/bin/bash
## makes PKGUILD and builds it (without root access), then installs it (prompts for password if necessary)
set -e
initPwd=$PWD
myPath="$0"
if [ "${myPath:0:2}" == "./" ] ; then
myPath=$initPwd${myPath:1}
elif [ "${myPath:0:1}" != "/" ] ; then
myPath=$initPwd/$myPath
fi
pkgName=starcal3
sourceDir="`dirname \"$myPath\"`"
#"$sourceDir/scripts/assert_python3"
version=`"$sourceDir/scal3/get_version.py" | sed 's/\-/_/g'`
tmpDir="$HOME/.${pkgName}/tmp/install-arch"
mkdir -p $tmpDir
cd $tmpDir
depends=('python>=3.2')
depends+=('python-gobject') ## The new gobject introspection
depends+=('python-cairo')
depends+=('python-httplib2')
depends+=('python-psutil')
depends+=('python-dateutil')
depends+=('python-pymongo')
#depends+=('python-gflags') # for google api client
optdepends=()
optdepends+=('libappindicator-gtk3')
optdepends+=('python-dateutil')
optdepends+=('python-igraph')
#optdepends+=('python-gnomevfs')
depends_str=$(printf " '%s'" "${depends[@]}") ; depends_str=${depends_str:1}
optdepends_str=$(printf " '%s'" "${optdepends[@]}") ; optdepends_str=${optdepends_str:1}
echo "# Contributor: Saeed Rasooli <[email protected]>
# This is a local PKGBUILD
sourceDir='$sourceDir'
pkgname=$pkgName
pkgver=$version
pkgrel=1
pkgdesc='A full-featured international calendar written in Python'
arch=('any')
url=http://ilius.github.io/starcal
license=('GPLv3')
depends=($depends_str)
optdepends=($optdepends_str)
makedepends=()
conflicts=('starcal-git')
source=()
md5sums=()
package() {
\"\$sourceDir/install\" \"\$pkgdir\" --for-pkg
}" > PKGBUILD
makepkg -sif
cp $pkgName*.pkg.tar* "$initPwd" || sudo cp $pkgName*.pkg.tar* "$initPwd" && echo "Package installed and copied into $initPwd directory"
cd "$initPwd"
rm -Rf $tmpDir