diff options
-rw-r--r-- | Makefile | 32 | ||||
m--------- | openssh | 0 |
2 files changed, 24 insertions, 8 deletions
@@ -8,7 +8,9 @@ compiled_programs=${cc_files} ${cpp_files} | |||
8 | CC=gcc -std=gnu99 | 8 | CC=gcc -std=gnu99 |
9 | CFLAGS=-Os | 9 | CFLAGS=-Os |
10 | 10 | ||
11 | all: samizdat-paths.sh ${compiled_programs} | 11 | SUBMODULES = fsmgr kiki openssh |
12 | |||
13 | all: samizdat-paths.sh ${compiled_programs} ${SUBMODULES} | ||
12 | 14 | ||
13 | dynmenu: src/dynmenu.cpp | 15 | dynmenu: src/dynmenu.cpp |
14 | $(CXX) $(CFLAGS) $< -o $@ -lcurses | 16 | $(CXX) $(CFLAGS) $< -o $@ -lcurses |
@@ -50,15 +52,18 @@ endif | |||
50 | 52 | ||
51 | include user.mk | 53 | include user.mk |
52 | 54 | ||
53 | SUBMODULES = fsmgr kiki openssh | 55 | .PHONY: submodule $(SUBMODULES) |
54 | .PHONY: rootfs submodule $(SUBMODULES) | ||
55 | |||
56 | $(SUBMODULES): | 56 | $(SUBMODULES): |
57 | [ -e $@/Makefile ] || git submodule update --init | 57 | [ -e $@/Makefile ] || git submodule update --init |
58 | $(MAKE) -C $@ | 58 | $(MAKE) -C $@ $(cmd) |
59 | $(MAKE) -C $@ install | ||
60 | 59 | ||
61 | rootfs: $(SUBMODULES) | 60 | install-submodules: cmd=install |
61 | install-submodules: $(SUBMODULES) | ||
62 | |||
63 | .PHONY: rootfs | ||
64 | rootfs: | ||
65 | [ -e install-submodules-stamp ] || make install-submodules-stamp | ||
66 | [ -e install-stamp ] || sudo make install-stamp | ||
62 | $(MAKE) -C rootfs | 67 | $(MAKE) -C rootfs |
63 | sudo mkdir -p /srv/nbd | 68 | sudo mkdir -p /srv/nbd |
64 | sudo ln -sf "$$PWD"/rootfs/samizdat.btrfs /srv/nbd/samizdat.btrfs | 69 | sudo ln -sf "$$PWD"/rootfs/samizdat.btrfs /srv/nbd/samizdat.btrfs |
@@ -78,8 +83,18 @@ isotest-nonet: install | |||
78 | xorriso-usb.sh $(reuse_child) --out samizdat-nonet.iso | 83 | xorriso-usb.sh $(reuse_child) --out samizdat-nonet.iso |
79 | USE_ISO=y SLOW_BOOT=y NO_NET=y qemu.sh samizdat-nonet.iso | 84 | USE_ISO=y SLOW_BOOT=y NO_NET=y qemu.sh samizdat-nonet.iso |
80 | 85 | ||
81 | install: ${bin_programs} samizdat-paths.sh ${compiled_programs} | 86 | .PHONY: install |
87 | install: | ||
88 | [ -e install-submodules-stamp ] || make install-submodules-stamp | ||
89 | sudo make install-stamp | ||
90 | |||
91 | install-submodules-stamp: install-submodules | ||
92 | touch $@ | ||
93 | |||
94 | install-bin-programs: ${bin_programs} | ||
82 | install -p ${bin_programs} ${instdir}${samizdat_bindir} | 95 | install -p ${bin_programs} ${instdir}${samizdat_bindir} |
96 | |||
97 | install-stamp: install-bin-programs samizdat-paths.sh ${compiled_programs} | ||
83 | mkdir -p ${instdir}${samizdat_initrd_files_dir} | 98 | mkdir -p ${instdir}${samizdat_initrd_files_dir} |
84 | mkdir -p ${instdir}${samizdat_child_dir} | 99 | mkdir -p ${instdir}${samizdat_child_dir} |
85 | mkdir -p ${instdir}${samizdat_grub_efi_dir} | 100 | mkdir -p ${instdir}${samizdat_grub_efi_dir} |
@@ -89,3 +104,4 @@ install: ${bin_programs} samizdat-paths.sh ${compiled_programs} | |||
89 | cp -r ${initrd_files} ${instdir}${samizdat_initrd_files_dir} | 104 | cp -r ${initrd_files} ${instdir}${samizdat_initrd_files_dir} |
90 | cp -r ${initramfs_conf_files} ${instdir}${samizdat_initramfs_conf_dir} | 105 | cp -r ${initramfs_conf_files} ${instdir}${samizdat_initramfs_conf_dir} |
91 | cp -r ${isolinux_files} ${instdir}${samizdat_isolinux_dir} | 106 | cp -r ${isolinux_files} ${instdir}${samizdat_isolinux_dir} |
107 | touch $@ | ||
diff --git a/openssh b/openssh | |||
Subproject 8a34eb2de148e1e504043d4bbf98fd45b36bbc9 | Subproject 3734a550eba796593f32e5b201127ecc359f07a | ||