aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rwxr-xr-xsrc/Makefile.nt90
1 files changed, 47 insertions, 43 deletions
diff --git a/src/Makefile.nt b/src/Makefile.nt
index 720dc0b..c92727b 100755
--- a/src/Makefile.nt
+++ b/src/Makefile.nt
@@ -1,43 +1,47 @@
-# ----------------------- NT -----------------------
-LIBNAME=zexy
-
-current: $(LIBNAME)
-
-PREFIX="C:\Programme\pd"
-
-EXT=dll
-CC=cl
-LD=link
-
-DEFS=/D__WIN32__ /DPD /DZEXY_LIBRARY
-IFLAGS=/I. /I$(PREFIX)\src
-AFLAGS=
-WFLAGS=/W3 /WX /nologo
-
-.SUFFIXES: .$(EXT)
-
-include Make.source
-
-## for LinePrinter-support: (if you don't want it, comment it out)
-DEFS = $(DEFS) /DZ_WANT_LPT
-
-
-CFLAGS = /O2 $(DEFS) $(IFLAGS) $(WFLAGS)
-LIBS = libc.lib oldnames.lib kernel32.lib $(PREFIX)\bin\pd.lib
-LFLAGS = /dll /export:$(LIBNAME)_setup
-
-
-TARGETS = $(SOURCES:.c=.obj)
-
-.c.obj:
- cl $(CFLAGS) /c $*.c
-
-
-$(LIBNAME): $(TARGETS)
- $(LD) $(LFLAGS) /out:..\$(LIBNAME).$(EXT) *.obj $(LIBS)
-
-clean:
- -del -f *.$(EXT) *.obj ..\$(LIBNAME).lib ..\$(LIBNAME).exp *.lib *.exp
-
-cleaner: clean
- -del -f *~ _* config.* ..\$(LIBNAME).$(EXT)
+# ----------------------- NT -----------------------
+
+.PHONY: clean cleaner all zexy
+
+LIBNAME=zexy
+
+current: $(LIBNAME)
+
+PREFIX=C:\Programme\pd
+
+EXT=dll
+CC=cl
+LD=link
+
+DEFS=/D__WIN32__ /DPD /DZEXY_LIBRARY
+IFLAGS=/I. /I$(PREFIX)\src
+AFLAGS=
+WFLAGS=/W3 /WX /nologo
+
+## for LinePrinter-support: (if you don't want it, comment it out)
+DEFS += /DZ_WANT_LPT
+
+.SUFFIXES: .$(EXT)
+
+SOURCES=$(sort $(filter %.c, $(wildcard *.c)))
+
+CFLAGS = /O2 $(DEFS) $(IFLAGS) $(WFLAGS)
+LIBS = libc.lib oldnames.lib kernel32.lib pd.lib
+LFLAGS = /dll /export:$(LIBNAME)_setup /LIBPATH:"$(PREFIX)\bin"
+
+
+TARGETS = $(SOURCES:.c=.obj)
+
+
+$(TARGETS): %.obj : %.c
+ $(CC) $(CFLAGS) /c $*.c
+
+
+$(LIBNAME): $(TARGETS)
+ $(LD) $(LFLAGS) /out:$(LIBNAME).$(EXT) *.obj $(LIBS)
+
+clean:
+ del /f *.obj $(LIBNAME).$(EXT)
+
+cleaner: clean
+ del /f *~ _* config.* $(LIBNAME).$(EXT)
+