mirror of
https://github.com/linux-msm/rmtfs.git
synced 2024-11-23 04:04:29 +08:00
6d2cfcddfc
Add rmtfs.service and install this. Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
28 lines
597 B
Makefile
28 lines
597 B
Makefile
OUT := rmtfs
|
|
|
|
CFLAGS += -Wall -g -O2
|
|
LDFLAGS += -lqrtr -ludev -lpthread
|
|
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
|
|
OBJS := $(SRCS:.c=.o)
|
|
|
|
$(OUT): $(OBJS)
|
|
$(CC) -o $@ $^ $(LDFLAGS)
|
|
|
|
%.c: %.qmi
|
|
qmic -k < $<
|
|
|
|
rmtfs.service: rmtfs.service.in
|
|
@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:
|
|
rm -f $(OUT) $(OBJS) rmtfs.service
|
|
|