diff options
author | Martin Jesper Low Madsen | 2016-02-11 18:32:09 +0100 |
---|---|---|
committer | Martin Jesper Low Madsen | 2016-02-11 18:36:11 +0100 |
commit | e9535a6828c53683aa17c097164d47beb8e1c0fc (patch) | |
tree | 0e8e5a15ad0b4290e760204a684963a12f7a8461 | |
download | aur-e9535a6828c53683aa17c097164d47beb8e1c0fc.tar.gz |
Initial commit
-rw-r--r-- | .SRCINFO | 21 | ||||
-rw-r--r-- | PKGBUILD | 50 | ||||
-rw-r--r-- | floodlight.install | 3 | ||||
-rw-r--r-- | floodlight.service | 6 |
4 files changed, 80 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..52a7ed1c2e3d --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,21 @@ +# Generated by makepkg 5.0.0 +# Thu Feb 11 17:34:15 UTC 2016 +pkgbase = floodlight + pkgdesc = Floodlight SDN OpenFlow Controller + pkgver = 1.2 + pkgrel = 1 + url = http://www.projectfloodlight.org + install = floodlight.install + arch = i686 + arch = x86_64 + license = custom + makedepends = git + makedepends = apache-ant + depends = java-runtime + source = https://github.com/floodlight/floodlight/archive/v1.2.tar.gz + source = floodlight.service + sha256sums = bf8a6209645fb50a1acd906ea9bf53b9f63bcd1d21f5213e15361273e28c9e45 + sha256sums = 30e0ff27a231f32f2c61655662961a310495de02e43cb88fbb39d35e436a791f + +pkgname = floodlight + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..89ec82bcc49c --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,50 @@ +# Contributor: Martin Jesper Low Madsen <martin@martinjlowm.dk> + +pkgname=floodlight +pkgver=1.2 +pkgrel=1 +pkgdesc="Floodlight SDN OpenFlow Controller" +url="http://www.projectfloodlight.org" +license=('custom') +depends=('java-runtime') +#optdepends=('xorg-xhost') +install="$pkgname.install" +makedepends=('git' 'apache-ant') +arch=('i686' 'x86_64') +source=("https://github.com/floodlight/floodlight/archive/v$pkgver.tar.gz" + "floodlight.service") +sha256sums=('bf8a6209645fb50a1acd906ea9bf53b9f63bcd1d21f5213e15361273e28c9e45' + '30e0ff27a231f32f2c61655662961a310495de02e43cb88fbb39d35e436a791f') + +build () { + cd "$srcdir/$pkgname-$pkgver" + + # Compile source + ant +} + +package () { + mkdir -p "$pkgdir/opt/" + + # Install systemd service file + mkdir -p "$pkgdir/usr/lib/systemd/system" + cp "floodlight.service" "$pkgdir/usr/lib/systemd/system/" + + cd "$srcdir/$pkgname-$pkgver" + + # Copy built files + cp -r "target" "$pkgdir/opt/floodlight" + + # Remove test files and directories + for _file in "bin-test" "floodlight-test.jar" "test" + do + rm -r "$pkgdir/opt/floodlight/$_file" + done + + # Copy resources + mkdir -p "$pkgdir/opt/floodlight/src/main" + for _res in "images" "python" "resources" "thrift" + do + cp -r "src/main/$_res" "$pkgdir/opt/floodlight/src/main/" + done +} diff --git a/floodlight.install b/floodlight.install new file mode 100644 index 000000000000..f88fa3bef55c --- /dev/null +++ b/floodlight.install @@ -0,0 +1,3 @@ +post_install () { + echo "Start Floodlight as `sudo systemctl start floodlight'." +} diff --git a/floodlight.service b/floodlight.service new file mode 100644 index 000000000000..f0021a934f75 --- /dev/null +++ b/floodlight.service @@ -0,0 +1,6 @@ +[Unit] +Description=Floodlight SDN OpenFlow Controller + +[Service] +WorkingDirectory=/opt/floodlight +ExecStart=-/usr/bin/java -jar /opt/floodlight/floodlight.jar
\ No newline at end of file |