summaryrefslogtreecommitdiff
path: root/script/deb-systemd-helper
diff options
context:
space:
mode:
authorIgor Pashev <pashev.igor@gmail.com>2014-05-13 18:41:17 +0400
committerIgor Pashev <pashev.igor@gmail.com>2014-05-13 18:41:17 +0400
commite1dcd7e330de580b410722615cb3f05a23466bf8 (patch)
tree3ac2561debd7b40a79cd802fb7b311b877eff5f3 /script/deb-systemd-helper
parenta51aa9741020d41009c462f906505f9d322f636d (diff)
downloadinit-system-helpers-master.tar.gz
init-system-helpers (1.18+dyson1) unstable; urgency=mediumHEADdyson/1.18+dyson1master
* Package for Dyson * deb-systemd-helper and deb-systemd-invoke work only on Linux; on other archs they do nothing and return 0 * dh_systemd_enable and dh_systemd_start work only for Linux; for other archs they do nothing and return 0
Diffstat (limited to 'script/deb-systemd-helper')
-rwxr-xr-xscript/deb-systemd-helper11
1 files changed, 11 insertions, 0 deletions
diff --git a/script/deb-systemd-helper b/script/deb-systemd-helper
index 59e76a0..8ab1ad8 100755
--- a/script/deb-systemd-helper
+++ b/script/deb-systemd-helper
@@ -78,6 +78,11 @@ filing a bugreport.
=back
+=head1 NOTES
+
+This command currently works on Linux only, on other Debian archs
+it does nothing and returns 0;
+
=cut
use strict;
@@ -444,6 +449,12 @@ if (!$ENV{DPKG_MAINTSCRIPT_PACKAGE}) {
exit 1;
}
+my $deb_host_arch_os = `dpkg-architecture -qDEB_HOST_ARCH_OS`;
+if ($deb_host_arch_os !~ /linux/) {
+ debug "systemd is unsupported on $deb_host_arch_os";
+ exit(0);
+}
+
if ($action eq 'purge') {
$ENV{_DEB_SYSTEMD_HELPER_PURGE} = 1;
$action = 'disable';