makefiles for Windows
authorVictor Kirhenshtein <victor@netxms.org>
Sun, 5 Feb 2017 10:53:17 +0000 (12:53 +0200)
committerVictor Kirhenshtein <victor@netxms.org>
Sun, 5 Feb 2017 10:53:17 +0000 (12:53 +0200)
79 files changed:
.gitignore
Makefile.inc.w32
Makefile.w32 [new file with mode: 0644]
build/Makefile.w32 [new file with mode: 0644]
clean [deleted file]
src/Makefile.w32
src/agent/Makefile.am
src/agent/Makefile.w32 [new file with mode: 0644]
src/agent/core/Makefile.am
src/agent/core/Makefile.w32 [new file with mode: 0644]
src/agent/core/messages.rc [new file with mode: 0644]
src/agent/core/nxagentd.rc
src/agent/core/nxagentd.res [new file with mode: 0644]
src/agent/libnxagent/Makefile.am
src/agent/libnxagent/Makefile.w32 [new file with mode: 0644]
src/agent/nxsagent/Makefile.w32 [new file with mode: 0644]
src/agent/subagents/Makefile.am
src/agent/subagents/Makefile.w32 [new file with mode: 0644]
src/agent/subagents/db2/Makefile.am
src/agent/subagents/db2/Makefile.w32 [new file with mode: 0644]
src/agent/subagents/dbquery/Makefile.am
src/agent/subagents/dbquery/Makefile.w32 [new file with mode: 0644]
src/agent/subagents/devemu/Makefile.am
src/agent/subagents/devemu/Makefile.w32 [new file with mode: 0644]
src/agent/subagents/ecs/Makefile.am
src/agent/subagents/ecs/Makefile.w32 [new file with mode: 0644]
src/agent/subagents/filemgr/Makefile.am
src/agent/subagents/filemgr/Makefile.w32 [new file with mode: 0644]
src/agent/subagents/gps/Makefile.am
src/agent/subagents/gps/Makefile.w32 [new file with mode: 0644]
src/agent/subagents/informix/Makefile.am
src/agent/subagents/informix/Makefile.w32 [new file with mode: 0644]
src/agent/tools/Makefile.am
src/agent/tools/Makefile.w32 [new file with mode: 0644]
src/agent/tools/nxappget/Makefile.am
src/agent/tools/nxappget/Makefile.w32 [new file with mode: 0644]
src/agent/tools/nxapush/Makefile.am
src/agent/tools/nxapush/Makefile.w32 [new file with mode: 0644]
src/appagent/Makefile.am
src/appagent/Makefile.w32 [new file with mode: 0644]
src/db/Makefile.am
src/db/Makefile.w32 [new file with mode: 0644]
src/db/dbdrv/Makefile.am
src/db/dbdrv/Makefile.w32 [new file with mode: 0644]
src/db/dbdrv/mssql/Makefile.am
src/db/dbdrv/mssql/Makefile.w32 [new file with mode: 0644]
src/db/dbdrv/odbc/Makefile.am
src/db/dbdrv/odbc/Makefile.w32 [new file with mode: 0644]
src/db/dbdrv/sqlite/Makefile.am
src/db/dbdrv/sqlite/Makefile.w32 [new file with mode: 0644]
src/db/libnxdb/Makefile.am
src/db/libnxdb/Makefile.w32 [new file with mode: 0644]
src/jansson/Makefile.am
src/jansson/Makefile.w32 [new file with mode: 0644]
src/libnetxms/Makefile.w32
src/libnxlp/Makefile.am
src/libnxlp/Makefile.w32 [new file with mode: 0644]
src/libnxmap/Makefile.w32 [new file with mode: 0644]
src/libnxmb/Makefile.am
src/libnxmb/Makefile.w32 [new file with mode: 0644]
src/libnxsl/Makefile.w32 [new file with mode: 0644]
src/libpng/Makefile.w32 [new file with mode: 0644]
src/libstrophe/Makefile.am
src/libstrophe/Makefile.w32 [new file with mode: 0644]
src/libtre/Makefile.am
src/libtre/Makefile.w32 [new file with mode: 0644]
src/snmp/Makefile.am
src/snmp/Makefile.w32 [new file with mode: 0644]
src/snmp/libnxsnmp/Makefile.am
src/snmp/libnxsnmp/Makefile.w32 [new file with mode: 0644]
src/snmp/nxsnmpget/Makefile.am
src/snmp/nxsnmpget/Makefile.w32 [new file with mode: 0644]
src/snmp/nxsnmpset/Makefile.am
src/snmp/nxsnmpset/Makefile.w32 [new file with mode: 0644]
src/snmp/nxsnmpwalk/Makefile.am
src/snmp/nxsnmpwalk/Makefile.w32 [new file with mode: 0644]
src/sqlite/Makefile.am
src/sqlite/Makefile.w32 [new file with mode: 0644]
src/zlib/Makefile.w32 [new file with mode: 0644]

index 07f152f..aae6816 100644 (file)
@@ -37,6 +37,7 @@ target
 .idea
 
 /netxms-build-tag.h
+/build/netxms-build-tag.h
 /include/netxms-build-tag.h
 
 /netxms-*.tar.gz
index be97bd5..f598e44 100644 (file)
 # Common settings for Win32 builds
 
-CC=cl
-CXX=cl
-LD=link
-MAKE=nmake
+CC = cl
+CXX = cl
+LD = link
+PERL = perl
+LEX = flex
+YACC = bison
+MC = mc
 
 # Source base path
-#BASE_PATH := $(dir $(lastword $(MAKEFILE_LIST)))
+# Default location is C:\Source\NetXMS
+# It can be changed by setting NETXMS_BASE environment variable
+!ifndef NETXMS_BASE
+NETXMS_BASE = C:\Source\NetXMS
+!endif
 
 # Architecture
 !ifndef ARCH
-ARCH=x64
+ARCH = x64
 !endif
 
-!if "$(ARCH)"=="x64"
-WINDDK_ARCH=amd64
-WINSDK_LIB=Lib\x64
-WINSDK_BIN=Bin\x64
-OBJDIR=amd64
+!if "$(ARCH)" == "x64"
+WINDDK_ARCH = amd64
+WINSDK_LIB = Lib\x64
+WINSDK_BIN = Bin\x64
+VCBUILD_LIB = Lib\amd64
+OBJDIR = amd64
 !endif
 
