1 #Contributor: Markus M. May <mmay AT javafreedom DOT org>
5 pkgdesc="A Maven Repository Manager."
6 url="http://nexus.sonatype.org"
9 depends=('java-environment')
10 optdepends=('apache: a full featured webserver'
11 'maven: a java project management and project comprehension tool')
13 install=java-nexus.install
14 conflicts=('java-nexus')
15 provides=('java-nexus')
16 options=(!strip !docs)
18 source=(http://nexus.sonatype.org/downloads/nexus-webapp-${pkgver}-bundle.tar.gz
24 md5sums=('47070ee947f3cc320bf33e485484f16a'
25 '419a6f2a6ce5a87114ccbb7623cd1fa3'
26 '64ce2ce85d4e6152ef64eafbc37c9f69'
27 '0731f813a4c565210fbc16b1b235ef63'
28 '42b7b1a097f05e1dd7a19d85d6ad346f')
34 # Create directory and copy everything
35 install -d $pkgdir/opt/nexus
37 # deleting unnecessary files before copying them
38 if [ $CARCH = 'x86_64' ]; then
39 mv $srcdir/nexus-webapp-${pkgver}/bin/jsw/linux-x86-64 $srcdir/nexus-bin || return 1
40 rm -r $srcdir/nexus-webapp-${pkgver}/bin || return 1
41 mv $srcdir/nexus-bin $srcdir/nexus-webapp-${pkgver}/bin || return 1
42 elif [ $CARCH} = 'i686' ]; then
43 mv $srcdir/nexus-webapp-${pkgver}/bin/jsw/linux-x86-32 $srcdir/nexus-bin || return 1
44 rm -r $srcdir/nexus-webapp-${pkgver}/bin || return 1
45 mv $srcdir/nexus-bin $srcdir/nexus-webapp-${pkgver}/bin || return 1
48 # copy the source to the final directory
49 cp -a $srcdir/nexus-webapp-${pkgver}/* $pkgdir/opt/nexus || return 1
51 # install the additional config files to the desired destination
52 install $srcdir/nexus $pkgdir/opt/nexus/bin || return 1
54 # generating /etc/nexus and put all needed contents in
55 mkdir -p $pkgdir/etc/nexus || return 1
56 install $srcdir/wrapper.conf $pkgdir/etc/nexus || return 1
57 install $srcdir/plexus.properties $pkgdir/etc/nexus || return 1
58 install $srcdir/classworlds.conf $pkgdir/etc/nexus || return 1
59 install $srcdir/nexus-webapp-${pkgver}/conf/plexus.xml $pkgdir/etc/nexus || return 1
60 mv $srcdir/nexus-webapp-${pkgver}/conf/examples $pkgdir/etc/nexus || return 1
61 rm -r $pkgdir/opt/nexus/conf
63 # generating /var/lib/nexus and put all needed contents in
64 mkdir -p $pkgdir/var/lib/nexus || return 1
65 mv $srcdir/nexus-webapp-${pkgver}/runtime $pkgdir/var/lib/nexus/runtime || return 1
67 mkdir -p $pkgdir/etc/rc.d || return 1
68 install $srcdir/nexus $pkgdir/opt/nexus/bin || return 1
69 ln -s $pkgdir/opt/nexus/bin/nexus $pkgdir/etc/rc.d/nexus || return 1
71 mkdir -p $pkgdir/var/log/nexus/
72 touch $pkgdir/var/log/nexus/wrapper.log