# make clean\r
# Delete unneeded files created by build process\r
\r
-LIB_TARGET=druntime-core.lib\r
-LIB_MASK=druntime-core*.lib\r
+LIB_BASE=druntime-core\r
+LIB_BUILD=\r
+LIB_TARGET=$(LIB_BASE)$(LIB_BUILD).lib\r
+LIB_MASK=$(LIB_BASE)*.lib\r
\r
CP=xcopy /y\r
RM=del /f\r
ADD_CFLAGS=\r
ADD_DFLAGS=\r
\r
-CFLAGS=-mn -6 -r $(ADD_CFLAGS)\r
-#CFLAGS=-g -mn -6 -r $(ADD_CFLAGS)\r
+CFLAGS_RELEASE=-mn -6 -r $(ADD_CFLAGS)\r
+CFLAGS_DEBUG=-g -mn -6 -r $(ADD_CFLAGS)\r
+CFLAGS=$(CFLAGS_RELEASE)\r
\r
-DFLAGS=-release -O -inline -w -nofloat $(ADD_DFLAGS)\r
-#DFLAGS=-g -w -nofloat $(ADD_DFLAGS)\r
+DFLAGS_RELEASE=-release -O -inline -w -nofloat $(ADD_DFLAGS)\r
+DFLAGS_DEBUG=-g -w -nofloat $(ADD_DFLAGS)\r
+DFLAGS=$(DFLAGS_RELEASE)\r
\r
-TFLAGS=-O -inline -w -nofloat $(ADD_DFLAGS)\r
-#TFLAGS=-g -w -nofloat $(ADD_DFLAGS)\r
+TFLAGS_RELEASE=-O -inline -w -nofloat $(ADD_DFLAGS)\r
+TFLAGS_DEBUG=-g -w -nofloat $(ADD_DFLAGS)\r
+TFLAGS=$(TFLAGS_RELEASE)\r
\r
DOCFLAGS=-version=DDoc\r
\r
core\runtime.html \\r
core\thread.html\r
\r
+######################################################\r
+\r
ALL_DOCS=\r
\r
######################################################\r
\r
+unittest :\r
+ make -fwin32.mak DC="$(DC)" LIB_BUILD="" DFLAGS="$(DFLAGS_RELEASE) -unittest"\r
+\r
+release :\r
+ make -fwin32.mak DC="$(DC)" LIB_BUILD="" DFLAGS="$(DFLAGS_RELEASE)"\r
+\r
+debug :\r
+ make -fwin32.mak DC="$(DC)" LIB_BUILD="-d" DFLAGS="$(DFLAGS_DEBUG)"\r
+\r
+######################################################\r
+\r
core.lib : $(LIB_TARGET)\r
\r
$(LIB_TARGET) : $(ALL_OBJS)\r