mirror of
https://github.com/linux-msm/rmtfs.git
synced 2024-11-23 12:14:12 +08:00
rmtfs.service: Add systemd service
Add rmtfs.service and install this. Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
This commit is contained in:
parent
976aa0ddbe
commit
6d2cfcddfc
1
.gitignore
vendored
1
.gitignore
vendored
@ -1,2 +1,3 @@
|
|||||||
rmtfs
|
rmtfs
|
||||||
*.o
|
*.o
|
||||||
|
rmtfs.service
|
||||||
|
12
Makefile
12
Makefile
@ -3,6 +3,8 @@ OUT := rmtfs
|
|||||||
CFLAGS += -Wall -g -O2
|
CFLAGS += -Wall -g -O2
|
||||||
LDFLAGS += -lqrtr -ludev -lpthread
|
LDFLAGS += -lqrtr -ludev -lpthread
|
||||||
prefix = /usr/local
|
prefix = /usr/local
|
||||||
|
bindir := $(prefix)/bin
|
||||||
|
servicedir := $(prefix)/lib/systemd/system
|
||||||
|
|
||||||
SRCS := qmi_rmtfs.c rmtfs.c rproc.c sharedmem.c storage.c util.c
|
SRCS := qmi_rmtfs.c rmtfs.c rproc.c sharedmem.c storage.c util.c
|
||||||
OBJS := $(SRCS:.c=.o)
|
OBJS := $(SRCS:.c=.o)
|
||||||
@ -13,9 +15,13 @@ $(OUT): $(OBJS)
|
|||||||
%.c: %.qmi
|
%.c: %.qmi
|
||||||
qmic -k < $<
|
qmic -k < $<
|
||||||
|
|
||||||
install: $(OUT)
|
rmtfs.service: rmtfs.service.in
|
||||||
install -D -m 755 $< $(DESTDIR)$(prefix)/bin/$<
|
@sed 's+RMTFS_PATH+$(bindir)+g' $< > $@
|
||||||
|
|
||||||
|
install: $(OUT) rmtfs.service
|
||||||
|
@install -D -m 755 $(OUT) $(DESTDIR)$(prefix)/bin/$(OUT)
|
||||||
|
@install -D -m 644 rmtfs.service $(DESTDIR)$(servicedir)/rmtfs.service
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
rm -f $(OUT) $(OBJS)
|
rm -f $(OUT) $(OBJS) rmtfs.service
|
||||||
|
|
||||||
|
11
rmtfs.service.in
Normal file
11
rmtfs.service.in
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
[Unit]
|
||||||
|
Description=Qualcomm remotefs service
|
||||||
|
Requires=qrtr-ns.service
|
||||||
|
After=qrtr-ns.service
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
ExecStart=RMTFS_PATH/rmtfs -r -P -s
|
||||||
|
Restart=always
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
Loading…
Reference in New Issue
Block a user