diff --git a/.gitignore b/.gitignore index 8621919..350a483 100644 --- a/.gitignore +++ b/.gitignore @@ -18,3 +18,4 @@ a.out *.log *.exe chytesting +disk0 \ No newline at end of file diff --git a/labcodes/lab8/Makefile b/labcodes/lab8/Makefile index d87f0a8..4aba038 100644 --- a/labcodes/lab8/Makefile +++ b/labcodes/lab8/Makefile @@ -273,6 +273,9 @@ $(foreach p,$(USER_BINS),$(eval $(call fscopy,$(p),$(SFSROOT)$(SLASH)))) $(SFSROOT): if [ ! -d "$(SFSROOT)" ]; then mkdir $(SFSROOT); fi +$(SFSROOT): + $(V)$(MKDIR) $@ + $(SFSIMG): $(SFSROOT) $(SFSBINS) | $(call totarget,mksfs) $(V)dd if=/dev/zero of=$@ bs=1M count=128 @$(call totarget,mksfs) $@ $(SFSROOT) diff --git a/labcodes_answer/lab8_result/Makefile b/labcodes_answer/lab8_result/Makefile index 0f28ca1..2ca4155 100644 --- a/labcodes_answer/lab8_result/Makefile +++ b/labcodes_answer/lab8_result/Makefile @@ -261,6 +261,9 @@ endef $(foreach p,$(USER_BINS),$(eval $(call fscopy,$(p),$(SFSROOT)$(SLASH)))) +$(SFSROOT): + $(V)$(MKDIR) $@ + $(SFSIMG): $(SFSROOT) $(SFSBINS) | $(call totarget,mksfs) $(V)dd if=/dev/zero of=$@ bs=1M count=128 @$(call totarget,mksfs) $@ $(SFSROOT)