dosutil/Makefile: more complete structure
authorH. Peter Anvin <hpa@zytor.com>
Sun, 5 Jul 2009 21:15:12 +0000 (14:15 -0700)
committerH. Peter Anvin <hpa@zytor.com>
Sun, 5 Jul 2009 21:15:12 +0000 (14:15 -0700)
More complete and consistent structure for dosutil/Makefile.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
dosutil/Makefile

index 6a11f51..1ff3aad 100644 (file)
@@ -1,18 +1,30 @@
 #
 # OpenWatcom compile and link utility
 #
-WCL           = wcl
-WCLOPT_DOSCOM = -3 -osx -mt -bt=DOS -l=COM
+WCL    = wcl
+WCLOPT = -6 -osx -mt -bt=DOS -l=COM
 
-UPX           = upx
+UPX     = upx
 
-%.com: %.c
-       $(WCL) $(WCLOPT_DOSCOM) -fe=$@ $<
+TARGETS = mdiskchk.com
+
+%.obj: %.c
+       $(WCL) $(WCLOPT) -c -fo=$@ $<
+
+%.com: %.obj
+       $(WCL) $(WCLOPT) -fe=$@ $<
        $(UPX) --ultra-brute --lzma $@ || \
                $(UPX) --ultra-brute $@ || \
                true
 
-all: mdiskchk.com
+all: $(TARGETS)
+
+tidy dist:
+       -rm -f *.obj *.o
+
+clean: tidy
+
+spotless: clean
+       -rm -f *.com *.sys *~
+
 
-clean:
-       rm -f *.o *.obj *.com *.sys