3a240221f0
* GNUmakefile (build-scripts): New target (HELP_TOP): Mention it. * configure (main): Write GUILE_FOR_BUILD. * make/bin-mlibc.make: Skip if CC32 is not set. * make/bin.make: Skip if CC is not set. * make/install.make (install): Only install $(OUT)/mes.mes if MES_BOOTSTRAP is set. * make/mescc-guile.make: Skip if GUILE is not set. * make/mescc-mes.make: Skip if MES is not set. * HACKING: write something about
60 lines
1.4 KiB
Makefile
60 lines
1.4 KiB
Makefile
SHELL:=bash
|
|
export SHELL
|
|
.export: SHELL
|
|
QUIET:=@
|
|
|
|
default: all
|
|
|
|
MES_DEBUG:=1
|
|
CFLAGS:=--std=gnu99 -O0 -g --include libc-gcc.c
|
|
OUT:=out
|
|
|
|
SUBDIRS:=\
|
|
module\
|
|
src\
|
|
scaffold\
|
|
scripts\
|
|
tests\
|
|
tinycc\
|
|
#
|
|
|
|
include make/common.make
|
|
-include .local.make
|
|
|
|
build-scripts:
|
|
make --dry-run MES=$(OUT)/mes CC= CC32= GUILE= MES_BOOTSTRAP=1 > $(OUT)/make.sh
|
|
make --dry-run MES=$(OUT)/mes CC= CC32= GUILE= MES_BOOTSTRAP=1 | tail +$(wc -l make.sh) > $(OUT)/make-check.sh
|
|
make --dry-run MES=$(OUT)/mes CC= CC32= GUILE= MES_BOOTSTRAP=1 | tail +$(wc -l make.sh) > $(OUT)/make-install.sh
|
|
|
|
make --dry-run > $(OUT)/make-dev.sh
|
|
make --dry-run | tail +$(wc -l make.sh) > $(OUT)/make-dev-check.sh
|
|
make --dry-run | tail +$(wc -l make.sh) > $(OUT)/make-dev-install.sh
|
|
|
|
help: help-top
|
|
|
|
install: all
|
|
release: all
|
|
|
|
help:
|
|
@echo
|
|
|
|
define HELP_TOP
|
|
Usage: make [OPTION]... [TARGET]...
|
|
|
|
Targets:
|
|
all update everything
|
|
build-scripts generate build scripts
|
|
check run unit tests
|
|
clean remove all generated stuff
|
|
dist create tarball in $(TARBALL)
|
|
distclean also clean configuration
|
|
maintainer-clean also clean expensive targets [$(strip $(MAINTAINER-CLEAN))]
|
|
mescc compile cc/main.c to a.out
|
|
install install in $$(DESTDIR)$$(PREFIX) [$(DESTDIR)$(PREFIX)]
|
|
release make a release
|
|
update-hash update hash in guix.scm
|
|
endef
|
|
export HELP_TOP
|
|
help-top:
|
|
@echo "$$HELP_TOP"
|