X-Git-Url: http://git.mutantstargoat.com/user/nuclear/?p=eradicate;a=blobdiff_plain;f=Makefile;h=cf58921049719a84b7109bc52e112da0382962e2;hp=bcebb62953fb71962c8906488bb90f1262e8dcb0;hb=ae47c13224ea63ac83f80ab332f7436b3265cdce;hpb=d3401f8f5fbe0b0a7939ce3a8ef680cf5356f9ba diff --git a/Makefile b/Makefile index bcebb62..cf58921 100644 --- a/Makefile +++ b/Makefile @@ -31,7 +31,7 @@ LD = wlink CFLAGS = -d3 -5 -fp5 -otebmileran $(def) -s -zq -bt=dos $(incpath) LDFLAGS = option map $(libpath) library { $(libs) } -$(bin): $(obj) +$(bin): cflags.occ $(obj) libs/imago/imago.lib %write objects.lnk $(obj) %write ldflags.lnk $(LDFLAGS) $(LD) debug all name $@ system dos4g file { @objects } @ldflags @@ -39,8 +39,11 @@ $(bin): $(obj) .c: src;src/dos;src/3dgfx .asm: src;src/dos;src/3dgfx +cflags.occ: Makefile + %write $@ $(CFLAGS) + .c.obj: .autodepend - $(CC) -fo=$@ $(CFLAGS) $[* + $(CC) -fo=$@ @cflags.occ $[* .asm.obj: nasm -f obj -o $@ $[*.asm @@ -49,10 +52,12 @@ $(bin): $(obj) clean: .symbolic rm -f $(obj) rm -f $(bin) + rm -f cflags.occ *.lnk !else clean: .symbolic del src\*.obj del src\dos\*.obj del *.lnk + del cflags.occ del $(bin) !endif