summaryrefslogtreecommitdiff
path: root/win32/Makefile.msvc
diff options
context:
space:
mode:
authorDaniel Veillard <veillard@src.gnome.org>2005-01-30 19:02:09 +0000
committerDaniel Veillard <veillard@src.gnome.org>2005-01-30 19:02:09 +0000
commite04fbb1e277d6650edf52bce332676d1999e6789 (patch)
treee6b8f9758ca2fd3cf0dd8a8c5770636e23c2c278 /win32/Makefile.msvc
parentcea555bf1eb259d9fc3d28c212d212fafa96caab (diff)
downloadlibxslt-e04fbb1e277d6650edf52bce332676d1999e6789.tar.gz
libxslt-e04fbb1e277d6650edf52bce332676d1999e6789.tar.bz2
libxslt-e04fbb1e277d6650edf52bce332676d1999e6789.zip
applied plugin patch for Windows by Joel Reed Daniel
* tests/plugins/testplugin.c win32/Makefile.msvc win32/configure.js: applied plugin patch for Windows by Joel Reed Daniel
Diffstat (limited to 'win32/Makefile.msvc')
-rw-r--r--win32/Makefile.msvc32
1 files changed, 32 insertions, 0 deletions
diff --git a/win32/Makefile.msvc b/win32/Makefile.msvc
index cf40a8b3..1ea64f0b 100644
--- a/win32/Makefile.msvc
+++ b/win32/Makefile.msvc
@@ -329,6 +329,38 @@ APPLIBS = $(LIBS) libxml2.lib
# Builds xsltproc and friends. Uses the implicit rule for commands.
$(UTILS) : $(UTILS_INTDIR) $(BINDIR) libxslt libxslta libexslt libexslta
+# plugins only work with non-static builds currently.
+!if "$(STATIC)" == "0"
+
+TESTPLUGIN_SRCDIR = $(BASEDIR)\tests\plugins
+TESTPLUGIN_DIR = $(TESTPLUGIN_SRCDIR)\plugin
+TESTPLUGIN_SO = xmlsoft_org_xslt_testplugin.dll
+TESTPLUGIN_OBJS = $(TESTPLUGIN_DIR)\testplugin.obj
+
+testplugin:
+ if exist $(TESTPLUGIN_DIR) rmdir /S /Q $(TESTPLUGIN_DIR)
+ $(MAKE) $(TESTPLUGIN_DIR)\$(TESTPLUGIN_SO)
+
+$(TESTPLUGIN_DIR) :
+ if not exist $(TESTPLUGIN_DIR) mkdir $(TESTPLUGIN_DIR)
+
+{$(TESTPLUGIN_SRCDIR)}.c{$(TESTPLUGIN_DIR)}.obj::
+ $(CC) $(CFLAGS) /Fo$(TESTPLUGIN_DIR)\ /c $<
+
+# Creates the testplugin archive.
+$(TESTPLUGIN_DIR)\$(TESTPLUGIN_SO) : $(TESTPLUGIN_DIR) $(TESTPLUGIN_OBJS) libxslt
+ $(LD) $(LDFLAGS) /DLL $(XSLT_IMP) $(APPLIBS) $(LIBS)\
+ /OUT:$(TESTPLUGIN_DIR)\$(TESTPLUGIN_SO) \
+ $(TESTPLUGIN_OBJS)
+
+!else
+
+testplugin:
+ @echo "plugins are disabled with static=yes"
+
+!endif
+
+
# Source dependences should be autogenerated somehow here, but how to
# do it? I have no clue.