updated on Thu Jan 26 16:09:46 UTC 2012
[aur-mirror.git] / idevicerestore-git / PKGBUILD
blob8394401257174bda341bbad042497eb6776885bd
1 # Contributor: Matthew Bauer <mjbauer95@gmail.com>
2 _pkgname=idevicerestore
3 pkgname=$_pkgname-git
4 pkgver=20100621
5 pkgrel=1
6 pkgdesc="Restores firmware and filesystem to iPhone/iPod Touch"
7 arch=('i686' 'x86_64')
8 url="http://github.com/posixninja/$_pkgname"
9 license=('custom')
10 groups=()
11 depends=('usbmuxd' 'libirecovery' 'libimobiledevice>=1.1.0')
12 makedepends=('git')
13 provides=("$_pkgname")
14 conflicts=("$_pkgname")
15 replaces=("$_pkgname")
16 backup=()
17 options=()
18 install=
19 source=()
20 noextract=()
21 md5sums=() #generate with 'makepkg -g'
23 _gitroot="git://github.com/posixninja/$_pkgname.git"
24 _gitname="$_pkgname"
26 build() {
27         cd "$srcdir"
28         msg "Connecting to GIT server...."
30         if [ -d $_gitname ] ; then
31                 cd $_gitname && git pull origin
32                 msg "The local files are updated."
33         else
34                 git clone $_gitroot $_gitname
35         fi
37         msg "GIT checkout done or server timeout"
38         msg "Starting make..."
40         rm -rf "$srcdir/$_gitname-build"
41         git clone "$srcdir/$_gitname" "$srcdir/$_gitname-build"
42         cd "$srcdir/$_gitname-build"
44         #sed -i -e 's/\/usr\/local\//\/usr\//g' src/Makefile.am
45         ./autogen.sh --prefix=/usr
46         ./configure --prefix=/usr
47         make libirecovery_CFLAGS="-I/usr/include" libirecovery_LIBS="-L/usr/lib -lirecovery -lusb-1.0" || return 1
48         make DESTDIR=$pkgdir install || return 1