-# This makefile builds the user-mode component\r
-# of OpenVPN for Windows in the Visual Studio 2008 environment.\r
-\r
-# To build:\r
-# python win\config.py\r
-# nmake /f msvc.mak\r
-\r
-# Each of the OPENSSL and LZO dirs should have 'lib' and 'include'\r
-# directories under them.\r
+# This makefile builds the user-mode component of OpenVPN for Windows in the
+# Visual Studio 2008 environment. Note that this file is basis for the real
+# makefile (..\msvc.mak) but unusable as is. The real makefile is automatically
+# generated during the build process by the Python build scripts.
+#
+# A few details are in order:
+#
+# - Everything between @<< and << is inserted into a s.c. "in-line file". This
+# file drives the linker (link.exe).
+# - HEADERS_OBJS is expanded to all all header and source files listed in
+# ..\Makefile.am
+# - OPENSSL_DIR and LZO_DIR are dynamically created from settings.in
\r
OPENSSL = @OPENSSL_DIR@\r
OPENSSL_DYNAMIC = libeay32.lib ssleay32.lib\r
!ifdef PRODUCT_OPENVPN_DEBUG\r
# debug:\r
CPP_PROJ=$(CPP_ARG_COMMON) /MD /Z7\r
-LINK32_FLAGS=/nologo /subsystem:console /incremental:no /opt:ref /opt:icf /debug /out:"$(EXE)"\r
-# old debug:\r
-#CPP_PROJ=$(CPP_ARG_COMMON) /MDd /Zi /Od -D_DEBUG\r
-#LINK32_FLAGS=/nologo /subsystem:console /incremental:no /debug /out:"$(EXE)"\r
+LINK32_FLAGS=/nologo /subsystem:console /incremental:no /opt:ref /opt:icf /debug
!else\r
# release:\r
CPP_PROJ=$(CPP_ARG_COMMON) /O2 /MD -DNDEBUG\r
-LINK32_FLAGS=/nologo /subsystem:console /incremental:no /out:"$(EXE)"\r
+LINK32_FLAGS=/nologo /subsystem:console /incremental:no
!endif\r
\r
-# HEADERS and OBJS definitions, automatically generated\r
+# HEADERS and OBJS definitions, automatically generated from ../Makefile.am
@HEADERS_OBJS@\r
\r
openvpn : $(OBJS)\r
$(LINK32) @<<\r
- $(LINK32_FLAGS) $(LIB_DIRS) $(LIBS) $(OBJS)\r
+ $(LINK32_FLAGS) "/out:$(EXE)" $(LIB_DIRS) $(LIBS) $(OBJS)
<<\r
\r
clean :\r