[Commits] (vajda) libxml2 now part of new build on windows
commits at osafoundation.org
commits at osafoundation.org
Thu Mar 18 17:16:13 PST 2004
Commit by: vajda
Modified files:
external/persistence/libxml2/Makefile 1.4 1.5
external/persistence/libxml2/patches 1.1 1.2
external/persistence/libxml2/win32/winSetup.py.in None 1.1
Log message:
libxml2 now part of new build on windows
ViewCVS links:
http://cvs.osafoundation.org/index.cgi/external/persistence/libxml2/Makefile.diff?r1=text&tr1=1.4&r2=text&tr2=1.5
http://cvs.osafoundation.org/index.cgi/external/persistence/libxml2/patches.diff?r1=text&tr1=1.1&r2=text&tr2=1.2
http://cvs.osafoundation.org/index.cgi/external/persistence/libxml2/win32/winSetup.py.in?rev=1.1&content-type=text/vnd.viewcvs-markup
Index: external/persistence/libxml2/patches
diff -u external/persistence/libxml2/patches:1.1 external/persistence/libxml2/patches:1.2
--- external/persistence/libxml2/patches:1.1 Mon Mar 15 12:35:32 2004
+++ external/persistence/libxml2/patches Thu Mar 18 17:15:42 2004
@@ -138,3 +138,112 @@
else
if test -x "$with_python"
then
+--- libxml2-2.6.3/win32/configure.js 2003-12-02 02:25:40.000000000 -0800
++++ libxml2-2.6.3-patched/win32/configure.js 2003-12-12 15:49:02.000000000 -0800
+@@ -53,6 +53,7 @@
+ var withSax1 = true;
+ var withLegacy = true;
+ var withOutput = true;
++var withPattern = false;
+ var withPython = false;
+ /* Win32 build options. */
+ var dirSep = "\\";
+@@ -158,17 +159,17 @@
+ /* Discovers the version we are working with by reading the apropriate
+ configuration file. Despite its name, this also writes the configuration
+ file included by our makefile. */
+-function discoverVersion()
++function discoverVersion(build_version)
+ {
+ var fso, cf, vf, ln, s;
+ fso = new ActiveXObject("Scripting.FileSystemObject");
+ cf = fso.OpenTextFile(configFile, 1);
+ if (compiler == "msvc")
+- versionFile = ".\\config.msvc";
++ versionFile = build_version + ".\\config.msvc";
+ else if (compiler == "mingw")
+- versionFile = ".\\config.mingw";
++ versionFile = build_version + ".\\config.mingw";
+ else if (compiler == "bcb")
+- versionFile = ".\\config.bcb";
++ versionFile = build_version + ".\\config.bcb";
+ vf = fso.CreateTextFile(versionFile, true);
+ vf.WriteLine("# " + versionFile);
+ vf.WriteLine("# This file is generated automatically by " + WScript.ScriptName + ".");
+@@ -314,6 +315,8 @@
+ of.WriteLine(s.replace(/\@WITH_LEGACY\@/, withLegacy? "1" : "0"));
+ } else if (s.search(/\@WITH_OUTPUT\@/) != -1) {
+ of.WriteLine(s.replace(/\@WITH_OUTPUT\@/, withOutput? "1" : "0"));
++ } else if (s.search(/\@WITH_PATTERN\@/) != -1) {
++ of.WriteLine(s.replace(/\@WITH_PATTERN\@/, withPattern? "1" : "0"));
+ } else
+ of.WriteLine(ln);
+ }
+@@ -323,8 +326,8 @@
+ /* Configures Python bindings. Otherwise identical to the above */
+ function configureLibxmlPy()
+ {
+- var pyOptsFileIn = srcDirXml + "\\python\\setup.py.in";
+- var pyOptsFile = srcDirXml + "\\python\\setup.py";
++ var pyOptsFileIn = srcDirXml + "\\python\\winSetup.py.in";
++ var pyOptsFile = srcDirXml + "\\python\\winSetup.py";
+ var fso, ofi, of, ln, s;
+ fso = new ActiveXObject("Scripting.FileSystemObject");
+ ofi = fso.OpenTextFile(pyOptsFileIn, 1);
+@@ -532,7 +535,7 @@
+ buildSoPrefix = "$(PREFIX)" + dirSep + "lib";
+
+ // Discover the version.
+-discoverVersion();
++discoverVersion(buildDebug ? "debug" : "release");
+ if (error != 0) {
+ WScript.Echo("Version discovery failed, aborting.");
+ WScript.Quit(error);
+--- libxml2-2.6.3/win32/Makefile.msvc 2003-11-28 23:58:21.000000000 -0800
++++ libxml2-2.6.3-patched/win32/Makefile.msvc 2004-01-28 18:02:11.000000000 -0800
+@@ -15,7 +15,9 @@
+ # There should never be a need to modify anything below this line.
+ # ----------------------------------------------------------------
+
+-AUTOCONF = .\config.msvc
++BUILD_VERSION=.
++
++AUTOCONF = $(BUILD_VERSION)\config.msvc
+ !include $(AUTOCONF)
+
+ # Names of various input and output components.
+@@ -27,10 +29,10 @@
+ XML_A = $(XML_BASENAME)_a.lib
+
+ # Place where we let the compiler put its output.
+-BINDIR = bin.msvc
+-XML_INTDIR = int.msvc
+-XML_INTDIR_A = int.a.msvc
+-UTILS_INTDIR = int.utils.msvc
++BINDIR = $(BUILD_VERSION)\bin.msvc
++XML_INTDIR = $(BUILD_VERSION)\int.msvc
++XML_INTDIR_A = $(BUILD_VERSION)\int.a.msvc
++UTILS_INTDIR = $(BUILD_VERSION)\int.utils.msvc
+
+ # The preprocessor and its options.
+ CPP = cl.exe /EP
+@@ -39,6 +41,10 @@
+ CPPFLAGS = $(CPPFLAGS) /D "_REENTRANT"
+ !endif
+
++!if "$(DEBUG)" == "1"
++CRUNTIME = $(CRUNTIME)d
++!endif
++
+ # The compiler and its options.
+ CC = cl.exe
+ CFLAGS = /nologo /D "WIN32" /D "_WINDOWS" /D "_MBCS" /W1 $(CRUNTIME)
+@@ -217,7 +223,7 @@
+ copy $(BINDIR)\$(XML_A) $(LIBPREFIX)
+ copy $(BINDIR)\$(XML_IMP) $(LIBPREFIX)
+ copy $(BINDIR)\*.exe $(BINPREFIX)
+- -copy $(BINDIR)\*.pdb $(BINPREFIX)
++ if exist $(BINDIR)\*.pdb copy $(BINDIR)\*.pdb $(BINPREFIX)
+
+ # This is a target for me, to make a binary distribution. Not for the public use,
+ # keep your hands off :-)
Index: external/persistence/libxml2/Makefile
diff -u external/persistence/libxml2/Makefile:1.4 external/persistence/libxml2/Makefile:1.5
--- external/persistence/libxml2/Makefile:1.4 Thu Mar 18 10:03:00 2004
+++ external/persistence/libxml2/Makefile Thu Mar 18 17:15:42 2004
@@ -5,23 +5,61 @@
include $(BUILD_ROOT)/Makefile.inc
+ifeq ($(OS),Darwin)
+WP=$(PREFIX)/$(FRAMEWORK)
+else
+WP=$(PREFIX)
+endif
+
+ifeq ($(OS),Cygwin)
+
ifeq ($(DEBUG),1)
-CONF_DBG=--enable-debug
+CONF_DBG=debug=yes
else
CONF_DBG=
endif
-ifeq ($(OS),Darwin)
-WP=$(PREFIX)/$(FRAMEWORK)
+BUILD=win32/$(SNAP)
+
+$(SRC)/$(BUILD)/config.msvc: apply
+ mkdir -p $(SRC)/$(BUILD)
+ cp -p win32/winSetup.py.in $(SRC)/python
+ cd $(SRC)/win32; \
+ cscript //E:JScript configure.js prefix=$(SNAP) $(CONF_DBG) \
+ python=yes iconv=no iso8859x=yes
+
+compile: $(SRC)/$(BUILD)/config.msvc
+ cd $(SRC)/win32; MAKEFLAGS=; \
+ nmake -nologo -f Makefile.msvc BUILD_VERSION=$(SNAP) install
+
+py:
+ cd $(SRC)/python; \
+ $(PYTHON) winSetup.py build --build-base=build_$(SNAP) $(DIST_DBG) \
+ install --force
+
+build: compile py
+
+clean:
+ cd $(SRC)/win32; rm -rf $(SNAP)
+ cd $(SRC)/python; rm -rf build_$(SNAP)
+
+snap:
+ cd $(BUILD_ROOT); \
+ tar -cvzf $(LIBXML2)/$(SNAP).tar.gz \
+ $(SNAP)/$(SITE)/libxml2*
+
else
-WP=$(PREFIX)
+
+ifeq ($(DEBUG),1)
+CONF_DBG=--enable-debug
+else
+CONF_DBG=
endif
BUILD=build_$(SNAP)
-$(SRC)/$(BUILD)/Makefile: patches
- patch -Nup0 < patches; echo ok; \
+$(SRC)/$(BUILD)/Makefile: apply
cd $(SRC); mkdir -p $(BUILD); cd $(BUILD); \
../configure --prefix=$(PREFIX) \
--srcdir=$(SRC) \
@@ -31,9 +69,6 @@
build: $(SRC)/$(BUILD)/Makefile
cd $(SRC)/$(BUILD); $(MAKE); $(MAKE) install
-expand: libxml2-$(VERSION).tar.gz
- tar xvzf libxml2-$(VERSION).tar.gz
-
snap:
cd $(BUILD_ROOT); \
tar -cvzf $(LIBXML2)/$(SNAP).tar.gz \
@@ -42,3 +77,11 @@
clean:
cd $(SRC); rm -rf $(BUILD)
+
+endif
+
+apply: patches
+ patch -Nup0 < patches; echo ok
+
+expand: libxml2-$(VERSION).tar.gz
+ tar xvzf libxml2-$(VERSION).tar.gz
More information about the Commits
mailing list