Subject: [alpine-devel] [PATCH] Fixed folders during installation of package

From: "Yves Schumann" <[email-masked]>
Date: Fri, 7 Jun 2013 00:04:54 +0200

- Fixed used folders for quasselcore log and data
- Setup proper binary name on init script
- Added missing dependency
---
 testing/quassel/APKBUILD              | 21 +++++++++++++++------
 testing/quassel/quassel-core.defaultd | 14 ++++++++------
 testing/quassel/quassel-core.initd    | 18 ++++++++++--------
 3 files changed, 33 insertions(+), 20 deletions(-)

diff --git a/testing/quassel/APKBUILD b/testing/quassel/APKBUILD
index 349b269..8e8636f 100644
--- a/testing/quassel/APKBUILD
+++ b/testing/quassel/APKBUILD
@@ -7,6 +7,7 @@ url="http://www.quassel-irc.org/"
 pkgdesc="Distributed IRC client - metapackage"
 arch="all"
 license="GPL"
+depends="sqlite"
 makedepends="qt-dev cmake"
 subpackages="$pkgname-core"
 source="http://www.quassel-irc.org/pub/quassel-$pkgver.tar.bz2
@@ -50,14 +51,22 @@ core() {
     "$subpkgdir"/etc/conf.d/quassel-core || return 1
   install -Dm0755 ${srcdir}/$subpkgname.initd \
     "$subpkgdir"/etc/init.d/quassel-core || return 1
+
+  # Setup log directory
+  mkdir -p "$subpkgdir"/var/log/quassel || return 1
+  chown quassel "$subpkgdir"/var/log/quassel || return 1
+
+  # Setup default data directory
+  mkdir -p "$subpkgdir"/usr/share/quassel-core || return 1
+  chown quassel "$subpkgdir"/usr/share/quassel-core || return 1
 }
 
 md5sums="29b843f18d703abfadb8fc729ca1df11  quassel-0.9.0.tar.bz2
-560e396db1e85d641c15eb6b15cbae74  quassel-core.defaultd
-5d4d6dee89961fb2108727b56b8bf75d  quassel-core.initd"
+b983d1409b36aa22bbb69069ee3ab2a0  quassel-core.defaultd
+e04cf9ad51bec2d6daf9c581b63f63a2  quassel-core.initd"
 sha256sums="2e3fe06ae3731c829aa3c2f6bb5320619bad264c831f322985c3aa3fe58b6027  quassel-0.9.0.tar.bz2
-9e916cefd6a1be7218249410490ce07c8a98ba8f96b2c3c16b3ee3f1222dbd51  quassel-core.defaultd
-6ad0a474f3978980a3337e6b523b88c6dd81850b6b7f0538cbe86d36345f1605  quassel-core.initd"
+8305310223b9369c5dfa74183fce243296f2f40cca8fbb947cf4834bbeb65c51  quassel-core.defaultd
+7b11f880ceed072795a185b173f388b5242cb2a3ef127e15e36335ffadbeeaaf  quassel-core.initd"
 sha512sums="5f0b54c7c0e839d30ec5cc1c76f115f60aef35c53b2ed1cc69cb856413e0b381bfa3b56d6a9b60d8a118d216930adb52856d39b1bbd4c96e8c0f3809756f6f21  quassel-0.9.0.tar.bz2
-6f8120cf08b676a896a63e370d9c0e16db72cf2a9b1a8db52f5ce3b983ce38a7d157d6346282158fd0d440048aad00bb3c57d6b5c81a0ab5a92918b11d15aa6d  quassel-core.defaultd
-f761d881973af0151b4e39419b972d8e9c5e9f43d3ae52d64fefc1fd631c397fee5a929b7d559705d2fbf53bd2adff943451d8402059e3ac6893b3b9fe72d979  quassel-core.initd"
+21621ea6ae70fe14d0963657ab2cc6d2b402afa1a5495705d5e657c506ba8a362639389651844e81c2f7d5631a4774a54c8bcd972bc814704602b187b437df41  quassel-core.defaultd
+1a0be3bc2c6037a67334de92219edf98e1df528d2c8650e3ee7e5d88969a6bd4a357626f2aa536b0ad95f36ea546d7290b3f782699f271a68452e35863f93efd  quassel-core.initd"
diff --git a/testing/quassel/quassel-core.defaultd b/testing/quassel/quassel-core.defaultd
index 7835da3..d593632 100644
--- a/testing/quassel/quassel-core.defaultd
+++ b/testing/quassel/quassel-core.defaultd
@@ -1,10 +1,12 @@
-# Quasselcore default configuration
+# Quasselcore configuration
 
-QUASSEL_CORE_PORT='4242'
+# Activate desired lines to modify default values
 
-QUASSEL_CORE_LOG_FILE=/var/log/quassel/quasselcore.log
-QUASSEL_CORE_LOG_LEVEL='info'
+#QUASSEL_CORE_PORT='4242'
 
-QUASSEL_CORE_DATADIR=/usr/local/quasselcore
+#QUASSEL_CORE_LOG_FILE=/var/log/quassel/quassel-core.log
+#QUASSEL_CORE_LOG_LEVEL='info'
 
-QUASSEL_CORE_DAEMON_OPTS=''
+#QUASSEL_CORE_DATADIR=/usr/share/quassel-core
+
+#QUASSEL_CORE_DAEMON_OPTS=''
diff --git a/testing/quassel/quassel-core.initd b/testing/quassel/quassel-core.initd
index b866600..7de2589 100644
--- a/testing/quassel/quassel-core.initd
+++ b/testing/quassel/quassel-core.initd
@@ -1,18 +1,20 @@
 #!/sbin/runscript
 # quasselcore init.d file for alpine linux.
 
-QUASSEL_CONFIG=/etc/config.d/quassel-core
-DAEMON=/usr/bin/quassel-core
+QUASSEL_CONFIG=/etc/conf.d/quassel-core
+DAEMON=/usr/bin/quasselcore
 ACCOUNT=quassel
 PID=/var/run/quassel-core.pid
 
-# Load defaults
-. /etc/default.d/quassel-core
+# Define defaults
+QUASSEL_CORE_PORT='4242'
+QUASSEL_CORE_LOG_FILE=/var/log/quassel/quassel-core.log
+QUASSEL_CORE_LOG_LEVEL='info'
+QUASSEL_CORE_DATADIR=/usr/share/quassel-core
+QUASSEL_CORE_DAEMON_OPTS=''
 
-# Load specific configuration
-if [ -e ${QUASSEL_CONFIG} ] ; then
-    . ${QUASSEL_CONFIG}
-fi
+# Load configuration
+. ${QUASSEL_CONFIG}
 
 depend() {
     need net
-- 
1.8.3

---
Unsubscribe:  [email-masked]
Help:         [email-masked]
---