diff options
author | dzwdz | 2023-06-25 16:38:32 +0200 |
---|---|---|
committer | dzwdz | 2023-06-25 16:38:32 +0200 |
commit | d4542c336a6cbfb43497055f19a85e7713f2eed7 (patch) | |
tree | 9f4a68974c3392b0ea546ecc94324911e86f0528 /Makefile | |
parent | fffd37f1680664bf055d8f5603ed1967718a6492 (diff) |
ports: reimplement the ports system from scratch
side stuff:
* removed sltar since it wasn't working anyways
* made signal() no longer panic, as that broke certain ports (oops)
* doom now ships with the FreeDOOM WADs
* /usr/ was aliased to /init/usr/, more directories were added to /bin/
to improve compat with ports
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 11 |
1 files changed, 9 insertions, 2 deletions
@@ -31,13 +31,14 @@ ifndef QEMU_DISPLAY QFLAGS += -display none endif +PORTS = define from_sources $(patsubst src/%,out/obj/%.o,$(shell find $(1) -type f,l -name '*.[csS]')) endef -.PHONY: all portdeps boot check clean +.PHONY: all portdeps boot check clean ports all: portdeps out/boot.iso check portdeps: out/libc.a out/libm.a src/user/lib/include/__errno.h @@ -116,13 +117,19 @@ $(foreach bin,$(USERBINS),$(eval $(call userbin_template,$(bin)))) out/obj/user/app/ext2fs/ext2/example.c.o: @touch $@ +# portdeps is phony, so ports/% is automatically "phony" too +ports: $(patsubst %,ports/%,$(PORTS)) +ports/%: portdeps + +$@/port install + out/initrd/%: sysroot/% @mkdir -p $(@D) @cp $< $@ out/initrd.tar: $(patsubst sysroot/%,out/initrd/%,$(shell find sysroot/ -type f)) \ $(patsubst %,out/initrd/bin/amd64/%,$(USERBINS)) \ - $(shell find out/initrd/) + $(shell find out/initrd/) \ + ports @cd out/initrd; tar chf ../initrd.tar * |