-!if "$(ARCH)"=="x86"
-WINDDK_ARCH=i386
-WINSDK_LIB=Lib
-WINSDK_BIN=Bin
-OBJDIR=i386
+!if "$(ARCH)" == "x86"
+WINDDK_ARCH = i386
+WINSDK_LIB = Lib
+WINSDK_BIN = Bin
+VCBUILD_LIB = Lib
+OBJDIR = i386
 !endif
 
 # SDK locations
 #-include ${BASE_PATH}winsdk.inc
 
 !ifndef VCBUILD_BASE
-VCBUILD_BASE=C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC
+VCBUILD_BASE = C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC
 !endif
 !ifndef WINSDK_BASE
-WINSDK_BASE=C:\SDK\Windows 7 SDK
+WINSDK_BASE = C:\SDK\Windows 7 SDK
 !endif
 !ifndef WINDDK_BASE
-WINDDK_BASE=C:\SDK\WinDDK
+WINDDK_BASE = C:\SDK\WinDDK
 !endif
 !ifndef OPENSSL_BASE
-OPENSSL_BASE=C:\SDK\OpenSSL
+OPENSSL_BASE = C:\SDK\OpenSSL
+!endif
+
+# Binaries directory
+BINDIR = $(NETXMS_BASE)\bin\$(OBJDIR)
+
+# Output files
+!ifdef TARGET
+BINFILE = $(BINDIR)\$(TARGET)
 !endif
 
 # Common C/C++ compiler flags
-CPPFLAGS=$(CPPFLAGS) /O2 /Gd -I "$(BASE_PATH)include" -I "$(WINSDK_BASE)\include" -I "$(VCBUILD_BASE)\include" \
-   -I "$(OPENSSL_BASE)\$(ARCH)\include" \
-       -D_MT -DUNICODE
+CPPFLAGS = $(CPPFLAGS) /O2 /Gd /EHs- /GR- \
+   /I "$(NETXMS_BASE)\include" \
+   /I "$(NETXMS_BASE)\build" \
+   /I "$(WINSDK_BASE)\include" \
+   /I "$(VCBUILD_BASE)\include" \
+   /I "$(OPENSSL_BASE)\$(ARCH)\include" \
+       /D_MT /DUNICODE
        
 # Common linker flags
-!if "$(TYPE)"=="dll"
-IMPLIB=$(TARGET:.dll=.lib)
-LDFLAGS=$(LDFLAGS) -dll -implib:$(IMPLIB)
+!if "$(TYPE)" == "dll"
+CPPFLAGS = $(CPPFLAGS) /D_USRDLL
+IMPLIB = $(BINFILE:.dll=.lib)
+LDFLAGS = $(LDFLAGS) /DLL /IMPLIB:$(IMPLIB)
+!endif
+!if "$(TYPE)" == "ddr"
+CPPFLAGS = $(CPPFLAGS) /D_USRDLL
+LDFLAGS = $(LDFLAGS) /DLL
 !endif
-MANIFEST=$(TARGET).intermediate.manifest
-LDFLAGS=$(LDFLAGS) -subsystem:windows -machine:$(ARCH) -manifestfile:$(MANIFEST) -libpath:"$(OPENSSL_BASE)\$(ARCH)\lib" -libpath:"$(WINDDK_BASE)\lib\wnet\$(WINDDK_ARCH)" -libpath:"$(WINSDK_BASE)\$(WINSDK_LIB)"
+!if "$(TYPE)" == "nsm"
+CPPFLAGS = $(CPPFLAGS) /D_USRDLL
+LDFLAGS = $(LDFLAGS) /DLL
+!endif
+MANIFEST = $(TARGET).intermediate.manifest
+LDFLAGS = $(LDFLAGS) /SUBSYSTEM:CONSOLE /MACHINE:$(ARCH) /MANIFESTFILE:$(MANIFEST) \
+   /LIBPATH:"$(BINDIR)" \
+   /LIBPATH:"$(OPENSSL_BASE)\$(ARCH)\lib" \
+   /LIBPATH:"$(WINDDK_BASE)\lib\wnet\$(WINDDK_ARCH)" \
+   /LIBPATH:"$(WINSDK_BASE)\$(WINSDK_LIB)"  \
+   /LIBPATH:"$(VCBUILD_BASE)\$(VCBUILD_LIB)"
 
 # Common libraries
-LIBS=$(LIBS) ssleay32.lib libeay32.lib uuid.lib kernel32.lib user32.lib advapi32.lib shell32.lib
+LIBS = $(LIBS) ssleay32.lib libeay32.lib uuid.lib kernel32.lib user32.lib advapi32.lib shell32.lib
 
 # Prepare list of object files 
-__sources=$(SOURCES:.cpp=.obj)
-OBJ=$(__sources:.c=.obj)
+__sources = $(SOURCES:.cpp=.obj)
+OBJ = $(__sources:.c=.obj)
 
 # Source directory
-SRCDIR=$(MAKEDIR)
+SRCDIR = $(MAKEDIR)
 
-all: subdirs $(GENERATED) $(TARGET)
+all: Makefile.w32 subdirs $(GENERATED) $(BINFILE)
 
 # Build target
 !ifdef TARGET
 
-$(TARGET): objdir $(OBJ)
-   $(LD) $(LDFLAGS) /out:$(TARGET) $(OBJ) $(LIBS)
-       rm -f $(MANIFEST)
+$(BINFILE): objdir $(OBJ)
+   @if not exist $(BINDIR) mkdir $(BINDIR)
+   @echo "    LD " $(TARGET)
+   @$(LD) /NOLOGO $(LDFLAGS) /out:$(BINFILE) $(OBJ) $(LIBS)
+       @rm -f $(MANIFEST)
 
 .PHONY: objdir
 
@@ -82,27 +119,54 @@ objdir:
    @cd $(OBJDIR)
 
 {$(SRCDIR)}.c.obj:
-   $(CC) $(CPPFLAGS) $(CFLAGS) /c $< /Fo$@
+   @echo "    CC " $(<F)
+   @$(CC) /nologo $(CPPFLAGS) $(CFLAGS) /c $< /Fo$@ | tail -n +2
 
 {$(SRCDIR)}.cpp.obj:
-   $(CXX) $(CPPFLAGS) $(CXXFLAGS) /c $< /Fo$@
+   @echo "    CXX" $(<F)
+   @$(CXX) /nologo $(CPPFLAGS) $(CXXFLAGS) /c $< /Fo$@ | tail -n +2
+
+.rc.res:
+   @echo "    RC " $(<F)
+   @$(RC) /nologo /r /i "$(WINSDK_BASE)\include" /i "$(VCBUILD_BASE)\include" $<
+
+MSG00001.bin: messages.mc
+   @echo "    MC  messages.mc"
+   @$(MC) messages.mc
 
