From 2cd5a18a03d679dc5f667e1402762cb741c5c122 Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Mon, 16 Jun 2014 13:15:25 -0400 Subject: Don't hardcode sbindir in the .service files --- .gitignore | 1 + Makefile | 3 +++ parabolaweb-reporead-inotify.service | 11 ----------- parabolaweb-reporead-inotify.service.in | 11 +++++++++++ parabolaweb.service | 11 ----------- parabolaweb.service.in | 11 +++++++++++ 6 files changed, 26 insertions(+), 22 deletions(-) delete mode 100644 parabolaweb-reporead-inotify.service create mode 100644 parabolaweb-reporead-inotify.service.in delete mode 100644 parabolaweb.service create mode 100644 parabolaweb.service.in diff --git a/.gitignore b/.gitignore index b7a19ed..9f66953 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ depends.txt +*.service diff --git a/Makefile b/Makefile index 6ea20b5..9bf082f 100644 --- a/Makefile +++ b/Makefile @@ -16,6 +16,9 @@ install: \ depends.txt: list-depends depends_static.txt bash $< > $@ +%.service: %.service.in + sed 's|@sbindir@|$(sbindir)|' < $< > $@ + $(DESTDIR)$(sbindir)/%: % install -Dm755 $< $@ diff --git a/parabolaweb-reporead-inotify.service b/parabolaweb-reporead-inotify.service deleted file mode 100644 index 243fce7..0000000 --- a/parabolaweb-reporead-inotify.service +++ /dev/null @@ -1,11 +0,0 @@ -[Unit] -Requires=postgresql.service -After=postgresql.service -Description=ParabolaWeb reporead_inotify daemon - -[Service] -Type=simple -ExecStart=/usr/sbin/parabolaweb-reporead-inotify - -[Install] -WantedBy=multi-user.target diff --git a/parabolaweb-reporead-inotify.service.in b/parabolaweb-reporead-inotify.service.in new file mode 100644 index 0000000..099db8d --- /dev/null +++ b/parabolaweb-reporead-inotify.service.in @@ -0,0 +1,11 @@ +[Unit] +Requires=postgresql.service +After=postgresql.service +Description=ParabolaWeb reporead_inotify daemon + +[Service] +Type=simple +ExecStart=@sbindir@/parabolaweb-reporead-inotify + +[Install] +WantedBy=multi-user.target diff --git a/parabolaweb.service b/parabolaweb.service deleted file mode 100644 index 011f3de..0000000 --- a/parabolaweb.service +++ /dev/null @@ -1,11 +0,0 @@ -[Unit] -Requires=postgresql.service -After=postgresql.service -Description=ParabolaWeb - -[Service] -Type=simple -ExecStart=/usr/sbin/parabolaweb-fcgi daemonize=false - -[Install] -WantedBy=multi-user.target diff --git a/parabolaweb.service.in b/parabolaweb.service.in new file mode 100644 index 0000000..e5a06ce --- /dev/null +++ b/parabolaweb.service.in @@ -0,0 +1,11 @@ +[Unit] +Requires=postgresql.service +After=postgresql.service +Description=ParabolaWeb + +[Service] +Type=simple +ExecStart=@sbindir@/parabolaweb-fcgi daemonize=false + +[Install] +WantedBy=multi-user.target -- cgit v1.2.3