1
0
Fork 0
mirror of https://github.com/ganelson/inform.git synced 2024-07-01 14:34:58 +03:00
inform7/inblorb/makescript.txt
2020-07-13 20:56:17 +01:00

53 lines
1 KiB
Plaintext

# This is the script from which inweb -makefile will construct a makefile.
{platform-settings}
{identity-settings}
BLORBLIB = $(ME)/Tests/Assistants/blorblib
# Making the program:
$(ME)/Tangled/$(MYNAME): $(BLORBLIB)/blorbscan {dependent-files}
$(call make-me)
.PHONY: force
force:
$(call make-me)
define make-me
$(INWEB) $(ME) -tangle
$(CC) -o $(ME)/Tangled/$(ME).o $(ME)/Tangled/$(ME).c
$(LINK) -o $(ME)/Tangled/$(ME)$(EXEEXTENSION) $(ME)/Tangled/$(ME).o $(LINKEROPTS)
endef
# Testing the program:
.PHONY: test
test: $(BLORBLIB)/blorbscan
$(INTEST) -from $(ME) all
$(BLORBLIB)/blorbscan: $(BLORBLIB)/*.c $(BLORBLIB)/*.h
cd $(BLORBLIB); $(INDULGENTCC) blorblib.c
cd $(BLORBLIB); $(INDULGENTCC) blorbscan.c
cd $(BLORBLIB); $(LINK) -o blorbscan$(EXEEXTENSION) *.o $(LINKEROPTS)
# Cleaning up:
.PHONY: clean
clean:
$(call clean-up)
.PHONY: purge
purge:
$(call clean-up)
rm -f $(ME)/Tangled/$(ME)
rm -f $(BLORBLIB)/blorbscan
define clean-up
rm -f $(ME)/Tangled/*.o
rm -f $(ME)/Tangled/*.c
rm -f $(ME)/Tangled/*.h
rm -f $(BLORBLIB)/*.o
endef