-messages.cpp: messages.mc
-       $(MC) $< -cpp
+messages.h: messages.mc
+   @echo "    MC  messages.mc"
+   @$(MC) messages.mc
 
 !endif
 
 # Clean
+.PHONY: clean
+
 clean:
-       rm -f $(OBJ) $(TARGET) $(GENERATED) $(EXTRA_CLEAN)
+   rm -rf $(OBJ) $(TARGET) $(OBJDIR) $(GENERATED) $(EXTRA_CLEAN)
+       @for %%s in ($(SUBDIRS)) do @( \
+               echo === Entering %%s === && \
+               cd %%s && \
+      @( \
+                       $(MAKE) /NOLOGO /F Makefile.w32 clean || \
+         exit 1 \
+      ) && \
+               echo === Leaving %%s === && \
+               cd .. \
+   )
 
 # Sub-directories building rules
 .PHONY: subdirs
 
 subdirs:
-   @for %%s in ($(SUBDIRS)) do @( \
-       echo === Entering %%s === && \
-      cd %%s && \
-          $(MAKE) /NOLOGO /F Makefile.w32 && \
-       echo === Leaving %%s === \
+       @for %%s in ($(SUBDIRS)) do @( \
+               echo === Entering %%s === && \
+               cd %%s && \
+      @( \
+                       $(MAKE) /NOLOGO /F Makefile.w32 || \
+         exit 1 \
+      ) && \
+               echo === Leaving %%s === && \
+               cd .. \
    )
diff --git a/Makefile.w32 b/Makefile.w32
new file mode 100644 (file)
index 0000000..e93edca
--- /dev/null
@@ -0,0 +1,3 @@
+SUBDIRS=build src
+
+!INCLUDE .\Makefile.inc.w32
diff --git a/build/Makefile.w32 b/build/Makefile.w32
new file mode 100644 (file)
index 0000000..9392e97
--- /dev/null
@@ -0,0 +1,10 @@
+GENERATED=netxms-build-tag.h
+
+!INCLUDE ..\Makefile.inc.w32
+
+$(GENERATED): tag
+
+.PHONY: tag
+
+tag:
+       $(PERL) updatetag.pl $(GENERATED)
diff --git a/clean b/clean
deleted file mode 100755 (executable)
index 082741b..0000000
--- a/clean
+++ /dev/null
@@ -1,3 +0,0 @@
-#!/bin/sh
-
-rm -f config.h config.log config.status stamp-h1
index faf511f..7f3d0ee 100644 (file)
@@ -1,3 +1,3 @@
-SUBDIRS=libexpat libnetxms
+SUBDIRS = jansson libexpat libtre sqlite zlib libnetxms libnxlp libnxmap libnxmb libstrophe db snmp appagent agent
 
 include ..\Makefile.inc.w32
index 9f8195a..1a570c4 100644 (file)
@@ -9,3 +9,5 @@
 # implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 
 SUBDIRS = libnxagent libnxappc libnxsd @AGENT_DIRS@ subagents core install tools
+
+EXTRA_DIST = Makefile.w32
diff --git a/src/agent/Makefile.w32 b/src/agent/Makefile.w32
new file mode 100644 (file)
index 0000000..d1d9074
--- /dev/null
@@ -0,0 +1,3 @@
+SUBDIRS = libnxagent core nxsagent subagents tools
+
+include ..\..\Makefile.inc.w32
index 13d3ca2..e0c5e58 100644 (file)
@@ -31,6 +31,7 @@ static_subagents.cpp: @top_srcdir@/config.h Makefile
        @top_builddir@/tools/create_ssa_list.sh "@STATIC_SUBAGENT_LIST@" > static_subagents.cpp
 
 EXTRA_DIST = \
+    Makefile.w32 \
     nxagentd.vcproj \
     messages.mc messages.h messages.c \
     nxagentd.rc \
diff --git a/src/agent/core/Makefile.w32 b/src/agent/core/Makefile.w32
new file mode 100644 (file)
index 0000000..c4a1db3
--- /dev/null
@@ -0,0 +1,17 @@
+TARGET = nxagentd.exe
+TYPE = exe
+SOURCES = \
+       actions.cpp appagent.cpp comm.cpp config.cpp \
+       ctrl.cpp datacoll.cpp dcsnmp.cpp dbupgrade.cpp dfile_info.cpp epp.cpp \
+       exec.cpp extagent.cpp getparam.cpp hddinfo.cpp localdb.cpp master.cpp \
+       nxagentd.cpp policy.cpp push.cpp register.cpp sa.cpp \
+       sd.cpp service.cpp session.cpp snmpproxy.cpp snmptrapproxy.cpp \
+       subagent.cpp sysinfo.cpp syslog.cpp \
+       tools.cpp trap.cpp tunnel.cpp upgrade.cpp watchdog.cpp win32.cpp
+GENERATED = messages.h MSG00001.bin nxagentd.res
+
+LIBS = libnxagent.lib appagent.lib libnxsnmp.lib libnxdb.lib libnetxms.lib ws2_32.lib
+         
+include ..\..\..\Makefile.inc.w32
+
+nxagentd.res: MSG00001.bin
diff --git a/src/agent/core/messages.rc b/src/agent/core/messages.rc
new file mode 100644 (file)
index 0000000..0abcb0f
--- /dev/null
@@ -0,0 +1,2 @@
+LANGUAGE 0x9,0x1
+1 11 "MSG00001.bin"
index 8df08b9..b7c9525 100644 (file)
@@ -7,7 +7,7 @@
 //
 // Generated from the TEXTINCLUDE 2 resource.
 //
-#include "afxres.h"
+#include <windows.h>
 
 /////////////////////////////////////////////////////////////////////////////
 #undef APSTUDIO_READONLY_SYMBOLS
diff --git a/src/agent/core/nxagentd.res b/src/agent/core/nxagentd.res
new file mode 100644 (file)
index 0000000..1241649
Binary files /dev/null and b/src/agent/core/nxagentd.res differ
index af4f029..f5ecd23 100644 (file)
@@ -7,4 +7,4 @@ libnxagent_la_CPPFLAGS=-I@top_srcdir@/include
 libnxagent_la_LDFLAGS = -version-info $(NETXMS_LIBRARY_VERSION)
 libnxagent_la_LIBADD = ../../db/libnxdb/libnxdb.la ../../libnetxms/libnetxms.la
 
-EXTRA_DIST = libnxagent.h libnxagent.vcproj
+EXTRA_DIST = Makefile.w32 libnxagent.h libnxagent.vcproj
diff --git a/src/agent/libnxagent/Makefile.w32 b/src/agent/libnxagent/Makefile.w32
new file mode 100644 (file)
index 0000000..29f5820
--- /dev/null
@@ -0,0 +1,8 @@
+TARGET = libnxagent.dll
+TYPE = dll
+SOURCES = bridge.cpp cmdexec.cpp main.cpp registry.cpp tools.cpp
+
+CPPFLAGS = /DLIBNXAGENT_EXPORTS
+LIBS = libnxdb.lib libnetxms.lib
+         
+include ..\..\..\Makefile.inc.w32
diff --git a/src/agent/nxsagent/Makefile.w32 b/src/agent/nxsagent/Makefile.w32
new file mode 100644 (file)
index 0000000..67f0a1c
--- /dev/null
@@ -0,0 +1,8 @@
+TARGET = nxsagent.exe
+TYPE = exe
+SOURCES = main.cpp png.cpp screenshot.cpp
+
+CPPFLAGS = /I$(NETXMS_BASE)\src\libpng
+LIBS = libnetxms.lib libpng.lib ws2_32.lib gdi32.lib wtsapi32.lib
+         
+include ..\..\..\Makefile.inc.w32
index 4c09f27..c698d69 100644 (file)
@@ -15,4 +15,4 @@
 # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
 
 SUBDIRS = dbquery filemgr gps winnt winperf wmi portCheck ping sms ups ecs logwatch devemu ${SUBAGENT_DIRS} 
-EXTRA_DIST = platform-subagent.sym subagent.sym
+EXTRA_DIST = platform-subagent.sym subagent.sym Makefile.w32
diff --git a/src/agent/subagents/Makefile.w32 b/src/agent/subagents/Makefile.w32
new file mode 100644 (file)
index 0000000..c7154e5
--- /dev/null
@@ -0,0 +1,3 @@
+SUBDIRS = db2 dbquery devemu ecs filemgr gps informix
+
+include ..\..\..\Makefile.inc.w32
index 9badf1c..86b229c 100644 (file)
@@ -6,7 +6,7 @@ db2_la_CPPFLAGS    = -I@top_srcdir@/include
 db2_la_LDFLAGS     = -module -avoid-version -export-symbols ../subagent.sym
 db2_la_LIBADD      = ../../libnxagent/libnxagent.la ../../../libnetxms/libnetxms.la ../../../db/libnxdb/libnxdb.la
 
-EXTRA_DIST         = db2_subagent.h db2dci.h db2.vcproj
+EXTRA_DIST         = db2_subagent.h db2dci.h db2.vcproj Makefile.w32
 
 if !STATIC_BUILD
 install-exec-hook:
diff --git a/src/agent/subagents/db2/Makefile.w32 b/src/agent/subagents/db2/Makefile.w32
new file mode 100644 (file)
index 0000000..eeabe5b
--- /dev/null
@@ -0,0 +1,7 @@
+TARGET = db2.nsm
+TYPE = nsm
+SOURCES = db2_subagent.cpp db2dci.cpp
+
+LIBS = libnxagent.lib libnxdb.lib libnetxms.lib
+         
+include ..\..\..\..\Makefile.inc.w32
index ce3a5ef..5d6ff2d 100644 (file)
@@ -6,7 +6,7 @@ dbquery_la_CPPFLAGS = -I@top_srcdir@/include
 dbquery_la_LDFLAGS = -module -avoid-version -export-symbols ../subagent.sym
 dbquery_la_LIBADD = ../../libnxagent/libnxagent.la ../../../libnetxms/libnetxms.la ../../../db/libnxdb/libnxdb.la
 
-EXTRA_DIST = dbquery.vcproj dbquery.h
+EXTRA_DIST = dbquery.vcproj dbquery.h Makefile.w32
 
 if !STATIC_BUILD
 install-exec-hook:
diff --git a/src/agent/subagents/dbquery/Makefile.w32 b/src/agent/subagents/dbquery/Makefile.w32
new file mode 100644 (file)
index 0000000..4891534
--- /dev/null
@@ -0,0 +1,7 @@
+TARGET = dbquery.nsm
+TYPE = nsm
+SOURCES = conn.cpp dbquery.cpp direct.cpp poll.cpp
+
+LIBS = libnxagent.lib libnxdb.lib libnetxms.lib
+         
+include ..\..\..\..\Makefile.inc.w32
index 3d86933..124169d 100644 (file)
@@ -6,7 +6,7 @@ devemu_la_CPPFLAGS=-I@top_srcdir@/include
 devemu_la_LDFLAGS = -module -avoid-version -export-symbols ../subagent.sym
 devemu_la_LIBADD = ../../libnxagent/libnxagent.la ../../../libnetxms/libnetxms.la
 
-EXTRA_DIST = devemu.vcproj
+EXTRA_DIST = devemu.vcproj Makefile.w32
 
 if !STATIC_BUILD
 install-exec-hook:
diff --git a/src/agent/subagents/devemu/Makefile.w32 b/src/agent/subagents/devemu/Makefile.w32
new file mode 100644 (file)
index 0000000..f480152
--- /dev/null
@@ -0,0 +1,7 @@
+TARGET = devemu.nsm
+TYPE = nsm
+SOURCES = devemu.cpp
+
+LIBS = libnxagent.lib libnetxms.lib ws2_32.lib
+         
+include ..\..\..\..\Makefile.inc.w32
index a19c254..1aa7656 100644 (file)
@@ -6,7 +6,7 @@ ecs_la_CPPFLAGS=-I@top_srcdir@/include
 ecs_la_LDFLAGS = -module -avoid-version -export-symbols ../subagent.sym
 ecs_la_LIBADD = ../../libnxagent/libnxagent.la ../../../libnetxms/libnetxms.la
 
-EXTRA_DIST = ecs.vcproj
+EXTRA_DIST = ecs.vcproj Makefile.w32
 
 if !STATIC_BUILD
 install-exec-hook:
diff --git a/src/agent/subagents/ecs/Makefile.w32 b/src/agent/subagents/ecs/Makefile.w32
new file mode 100644 (file)
index 0000000..545eee4
--- /dev/null
@@ -0,0 +1,7 @@
+TARGET = ecs.nsm
+TYPE = nsm
+SOURCES = ecs.cpp
+
+LIBS = libnxagent.lib libnetxms.lib ws2_32.lib
+         
+include ..\..\..\..\Makefile.inc.w32
index 1627f22..b66250e 100644 (file)
@@ -6,7 +6,7 @@ filemgr_la_CPPFLAGS=-I@top_srcdir@/include
 filemgr_la_LDFLAGS = -module -avoid-version -export-symbols ../subagent.sym
 filemgr_la_LIBADD = ../../libnxagent/libnxagent.la ../../../libnetxms/libnetxms.la
 
-EXTRA_DIST = filemgr.vcproj filemgr.h
+EXTRA_DIST = filemgr.vcproj filemgr.h Makefile.w32
 
 if !STATIC_BUILD
 install-exec-hook:
diff --git a/src/agent/subagents/filemgr/Makefile.w32 b/src/agent/subagents/filemgr/Makefile.w32
new file mode 100644 (file)
index 0000000..f29d52b
--- /dev/null
@@ -0,0 +1,7 @@
+TARGET = filemgr.nsm
+TYPE = nsm
+SOURCES = filemgr.cpp logmonitoring.cpp
+
+LIBS = libnxagent.lib libnetxms.lib
+         
+include ..\..\..\..\Makefile.inc.w32
index 70cdceb..8abab14 100644 (file)
@@ -6,7 +6,7 @@ gps_la_CPPFLAGS=-I@top_srcdir@/include
 gps_la_LDFLAGS = -module -avoid-version -export-symbols ../subagent.sym
 gps_la_LIBADD = ../../libnxagent/libnxagent.la ../../../libnetxms/libnetxms.la
 
-EXTRA_DIST = gps.vcproj nmea.h
+EXTRA_DIST = gps.vcproj nmea.h Makefile.w32
 
 if !STATIC_BUILD
 install-exec-hook:
diff --git a/src/agent/subagents/gps/Makefile.w32 b/src/agent/subagents/gps/Makefile.w32
new file mode 100644 (file)
index 0000000..1e66b2c
--- /dev/null
@@ -0,0 +1,7 @@
+TARGET = gps.nsm
+TYPE = nsm
+SOURCES = main.cpp nmea.c
+
+LIBS = libnxagent.lib libnetxms.lib
+         
+include ..\..\..\..\Makefile.inc.w32
index 5e4486f..5b1273c 100644 (file)
@@ -6,7 +6,7 @@ informix_la_CPPFLAGS=-I@top_srcdir@/include
 informix_la_LDFLAGS = -module -avoid-version -export-symbols ../subagent.sym
 informix_la_LIBADD = ../../libnxagent/libnxagent.la ../../../libnetxms/libnetxms.la ../../../db/libnxdb/libnxdb.la
 
-EXTRA_DIST = informix.vcproj informix_subagent.h
+EXTRA_DIST = informix.vcproj informix_subagent.h Makefile.w32
 
 if !STATIC_BUILD
 install-exec-hook:
diff --git a/src/agent/subagents/informix/Makefile.w32 b/src/agent/subagents/informix/Makefile.w32
new file mode 100644 (file)
index 0000000..8860da1
--- /dev/null
@@ -0,0 +1,7 @@
+TARGET = informix.nsm
+TYPE = nsm
+SOURCES = main.cpp
+
+LIBS = libnxagent.lib libnxdb.lib libnetxms.lib
+         
+include ..\..\..\..\Makefile.inc.w32
index 9419245..3cfeb2c 100644 (file)
@@ -9,3 +9,5 @@
 # implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 
 SUBDIRS = nxappget nxapush
+
+EXTRA_DIST = Makefile.w32
diff --git a/src/agent/tools/Makefile.w32 b/src/agent/tools/Makefile.w32
new file mode 100644 (file)
index 0000000..9f9cb5b
--- /dev/null
@@ -0,0 +1,3 @@
+SUBDIRS = nxappget nxapush
+
+include ..\..\..\Makefile.inc.w32
index 9472c40..a695cce 100644 (file)
@@ -11,4 +11,5 @@ endif
 endif
 
 EXTRA_DIST = \
+    Makefile.w32 \
     nxappget.vcproj
diff --git a/src/agent/tools/nxappget/Makefile.w32 b/src/agent/tools/nxappget/Makefile.w32
new file mode 100644 (file)
index 0000000..3bad13d
--- /dev/null
@@ -0,0 +1,7 @@
+TARGET = nxappget.exe
+TYPE = exe
+SOURCES = nxappget.cpp
+
+LIBS = appagent.lib libnetxms.lib
+         
+include ..\..\..\..\Makefile.inc.w32
index 0df57ca..9ae0c6d 100644 (file)
@@ -11,4 +11,5 @@ endif
 endif
 
 EXTRA_DIST = \
+    Makefile.w32 \
     nxapush.vcproj
diff --git a/src/agent/tools/nxapush/Makefile.w32 b/src/agent/tools/nxapush/Makefile.w32
new file mode 100644 (file)
index 0000000..5345f6b
--- /dev/null
@@ -0,0 +1,7 @@
+TARGET = nxapush.exe
+TYPE = exe
+SOURCES = nxapush.cpp
+
+LIBS = libnetxms.lib ws2_32.lib
+         
+include ..\..\..\..\Makefile.inc.w32
index 1ad9058..0cb4467 100644 (file)
@@ -7,4 +7,4 @@ libappagent_la_CPPFLAGS=-I@top_srcdir@/include
 libappagent_la_LDFLAGS = -version-info $(NETXMS_LIBRARY_VERSION)
 libappagent_la_LIBADD = @top_srcdir@/src/libnetxms/libnetxms.la
 
-EXTRA_DIST = appagent-internal.h appagent.vcproj
+EXTRA_DIST = Makefile.w32 appagent-internal.h appagent.vcproj
diff --git a/src/appagent/Makefile.w32 b/src/appagent/Makefile.w32
new file mode 100644 (file)
index 0000000..63d9794
--- /dev/null
@@ -0,0 +1,8 @@
+TARGET = appagent.dll
+TYPE = dll
+SOURCES = appagent.cpp client.cpp message.cpp tools.cpp
+
+CPPFLAGS = /DAPPAGENT_EXPORTS
+LIBS = libnetxms.lib
+         
+include ..\..\Makefile.inc.w32
index dc003cf..6f0e6d2 100644 (file)
@@ -9,3 +9,5 @@
 # implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 
 SUBDIRS = libnxdb dbdrv
+
+EXTRA_DIST = Makefile.w32
diff --git a/src/db/Makefile.w32 b/src/db/Makefile.w32
new file mode 100644 (file)
index 0000000..a8134ba
--- /dev/null
@@ -0,0 +1,3 @@
+SUBDIRS = libnxdb dbdrv
+
+include ..\..\Makefile.inc.w32
index 0a96c8c..cf630ab 100644 (file)
@@ -9,3 +9,5 @@
 # implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 
 SUBDIRS = @DB_DRIVERS@
+
+EXTRA_DIST = Makefile.w32
diff --git a/src/db/dbdrv/Makefile.w32 b/src/db/dbdrv/Makefile.w32
new file mode 100644 (file)
index 0000000..af0fc04
--- /dev/null
@@ -0,0 +1,3 @@
+SUBDIRS = odbc sqlite
+
+include ..\..\..\Makefile.inc.w32
index e4cf40c..c8c1158 100644 (file)
@@ -1,3 +1,4 @@
 EXTRA_DIST = \
+    Makefile.w32 \
     mssql.cpp mssqldrv.h \
     mssql.vcproj
diff --git a/src/db/dbdrv/mssql/Makefile.w32 b/src/db/dbdrv/mssql/Makefile.w32
new file mode 100644 (file)
index 0000000..27e935f
--- /dev/null
@@ -0,0 +1,7 @@
+TARGET = mssql.ddr
+TYPE = ddr
+SOURCES = mssql.cpp
+
+LIBS = libnetxms.lib odbc32.lib
+         
+include ..\..\..\..\Makefile.inc.w32
index d83f048..d3bac31 100644 (file)
@@ -6,7 +6,7 @@ odbc_la_CPPFLAGS=-I@top_srcdir@/include -I@top_srcdir@/src/server/include @ODBC_
 odbc_la_LDFLAGS = -module -avoid-version @ODBC_LDFLAGS@
 odbc_la_LIBADD = ../../../libnetxms/libnetxms.la @ODBC_LIBS@
 
-EXTRA_DIST = odbc.vcproj odbcdrv.h
+EXTRA_DIST = Makefile.w32 odbc.vcproj odbcdrv.h
 
 install-exec-hook:
        if test "x`uname -s`" = "xAIX" ; then OBJECT_MODE=@OBJECT_MODE@ $(AR) x $(DESTDIR)$(pkglibdir)/$(DRIVER).a $(DESTDIR)$(pkglibdir)/$(DRIVER).so ; rm -f $(DESTDIR)$(pkglibdir)/$(DRIVER).a ; fi
diff --git a/src/db/dbdrv/odbc/Makefile.w32 b/src/db/dbdrv/odbc/Makefile.w32
new file mode 100644 (file)
index 0000000..7907953
--- /dev/null
@@ -0,0 +1,7 @@
+TARGET = odbc.ddr
+TYPE = ddr
+SOURCES = odbc.cpp
+
+LIBS = libnetxms.lib odbc32.lib
+         
+include ..\..\..\..\Makefile.inc.w32
index 65ff932..e3a488f 100644 (file)
@@ -14,6 +14,7 @@ sqlite_la_LIBADD += -lsqlite3
 endif
 
 EXTRA_DIST = \
+       Makefile.w32 \
        sqlite.vcproj \
        sqlitedrv.h
 
diff --git a/src/db/dbdrv/sqlite/Makefile.w32 b/src/db/dbdrv/sqlite/Makefile.w32
new file mode 100644 (file)
index 0000000..f9753e5
--- /dev/null
@@ -0,0 +1,8 @@
+TARGET = sqlite.ddr
+TYPE = ddr
+SOURCES = sqlite.cpp
+
+CPPFLAGS = /I$(NETXMS_BASE)\src\sqlite
+LIBS = libnetxms.lib nxsqlite.lib
+         
+include ..\..\..\..\Makefile.inc.w32
index 6b1419e..5da01c1 100644 (file)
@@ -5,4 +5,5 @@ libnxdb_la_LDFLAGS = -version-info $(NETXMS_LIBRARY_VERSION)
 libnxdb_la_LIBADD = ../../libnetxms/libnetxms.la
 
 EXTRA_DIST = \
+       Makefile.w32 \
        libnxdb.vcproj libnxdbw.vcproj libnxdb.h
diff --git a/src/db/libnxdb/Makefile.w32 b/src/db/libnxdb/Makefile.w32
new file mode 100644 (file)
index 0000000..c40e9df
--- /dev/null
@@ -0,0 +1,8 @@
+TARGET = libnxdb.dll
+TYPE = dll
+SOURCES = dbcp.cpp drivers.cpp main.cpp session.cpp util.cpp
+
+CPPFLAGS = /DLIBNXDB_EXPORTS
+LIBS = libnetxms.lib ws2_32.lib
+         
+include ..\..\..\Makefile.inc.w32
index 8780f74..48e2282 100644 (file)
@@ -16,6 +16,7 @@ libnxjansson_la_LDFLAGS = -no-undefined -export-symbols-regex '^json_' -version-
 libnxjansson_la_LIBADD = -lm
 
 EXTRA_DIST = \
+       Makefile.w32 \
        hashtable.h \
        jansson.def \
        jansson.vcproj \
diff --git a/src/jansson/Makefile.w32 b/src/jansson/Makefile.w32
new file mode 100644 (file)
index 0000000..48be241
--- /dev/null
@@ -0,0 +1,19 @@
+TARGET = jansson.dll
+TYPE = dll
+SOURCES = \
+       dump.c \
+       error.c \
+       hashtable.c \
+       hashtable_seed.c \
+       load.c \
+       memory.c \
+       pack_unpack.c \
+       strbuffer.c \
+       strconv.c \
+       utf.c \
+       value.c
+
+CPPFLAGS = /I ..
+LDFLAGS = /DEF:..\jansson.def
+
+include ..\..\Makefile.inc.w32
index f9e6af9..ef3f2ac 100644 (file)
@@ -12,8 +12,7 @@ SOURCES = array.cpp base64.cpp bytestream.cpp cc_mb.cpp cc_ucs2.cpp \
        strtoll.c strtoull.c table.cpp threads.cpp timegm.c tools.cpp \
        tp.cpp unicode.cpp uuid.cpp wcstoll.c wcstoull.c xml.cpp
 
-CPPFLAGS = -I../libexpat/libexpat -I../zlib -DLIBNETXMS_EXPORTS
-LDFLAGS = -libpath:../libexpat/libexpat
-LIBS = libexpat.lib ws2_32.lib dbghelp.lib psapi.lib rpcrt4.lib iphlpapi.lib crypt32.lib
+CPPFLAGS = /I "$(NETXMS_BASE)\src\libexpat\libexpat" /I "$(NETXMS_BASE)\src\zlib" /DLIBNETXMS_EXPORTS
+LIBS = libexpat.lib libtre.lib nxzlib.lib ws2_32.lib dbghelp.lib psapi.lib rpcrt4.lib iphlpapi.lib crypt32.lib
          
 include ../../Makefile.inc.w32
index d3e3c74..9e88231 100644 (file)
@@ -17,6 +17,7 @@ libnxlp_la_LIBADD += @top_srcdir@/src/libtre/libnxtre.la
 endif
 
 EXTRA_DIST = \
+       Makefile.w32 \
        eventlog.cpp wevt.cpp \
        libnxlp.vcproj \
        libnxlp.h
diff --git a/src/libnxlp/Makefile.w32 b/src/libnxlp/Makefile.w32
new file mode 100644 (file)
index 0000000..c7c00a7
--- /dev/null
@@ -0,0 +1,8 @@
+TARGET = libnxlp.dll
+TYPE = dll
+SOURCES = eventlog.cpp file.cpp main.cpp parser.cpp rule.cpp wevt.cpp
+
+CPPFLAGS = /I$(NETXMS_BASE)\src\libexpat\libexpat /DLIBNXLP_EXPORTS
+LIBS = libnetxms.lib libexpat.lib libtre.lib
+         
+include ..\..\Makefile.inc.w32
diff --git a/src/libnxmap/Makefile.w32 b/src/libnxmap/Makefile.w32
new file mode 100644 (file)
index 0000000..dc373ce
--- /dev/null
@@ -0,0 +1,8 @@
+TARGET=libnxmap.dll
+TYPE=dll
+SOURCES=element.cpp link.cpp main.cpp objlist.cpp
+
+CPPFLAGS=/DLIBNXMAP_EXPORTS
+LIBS=libnetxms.lib
+         
+include ../../Makefile.inc.w32
index 2c8558e..45de45f 100644 (file)
@@ -7,7 +7,7 @@ libnxmb_la_CPPFLAGS=-I@top_srcdir@/include
 libnxmb_la_LDFLAGS = -version-info $(NETXMS_LIBRARY_VERSION)
 libnxmb_la_LIBADD = @top_srcdir@/src/libnetxms/libnetxms.la
 
-
 EXTRA_DIST = \
+       Makefile.w32 \
        libnxmb.vcproj \
        libnxmb.h
diff --git a/src/libnxmb/Makefile.w32 b/src/libnxmb/Makefile.w32
new file mode 100644 (file)
index 0000000..628b93a
--- /dev/null
@@ -0,0 +1,8 @@
+TARGET = libnxmb.dll
+TYPE = dll
+SOURCES = dispatcher.cpp filter.cpp main.cpp message.cpp subscriber.cpp
+
+CPPFLAGS = /DLIBNXMB_EXPORTS
+LIBS = libnetxms.lib
+         
+include ../../Makefile.inc.w32
diff --git a/src/libnxsl/Makefile.w32 b/src/libnxsl/Makefile.w32
new file mode 100644 (file)
index 0000000..5ec60b3
--- /dev/null
@@ -0,0 +1,21 @@
+TARGET=libnxsl.dll
+TYPE=dll
+SOURCES=lex.parser.cpp parser.tab.cpp \
+     array.cpp class.cpp compiler.cpp env.cpp functions.cpp \
+     geolocation.cpp hashmap.cpp instruction.cpp iterator.cpp \
+     lexer.cpp library.cpp main.cpp network.cpp program.cpp \
+     selectors.cpp stack.cpp storage.cpp table.cpp value.cpp \
+     variable.cpp vm.cpp
+
+CPPFLAGS = /DLIBNXSL_EXPORTS
+LIBS = libnetxms.lib libtre.lib
+         
+include ../../Makefile.inc.w32
+
+lex.parser.cpp: ..\parser.l ..\parser.tab.cpp ..\parser.tab.hpp
+       $(LEX) -B -f -8 -o..\lex.parser.cpp ..\parser.l
+
+..\parser.tab.hpp: ..\parser.tab.cpp
+
+..\parser.tab.cpp: ..\parser.y
+       $(YACC) -b parser -o parser.tab.cpp -d -t -v parser.y
diff --git a/src/libpng/Makefile.w32 b/src/libpng/Makefile.w32
new file mode 100644 (file)
index 0000000..07ef589
--- /dev/null
@@ -0,0 +1,10 @@
+TARGET = libpng.dll
+TYPE = dll
+SOURCES = png.c pngerror.c pngget.c pngmem.c pngpread.c pngread.c \
+          pngrio.c pngrtran.c pngrutil.c pngset.c pngtrans.c \
+          pngwio.c pngwrite.c pngwtran.c pngwutil.c 
+
+CPPFLAGS = /I "$(NETXMS_BASE)\src\zlib" /DLIBPNG_EXPORTS /DPNG_BUILD_DLL
+LIBS = nxzlib.lib
+
+include ..\..\Makefile.inc.w32
index a4bef31..087c5ce 100644 (file)
@@ -11,6 +11,7 @@ libstrophe_la_LIBADD += ../libexpat/libexpat/libnxexpat.la
 endif
 
 EXTRA_DIST = \
+       Makefile.w32 \
        GPL-LICENSE.txt LICENSE.txt MIT-LICENSE.txt \
        libstrophe.vcproj \
        common.h \
diff --git a/src/libstrophe/Makefile.w32 b/src/libstrophe/Makefile.w32
new file mode 100644 (file)
index 0000000..a404f46
--- /dev/null
@@ -0,0 +1,10 @@
+TARGET = libstrophe.dll
+TYPE = dll
+SOURCES = auth.c conn.c ctx.c event.c handler.c hash.c jid.c \
+       md5.c parser_expat.c sasl.c snprintf.c sock.c \
+       stanza.c tls_openssl.c util.c
+
+CPPFLAGS = /I$(NETXMS_BASE)\src\libexpat\libexpat /DLIBSTROPHE_EXPORTS
+LIBS = libexpat.lib ws2_32.lib
+         
+include ../../Makefile.inc.w32
index 20eca8c..2166f8e 100644 (file)
@@ -35,6 +35,7 @@ EXTRA_DIST = \
        LICENSE \
        README \
        THANKS \
+       Makefile.w32 \
        libtre.def \
        libtre.vcproj \
        windll.cpp \
diff --git a/src/libtre/Makefile.w32 b/src/libtre/Makefile.w32
new file mode 100644 (file)
index 0000000..a3b33ae
--- /dev/null
@@ -0,0 +1,20 @@
+TARGET = libtre.dll
+TYPE = dll
+SOURCES = \
+       tre-ast.c               \
+       tre-compile.c           \
+       tre-match-approx.c      \
+       tre-match-backtrack.c   \
+       tre-match-parallel.c    \
+       tre-mem.c               \
+       tre-parse.c             \
+       tre-stack.c             \
+       regcomp.c               \
+       regexec.c               \
+       regerror.c              \
+       windll.cpp
+
+CPPFLAGS = /I.. /I..\win32 /DLIBTRE_EXPORTS /DHAVE_CONFIG_H
+LDFLAGS = /DEF:..\libtre.def
+
+!include ..\..\Makefile.inc.w32
index 6ade05a..d1ea09a 100644 (file)
@@ -9,3 +9,5 @@
 # implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 
 SUBDIRS = libnxsnmp nxmibc nxsnmpget nxsnmpset nxsnmpwalk
+
+EXTRA_DIST = Makefile.w32
diff --git a/src/snmp/Makefile.w32 b/src/snmp/Makefile.w32
new file mode 100644 (file)
index 0000000..b9b3de7
--- /dev/null
@@ -0,0 +1,3 @@
+SUBDIRS = libnxsnmp nxsnmpget nxsnmpset nxsnmpwalk
+
+include ..\..\Makefile.inc.w32
index f5b2a8d..54268c4 100644 (file)
@@ -15,5 +15,6 @@ libnxsnmp_la_LIBADD += ../../zlib/libnxzlib.la
 endif
 
 EXTRA_DIST = \
+       Makefile.w32 \
        libnxsnmp.vcproj \
        libnxsnmp.h
diff --git a/src/snmp/libnxsnmp/Makefile.w32 b/src/snmp/libnxsnmp/Makefile.w32
new file mode 100644 (file)
index 0000000..fb862a2
--- /dev/null
@@ -0,0 +1,10 @@
+TARGET = libnxsnmp.dll
+TYPE = dll
+SOURCES = ber.cpp engine.cpp main.cpp mib.cpp oid.cpp pdu.cpp \
+          security.cpp snapshot.cpp transport.cpp util.cpp \
+          variable.cpp zfile.cpp
+
+CPPFLAGS = /I$(NETXMS_BASE)\src\zlib /DLIBNXSNMP_EXPORTS
+LIBS = libnetxms.lib nxzlib.lib ws2_32.lib
+         
+include ..\..\..\Makefile.inc.w32
index 2327351..426fec5 100644 (file)
@@ -4,4 +4,5 @@ nxsnmpget_CPPFLAGS=-I@top_srcdir@/include -I@top_srcdir@/src/server/include
 nxsnmpget_LDADD = ../../libnetxms/libnetxms.la ../libnxsnmp/libnxsnmp.la
 
 EXTRA_DIST = \
+       Makefile.w32 \
        nxsnmpget.vcproj
diff --git a/src/snmp/nxsnmpget/Makefile.w32 b/src/snmp/nxsnmpget/Makefile.w32
new file mode 100644 (file)
index 0000000..7f73a60
--- /dev/null
@@ -0,0 +1,7 @@
+TARGET = nxsnmpget.exe
+TYPE = exe
+SOURCES = nxsnmpget.cpp
+
+LIBS = libnetxms.lib libnxsnmp.lib ws2_32.lib
+         
+include ..\..\..\Makefile.inc.w32
index 435f9ad..7e506e0 100644 (file)
@@ -4,4 +4,5 @@ nxsnmpset_CPPFLAGS=-I@top_srcdir@/include -I@top_srcdir@/src/server/include
 nxsnmpset_LDADD = ../../libnetxms/libnetxms.la ../libnxsnmp/libnxsnmp.la
 
 EXTRA_DIST = \
+       Makefile.w32 \
        nxsnmpset.vcproj
diff --git a/src/snmp/nxsnmpset/Makefile.w32 b/src/snmp/nxsnmpset/Makefile.w32
new file mode 100644 (file)
index 0000000..298cf05
--- /dev/null
@@ -0,0 +1,7 @@
+TARGET = nxsnmpset.exe
+TYPE = exe
+SOURCES = nxsnmpset.cpp
+
+LIBS = libnetxms.lib libnxsnmp.lib ws2_32.lib
+         
+include ..\..\..\Makefile.inc.w32
index d0e6fcf..593f32c 100644 (file)
@@ -4,4 +4,5 @@ nxsnmpwalk_CPPFLAGS=-I@top_srcdir@/include -I@top_srcdir@/src/server/include
 nxsnmpwalk_LDADD = ../../libnetxms/libnetxms.la ../libnxsnmp/libnxsnmp.la
 
 EXTRA_DIST = \
+       Makefile.w32 \
        nxsnmpwalk.vcproj
diff --git a/src/snmp/nxsnmpwalk/Makefile.w32 b/src/snmp/nxsnmpwalk/Makefile.w32
new file mode 100644 (file)
index 0000000..8378ed7
--- /dev/null
@@ -0,0 +1,7 @@
+TARGET = nxsnmpwalk.exe
+TYPE = exe
+SOURCES = nxsnmpwalk.cpp
+
+LIBS = libnetxms.lib libnxsnmp.lib ws2_32.lib
+         
+include ..\..\..\Makefile.inc.w32
index 2b9a94d..38e5001 100644 (file)
@@ -5,4 +5,4 @@ libnxsqlite_la_SOURCES = $(SOURCES)
 libnxsqlite_la_CPPFLAGS=-I@top_srcdir@/include
 libnxsqlite_la_LDFLAGS = -version-info $(NETXMS_LIBRARY_VERSION)
 
-EXTRA_DIST = sqlite3.h sqlite3ext.h dllmain.c nxsqlite.vcproj
+EXTRA_DIST = Makefile.w32 sqlite3.h sqlite3ext.h dllmain.c nxsqlite.vcproj
diff --git a/src/sqlite/Makefile.w32 b/src/sqlite/Makefile.w32
new file mode 100644 (file)
index 0000000..413a0df
--- /dev/null
@@ -0,0 +1,5 @@
+TARGET = nxsqlite.dll
+TYPE = dll
+SOURCES= dllmain.c sqlite3.c
+
+include ..\..\Makefile.inc.w32
diff --git a/src/zlib/Makefile.w32 b/src/zlib/Makefile.w32
new file mode 100644 (file)
index 0000000..701e2f2
--- /dev/null
@@ -0,0 +1,20 @@
+TARGET = nxzlib.dll
+TYPE = dll
+SOURCES= \
+       adler32.c \
+       compress.c \
+       crc32.c \
+       deflate.c \
+       gzio.c \
+       infback.c \
+       inffast.c \
+       inflate.c \
+       inftrees.c \
+       trees.c \
+       uncompr.c \
+       zutil.c
+
+CPPFLAGS = /I ..
+LDFLAGS = /DEF:..\nxzlib.def
+
+!include ..\..\Makefile.inc.w32