1 # Contributor: Mathias Buren <mathias.buren@gmail.com>
5 pkgdesc="A tool for managing/monitoring Linux md device arrays, also known as Software RAID. -git version"
8 url="http://neil.brown.name/blog/mdadm/"
9 conflicts=('mkinitcpio<0.5.99' 'mdadm')
12 backup=('etc/mdadm.conf')
18 replaces=('raidtools')
20 _gitroot="git://neil.brown.name/mdadm"
25 msg "Connecting to GIT server...."
27 if [ -d $_gitname ] ; then
28 cd $_gitname && git pull origin
29 msg "The local files are updated."
31 git clone $_gitroot $_gitname --depth=1
34 msg "GIT checkout done or server timeout"
35 msg "Starting make..."
37 rm -rf "$srcdir/$_gitname-build"
38 git clone "$srcdir/$_gitname" "$srcdir/$_gitname-build"
39 cd "$srcdir/$_gitname-build"
46 # build static mdassemble for Arch's initramfs
47 make MDASSEMBLE_AUTO=1 mdassemble
52 cd "$srcdir/$_gitname-build"
53 make INSTALL=/bin/install DESTDIR=$pkgdir install
54 install -D -m644 $srcdir/mdadm.conf $pkgdir/etc/mdadm.conf
55 install -D -m755 $srcdir/mdadm-git $pkgdir/etc/rc.d/mdadm
56 install -D -m644 $srcdir/mdadm_install $pkgdir/lib/initcpio/install/mdadm
57 install -D -m644 $srcdir/mdadm_hook $pkgdir/lib/initcpio/hooks/mdadm
58 # symlink for backward compatibility
59 ln -sf /lib/initcpio/hooks/mdadm $pkgdir/lib/initcpio/hooks/raid
60 install -D -m755 mdassemble $pkgdir/sbin/mdassemble
62 md5sums=('6df172c8f77b280018cf87eb3d313f29'
63 '00cbed931db4f15b6ce49e3e7d433966'
64 '865c3d39e5f5dae58388160b563981f1'
65 '1a3eb63832cecd6550f5b0a21d58cfdb')