Made a start on building the runtimes for each platform and language; the

Linuxes all build.

--HG--
branch : dtrg-buildsystem
rename : modules/src/em_mes/build.mk => modules/src/read_em/build.mk
rename : plat/pc86/build.mk => plat/linux386/build.mk
rename : plat/pc86/build.mk => plat/linux68k/build.mk
rename : plat/pc86/build.mk => plat/linuxppc/build.mk
rename : util/ack/build.mk => util/misc/build.mk
This commit is contained in:
David Given
2013-05-12 23:51:55 +01:00
parent c1aca7dae5
commit b0c238eb5d
23 changed files with 501 additions and 92 deletions

View File

@@ -16,7 +16,7 @@ $(eval $(build-tabgen-impl))
# Output file is compiled with cfile and queued.
define tabgen-impl
$(eval g := $(OBJDIR)/$(strip $1).c)
$(eval g := $(OBJDIR)/$(objdir)/$(strip $1).c)
$g: $1 $(TABGEN)
@echo TABGEN $g
@@ -24,8 +24,9 @@ $g: $1 $(TABGEN)
$(hide) $(TABGEN) -f$(strip $1) > $g || $(RM) $g
$(eval CLEANABLES += $g)
$(call cfile,$g)
$(call $2,$g)
endef
tabgen = $(eval $(call tabgen-impl,$1))
tabgen = $(eval $(call tabgen-impl,$1,cfile))
acktabgen = $(eval $(call tabgen-impl,$1,ackfile))

View File

@@ -11,7 +11,8 @@ $(eval g := \
$(OBJDIR)/$D/em_mnem.c)
$(eval CLEANABLES += $g)
$g: $D/new_table h/em_table
$(wordlist 2, $(words $g), $g): $(firstword $g)
$(firstword $g): $D/new_table h/em_table
@echo DATA
@mkdir -p $(dir $g)
$(hide) $D/new_table h/em_table $(INCDIR) $(OBJDIR)/$D

48
util/misc/build.mk Normal file
View File

@@ -0,0 +1,48 @@
D := util/misc
define build-misc-impl
$(call reset)
$(call cfile, $D/esize.c)
$(call cprogram, $(BINDIR)/esize)
$(call installto, $(INSDIR)/bin/esize)
$(call reset)
$(eval q := $D/esize.1)
$(call installto, $(INSDIR)/share/man/man1/esize.1)
$(call reset)
$(eval objdir := encode)
$(call cfile, $D/convert.c)
$(eval $q: $(INCDIR)/em_comp.h $(INCDIR)/em_codeEK.h)
$(call file, $(LIBREAD_EMEV))
$(call file, $(LIBEMK))
$(call file, $(LIBEM_DATA))
$(call file, $(LIBALLOC))
$(call file, $(LIBPRINT))
$(call file, $(LIBSTRING))
$(call file, $(LIBSYSTEM))
$(call cprogram, $(BINDIR)/em_encode)
$(call installto, $(PLATDEP)/em_encode)
$(eval EM_ENCODE := $o)
$(call reset)
$(eval objdir := decode)
$(call cfile, $D/convert.c)
$(eval $q: $(INCDIR)/em_comp.h $(INCDIR)/em_codeEK.h)
$(call file, $(LIBREAD_EMKV))
$(call file, $(LIBEME))
$(call file, $(LIBEM_DATA))
$(call file, $(LIBALLOC))
$(call file, $(LIBPRINT))
$(call file, $(LIBSTRING))
$(call file, $(LIBSYSTEM))
$(call cprogram, $(BINDIR)/em_decode)
$(call installto, $(PLATDEP)/em_decode)
$(eval EM_DECODE := $o)
$(call reset)
$(eval q := $D/em_decode.6)
$(call installto, $(INSDIR)/share/man/man6/em_decode.6)
endef
$(eval $(build-misc-impl))