summaryrefslogtreecommitdiff
path: root/packaging/linux-hotplug/Makefile.am
blob: 8b182ec2641b70e1cb496818949f8ad107829757 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
EXTRA_DIST = usbcam.console usbcam.group usbcam.user

# no need to build or install the following on non-linux systems
if HAVE_LINUX

docdir = @DOC_DIR@/linux-hotplug
doc_DATA = usbcam.console usbcam.group usbcam.user

INCLUDES =	\
	-I$(top_srcdir)/libgphoto2	\
	-I$(top_srcdir)/libgphoto2_port/libgphoto2_port

noinst_PROGRAMS = print-usb-usermap

# FIXME: This should only be built if target system is linux
print_usb_usermap_SOURCE = print-usb-usermap.c
print_usb_usermap_LDADD = ../../libgphoto2/libgphoto2.la

USERMAP = gphoto2-usb.usermap

install-data-local: print-usb-usermap
	./print-usb-usermap > $(USERMAP)
	mkdir -p $(DESTDIR)$(docdir)/
	$(INSTALL_DATA) $(USERMAP) $(DESTDIR)$(docdir)/

uninstall-local:
	rm -f $(DESTDIR)$(docdir)/$(USERMAP)

else

install-data-local:
	@echo "Dummy $@ target"

uninstall-local:
	@echo "Dummy $@ target"

endif