13 |
#SUBDIRS += loadinitrd |
#SUBDIRS += loadinitrd |
14 |
#endif |
#endif |
15 |
|
|
16 |
|
OPTCFLAGS = $(CFLAGS) |
17 |
|
|
18 |
mandir = usr/share/man |
mandir = usr/share/man |
19 |
docdir = usr/share/doc/mkinitrd-$(VERSION) |
docdir = usr/share/doc/mkinitrd-$(VERSION) |
20 |
|
|
23 |
make -C klibc |
make -C klibc |
24 |
make -C busybox defconfig |
make -C busybox defconfig |
25 |
make -C busybox |
make -C busybox |
26 |
|
sed -i 's/%VERSIONTAG%/$(VERSION)/' mkinitrd |
27 |
|
|
28 |
test: all |
test: all |
29 |
cd grubby; make test |
for i in grubby busybox klibc; do make -C $$i test; done |
30 |
|
|
31 |
install: |
install: |
32 |
for n in $(SUBDIRS); do make -C $$n install DESTDIR=$(DESTDIR); done |
for n in $(SUBDIRS); do make -C $$n install DESTDIR=$(DESTDIR); done |
35 |
mkdir -p $(DESTDIR)/$$i; \ |
mkdir -p $(DESTDIR)/$$i; \ |
36 |
fi; \ |
fi; \ |
37 |
done |
done |
38 |
sed 's/%VERSIONTAG%/$(VERSION)/' < mkinitrd > $(DESTDIR)/sbin/mkinitrd |
install -m755 mkinitrd $(DESTDIR)/sbin/mkinitrd |
39 |
install -m755 installkernel $(DESTDIR)/sbin/installkernel |
install -m755 installkernel $(DESTDIR)/sbin/installkernel |
40 |
chmod 755 $(DESTDIR)/sbin/mkinitrd |
chmod 755 $(DESTDIR)/sbin/mkinitrd |
41 |
install -m644 mkinitrd.8 $(DESTDIR)/$(mandir)/man8/mkinitrd.8 |
install -m644 mkinitrd.8 $(DESTDIR)/$(mandir)/man8/mkinitrd.8 |
42 |
install -m644 mkinitrd.confd $(DESTDIR)/etc/conf.d/mkinitrd |
install -m644 mkinitrd.confd $(DESTDIR)/etc/conf.d/mkinitrd |
43 |
install -m755 busybox/busybox $(DESTDIR)/usr/sbin/busybox.mkinitrd |
install -m755 busybox/busybox $(DESTDIR)/usr/sbin/busybox.mkinitrd |
44 |
install -m644 busybox/LICENSE $(DESTDIR)/$(docdir)/busybox |
cat busybox/LICENSE | gzip -9 > $(DESTDIR)/$(docdir)/busybox/LICENSE.gz |
45 |
install -m644 busybox/README $(DESTDIR)/$(docdir)/busybox |
cat busybox/README | gzip -9 > $(DESTDIR)/$(docdir)/busybox/README.gz |
46 |
install -m644 busybox/TODO $(DESTDIR)/$(docdir)/busybox |
cat busybox/TODO | gzip -9 > $(DESTDIR)/$(docdir)/busybox/TODO.gz |
47 |
install -m755 klibc/usr/kinit/run-init/static/run-init $(DESTDIR)/usr/sbin/run-init.mkinitrd |
install -m755 klibc/usr/kinit/run-init/static/run-init $(DESTDIR)/usr/sbin/run-init.mkinitrd |
48 |
install -m644 klibc/usr/klibc/README $(DESTDIR)/$(docdir)/klibc |
cat klibc/usr/klibc/README | gzip -9 > $(DESTDIR)/$(docdir)/klibc/README.gz |
49 |
install -m644 klibc/usr/klibc/LICENSE $(DESTDIR)/$(docdir)/klibc |
cat klibc/usr/klibc/LICENSE | gzip -9 > $(DESTDIR)/$(docdir)/klibc/LICENSE.gz |
50 |
|
|
51 |
clean: |
clean: |
52 |
for n in $(SUBDIRS) busybox klibc isolinux; do make -C $$n clean; done |
for n in $(SUBDIRS) busybox klibc isolinux; do make -C $$n clean; done |