61 lines
3.0 KiB
Diff
61 lines
3.0 KiB
Diff
--- Makefile.old 2014-05-29 20:35:46.000000000 +0200
|
|
+++ Makefile 2014-12-08 08:45:45.067710346 +0100
|
|
@@ -5,11 +5,11 @@ CFLAGS += -Wall
|
|
LIBS = `pkg-config --libs --cflags libusb-1.0`
|
|
RM = /bin/rm -f
|
|
OBJS = usb_modeswitch.c
|
|
-PREFIX = $(DESTDIR)/usr
|
|
-ETCDIR = $(DESTDIR)/etc
|
|
+PREFIX = /usr
|
|
+ETCDIR = /etc
|
|
SYSDIR = $(ETCDIR)/systemd/system
|
|
UPSDIR = $(ETCDIR)/init
|
|
-UDEVDIR = $(DESTDIR)/lib/udev
|
|
+UDEVDIR = /lib/udev
|
|
SBINDIR = $(PREFIX)/sbin
|
|
MANDIR = $(PREFIX)/share/man/man1
|
|
VPATH = jimtcl
|
|
@@ -77,15 +77,15 @@ ums-clean:
|
|
# If not, use the dispatcher directly from the udev rule as in previous versions
|
|
|
|
install-common: $(PROG) usb_modeswitch_dispatcher
|
|
- install -D --mode=755 usb_modeswitch $(SBINDIR)/usb_modeswitch
|
|
- install -D --mode=755 usb_modeswitch.sh $(UDEVDIR)/usb_modeswitch
|
|
- install -D --mode=644 usb_modeswitch.conf $(ETCDIR)/usb_modeswitch.conf
|
|
- install -D --mode=644 usb_modeswitch.1 $(MANDIR)/usb_modeswitch.1
|
|
- install -D --mode=644 usb_modeswitch_dispatcher.1 $(MANDIR)/usb_modeswitch_dispatcher.1
|
|
- install -D --mode=755 usb_modeswitch_dispatcher $(SBINDIR)/usb_modeswitch_dispatcher
|
|
- install -d $(DESTDIR)/var/lib/usb_modeswitch
|
|
- test -d $(UPSDIR) -a -e /sbin/initctl && install --mode=644 usb-modeswitch-upstart.conf $(UPSDIR) || test 1
|
|
- test -d $(SYSDIR) -a -e /usr/bin/systemctl && install --mode=644 usb_modeswitch@.service $(SYSDIR) || test 1
|
|
+ install -D --mode=755 usb_modeswitch $(DESTDIR)/$(SBINDIR)/usb_modeswitch
|
|
+ install -D --mode=755 usb_modeswitch.sh $(DESTDIR)/$(UDEVDIR)/usb_modeswitch
|
|
+ install -D --mode=644 usb_modeswitch.conf $(DESTDIR)/$(ETCDIR)/usb_modeswitch.conf
|
|
+ install -D --mode=644 usb_modeswitch.1 $(DESTDIR)/$(MANDIR)/usb_modeswitch.1
|
|
+ install -D --mode=644 usb_modeswitch_dispatcher.1 $(DESTDIR)/$(MANDIR)/usb_modeswitch_dispatcher.1
|
|
+ install -D --mode=755 usb_modeswitch_dispatcher $(DESTDIR)/$(SBINDIR)/usb_modeswitch_dispatcher
|
|
+ install -d $(DESTDIR)/var/lib/usb_modeswitch
|
|
+ test -d $(DESTDIR)/$(UPSDIR) -a -e /sbin/initctl && install --mode=644 usb-modeswitch-upstart.conf $(DESTDIR)/$(UPSDIR) || test 1
|
|
+ test -d $(DESTDIR)/$(SYSDIR) -a -e /usr/bin/systemctl && install --mode=644 usb_modeswitch@.service $(DESTDIR)/$(SYSDIR) || test 1
|
|
|
|
install: install-script
|
|
|
|
@@ -96,10 +96,10 @@ install-shared: dispatcher-shared instal
|
|
install-static: dispatcher-static install-common
|
|
|
|
uninstall:
|
|
- $(RM) $(SBINDIR)/usb_modeswitch
|
|
- $(RM) $(SBINDIR)/usb_modeswitch_dispatcher
|
|
- $(RM) $(UDEVDIR)/usb_modeswitch
|
|
- $(RM) $(ETCDIR)/usb_modeswitch.conf
|
|
- $(RM) $(MANDIR)/usb_modeswitch.1
|
|
- $(RM) -R $(DESTDIR)/var/lib/usb_modeswitch
|
|
- $(RM) $(SYSDIR)/usb_modeswitch@.service
|
|
+ $(RM) $(DESTDIR)/$(SBINDIR)/usb_modeswitch
|
|
+ $(RM) $(DESTDIR)/$(SBINDIR)/usb_modeswitch_dispatcher
|
|
+ $(RM) $(DESTDIR)/$(UDEVDIR)/usb_modeswitch
|
|
+ $(RM) $(DESTDIR)/$(ETCDIR)/usb_modeswitch.conf
|
|
+ $(RM) $(DESTDIR)/$(MANDIR)/usb_modeswitch.1
|
|
+ $(RM) -R $(DESTDIR)/var/lib/usb_modeswitch
|
|
+ $(RM) $(DESTDIR)/$(SYSDIR)/usb_modeswitch@.service
|