summaryrefslogtreecommitdiff
path: root/Makefile
blob: cb5ec1d47ee4735ca6537003a2920a33e82deaa0 (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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
V=1

all:

install: install-program install-hooks install-examples install-doc

install-program:
	install -D -m 755 archiso/mkarchiso $(DESTDIR)/usr/sbin/mkarchiso

install-hooks:
	# hooks/install are needed by mkinitcpio
	install -D -m 644 archiso/hooks/archiso $(DESTDIR)/usr/lib/initcpio/hooks/archiso
	install -D -m 644 archiso/install/archiso $(DESTDIR)/usr/lib/initcpio/install/archiso
	install -D -m 755 archiso/archiso_shutdown $(DESTDIR)/usr/lib/initcpio/archiso_shutdown
	install -D -m 644 archiso/hooks/archiso_shutdown $(DESTDIR)/usr/lib/initcpio/hooks/archiso_shutdown
	install -D -m 644 archiso/install/archiso_shutdown $(DESTDIR)/usr/lib/initcpio/install/archiso_shutdown
	install -D -m 644 archiso/hooks/archiso_pxe_common $(DESTDIR)/usr/lib/initcpio/hooks/archiso_pxe_common
	install -D -m 644 archiso/install/archiso_pxe_common $(DESTDIR)/usr/lib/initcpio/install/archiso_pxe_common
	install -D -m 644 archiso/hooks/archiso_pxe_nbd $(DESTDIR)/usr/lib/initcpio/hooks/archiso_pxe_nbd
	install -D -m 644 archiso/install/archiso_pxe_nbd $(DESTDIR)/usr/lib/initcpio/install/archiso_pxe_nbd
	install -D -m 644 archiso/hooks/archiso_pxe_http $(DESTDIR)/usr/lib/initcpio/hooks/archiso_pxe_http
	install -D -m 644 archiso/install/archiso_pxe_http $(DESTDIR)/usr/lib/initcpio/install/archiso_pxe_http
	install -D -m 644 archiso/hooks/archiso_pxe_nfs $(DESTDIR)/usr/lib/initcpio/hooks/archiso_pxe_nfs
	install -D -m 644 archiso/install/archiso_pxe_nfs $(DESTDIR)/usr/lib/initcpio/install/archiso_pxe_nfs
	install -D -m 644 archiso/hooks/archiso_loop_mnt $(DESTDIR)/usr/lib/initcpio/hooks/archiso_loop_mnt
	install -D -m 644 archiso/install/archiso_loop_mnt $(DESTDIR)/usr/lib/initcpio/install/archiso_loop_mnt
	install -D -m 644 archiso/install/archiso_kms $(DESTDIR)/usr/lib/initcpio/install/archiso_kms

install-examples:
	install -d -m 755 $(DESTDIR)/usr/share/archiso/
	cp -r configs $(DESTDIR)/usr/share/archiso/

install-doc:
	install -d -m 755 $(DESTDIR)/usr/share/archiso/
	install -D -m 644 README $(DESTDIR)/usr/share/doc/archiso/README

uninstall:
	rm -f $(DESTDIR)/usr/sbin/mkarchiso
	rm -f $(DESTDIR)/usr/lib/initcpio/hooks/archiso
	rm -f $(DESTDIR)/usr/lib/initcpio/install/archiso
	rm -f $(DESTDIR)/usr/lib/initcpio/archiso_shutdown
	rm -f $(DESTDIR)/usr/lib/initcpio/hooks/archiso_shutdown
	rm -f $(DESTDIR)/usr/lib/initcpio/install/archiso_shutdown
	rm -f $(DESTDIR)/usr/lib/initcpio/hooks/archiso_pxe_common
	rm -f $(DESTDIR)/usr/lib/initcpio/install/archiso_pxe_common
	rm -f $(DESTDIR)/usr/lib/initcpio/hooks/archiso_pxe_nbd
	rm -f $(DESTDIR)/usr/lib/initcpio/install/archiso_pxe_nbd
	rm -f $(DESTDIR)/usr/lib/initcpio/hooks/archiso_pxe_http
	rm -f $(DESTDIR)/usr/lib/initcpio/install/archiso_pxe_http
	rm -f $(DESTDIR)/usr/lib/initcpio/hooks/archiso_pxe_nfs
	rm -f $(DESTDIR)/usr/lib/initcpio/install/archiso_pxe_nfs
	rm -f $(DESTDIR)/usr/lib/initcpio/hooks/archiso_loop_mnt
	rm -f $(DESTDIR)/usr/lib/initcpio/install/archiso_loop_mnt
	rm -f $(DESTDIR)/usr/lib/initcpio/install/archiso_kms
	rm -rf $(DESTDIR)/usr/share/archiso/
	rm -f $(DESTDIR)/usr/share/doc/archiso/README

dist:
	git archive --format=tar --prefix=archiso-$(V)/ v$(V) | gzip -9 > archiso-$(V).tar.gz
	gpg --detach-sign --use-agent archiso-$(V).tar.gz

.PHONY: install install-program install-hooks install-examples install-doc uninstall dist