summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorManuel Hüsers2015-09-21 15:00:04 +0200
committerManuel Hüsers2015-09-21 15:00:04 +0200
commit82c4480c47beb36eae8278796ae6fe8416172568 (patch)
tree208680d9d7b0f44185e5fa77ea79bbe2beab7165
parentecf3a885a8da36e3d64c4f148ff03b4ebad3a75c (diff)
downloadaur-82c4480c47beb36eae8278796ae6fe8416172568.tar.gz
Version 1.1
-rw-r--r--.SRCINFO14
-rw-r--r--PKGBUILD26
-rw-r--r--rc-local.install16
-rw-r--r--rc-local.service20
-rw-r--r--rc.local14
5 files changed, 69 insertions, 21 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 7bca8650e8fc..26ae8d004d01 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,13 +1,17 @@
pkgbase = rc-local
pkgdesc = Support for legacy rc.local scripts
- pkgver = 1
+ pkgver = 1.1
pkgrel = 1
- url = https://aur.archlinux.org/packages/rc-local/
+ url = https://aur.archlinux.org/packages/rc-local
+ install = rc-local.install
arch = any
- license = BSD
- depends = bash
+ license = LGPL2.1
+ depends = systemd
+ backup = etc/rc.local
+ source = rc.local
source = rc-local.service
- md5sums = bb2cfecf3c6d99c6e6ee9eb58bcde75d
+ sha256sums = 8aa661c15cf9a35c32c79055bf69ab2d16354128ddd67a1bce0a7e48fe26f2e3
+ sha256sums = 7ac3eae0aee580448acbe386a3a2954990510790c42f2b9a0df293078d22dc14
pkgname = rc-local
diff --git a/PKGBUILD b/PKGBUILD
index 46e01d2142a7..a5f272562f5e 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,19 +1,23 @@
-# Maintainer: megadriver <megadriver at gmx dot com>
+# Maintainer: Manuel Hüsers <manuel.huesers@uni-ol.de>
+# Contributor: megadriver <megadriver at gmx dot com>
# Contributor: $pooky Hunter <spookyh+arch@gmail.org>
pkgname=rc-local
-pkgver=1
+pkgver=1.1
pkgrel=1
-pkgdesc="Support for legacy rc.local scripts"
-url=("https://aur.archlinux.org/packages/rc-local/")
+pkgdesc='Support for legacy rc.local scripts'
+url=('https://aur.archlinux.org/packages/rc-local')
arch=('any')
-license=('BSD')
-depends=('bash')
-source=(rc-local.service)
-md5sums=('bb2cfecf3c6d99c6e6ee9eb58bcde75d')
+license=('LGPL2.1')
+install="${pkgname}.install"
+depends=('systemd')
+backup=('etc/rc.local')
+source=('rc.local'
+ 'rc-local.service')
+sha256sums=('8aa661c15cf9a35c32c79055bf69ab2d16354128ddd67a1bce0a7e48fe26f2e3'
+ '7ac3eae0aee580448acbe386a3a2954990510790c42f2b9a0df293078d22dc14')
package() {
- echo "#!/bin/bash" > rc.local
- install -D -m 0755 rc.local $pkgdir/etc/rc.local
- install -D -m 0644 rc-local.service $pkgdir/usr/lib/systemd/system/rc-local.service
+ install -Dm755 'rc.local' "${pkgdir}/etc/rc.local"
+ install -Dm644 'rc-local.service' "${pkgdir}/usr/lib/systemd/system/rc-local.service"
}
diff --git a/rc-local.install b/rc-local.install
new file mode 100644
index 000000000000..9908ee17f408
--- /dev/null
+++ b/rc-local.install
@@ -0,0 +1,16 @@
+_update() {
+ systemctl daemon-reload
+}
+
+post_install() {
+ _update
+ systemctl enable rc-local.service
+}
+
+post_upgrade() {
+ _update
+}
+
+post_remove() {
+ _update
+} \ No newline at end of file
diff --git a/rc-local.service b/rc-local.service
index c56106f7dc4d..c7d6fcf4680f 100644
--- a/rc-local.service
+++ b/rc-local.service
@@ -1,11 +1,21 @@
+# This file is part of systemd.
+#
+# systemd is free software; you can redistribute it and/or modify it
+# under the terms of the GNU Lesser General Public License as published by
+# the Free Software Foundation; either version 2.1 of the License, or
+# (at your option) any later version.
+
[Unit]
-Description=/etc/rc.local compatibility
-After=network.target
+Description=/etc/rc.local Compatibility
+ConditionFileIsExecutable=/etc/rc.local
[Service]
-Type=oneshot
-ExecStart=/etc/rc.local
+Type=forking
+ExecStart=/etc/rc.local start
+TimeoutSec=0
+StandardOutput=tty
RemainAfterExit=yes
-
+SysVStartPriority=99
+
[Install]
WantedBy=multi-user.target
diff --git a/rc.local b/rc.local
new file mode 100644
index 000000000000..65634dfa4682
--- /dev/null
+++ b/rc.local
@@ -0,0 +1,14 @@
+#!/bin/sh -e
+#
+# rc.local
+#
+# This script is executed at the end of each multiuser runlevel.
+# Make sure that the script will "exit 0" on success or any other
+# value on error.
+#
+# In order to enable or disable this script just change the execution
+# bits.
+#
+# By default this script does nothing.
+
+exit 0