summaryrefslogtreecommitdiffstats
path: root/testing/openvcp
diff options
context:
space:
mode:
authorCarlo Landmeter <clandmeter@gmail.com>2009-02-04 12:24:27 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2009-02-04 12:24:27 +0000
commit5d089d56afa69c5e97437633c6dd2a655153974b (patch)
tree2d8e75523dbbf8ba66d5fba6cd809c171bf0903e /testing/openvcp
parent49d50b7752a44b7e27b3b52acdc451e6c612103e (diff)
downloadaports-5d089d56afa69c5e97437633c6dd2a655153974b.tar.bz2
aports-5d089d56afa69c5e97437633c6dd2a655153974b.tar.xz
testing/openvcp: new aport
vserver control panel daemon http://openvcp.org/
Diffstat (limited to 'testing/openvcp')
-rw-r--r--testing/openvcp/APKBUILD40
-rw-r--r--testing/openvcp/openvcpd-0.4-rc1-makefile.patch46
-rw-r--r--testing/openvcp/openvcpd-0.4-rc1-posix-shell.patch21
3 files changed, 107 insertions, 0 deletions
diff --git a/testing/openvcp/APKBUILD b/testing/openvcp/APKBUILD
new file mode 100644
index 000000000..ea24882fb
--- /dev/null
+++ b/testing/openvcp/APKBUILD
@@ -0,0 +1,40 @@
+# Contributor: Carlo Landmeter <clandmeter at gmail>
+# Maintainer: Carlo Landmeter <clandmeter at gmail>
+pkgname=openvcpd
+pkgver="0.4_rc1"
+_myver="0.4-rc1"
+pkgrel=0
+pkgdesc="vserver control panel daemon"
+url="http://openvcp.org/"
+license="GPL"
+depends="sqlite libxml2"
+makedepends="libxml2-dev pkgconfig util-vserver-dev iptables-dev sqlite-dev libpcap-dev autoconf"
+source="http://files.openvcp.org/${pkgname}-${_myver}.tar.gz
+ $pkgname-0.4-rc1-makefile.patch
+ $pkgname-0.4-rc1-posix-shell.patch
+ "
+
+build() {
+ cd "$srcdir/$pkgname-$_myver"
+ for i in ../*.patch; do
+ msg "Applying $i"
+ patch -p1 < $i || return 1
+ done
+ autoconf
+
+ ./configure --prefix=/usr \
+ --sysconfdir=/etc \
+ --mandir=/usr/share/man \
+ --infodir=/usr/share/info
+ make || return 1
+ mkdir -p "$pkgdir"/usr/bin/
+ mkdir -p "$pkgdir"/etc/
+ make DESTDIR="$pkgdir" install
+
+ # install -m755 -D "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname
+ # install -m644 -D "$srcdir"/$pkgname.confd "$pkgdir"/etc/conf.d/$pkgname
+}
+
+md5sums="18725ca88753e0a5c42af849347934c0 openvcpd-0.4-rc1.tar.gz
+fb1802bf62ebc524a836b38683825b25 openvcpd-0.4-rc1-makefile.patch
+b27f708c81a27bbf03f4c111b4b1f9f8 openvcpd-0.4-rc1-posix-shell.patch"
diff --git a/testing/openvcp/openvcpd-0.4-rc1-makefile.patch b/testing/openvcp/openvcpd-0.4-rc1-makefile.patch
new file mode 100644
index 000000000..a7a26e52c
--- /dev/null
+++ b/testing/openvcp/openvcpd-0.4-rc1-makefile.patch
@@ -0,0 +1,46 @@
+--- a/Makefile.in Wed Feb 4 10:55:05 2009
++++ b/Makefile.in Wed Feb 4 10:57:25 2009
+@@ -3,8 +3,9 @@
+ datadir = @datarootdir@
+ sysconfdir = @sysconfdir@
+
++REV:=$(shell svnversion 2>/dev/null | sed 's/M//')
+ CC=@CC@
+-CFLAGS=@CFLAGS@ @DEFS@ -DOPENVCP_CONFIG=\"$(sysconfdir)/openvcpd.conf\" -DOPENVCP_DATA=\"$(datadir)/openvcpd\" -Ilib/ -Isrc/ -rdynamic -DREVISION=\"`svnversion | sed 's/M//'`\"
++CFLAGS=@CFLAGS@ @DEFS@ -DOPENVCP_CONFIG=\"$(sysconfdir)/openvcpd.conf\" -DOPENVCP_DATA=\"$(datadir)/openvcpd\" -Ilib/ -Isrc/ -rdynamic -DREVISION=\"$(REV)\"
+ LDFLAGS=@LDFLAGS@
+ LIBS=@LIBS@
+
+@@ -39,22 +40,24 @@
+ @rm -f parse_ipfmlogs
+
+ install:
+- mkdir -p $(datadir)/openvcpd
+- cp openvcpd $(bindir)/openvcpd
+- cp parse_ipfmlogs $(bindir)/parse_ipfmlogs
++ mkdir -p "$(DESTDIR)/$(datadir)"/openvcpd \
++ "$(DESTDIR)/$(bindir)" \
++ "$(DESTDIR)/$(sysconfdir)"
++ cp openvcpd "$(DESTDIR)/$(bindir)"/openvcpd
++ cp parse_ipfmlogs "$(DESTDIR)/$(bindir)"/parse_ipfmlogs
+
+- @if (test -e $(sysconfdir)/openvcpd.conf); then \
++ @if (test -e "$(DESTDIR)/$(sysconfdir)"/openvcpd.conf); then \
+ echo "Configuration File exists. Please check for updates of the configurationfile"; \
+ else \
+ cfgdir=`vserver-info 2>&1 | grep 'cfg-Directory:' | awk -F: '{ print $$2 }' | cut -c2-`; \
+ rootdir=`vserver-info 2>&1 | grep 'vserver-Rootdir:' | awk -F: '{ print $$2 }' | cut -c2-`; \
+ rundir=`vserver-info 2>&1 | grep 'pkgstate-Directory:' | awk -F: '{ print $$2 }' | cut -c2-`; \
+ echo "CONF: $$cfgdir, $$rootdir, $$rundir"; \
+- cat openvcpd.conf | sed s#'CONFIGDIR'#$$cfgdir# | sed s#'ROOTDIR'#$$rootdir# | sed s#'RUNDIR'#$$rundir# > $(sysconfdir)/openvcpd.conf; \
++ cat openvcpd.conf | sed s#'CONFIGDIR'#$$cfgdir# | sed s#'ROOTDIR'#$$rootdir# | sed s#'RUNDIR'#$$rundir# > $(DESTDIR)/$(sysconfdir)/openvcpd.conf; \
+ echo "Configuration File created ($(sysconfdir)/openvcpd.conf)"; \
+ fi \
+
+ uninstall:
+- rm -rf $(datadir)/openvcpd
+- rm -f $(bindir)/openvcpd
+- rm -f $(sysconfdir)/openvcpd.conf
++ rm -rf "$(DESTDIR)/$(datadir)"/openvcpd
++ rm -f "$(DESTDIR)/$(bindir)"/openvcpd
++ rm -f "$(DESTDIR)/$(sysconfdir)"/openvcpd.conf
diff --git a/testing/openvcp/openvcpd-0.4-rc1-posix-shell.patch b/testing/openvcp/openvcpd-0.4-rc1-posix-shell.patch
new file mode 100644
index 000000000..492e6b033
--- /dev/null
+++ b/testing/openvcp/openvcpd-0.4-rc1-posix-shell.patch
@@ -0,0 +1,21 @@
+--- a/configure.ac Wed Feb 4 10:11:07 2009
++++ b/configure.ac Wed Feb 4 10:23:07 2009
+@@ -67,15 +67,15 @@
+ fi
+
+ if test "x$with_ipv6" != xno; then
+- CFLAGS+=" -DIPV6_SUPPORT"
++ CFLAGS="$CFLAGS -DIPV6_SUPPORT"
+ fi
+
+ xmlflags=`pkg-config libxml-2.0 --cflags`
+-if test "$xmlflags" == ""; then
++if test "$xmlflags" = ""; then
+ AC_MSG_ERROR([libxml2 headers not found])
+ fi
+
+-CFLAGS+=" $xmlflags"
++CFLAGS="$CFLAGS $xmlflags"
+
+ AC_CONFIG_FILES([Makefile])
+ AC_OUTPUT