summaryrefslogtreecommitdiff
path: root/redland
diff options
context:
space:
mode:
Diffstat (limited to 'redland')
-rw-r--r--redland/LICENSE.txt11
-rw-r--r--redland/README38
-rw-r--r--redland/prj/build.lst5
-rw-r--r--redland/prj/d.lst19
-rw-r--r--redland/raptor/makefile.mk169
-rw-r--r--redland/raptor/raptor-1.4.18.patch.autotools46
-rw-r--r--redland/raptor/raptor-1.4.18.patch.dmake124
-rw-r--r--redland/raptor/raptor-1.4.18.patch.legal18
-rw-r--r--redland/raptor/raptor-1.4.18.patch.mingw30
-rw-r--r--redland/raptor/raptor-1.4.18.patch.ooo_build43
-rw-r--r--redland/raptor/raptor-1.4.18.patch.win3278
-rw-r--r--redland/raptor/raptor-aix.patch21
-rw-r--r--redland/raptor/raptor2.map294
-rw-r--r--redland/rasqal/makefile.mk162
-rw-r--r--redland/rasqal/rasqal-0.9.16.patch.autotools38
-rw-r--r--redland/rasqal/rasqal-0.9.16.patch.dmake98
-rw-r--r--redland/rasqal/rasqal-0.9.16.patch.legal18
-rw-r--r--redland/rasqal/rasqal-0.9.16.patch.ooo_build56
-rw-r--r--redland/rasqal/rasqal-0.9.16.patch.win3243
-rw-r--r--redland/rasqal/rasqal-aix.patch44
-rw-r--r--redland/rasqal/rasqal2.map194
-rw-r--r--redland/redland/makefile.mk163
-rw-r--r--redland/redland/redland-1.0.8.patch.autotools58
-rw-r--r--redland/redland/redland-1.0.8.patch.dmake115
-rw-r--r--redland/redland/redland-1.0.8.patch.legal54
-rw-r--r--redland/redland/redland-1.0.8.patch.ooo_build22
-rw-r--r--redland/redland/redland-1.0.8.patch.win32154
-rw-r--r--redland/redland/redland-aix.patch21
-rw-r--r--redland/redland/redland2.map316
-rw-r--r--redland/redlandversion.mk32
30 files changed, 2484 insertions, 0 deletions
diff --git a/redland/LICENSE.txt b/redland/LICENSE.txt
new file mode 100644
index 000000000000..a3a5fa8901e5
--- /dev/null
+++ b/redland/LICENSE.txt
@@ -0,0 +1,11 @@
+
+LGPL Disclaimer
+
+For the avoidance of doubt, except that if any license choice other
+than GPL or LGPL is available it will apply instead, Sun elects to
+use only the Lesser General Public License version 2.1 (LGPLv2) at
+this time for any software where a choice of LGPL license versions
+is made available with the language indicating that LGPLv2.1 or any
+later version may be used, or where a choice of which version of the
+LGPL is applied is otherwise unspecified.
+
diff --git a/redland/README b/redland/README
new file mode 100644
index 000000000000..87299ebf1fd4
--- /dev/null
+++ b/redland/README
@@ -0,0 +1,38 @@
+Redland RDF library (librdf)
+
+Module: external/redland
+
+Upstream URL: http://librdf.org/
+
+License: Triple-licensed: LGPL v2+/GPL v2+/Apache v2
+ Note that Sun distributes this software only under LGPL v2
+ (see LICENSE.txt)
+
+Description:
+This module contains the third-party Redland RDF / librdf library, which
+is needed to support data in RDF (Resource Description Framework) format.
+It consists of 3 parts:
+- raptor: parsers and serializers for numerous RDF file formats
+- rasqal: query engine which supports SPARQL queries
+- redland: librdf integrates raptor and rasqal, and provides numerous storage
+ engines for storing RDF graphs (in memory, SQL, ...)
+
+Libraries: libraptor, librasqal, librdf
+
+Patches:
+There are several patches, most of which contain only hacks to get it to
+build with OOo build system.
+There used to be also 3 patches here that fix bugs in redland and ought to be
+of general interest:
+- redland-1.0.8.patch.free_null:
+ redland destructor functions don't check if argument is NULL
+- redland-1.0.8.patch.storage_hashes_context_serialize_get_statement:
+ hashes storage: the function to create statements during serialization does
+ not fill in the context propery (i.e. context is NULL)
+- redland-1.0.8.patch.storage_hashes_list_duplicates:
+ hashes, list storage: if contexts are enabled, then it is possible to add
+ duplicate statements
+Attempts to upstream these patches failed for reasons upstream kept to
+themselves. Now these patches are replaced with workarounds in unoxml.
+Note to future maintainers: work around redland bugs in client code.
+
diff --git a/redland/prj/build.lst b/redland/prj/build.lst
new file mode 100644
index 000000000000..c23ad527fc71
--- /dev/null
+++ b/redland/prj/build.lst
@@ -0,0 +1,5 @@
+rld redland : soltools LIBXML2:libxml2 LIBXSLT:libxslt OPENSSL:openssl NULL
+rld redland usr1 - all rld_mkout NULL
+rld redland\raptor nmake - all rld_raptor NULL
+rld redland\rasqal nmake - all rld_rasqal rld_raptor NULL
+rld redland\redland nmake - all rld_redland rld_raptor rld_rasqal NULL
diff --git a/redland/prj/d.lst b/redland/prj/d.lst
new file mode 100644
index 000000000000..f96f3a516fff
--- /dev/null
+++ b/redland/prj/d.lst
@@ -0,0 +1,19 @@
+mkdir: %_DEST%\inc%_EXT%\external
+..\%__SRC%\inc\*.h %_DEST%\inc%_EXT%\external\*.h
+..\%__SRC%\lib\libraptor.so.1 %_DEST%\lib%_EXT%\libraptor.so.1
+symlink: %_DEST%\lib%_EXT%\libraptor.so.1 %_DEST%\lib%_EXT%\libraptor.so
+..\%__SRC%\lib\libraptor.1.dylib %_DEST%\lib%_EXT%\libraptor.1.dylib
+symlink: %_DEST%\lib%_EXT%\libraptor.1.dylib %_DEST%\lib%_EXT%\libraptor.dylib
+..\%__SRC%\lib\librasqal.so.1 %_DEST%\lib%_EXT%\librasqal.so.1
+symlink: %_DEST%\lib%_EXT%\librasqal.so.1 %_DEST%\lib%_EXT%\librasqal.so
+..\%__SRC%\lib\librasqal.1.dylib %_DEST%\lib%_EXT%\librasqal.1.dylib
+symlink: %_DEST%\lib%_EXT%\librasqal.1.dylib %_DEST%\lib%_EXT%\librasqal.dylib
+..\%__SRC%\lib\librdf.so.0 %_DEST%\lib%_EXT%\librdf.so.0
+symlink: %_DEST%\lib%_EXT%\librdf.so.0 %_DEST%\lib%_EXT%\librdf.so
+..\%__SRC%\lib\librdf.0.dylib %_DEST%\lib%_EXT%\librdf.0.dylib
+symlink: %_DEST%\lib%_EXT%\librdf.0.dylib %_DEST%\lib%_EXT%\librdf.dylib
+..\%__SRC%\lib\*.lib %_DEST%\lib%_EXT%
+..\%__SRC%\lib\*.a %_DEST%\lib%_EXT%
+..\%__SRC%\lib\lib*.dll.a %_DEST%\lib%_EXT%\lib*.a
+..\%__SRC%\bin\*.dll %_DEST%\bin%_EXT%
+..\redlandversion.mk %_DEST%\inc%_EXT%\redlandversion.mk
diff --git a/redland/raptor/makefile.mk b/redland/raptor/makefile.mk
new file mode 100644
index 000000000000..bbedd36bec62
--- /dev/null
+++ b/redland/raptor/makefile.mk
@@ -0,0 +1,169 @@
+#*************************************************************************
+#
+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+#
+# Copyright 2000, 2010 Oracle and/or its affiliates.
+#
+# OpenOffice.org - a multi-platform office productivity suite
+#
+# This file is part of OpenOffice.org.
+#
+# OpenOffice.org is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License version 3
+# only, as published by the Free Software Foundation.
+#
+# OpenOffice.org is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License version 3 for more details
+# (a copy is included in the LICENSE file that accompanied this code).
+#
+# You should have received a copy of the GNU Lesser General Public License
+# version 3 along with OpenOffice.org. If not, see
+# <http://www.openoffice.org/license.html>
+# for a copy of the LGPLv3 License.
+#
+#*************************************************************************
+
+PRJ=..
+
+PRJNAME=redland
+TARGET=so_raptor
+
+# --- Settings -----------------------------------------------------
+
+.INCLUDE : settings.mk
+
+.IF "$(SYSTEM_REDLAND)" == "YES"
+all:
+ @echo "An already available installation of Redland RDF should exist on your system."
+ @echo "Therefore the version provided here does not need to be built in addition."
+.ENDIF
+
+# --- Files --------------------------------------------------------
+
+.INCLUDE : ../redlandversion.mk
+
+RAPTORVERSION=$(RAPTOR_MAJOR).4.18
+
+TARFILE_NAME=raptor-$(RAPTORVERSION)
+TARFILE_MD5=284e768eeda0e2898b0d5bf7e26a016e
+
+ADDITIONAL_FILES=src/makefile.mk src/raptor_config.h
+
+OOO_PATCH_FILES= \
+ $(TARFILE_NAME).patch.legal \
+ $(TARFILE_NAME).patch.autotools \
+ $(TARFILE_NAME).patch.ooo_build \
+ $(TARFILE_NAME).patch.dmake \
+ $(TARFILE_NAME).patch.win32 \
+ raptor-aix.patch
+
+PATCH_FILES=$(OOO_PATCH_FILES)
+
+
+.IF "$(OS)"=="OS2"
+BUILD_ACTION=dmake
+BUILD_DIR=$(CONFIGURE_DIR)$/src
+.ELIF "$(OS)"=="WNT"
+.IF "$(COM)"=="GCC"
+OOO_PATCH_FILES+=$(TARFILE_NAME).patch.mingw
+raptor_CC=$(CC) -mthreads
+.IF "$(MINGW_SHARED_GCCLIB)"=="YES"
+raptor_CC+=-shared-libgcc
+.ENDIF
+raptor_LIBS=
+.IF "$(MINGW_SHARED_GXXLIB)"=="YES"
+raptor_LIBS+=$(MINGW_SHARED_LIBSTDCPP)
+.ENDIF
+
+CONFIGURE_DIR=
+CONFIGURE_ACTION=.$/configure
+# do not enable grddl parser (#i93768#)
+CONFIGURE_FLAGS=--disable-static --disable-gtk-doc --with-openssl-digests --with-xml-parser=libxml --enable-parsers="rdfxml ntriples turtle trig guess rss-tag-soup" --without-bdb --without-sqlite --without-mysql --without-postgresql --without-threestore --with-regex-library=posix --with-decimal=none --with-www=xml --build=i586-pc-mingw32 --host=i586-pc-mingw32 lt_cv_cc_dll_switch="-shared" CC="$(raptor_CC)" CPPFLAGS="-nostdinc $(INCLUDE)" LDFLAGS="-no-undefined -Wl,--enable-runtime-pseudo-reloc-v2,--export-all-symbols -L$(ILIB:s/;/ -L/)" LIBS="$(raptor_LIBS)" OBJDUMP="$(WRAPCMD) objdump" LIBXML2LIB=$(LIBXML2LIB) XSLTLIB="$(XSLTLIB)"
+BUILD_ACTION=$(GNUMAKE)
+BUILD_FLAGS+= -j$(EXTMAXPROCESS)
+BUILD_DIR=$(CONFIGURE_DIR)
+.ELSE
+# there is no wntmsci build environment in the tarball; we use custom dmakefile
+BUILD_ACTION=dmake
+BUILD_DIR=$(CONFIGURE_DIR)$/src
+.ENDIF
+
+.ELSE # "WNT"
+
+.IF "$(OS)$(COM)"=="LINUXGCC" || "$(OS)$(COM)"=="FREEBSDGCC"
+LDFLAGS:=-Wl,-rpath,'$$$$ORIGIN:$$$$ORIGIN/../ure-link/lib' -Wl,-noinhibit-exec
+.ENDIF # "$(OS)$(COM)"=="LINUXGCC"
+.IF "$(OS)$(COM)"=="SOLARISC52"
+LDFLAGS:=-Wl,-R'$$$$ORIGIN:$$$$ORIGIN/../ure-link/lib'
+.ENDIF # "$(OS)$(COM)"=="SOLARISC52"
+
+.IF "$(COM)"=="C52" && "$(CPU)"=="U"
+CFLAGS=-m64
+.EXPORT: CFLAGS
+.ENDIF
+
+# NB: SOLARDIR before SYSBASE, because linux SYSBASE contains obsolete libcrypto
+CPPFLAGS+:=-I$(SOLARINCDIR)$/external
+LDFLAGS+:=-L$(SOLARLIBDIR)
+
+.IF "$(OS)"=="AIX"
+LDFLAGS+:=$(LINKFLAGS) $(LINKFLAGSRUNPATH_OOO)
+.ENDIF
+
+.IF "$(SYSBASE)"!=""
+CPPFLAGS+:=-I$(SYSBASE)$/usr$/include
+.IF "$(OS)"=="SOLARIS" || "$(OS)"=="LINUX"
+LDFLAGS+:=-L$(SYSBASE)$/lib -L$(SYSBASE)$/usr$/lib -lpthread -ldl
+.ENDIF
+.ENDIF # "$(SYSBASE)"!=""
+
+CPPFLAGS+:=$(EXTRA_CDEFS) $(EXTRA_CFLAGS)
+LDFLAGS+:=$(EXTRA_LINKFLAGS)
+XSLTLIB!:=$(XSLTLIB) # expand dmake variables for xslt-config
+
+.EXPORT: CPPFLAGS
+.EXPORT: LDFLAGS
+.EXPORT: LIBXML2LIB
+.EXPORT: XSLTLIB
+
+CONFIGURE_DIR=
+CONFIGURE_ACTION=.$/configure
+# do not enable grddl parser (#i93768#)
+CONFIGURE_FLAGS=--disable-static --disable-gtk-doc --with-threads --with-openssl-digests --with-xml-parser=libxml --enable-parsers="rdfxml ntriples turtle trig guess rss-tag-soup" --without-bdb --without-sqlite --without-mysql --without-postgresql --without-threestore --with-regex-library=posix --with-decimal=none --with-www=xml
+BUILD_ACTION=$(GNUMAKE)
+BUILD_FLAGS+= -j$(EXTMAXPROCESS)
+BUILD_DIR=$(CONFIGURE_DIR)
+.ENDIF
+
+
+OUT2INC+=src$/raptor.h
+
+.IF "$(OS)"=="MACOSX"
+OUT2LIB+=src$/.libs$/libraptor.$(RAPTOR_MAJOR).dylib src$/.libs$/libraptor.dylib
+OUT2BIN+=src/raptor-config
+.ELIF "$(OS)"=="AIX"
+OUT2LIB+=src$/.libs$/libraptor.so.$(RAPTOR_MAJOR) src$/.libs$/libraptor.so
+OUT2BIN+=src/raptor-config
+.ELIF "$(OS)"=="WNT"
+.IF "$(COM)"=="GCC"
+OUT2LIB+=src$/.libs$/*.a
+OUT2BIN+=src$/.libs$/*.dll
+OUT2BIN+=src/raptor-config
+.ELSE
+# if we use dmake, this is done automagically
+.ENDIF
+.ELIF "$(GUI)"=="OS2"
+# if we use dmake, this is done automagically
+.ELSE
+OUT2LIB+=src$/.libs$/libraptor.so.$(RAPTOR_MAJOR) src$/.libs$/libraptor.so
+OUT2BIN+=src/raptor-config
+.ENDIF
+
+# --- Targets ------------------------------------------------------
+
+.INCLUDE : set_ext.mk
+.INCLUDE : target.mk
+.INCLUDE : tg_ext.mk
+
diff --git a/redland/raptor/raptor-1.4.18.patch.autotools b/redland/raptor/raptor-1.4.18.patch.autotools
new file mode 100644
index 000000000000..4b43def56511
--- /dev/null
+++ b/redland/raptor/raptor-1.4.18.patch.autotools
@@ -0,0 +1,46 @@
+--- misc/raptor-1.4.18/configure Sun Jun 15 10:25:55 2008
++++ misc/build/raptor-1.4.18/configure Wed Feb 18 13:23:12 2009
+@@ -4321,7 +4321,7 @@
+
+ cygwin*)
+ # func_win32_libid is a shell function defined in ltmain.sh
+- lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
++ lt_cv_deplibs_check_method='file_magic ^x86 archive|^x86 DLL'
+ lt_cv_file_magic_cmd='func_win32_libid'
+ ;;
+
+@@ -4330,7 +4330,7 @@
+ # func_win32_libid shell function, so use a weaker test based on 'objdump',
+ # unless we find 'file', for example because we are cross-compiling.
+ if ( file / ) >/dev/null 2>&1; then
+- lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
++ lt_cv_deplibs_check_method='file_magic ^x86 archive|^x86 DLL'
+ lt_cv_file_magic_cmd='func_win32_libid'
+ else
+ lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
+--- misc/raptor-1.4.18/ltmain.sh 2008-02-02 22:28:24.000000000 +0900
++++ misc/build/raptor-1.4.18/ltmain.sh 2008-07-08 11:58:42.000000000 +0900
+@@ -3262,9 +3262,9 @@
+ revision="$number_revision"
+ ;;
+ freebsd-aout|freebsd-elf|sunos)
+- current="$number_major"
+- revision="$number_minor"
+- age="0"
++ current=`expr $number_major + $number_minor`
++ age="$number_minor"
++ revision="$number_revision"
+ ;;
+ irix|nonstopux)
+ current=`expr $number_major + $number_minor`
+@@ -3344,8 +3344,8 @@
+ ;;
+
+ freebsd-elf)
+- major=".$current"
+- versuffix=".$current";
++ major=.`expr $current - $age`
++ versuffix="$major.$age.$revision"
+ ;;
+
+ irix | nonstopux)
diff --git a/redland/raptor/raptor-1.4.18.patch.dmake b/redland/raptor/raptor-1.4.18.patch.dmake
new file mode 100644
index 000000000000..b0172754d8f1
--- /dev/null
+++ b/redland/raptor/raptor-1.4.18.patch.dmake
@@ -0,0 +1,124 @@
+--- misc/raptor-1.4.18/src/makefile.mk Thu Nov 6 15:25:51 2008
++++ misc/build/raptor-1.4.18/src/makefile.mk Thu Nov 6 15:33:14 2008
+@@ -1,1 +1,119 @@
+-dummy
++#*************************************************************************
++#
++# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
++#
++# Copyright 2000, 2010 Oracle and/or its affiliates.
++#
++# OpenOffice.org - a multi-platform office productivity suite
++#
++# This file is part of OpenOffice.org.
++#
++# OpenOffice.org is free software: you can redistribute it and/or modify
++# it under the terms of the GNU Lesser General Public License version 3
++# only, as published by the Free Software Foundation.
++#
++# OpenOffice.org is distributed in the hope that it will be useful,
++# but WITHOUT ANY WARRANTY; without even the implied warranty of
++# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
++# GNU Lesser General Public License version 3 for more details
++# (a copy is included in the LICENSE file that accompanied this code).
++#
++# You should have received a copy of the GNU Lesser General Public License
++# version 3 along with OpenOffice.org. If not, see
++# <http://www.openoffice.org/license.html>
++# for a copy of the LGPLv3 License.
++#
++#*************************************************************************
++
++PRJ=..$/..$/..$/..$/..
++
++PRJNAME=redland
++TARGET=raptor
++LIBTARGET=NO
++UWINAPIDLL=
++
++EXTERNAL_WARNINGS_NOT_ERRORS=TRUE
++UWINAPILIB=
++
++
++# --- Settings -----------------------------------------------------
++
++.INCLUDE : settings.mk
++
++CDEFS+=-DRAPTOR_INTERNAL -DWIN32 -DNDEBUG -D_WINDOWS -D_USRDLL -DWIN32_EXPORTS
++
++# --- Files --------------------------------------------------------
++
++SLOFILES = \
++ $(SLO)$/n3_lexer.obj \
++ $(SLO)$/n3_parser.obj \
++ $(SLO)$/ntriples_parse.obj \
++ $(SLO)$/parsedate.obj \
++ $(SLO)$/raptor_feature.obj \
++ $(SLO)$/raptor_general.obj \
++ $(SLO)$/raptor_guess.obj \
++ $(SLO)$/raptor_identifier.obj \
++ $(SLO)$/raptor_iostream.obj \
++ $(SLO)$/raptor_libxml.obj \
++ $(SLO)$/raptor_locator.obj \
++ $(SLO)$/raptor_namespace.obj \
++ $(SLO)$/raptor_nfc.obj \
++ $(SLO)$/raptor_nfc_data.obj \
++ $(SLO)$/raptor_parse.obj \
++ $(SLO)$/raptor_qname.obj \
++ $(SLO)$/raptor_rdfxml.obj \
++ $(SLO)$/raptor_rfc2396.obj \
++ $(SLO)$/raptor_rss.obj \
++ $(SLO)$/raptor_rss_common.obj \
++ $(SLO)$/raptor_sax2.obj \
++ $(SLO)$/raptor_sequence.obj \
++ $(SLO)$/raptor_serialize.obj \
++ $(SLO)$/raptor_serialize_ntriples.obj \
++ $(SLO)$/raptor_serialize_rdfxml.obj \
++ $(SLO)$/raptor_serialize_rdfxmla.obj \
++ $(SLO)$/raptor_serialize_simple.obj \
++ $(SLO)$/raptor_set.obj \
++ $(SLO)$/raptor_stringbuffer.obj \
++ $(SLO)$/raptor_uri.obj \
++ $(SLO)$/raptor_utf8.obj \
++ $(SLO)$/raptor_win32.obj \
++ $(SLO)$/raptor_www.obj \
++ $(SLO)$/raptor_www_libxml.obj \
++ $(SLO)$/raptor_xml.obj \
++ $(SLO)$/raptor_xml_writer.obj \
++ $(SLO)$/raptor_xsd.obj \
++ $(SLO)$/raptor_strcasecmp.obj \
++ $(SLO)$/turtle_common.obj \
++ $(SLO)$/turtle_lexer.obj \
++ $(SLO)$/turtle_parser.obj \
++ $(SLO)$/raptor_abbrev.obj \
++ $(SLO)$/raptor_avltree.obj \
++ $(SLO)$/raptor_statement.obj \
++ $(SLO)$/raptor_turtle_writer.obj \
++
++# $(SLO)$/raptor_grddl.obj \
++# $(SLO)$/raptor_serialize_rss.obj \
++
++
++SHL1DEPN= makefile.mk
++SHL1OBJS= $(SLOFILES)
++SHL1USE_EXPORTS=name
++
++#SHL1TARGET= $(TARGET)$(DLLPOSTFIX)
++SHL1TARGET= $(TARGET)
++SHL1IMPLIB= lib$(TARGET)
++
++#SHL1VERSIONMAP=../service/exports.map
++SHL1DEF=$(MISC)$/$(SHL1TARGET).def
++DEF1NAME=$(SHL1TARGET)
++
++SHL1STDLIBS= \
++ $(LIBXML2LIB) \
++ $(XSLTLIB) \
++
++# --- Targets ------------------------------------------------------
++
++.INCLUDE : target.mk
++
++$(MISC)$/raptor_strcasecmp.c : strcasecmp.c
++ $(COPY) $< $@
++
diff --git a/redland/raptor/raptor-1.4.18.patch.legal b/redland/raptor/raptor-1.4.18.patch.legal
new file mode 100644
index 000000000000..217b7d154812
--- /dev/null
+++ b/redland/raptor/raptor-1.4.18.patch.legal
@@ -0,0 +1,18 @@
+--- misc/raptor-1.4.18/LICENSE.txt Sun Mar 30 06:52:22 2008
++++ misc/build/raptor-1.4.18/LICENSE.txt Mon Jun 16 15:55:38 2008
+@@ -60,3 +60,15 @@
+
+ Copyright (C) 2000-2008 David Beckett
+ Copyright (C) 2000-2005 University of Bristol
++
++
++LGPL Disclaimer
++
++For the avoidance of doubt, except that if any license choice other
++than GPL or LGPL is available it will apply instead, Sun elects to
++use only the Lesser General Public License version 2.1 (LGPLv2) at
++this time for any software where a choice of LGPL license versions
++is made available with the language indicating that LGPLv2.1 or any
++later version may be used, or where a choice of which version of the
++LGPL is applied is otherwise unspecified.
++
diff --git a/redland/raptor/raptor-1.4.18.patch.mingw b/redland/raptor/raptor-1.4.18.patch.mingw
new file mode 100644
index 000000000000..e29a0a07c5a9
--- /dev/null
+++ b/redland/raptor/raptor-1.4.18.patch.mingw
@@ -0,0 +1,30 @@
+--- misc/raptor-1.4.18/configure 2008-06-15 17:25:55.000000000 +0900
++++ misc/build/raptor-1.4.18/configure 2009-06-04 21:10:22.447125000 +0900
+@@ -25238,6 +25238,12 @@
+ rdfa_parser=yes
+
+ rdf_parsers_available="rdfxml ntriples turtle trig guess rss-tag-soup rdfa"
++case $host_os in
++mingw*)
++ rdfa_parser=no
++ rdf_parsers_available="rdfxml ntriples turtle trig guess rss-tag-soup"
++ ;;
++esac
+ if test "$USE_MAINTAINER_MODE" = yes; then
+ rdf_parsers_available="$rdf_parsers_available n3"
+ fi
+--- misc/raptor-1.4.18/configure.ac 2008-06-15 17:25:20.000000000 +0900
++++ misc/build/raptor-1.4.18/configure.ac 2009-06-04 21:10:31.025250000 +0900
+@@ -758,6 +758,12 @@
+ rdfa_parser=yes
+
+ rdf_parsers_available="rdfxml ntriples turtle trig guess rss-tag-soup rdfa"
++case $host_os in
++mingw*)
++ rdfa_parser=no
++ rdf_parsers_available="rdfxml ntriples turtle trig guess rss-tag-soup"
++ ;;
++esac
+ if test "$USE_MAINTAINER_MODE" = yes; then
+ rdf_parsers_available="$rdf_parsers_available n3"
+ fi
diff --git a/redland/raptor/raptor-1.4.18.patch.ooo_build b/redland/raptor/raptor-1.4.18.patch.ooo_build
new file mode 100644
index 000000000000..a16878503ede
--- /dev/null
+++ b/redland/raptor/raptor-1.4.18.patch.ooo_build
@@ -0,0 +1,43 @@
+--- misc/raptor-1.4.18/src/raptor-config.in Sat Jan 6 05:02:00 2007
++++ misc/build/raptor-1.4.18/src/raptor-config.in Mon Jun 16 15:55:38 2008
+@@ -21,14 +21,23 @@
+ #
+ #
+
+-prefix=@prefix@
+-exec_prefix=@exec_prefix@
++prefix=${SOLARVERSION}/${INPATH}
++exec_prefix=${SOLARVERSION}/${INPATH}
++#includedir=${SOLARVERSION}/${INPATH}/inc${UPDMINOREXT}/external
++#libdir=${SOLARVERSION}/${INPATH}/lib${UPDMINOREXT}
++# HACK: map to build directory
++includedir=../../../../inc
++libdir=../../../../lib
++includes=-I${includedir}
+
+-if test "@includedir@" != /usr/include ; then
+- includes="-I@includedir@"
+-else
+- includes=
+-fi
++#prefix=@prefix@
++#exec_prefix=@exec_prefix@
++#
++#if test "@includedir@" != /usr/include ; then
++# includes="-I@includedir@"
++#else
++# includes=
++#fi
+
+
+ usage()
+@@ -130,7 +139,8 @@
+ done
+ fi
+ if test "$echo_libs" = "yes"; then
+- echo -L@libdir@ -lraptor
++# echo -L@libdir@ -lraptor
++ echo -L${libdir} -lraptor
+ fi
+ if test "$echo_libtool_libs" = "yes"; then
+ echo @libdir@/@RAPTOR_LIBTOOLLIBS@
diff --git a/redland/raptor/raptor-1.4.18.patch.win32 b/redland/raptor/raptor-1.4.18.patch.win32
new file mode 100644
index 000000000000..8de0d25cad5e
--- /dev/null
+++ b/redland/raptor/raptor-1.4.18.patch.win32
@@ -0,0 +1,78 @@
+--- misc/raptor-1.4.18/src/win32_raptor_config.h Wed Apr 2 06:50:14 2008
++++ misc/build/raptor-1.4.18/src/win32_raptor_config.h Wed Feb 18 13:21:23 2009
+@@ -38,6 +38,8 @@
+
+ #define HAVE_STDLIB_H 1
+
++#define HAVE_ERRNO_H 1
++
+ #if 0
+ /* For using expat on win32 */
+ #define RAPTOR_XML_EXPAT 1
+@@ -47,8 +49,17 @@
+ /* For using libxml2 on win32 */
+ #define RAPTOR_XML_LIBXML
+ #define HAVE_LIBXML_XMLREADER_H
++#define HAVE_LIBXML_HASH_H 1
++#define HAVE_LIBXML_HTMLPARSER_H 1
++#define HAVE_LIBXML_NANOHTTP_H 1
++#define HAVE_LIBXML_PARSER_H 1
++#define HAVE_LIBXSLT_XSLT_H 1
++
++#define RAPTOR_LIBXML_HTML_PARSE_NONET 1
++#define RAPTOR_LIBXML_XML_PARSE_NONET 1
++
+ /* does libxml struct xmlEntity have a field etype */
+-/*#define RAPTOR_LIBXML_ENTITY_ETYPE*/
++#define RAPTOR_LIBXML_ENTITY_ETYPE
+
+ /* does libxml struct xmlEntity have a field name_length */
+ /*#define RAPTOR_LIBXML_ENTITY_NAME_LENGTH*/
+@@ -60,16 +71,17 @@
+ #define HAVE_XMLSAX2INTERNALSUBSET 1
+
+ /* does libxml xmlSAXHandler have externalSubset field */
+-/*#define RAPTOR_LIBXML_XMLSAXHANDLER_EXTERNALSUBSET*/
++#define RAPTOR_LIBXML_XMLSAXHANDLER_EXTERNALSUBSET 1
+
+ /* does libxml xmlSAXHandler have initialized field */
+-/*#define RAPTOR_LIBXML_XMLSAXHANDLER_INITIALIZED*/
++#define RAPTOR_LIBXML_XMLSAXHANDLER_INITIALIZED 1
+ #endif
+
+ #define HAVE_STRICMP 1
+
+ /* MS names for these functions */
+-#define vsnprintf _vsnprintf
++// next line breaks build on wntmsci12
++//#define vsnprintf _vsnprintf
+ #define snprintf _snprintf
+ #define access _access
+ #define stricmp _stricmp
+@@ -113,19 +125,23 @@
+ #endif
+
+ #define RAPTOR_PARSER_GUESS 1
+-#define RAPTOR_PARSER_GRDDL 1
++/* #define RAPTOR_PARSER_GRDDL 1 disabled: (#i93768#) */
++#ifndef __MINGW32__ /* conflicts with normal configure result */
+ #define RAPTOR_PARSER_N3 1
++#endif
+ #define RAPTOR_PARSER_TURTLE 1
+ #define RAPTOR_PARSER_NTRIPLES 1
+ #define RAPTOR_PARSER_RDFXML 1
+
++/* does not build on wntmsci12 due to gettimeofday
+ #define RAPTOR_SERIALIZER_ATOM 1
+-#define RAPTOR_SERIALIZER_RSS_1_0 1
++#define RAPTOR_SERIALIZER_RSS_1_0 1 */
+ #define RAPTOR_SERIALIZER_RDFXML 1
+ #define RAPTOR_SERIALIZER_RDFXML_ABBREV 1
+ #define RAPTOR_SERIALIZER_NTRIPLES 1
+
+-#define RAPTOR_WWW_LIBCURL 1
++//#define RAPTOR_WWW_LIBCURL 1
++#define RAPTOR_WWW_LIBXML 1
+
+
+ #include <windows.h>
diff --git a/redland/raptor/raptor-aix.patch b/redland/raptor/raptor-aix.patch
new file mode 100644
index 000000000000..d6427c501d68
--- /dev/null
+++ b/redland/raptor/raptor-aix.patch
@@ -0,0 +1,21 @@
+--- misc/raptor-1.4.18/config.guess 2010-09-16 03:07:14.000000000 -0500
++++ misc/build/raptor-1.4.18/config.guess 2010-09-16 03:08:00.000000000 -0500
+@@ -532,7 +532,7 @@
+ echo rs6000-ibm-aix3.2
+ fi
+ exit ;;
+- *:AIX:*:[456])
++ *:AIX:*:[4567])
+ IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
+ if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then
+ IBM_ARCH=rs6000
+@@ -544,6 +544,9 @@
+ else
+ IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
+ fi
++ if [ "$IBM_REV" == "V7BETA" ]; then
++ IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
++ fi
+ echo ${IBM_ARCH}-ibm-aix${IBM_REV}
+ exit ;;
+ *:AIX:*:*)
diff --git a/redland/raptor/raptor2.map b/redland/raptor/raptor2.map
new file mode 100644
index 000000000000..109a74b632bb
--- /dev/null
+++ b/redland/raptor/raptor2.map
@@ -0,0 +1,294 @@
+UDK_3_0_0 {
+ global:
+ GetVersionInfo;
+raptor_ntriples_string_as_utf8_string;
+raptor_ntriples_term_as_string;
+raptor_feature_from_uri;
+raptor_get_feature_count;
+raptor_feature_value_type;
+raptor_xml_literal_datatype_uri_string_len;
+raptor_xml_literal_datatype_uri_string;
+raptor_version_decimal;
+raptor_version_release;
+raptor_version_minor;
+raptor_version_major;
+raptor_version_string;
+raptor_home_url_string;
+raptor_license_string;
+raptor_copyright_string;
+raptor_short_copyright_string;
+raptor_init;
+raptor_finish;
+raptor_vsnprintf;
+raptor_print_ntriples_string;
+raptor_free_memory;
+raptor_alloc_memory;
+raptor_calloc_memory;
+raptor_error_handlers_init;
+raptor_new_identifier;
+raptor_copy_identifier;
+raptor_free_identifier;
+raptor_new_iostream_to_string;
+raptor_new_iostream_to_filename;
+raptor_new_iostream_from_filename;
+raptor_iostream_write_string;
+raptor_iostream_write_uri;
+raptor_iostream_write_stringbuffer;
+raptor_iostream_format_hexadecimal;
+raptor_new_iostream_from_handler;
+raptor_new_iostream_to_sink;
+raptor_new_iostream_from_sink;
+raptor_new_iostream_from_handler2;
+raptor_new_iostream_to_file_handle;
+raptor_new_iostream_from_file_handle;
+raptor_new_iostream_from_string;
+raptor_free_iostream;
+raptor_iostream_tell;
+raptor_iostream_read_eof;
+raptor_iostream_read_bytes;
+raptor_iostream_write_decimal;
+raptor_iostream_get_bytes_written_count;
+raptor_iostream_write_end;
+raptor_iostream_write_counted_string;
+raptor_iostream_write_bytes;
+raptor_iostream_write_byte;
+raptor_print_locator;
+raptor_format_locator;
+raptor_locator_uri;
+raptor_locator_file;
+raptor_locator_byte;
+raptor_locator_column;
+raptor_locator_line;
+raptor_owl_namespace_uri;
+raptor_xmlschema_datatypes_namespace_uri;
+raptor_rdf_schema_namespace_uri;
+raptor_rdf_namespace_uri_len;
+raptor_rdf_namespace_uri;
+raptor_xml_namespace_uri;
+raptor_new_namespaces;
+raptor_namespaces_init;
+raptor_namespaces_start_namespace_full;
+raptor_new_namespace;
+raptor_namespace_copy;
+raptor_new_namespace_from_uri;
+raptor_free_namespaces;
+raptor_namespaces_clear;
+raptor_namespaces_end_for_depth;
+raptor_free_namespace;
+raptor_namespaces_format;
+raptor_iostream_write_namespace;
+raptor_new_namespace_parts_from_string;
+raptor_namespaces_qname_from_uri;
+raptor_namespaces_find_namespace;
+raptor_namespace_get_counted_prefix;
+raptor_namespace_get_prefix;
+raptor_namespace_get_uri;
+raptor_namespaces_namespace_in_scope;
+raptor_namespaces_find_namespace_by_uri;
+raptor_namespaces_get_default_namespace;
+raptor_namespaces_start_namespace;
+raptor_new_parser_for_content;
+raptor_new_parser;
+raptor_parse_file;
+raptor_parse_file_stream;
+raptor_parse_uri;
+raptor_parse_uri_with_connection;
+raptor_parse_chunk;
+raptor_start_parse;
+raptor_free_parser;
+raptor_features_enumerate;
+raptor_parser_set_feature_string;
+raptor_parser_get_feature_string;
+raptor_set_default_generate_id_parameters;
+raptor_guess_parser_name;
+raptor_syntax_name_check;
+raptor_parser_get_accept_header;
+raptor_parsers_enumerate;
+raptor_syntaxes_enumerate;
+raptor_get_mime_type;
+raptor_get_locator;
+raptor_parse_abort;
+raptor_get_need_base_uri;
+raptor_get_label;
+raptor_get_name;
+raptor_set_parser_strict;
+raptor_get_feature;
+raptor_set_feature;
+raptor_parser_set_uri_filter;
+raptor_set_namespace_handler;
+raptor_set_generate_id_handler;
+raptor_set_graph_handler;
+raptor_set_statement_handler;
+raptor_set_warning_handler;
+raptor_set_error_handler;
+raptor_set_fatal_error_handler;
+raptor_new_qname;
+raptor_new_qname_from_namespace_local_name;
+raptor_qname_copy;
+raptor_free_qname;
+raptor_qname_equal;
+raptor_qname_string_to_uri;
+raptor_iostream_write_qname;
+raptor_qname_get_counted_value;
+raptor_qname_get_value;
+raptor_qname_get_local_name;
+raptor_qname_get_namespace;
+raptor_uri_resolve_uri_reference;
+raptor_new_sax2;
+raptor_sax2_parse_start;
+raptor_free_sax2;
+raptor_sax2_parse_chunk;
+raptor_sax2_inscope_base_uri;
+raptor_sax2_inscope_xml_language;
+raptor_xml_element_is_empty;
+raptor_sax2_set_namespace_handler;
+raptor_sax2_set_external_entity_ref_handler;
+raptor_sax2_set_unparsed_entity_decl_handler;
+raptor_sax2_set_comment_handler;
+raptor_sax2_set_cdata_handler;
+raptor_sax2_set_characters_handler;
+raptor_sax2_set_end_element_handler;
+raptor_sax2_set_start_element_handler;
+raptor_compare_strings;
+raptor_sequence_sort;
+raptor_sequence_print_string;
+raptor_sequence_print_uri;
+raptor_sequence_print;
+raptor_free_sequence;
+raptor_sequence_set_at;
+raptor_sequence_push;
+raptor_sequence_shift;
+raptor_sequence_join;
+raptor_new_sequence;
+raptor_sequence_size;
+raptor_sequence_get_at;
+raptor_sequence_pop;
+raptor_sequence_unshift;
+raptor_sequence_set_print_handler;
+raptor_serializer_syntax_name_check;
+raptor_new_serializer;
+raptor_serializers_enumerate;
+raptor_serialize_start_to_filename;
+raptor_serialize_start_to_string;
+raptor_serialize_start_to_file_handle;
+raptor_serialize_start;
+raptor_serialize_set_namespace_from_namespace;
+raptor_serialize_end;
+raptor_free_serializer;
+raptor_serializer_features_enumerate;
+raptor_serializer_set_feature_string;
+raptor_serializer_get_feature_string;
+raptor_serializer_get_locator;
+raptor_serializer_set_warning_handler;
+raptor_serializer_set_error_handler;
+raptor_serializer_get_feature;
+raptor_serializer_set_feature;
+raptor_serializer_get_iostream;
+raptor_serialize_statement;
+raptor_serialize_set_namespace;
+raptor_iostream_write_statement_ntriples;
+raptor_iostream_write_string_ntriples;
+raptor_new_stringbuffer;
+raptor_free_stringbuffer;
+raptor_stringbuffer_append_decimal;
+raptor_stringbuffer_append_counted_string;
+raptor_stringbuffer_append_string;
+raptor_stringbuffer_append_stringbuffer;
+raptor_stringbuffer_prepend_counted_string;
+raptor_stringbuffer_prepend_string;
+raptor_stringbuffer_as_string;
+raptor_stringbuffer_copy_to_string;
+raptor_stringbuffer_length;
+raptor_uri_set_handler;
+raptor_uri_filename_to_uri_string;
+raptor_uri_uri_string_to_filename;
+raptor_uri_uri_string_to_filename_fragment;
+raptor_uri_is_file_uri;
+raptor_uri_uri_string_is_file_uri;
+raptor_new_uri_for_xmlbase;
+raptor_new_uri_for_retrieval;
+raptor_new_uri_from_id;
+raptor_uri_to_relative_uri_string;
+raptor_uri_to_relative_counted_uri_string;
+raptor_uri_compare;
+raptor_uri_print;
+raptor_uri_to_string;
+raptor_uri_to_counted_string;
+raptor_uri_as_counted_string;
+raptor_uri_as_string;
+raptor_uri_copy;
+raptor_uri_equals;
+raptor_free_uri;
+raptor_new_uri_for_rdf_concept;
+raptor_new_uri_relative_to_base;
+raptor_new_uri_from_uri_local_name;
+raptor_new_uri;
+raptor_uri_get_handler;
+raptor_utf8_check;
+raptor_unicode_is_xml10_namechar;
+raptor_unicode_is_xml10_namestartchar;
+raptor_unicode_is_xml11_namechar;
+raptor_unicode_is_xml11_namestartchar;
+raptor_utf8_to_unicode_char;
+raptor_unicode_char_to_utf8;
+raptor_www_new;
+raptor_www_new_with_connection;
+raptor_www_free;
+raptor_www_set_user_agent;
+raptor_www_set_proxy;
+raptor_www_set_http_accept;
+raptor_www_set_http_cache_control;
+raptor_www_fetch_to_string;
+raptor_www_fetch;
+raptor_www_get_final_uri;
+raptor_www_set_final_uri_handler;
+raptor_www_abort;
+raptor_www_get_connection;
+raptor_www_set_uri_filter;
+raptor_www_set_connection_timeout;
+raptor_www_set_content_type_handler;
+raptor_www_set_write_bytes_handler;
+raptor_www_set_error_handler;
+raptor_www_finish;
+raptor_www_no_www_library_init_finish;
+raptor_www_init;
+raptor_new_xml_element_from_namespace_local_name;
+raptor_new_xml_element;
+raptor_free_xml_element;
+raptor_xml_element_declare_namespace;
+raptor_iostream_write_xml_element;
+raptor_xml_escape_string;
+raptor_xml_any_escape_string;
+raptor_iostream_write_xml_escaped_string;
+raptor_iostream_write_xml_any_escaped_string;
+raptor_xml_name_check;
+raptor_xml_element_get_language;
+raptor_xml_element_get_attributes_count;
+raptor_xml_element_get_attributes;
+raptor_xml_element_set_attributes;
+raptor_xml_element_get_name;
+raptor_new_xml_writer;
+raptor_free_xml_writer;
+raptor_xml_writer_empty_element;
+raptor_xml_writer_start_element;
+raptor_xml_writer_end_element;
+raptor_xml_writer_comment;
+raptor_xml_writer_cdata;
+raptor_xml_writer_comment_counted;
+raptor_xml_writer_cdata_counted;
+raptor_xml_writer_raw;
+raptor_xml_writer_raw_counted;
+raptor_xml_writer_features_enumerate;
+raptor_xml_writer_set_feature_string;
+raptor_xml_writer_get_feature_string;
+raptor_xml_writer_get_feature;
+raptor_xml_writer_set_feature;
+raptor_statement_part_as_string;
+raptor_statement_part_as_counted_string;
+raptor_print_statement_as_ntriples;
+raptor_print_statement_detailed;
+raptor_print_statement;
+raptor_statement_compare;
+raptor_iostream_write_string_turtle;
+raptor_iostream_write_string_python;
+};
diff --git a/redland/rasqal/makefile.mk b/redland/rasqal/makefile.mk
new file mode 100644
index 000000000000..a4c2187d483c
--- /dev/null
+++ b/redland/rasqal/makefile.mk
@@ -0,0 +1,162 @@
+#*************************************************************************
+#
+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+#
+# Copyright 2000, 2010 Oracle and/or its affiliates.
+#
+# OpenOffice.org - a multi-platform office productivity suite
+#
+# This file is part of OpenOffice.org.
+#
+# OpenOffice.org is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License version 3
+# only, as published by the Free Software Foundation.
+#
+# OpenOffice.org is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License version 3 for more details
+# (a copy is included in the LICENSE file that accompanied this code).
+#
+# You should have received a copy of the GNU Lesser General Public License
+# version 3 along with OpenOffice.org. If not, see
+# <http://www.openoffice.org/license.html>
+# for a copy of the LGPLv3 License.
+#
+#*************************************************************************
+
+PRJ=..
+
+PRJNAME=redland
+TARGET=so_rasqal
+
+# --- Settings -----------------------------------------------------
+
+.INCLUDE : settings.mk
+
+.IF "$(SYSTEM_REDLAND)" == "YES"
+all:
+ @echo "An already available installation of Redland RDF should exist on your system."
+ @echo "Therefore the version provided here does not need to be built in addition."
+.ENDIF
+
+# --- Files --------------------------------------------------------
+
+.INCLUDE : ../redlandversion.mk
+
+RASQALVERSION=0.9.16
+
+TARFILE_NAME=rasqal-$(RASQALVERSION)
+TARFILE_MD5=fca8706f2c4619e2fa3f8f42f8fc1e9d
+
+ADDITIONAL_FILES=src/makefile.mk src/rasqal_config.h
+
+OOO_PATCH_FILES= \
+ $(TARFILE_NAME).patch.legal \
+ $(TARFILE_NAME).patch.autotools \
+ $(TARFILE_NAME).patch.ooo_build \
+ $(TARFILE_NAME).patch.dmake \
+ $(TARFILE_NAME).patch.win32 \
+ rasqal-aix.patch
+
+PATCH_FILES=$(OOO_PATCH_FILES)
+
+
+.IF "$(OS)"=="OS2"
+BUILD_ACTION=dmake
+BUILD_DIR=$(CONFIGURE_DIR)$/src
+.ELIF "$(OS)"=="WNT"
+.IF "$(COM)"=="GCC"
+rasqal_CC=$(CC) -mthreads
+.IF "$(MINGW_SHARED_GCCLIB)"=="YES"
+rasqal_CC+=-shared-libgcc
+.ENDIF
+rasqal_LIBS=
+.IF "$(MINGW_SHARED_GXXLIB)"=="YES"
+rasqal_LIBS+=$(MINGW_SHARED_LIBSTDCPP)
+.ENDIF
+
+CONFIGURE_DIR=
+CONFIGURE_ACTION=.$/configure PATH="..$/..$/..$/bin:$$PATH"
+CONFIGURE_FLAGS=--disable-static --disable-gtk-doc --with-openssl-digests --with-xml-parser=libxml --without-bdb --without-sqlite --without-mysql --without-postgresql --without-threestore --disable-pcre --with-decimal=none --with-www=xml --build=i586-pc-mingw32 --host=i586-pc-mingw32 lt_cv_cc_dll_switch="-shared" CC="$(rasqal_CC)" CPPFLAGS="-nostdinc $(INCLUDE)" LDFLAGS="-no-undefined -Wl,--enable-runtime-pseudo-reloc-v2,--export-all-symbols -L$(ILIB:s/;/ -L/)" LIBS="$(rasqal_LIBS)" OBJDUMP="$(WRAPCMD) objdump" LIBXML2LIB=$(LIBXML2LIB) XSLTLIB="$(XSLTLIB)"
+BUILD_ACTION=$(GNUMAKE)
+BUILD_FLAGS+= -j$(EXTMAXPROCESS)
+BUILD_DIR=$(CONFIGURE_DIR)
+.ELSE
+# there is no wntmsci build environment in the tarball; we use custom dmakefile
+BUILD_ACTION=dmake
+BUILD_DIR=$(CONFIGURE_DIR)$/src
+.ENDIF
+.ELSE # "WNT"
+
+.IF "$(OS)$(COM)"=="LINUXGCC" || "$(OS)$(COM)"=="FREEBSDGCC"
+LDFLAGS:=-Wl,-rpath,'$$$$ORIGIN:$$$$ORIGIN/../ure-link/lib' -Wl,-noinhibit-exec
+.ENDIF # "$(OS)$(COM)"=="LINUXGCC"
+.IF "$(OS)$(COM)"=="SOLARISC52"
+LDFLAGS:=-Wl,-R'$$$$ORIGIN:$$$$ORIGIN/../ure-link/lib'
+.ENDIF # "$(OS)$(COM)"=="SOLARISC52"
+
+.IF "$(COM)"=="C52" && "$(CPU)"=="U"
+CFLAGS=-m64
+.EXPORT: CFLAGS
+.ENDIF
+
+# NB: SOLARDIR before SYSBASE, because linux SYSBASE contains obsolete libcrypto
+CPPFLAGS+:=-I$(SOLARINCDIR)$/external
+LDFLAGS+:=-L$(SOLARLIBDIR)
+
+.IF "$(OS)"=="AIX"
+LDFLAGS+:=$(LINKFLAGS) $(LINKFLAGSRUNPATH_OOO)
+.ENDIF
+
+.IF "$(SYSBASE)"!=""
+CPPFLAGS+:=-I$(SYSBASE)$/usr$/include
+.IF "$(OS)"=="SOLARIS" || "$(OS)"=="LINUX"
+LDFLAGS+:=-L$(SYSBASE)$/lib -L$(SYSBASE)$/usr$/lib -lpthread -ldl
+.ENDIF
+.ENDIF # "$(SYSBASE)"!=""
+
+CPPFLAGS+:=$(EXTRA_CDEFS) $(EXTRA_CFLAGS)
+LDFLAGS+:=$(EXTRA_LINKFLAGS)
+XSLTLIB!:=$(XSLTLIB) # expand dmake variables for xslt-config
+
+.EXPORT: CPPFLAGS
+.EXPORT: LDFLAGS
+.EXPORT: LIBXML2LIB
+.EXPORT: XSLTLIB
+
+CONFIGURE_DIR=
+CONFIGURE_ACTION=.$/configure PATH="..$/..$/..$/bin:$$PATH"
+CONFIGURE_FLAGS=--disable-static --disable-gtk-doc --with-threads --with-openssl-digests --with-xml-parser=libxml --without-bdb --without-sqlite --without-mysql --without-postgresql --without-threestore --with-regex-library=posix --with-decimal=none --with-www=xml
+BUILD_ACTION=$(AUGMENT_LIBRARY_PATH) $(GNUMAKE)
+BUILD_FLAGS+= -j$(EXTMAXPROCESS)
+BUILD_DIR=$(CONFIGURE_DIR)
+.ENDIF
+
+
+OUT2INC+=src$/rasqal.h
+
+.IF "$(OS)"=="MACOSX"
+OUT2LIB+=src$/.libs$/librasqal.$(RASQAL_MAJOR).dylib src$/.libs$/librasqal.dylib
+OUT2BIN+=src/rasqal-config
+.ELIF "$(OS)"=="WNT"
+.IF "$(COM)"=="GCC"
+OUT2LIB+=src$/.libs$/*.a
+OUT2BIN+=src$/.libs$/*.dll
+OUT2BIN+=src/rasqal-config
+.ELSE
+# if we use dmake, this is done automagically
+.ENDIF
+.ELIF "$(OS)"=="OS2"
+# if we use dmake, this is done automagically
+.ELSE
+OUT2LIB+=src$/.libs$/librasqal.so.$(RASQAL_MAJOR) src$/.libs$/librasqal.so
+OUT2BIN+=src/rasqal-config
+.ENDIF
+
+# --- Targets ------------------------------------------------------
+
+.INCLUDE : set_ext.mk
+.INCLUDE : target.mk
+.INCLUDE : tg_ext.mk
+
diff --git a/redland/rasqal/rasqal-0.9.16.patch.autotools b/redland/rasqal/rasqal-0.9.16.patch.autotools
new file mode 100644
index 000000000000..100499dd3ed8
--- /dev/null
+++ b/redland/rasqal/rasqal-0.9.16.patch.autotools
@@ -0,0 +1,38 @@
+--- misc/rasqal-0.9.16/ltmain.sh Tue Apr 29 23:33:55 2008
++++ misc/build/rasqal-0.9.16/ltmain.sh Wed Feb 18 13:25:00 2009
+@@ -1565,6 +1565,11 @@
+ [\\/]* | [A-Za-z]:[\\/]*) ;;
+ *)
+ absdir=`cd "$dir" && pwd`
++ case $host_os in
++ mingw*)
++ absdir=`cygpath -m $absdir`
++ ;;
++ esac
+ if test -z "$absdir"; then
+ $echo "$modename: cannot determine absolute directory name of \`$dir'" 1>&2
+ absdir="$dir"
+@@ -3262,9 +3267,9 @@
+ revision="$number_revision"
+ ;;
+ freebsd-aout|freebsd-elf|sunos)
+- current="$number_major"
+- revision="$number_minor"
+- age="0"
++ current=`expr $number_major + $number_minor`
++ age="$number_minor"
++ revision="$number_revision"
+ ;;
+ irix|nonstopux)
+ current=`expr $number_major + $number_minor`
+@@ -3344,8 +3349,8 @@
+ ;;
+
+ freebsd-elf)
+- major=".$current"
+- versuffix=".$current";
++ major=.`expr $current - $age`
++ versuffix="$major.$age.$revision"
+ ;;
+
+ irix | nonstopux)
diff --git a/redland/rasqal/rasqal-0.9.16.patch.dmake b/redland/rasqal/rasqal-0.9.16.patch.dmake
new file mode 100644
index 000000000000..6795eb95c43d
--- /dev/null
+++ b/redland/rasqal/rasqal-0.9.16.patch.dmake
@@ -0,0 +1,98 @@
+--- misc/rasqal-0.9.16/src/makefile.mk Thu Nov 6 15:56:45 2008
++++ misc/build/rasqal-0.9.16/src/makefile.mk Thu Nov 6 15:55:09 2008
+@@ -1,1 +1,94 @@
+-dummy
++#*************************************************************************
++#
++# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
++#
++# Copyright 2000, 2010 Oracle and/or its affiliates.
++#
++# OpenOffice.org - a multi-platform office productivity suite
++#
++# This file is part of OpenOffice.org.
++#
++# OpenOffice.org is free software: you can redistribute it and/or modify
++# it under the terms of the GNU Lesser General Public License version 3
++# only, as published by the Free Software Foundation.
++#
++# OpenOffice.org is distributed in the hope that it will be useful,
++# but WITHOUT ANY WARRANTY; without even the implied warranty of
++# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
++# GNU Lesser General Public License version 3 for more details
++# (a copy is included in the LICENSE file that accompanied this code).
++#
++# You should have received a copy of the GNU Lesser General Public License
++# version 3 along with OpenOffice.org. If not, see
++# <http://www.openoffice.org/license.html>
++# for a copy of the LGPLv3 License.
++#
++#*************************************************************************
++
++PRJ=..$/..$/..$/..$/..
++
++PRJNAME=redland
++TARGET=rasqal
++LIBTARGET=NO
++UWINAPILIB=
++
++EXTERNAL_WARNINGS_NOT_ERRORS=TRUE
++
++
++# --- Settings -----------------------------------------------------
++
++.INCLUDE : settings.mk
++
++CDEFS+=-DRASQAL_INTERNAL -DWIN32 -DNDEBUG -D_WINDOWS -D_USRDLL -DWIN32_EXPORTS -D_MT
++
++# --- Files --------------------------------------------------------
++
++SLOFILES = \
++ $(SLO)$/rasqal_datetime.obj \
++ $(SLO)$/rasqal_decimal.obj \
++ $(SLO)$/rasqal_engine.obj \
++ $(SLO)$/rasqal_expr.obj \
++ $(SLO)$/rasqal_feature.obj \
++ $(SLO)$/rasqal_general.obj \
++ $(SLO)$/rasqal_graph_pattern.obj \
++ $(SLO)$/rasqal_literal.obj \
++ $(SLO)$/rasqal_map.obj \
++ $(SLO)$/rasqal_query_results.obj \
++ $(SLO)$/rasqal_query.obj \
++ $(SLO)$/rasqal_raptor.obj \
++ $(SLO)$/rasqal_result_formats.obj \
++ $(SLO)$/rasqal_rowsource.obj \
++ $(SLO)$/rasqal_sparql_xml.obj \
++ $(SLO)$/rasqal_xsd_datatypes.obj \
++ $(SLO)$/rdql_lexer.obj \
++ $(SLO)$/rdql_parser.obj \
++ $(SLO)$/sparql_lexer.obj \
++ $(SLO)$/sparql_parser.obj \
++ $(SLO)$/strcasecmp.obj \
++
++
++# $(SLO)$/rasqal_redland.obj \
++
++SHL1DEPN= makefile.mk
++SHL1OBJS= $(SLOFILES)
++SHL1USE_EXPORTS=name
++
++#SHL1TARGET= $(TARGET)$(DLLPOSTFIX)
++SHL1TARGET= $(TARGET)
++SHL1IMPLIB= lib$(TARGET)
++
++#SHL1VERSIONMAP=../service/exports.map
++SHL1DEF=$(MISC)$/$(SHL1TARGET).def
++DEF1NAME=$(SHL1TARGET)
++
++SHL1STDLIBS= \
++ $(PRJ)$/$(INPATH)$/lib$/libraptor.lib \
++
++
++#$(LIBXML2LIB) \
++# $(XSLTLIB) \
++
++# --- Targets ------------------------------------------------------
++
++.INCLUDE : target.mk
++
diff --git a/redland/rasqal/rasqal-0.9.16.patch.legal b/redland/rasqal/rasqal-0.9.16.patch.legal
new file mode 100644
index 000000000000..59b125d6b64e
--- /dev/null
+++ b/redland/rasqal/rasqal-0.9.16.patch.legal
@@ -0,0 +1,18 @@
+--- misc/rasqal-0.9.16/LICENSE.txt Fri Jun 27 04:24:52 2008
++++ misc/build/rasqal-0.9.16/LICENSE.txt Thu Nov 6 12:06:55 2008
+@@ -60,3 +60,15 @@
+
+ Copyright (C) 2003-2008 Dave Beckett
+ Copyright (C) 2003-2005 University of Bristol
++
++
++LGPL Disclaimer
++
++For the avoidance of doubt, except that if any license choice other
++than GPL or LGPL is available it will apply instead, Sun elects to
++use only the Lesser General Public License version 2.1 (LGPLv2) at
++this time for any software where a choice of LGPL license versions
++is made available with the language indicating that LGPLv2.1 or any
++later version may be used, or where a choice of which version of the
++LGPL is applied is otherwise unspecified.
++
diff --git a/redland/rasqal/rasqal-0.9.16.patch.ooo_build b/redland/rasqal/rasqal-0.9.16.patch.ooo_build
new file mode 100644
index 000000000000..827147995e6f
--- /dev/null
+++ b/redland/rasqal/rasqal-0.9.16.patch.ooo_build
@@ -0,0 +1,56 @@
+--- misc/rasqal-0.9.16/src/rasqal-config.in Sun Jun 22 07:07:12 2008
++++ misc/build/rasqal-0.9.16/src/rasqal-config.in Thu Nov 6 12:10:52 2008
+@@ -22,10 +22,19 @@
+ #
+ #
+
+-prefix=@prefix@
+-includes="-I@includedir@/@PACKAGE@"
++prefix=${SOLARVERSION}/${INPATH}
++exec_prefix=${SOLARVERSION}/${INPATH}
++#includedir=${SOLARVERSION}/${INPATH}/inc${UPDMINOREXT}/external
++#libdir=${SOLARVERSION}/${INPATH}/lib${UPDMINOREXT}
++# HACK: map to build directory
++includedir=../../../../inc
++libdir=../../../../lib
++includes=-I${includedir}
+
++#prefix=@prefix@
++#includes="-I@includedir@/@PACKAGE@"
+
++
+ usage()
+ {
+ cat<<EOF
+@@ -104,7 +113,8 @@
+ echo $includes
+ fi
+ if test "$echo_libs" = "yes"; then
+- echo -L@libdir@ -lrasqal
++# echo -L@libdir@ -lrasqal
++ echo -L${libdir} -lrasqal
+ fi
+ if test "$echo_libtool_libs" = "yes"; then
+ echo @libdir@/@RASQAL_LIBTOOLLIBS@
+--- misc/rasqal-0.9.16/Makefile.am 2010-02-12 08:43:21.000000000 +0000
++++ misc/build/rasqal-0.9.16/Makefile.am 2010-02-12 08:43:56.000000000 +0000
+@@ -22,7 +22,7 @@
+
+ noinst_SCRIPTS = rasqal-src-config
+
+-SUBDIRS=src utils tests docs data win32
++SUBDIRS=src tests docs data win32
+
+ pkgconfigdir = $(libdir)/pkgconfig
+ pkgconfig_DATA = rasqal.pc
+--- misc/rasqal-0.9.16/Makefile.in 2010-02-12 08:43:19.000000000 +0000
++++ misc/build/rasqal-0.9.16/Makefile.in 2010-02-12 08:44:03.000000000 +0000
+@@ -242,7 +242,7 @@
+ with_raptor = @with_raptor@
+ with_redland = @with_redland@
+ noinst_SCRIPTS = rasqal-src-config
+-SUBDIRS = src utils tests docs data win32
++SUBDIRS = src tests docs data win32
+ pkgconfigdir = $(libdir)/pkgconfig
+ pkgconfig_DATA = rasqal.pc
+ EXTRA_DIST = ChangeLog ChangeLog.1 ChangeLog.2 ChangeLog.3 ChangeLog.4 \
diff --git a/redland/rasqal/rasqal-0.9.16.patch.win32 b/redland/rasqal/rasqal-0.9.16.patch.win32
new file mode 100644
index 000000000000..51bad96e0e29
--- /dev/null
+++ b/redland/rasqal/rasqal-0.9.16.patch.win32
@@ -0,0 +1,43 @@
+--- misc/rasqal-0.9.16/src/win32_rasqal_config.h Fri Jun 27 04:02:09 2008
++++ misc/build/rasqal-0.9.16/src/win32_rasqal_config.h Thu Nov 6 12:07:06 2008
+@@ -37,10 +37,13 @@
+
+ #define HAVE_STDLIB_H 1
+
++#define HAVE_ERRNO_H 1
++
+ #define HAVE_STRICMP 1
+
+ /* MS names for these functions */
+-#define vsnprintf _vsnprintf
++// next line breaks build on wntmsci12
++//#define vsnprintf _vsnprintf
+ #define snprintf _snprintf
+ #define access _access
+ #define stricmp _stricmp
+@@ -85,6 +88,9 @@
+ #include <io.h>
+ #include <memory.h>
+
++// argh! stupid winnt.h...
++#undef DELETE
++
+ /* This is a SPARQL token define */
+ #ifdef OPTIONAL
+ #undef OPTIONAL
+@@ -116,8 +122,14 @@
+ /* #define RAPTOR_TRIPLES_SOURCE_REDLAND 1 */
+
+ /* Use PCRE regex library */
+-#define RASQAL_REGEX_PCRE 1
++//#define RASQAL_REGEX_PCRE 1
+
++#define HAVE_LIBXML_SCHEMASINTERNALS_H 1
++#define HAVE_LIBXML_XMLSCHEMASTYPES_H 1
++#define HAVE_LIBXML_XMLSCHEMAS_H 1
++
++#define RASQAL_DECIMAL_NONE 1
++
+ #ifdef _DEBUG
+ #define RASQAL_DEBUG 1
+ #endif
diff --git a/redland/rasqal/rasqal-aix.patch b/redland/rasqal/rasqal-aix.patch
new file mode 100644
index 000000000000..86470d421f81
--- /dev/null
+++ b/redland/rasqal/rasqal-aix.patch
@@ -0,0 +1,44 @@
+--- misc/rasqal-0.9.16/config.guess 2010-09-16 03:13:19.000000000 -0500
++++ misc/build/rasqal-0.9.16/config.guess 2010-09-16 03:15:05.000000000 -0500
+@@ -532,7 +532,7 @@
+ echo rs6000-ibm-aix3.2
+ fi
+ exit ;;
+- *:AIX:*:[456])
++ *:AIX:*:[4567])
+ IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
+ if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then
+ IBM_ARCH=rs6000
+@@ -544,6 +544,9 @@
+ else
+ IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
+ fi
++ if [ "$IBM_REV" == "V7BETA" ]; then
++ IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
++ fi
+ echo ${IBM_ARCH}-ibm-aix${IBM_REV}
+ exit ;;
+ *:AIX:*:*)
+--- misc/rasqal-0.9.16/src/rasqal_literal.c 2010-09-09 14:53:30.000000000 -0500
++++ misc/build/rasqal-0.9.16/src/rasqal_literal.c 2010-09-09 14:54:47.000000000 -0500
+@@ -36,8 +36,20 @@
+ #include <stdlib.h>
+ #endif
+ #include <stdarg.h>
++#ifdef _AIX
++# ifndef isnan
++# define isnan(x) \
++ (sizeof (x) == sizeof (long double) ? isnan_ld (x) \
++ : sizeof (x) == sizeof (double) ? isnan_d (x) \
++ : isnan_f (x))
++ static inline int isnan_f (float x) { return x != x; }
++ static inline int isnan_d (double x) { return x != x; }
++ static inline int isnan_ld (long double x) { return x != x; }
++# endif
++#else
+ /* for isnan() */
+ #include <math.h>
++#endif
+
+ #ifdef RASQAL_REGEX_PCRE
+ #include <pcre.h>
diff --git a/redland/rasqal/rasqal2.map b/redland/rasqal/rasqal2.map
new file mode 100644
index 000000000000..622043ac984c
--- /dev/null
+++ b/redland/rasqal/rasqal2.map
@@ -0,0 +1,194 @@
+UDK_3_0_0 {
+global:
+GetVersionInfo;
+rasqal_xsd_decimal_set_string;
+rasqal_xsd_decimal_print;
+rasqal_xsd_decimal_as_counted_string;
+rasqal_xsd_decimal_as_string;
+rasqal_new_xsd_decimal;
+rasqal_free_xsd_decimal;
+rasqal_xsd_decimal_set_long;
+rasqal_xsd_decimal_set_double;
+rasqal_xsd_decimal_add;
+rasqal_xsd_decimal_subtract;
+rasqal_xsd_decimal_multiply;
+rasqal_xsd_decimal_divide;
+rasqal_xsd_decimal_negate;
+rasqal_xsd_decimal_equals;
+rasqal_xsd_decimal_compare;
+rasqal_xsd_decimal_is_zero;
+rasqal_xsd_decimal_get_double;
+rasqal_set_triples_source_factory;
+rasqal_new_variable;
+rasqal_new_variable_typed;
+rasqal_data_graph_print;
+rasqal_prefix_print;
+rasqal_new_data_graph;
+rasqal_new_prefix;
+rasqal_new_triple;
+rasqal_new_triple_from_triple;
+rasqal_new_0op_expression;
+rasqal_new_1op_expression;
+rasqal_new_2op_expression;
+rasqal_new_3op_expression;
+rasqal_new_string_op_expression;
+rasqal_new_literal_expression;
+rasqal_new_function_expression;
+rasqal_new_cast_expression;
+rasqal_free_variable;
+rasqal_free_expression;
+rasqal_free_data_graph;
+rasqal_free_prefix;
+rasqal_free_triple;
+rasqal_expression_evaluate;
+rasqal_variable_set_value;
+rasqal_variable_print;
+rasqal_expression_print;
+rasqal_expression_print_op;
+rasqal_triple_print;
+rasqal_expression_foreach;
+rasqal_expression_visit;
+rasqal_new_expression_from_expression;
+rasqal_triple_get_origin;
+rasqal_triple_set_origin;
+rasqal_features_enumerate;
+rasqal_feature_from_uri;
+rasqal_get_feature_count;
+rasqal_feature_value_type;
+rasqal_version_decimal;
+rasqal_version_release;
+rasqal_version_minor;
+rasqal_version_major;
+rasqal_version_string;
+rasqal_home_url_string;
+rasqal_license_string;
+rasqal_copyright_string;
+rasqal_short_copyright_string;
+rasqal_init;
+rasqal_finish;
+rasqal_language_name_check;
+rasqal_query_set_default_generate_bnodeid_parameters;
+rasqal_free_memory;
+rasqal_alloc_memory;
+rasqal_calloc_memory;
+rasqal_query_set_generate_bnodeid_handler;
+rasqal_languages_enumerate;
+rasqal_graph_pattern_add_constraint;
+rasqal_graph_pattern_print;
+rasqal_graph_pattern_add_sub_graph_pattern;
+rasqal_graph_pattern_get_flags;
+rasqal_graph_pattern_visit;
+rasqal_graph_pattern_get_constraint;
+rasqal_graph_pattern_get_triple;
+rasqal_graph_pattern_get_sub_graph_pattern;
+rasqal_graph_pattern_get_sub_graph_pattern_sequence;
+rasqal_graph_pattern_get_index;
+rasqal_graph_pattern_operator_as_string;
+rasqal_graph_pattern_get_operator;
+rasqal_graph_pattern_get_constraint_sequence;
+rasqal_new_floating_literal;
+rasqal_literal_compare;
+rasqal_literal_equals;
+rasqal_new_double_literal;
+rasqal_new_integer_literal;
+rasqal_new_float_literal;
+rasqal_new_typed_literal;
+rasqal_new_decimal_literal;
+rasqal_new_decimal_literal_from_decimal;
+rasqal_new_string_literal;
+rasqal_new_uri_literal;
+rasqal_new_boolean_literal;
+rasqal_literal_as_node;
+rasqal_free_literal;
+rasqal_literal_print;
+rasqal_literal_print_type;
+rasqal_new_pattern_literal;
+rasqal_new_simple_literal;
+rasqal_new_variable_literal;
+rasqal_literal_as_string;
+rasqal_literal_as_string_flags;
+rasqal_literal_value;
+rasqal_literal_datatype;
+rasqal_literal_as_variable;
+rasqal_new_literal_from_literal;
+rasqal_free_query_results;
+rasqal_query_results_get_bindings;
+rasqal_query_results_get_binding_value;
+rasqal_query_results_get_binding_value_by_name;
+rasqal_query_results_get_triple;
+rasqal_query_results_next;
+rasqal_query_results_next_triple;
+rasqal_query_results_write;
+rasqal_query_results_formatter_write;
+rasqal_query_results_get_boolean;
+rasqal_query_results_get_bindings_count;
+rasqal_query_results_get_binding_name;
+rasqal_query_results_finished;
+rasqal_query_results_get_count;
+rasqal_query_results_is_syntax;
+rasqal_query_results_is_graph;
+rasqal_query_results_is_boolean;
+rasqal_query_results_is_bindings;
+rasqal_new_query;
+rasqal_free_query;
+rasqal_query_set_feature_string;
+rasqal_query_get_feature_string;
+rasqal_query_add_data_graph;
+rasqal_query_set_variable;
+rasqal_query_add_prefix;
+rasqal_query_add_variable;
+rasqal_query_prepare;
+rasqal_query_execute;
+rasqal_query_print;
+rasqal_query_graph_pattern_visit;
+rasqal_query_write;
+rasqal_query_get_graph_pattern_sequence;
+rasqal_query_get_graph_pattern;
+rasqal_query_get_data_graph;
+rasqal_query_get_variable;
+rasqal_query_has_variable;
+rasqal_query_get_triple;
+rasqal_query_get_prefix;
+rasqal_query_get_construct_triple;
+rasqal_query_get_order_condition;
+rasqal_query_get_group_condition;
+rasqal_query_escape_counted_string;
+rasqal_query_iostream_write_escaped_counted_string;
+rasqal_query_get_group_conditions_sequence;
+rasqal_query_get_order_conditions_sequence;
+rasqal_query_get_wildcard;
+rasqal_query_get_verb;
+rasqal_query_set_user_data;
+rasqal_query_get_user_data;
+rasqal_query_verb_as_string;
+rasqal_query_get_construct_triples_sequence;
+rasqal_query_get_query_graph_pattern;
+rasqal_query_get_prefix_sequence;
+rasqal_query_get_triple_sequence;
+rasqal_query_get_all_variable_sequence;
+rasqal_query_get_anonymous_variable_sequence;
+rasqal_query_get_bound_variable_sequence;
+rasqal_query_get_data_graph_sequence;
+rasqal_query_set_offset;
+rasqal_query_get_offset;
+rasqal_query_set_limit;
+rasqal_query_get_limit;
+rasqal_query_set_explain;
+rasqal_query_get_explain;
+rasqal_query_set_distinct;
+rasqal_query_get_distinct;
+rasqal_query_get_feature;
+rasqal_query_set_feature;
+rasqal_query_set_warning_handler;
+rasqal_query_set_error_handler;
+rasqal_query_set_fatal_error_handler;
+rasqal_query_get_label;
+rasqal_query_get_name;
+rasqal_query_results_formats_check;
+rasqal_new_query_results_formatter;
+rasqal_new_query_results_formatter_by_mime_type;
+rasqal_query_results_formats_enumerate;
+rasqal_query_results_formats_enumerate_full;
+rasqal_free_query_results_formatter;
+rasqal_query_results_formatter_get_mime_type;
+};
diff --git a/redland/redland/makefile.mk b/redland/redland/makefile.mk
new file mode 100644
index 000000000000..c8a04dce3b45
--- /dev/null
+++ b/redland/redland/makefile.mk
@@ -0,0 +1,163 @@
+#*************************************************************************
+#
+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+#
+# Copyright 2000, 2010 Oracle and/or its affiliates.
+#
+# OpenOffice.org - a multi-platform office productivity suite
+#
+# This file is part of OpenOffice.org.
+#
+# OpenOffice.org is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License version 3
+# only, as published by the Free Software Foundation.
+#
+# OpenOffice.org is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License version 3 for more details
+# (a copy is included in the LICENSE file that accompanied this code).
+#
+# You should have received a copy of the GNU Lesser General Public License
+# version 3 along with OpenOffice.org. If not, see
+# <http://www.openoffice.org/license.html>
+# for a copy of the LGPLv3 License.
+#
+#*************************************************************************
+
+PRJ=..
+
+PRJNAME=redland
+TARGET=so_redland
+
+# --- Settings -----------------------------------------------------
+
+.INCLUDE : settings.mk
+
+.IF "$(SYSTEM_REDLAND)" == "YES"
+all:
+ @echo "An already available installation of Redland RDF should exist on your system."
+ @echo "Therefore the version provided here does not need to be built in addition."
+.ENDIF
+
+# --- Files --------------------------------------------------------
+
+.INCLUDE : ../redlandversion.mk
+
+REDLANDVERSION=1.0.8
+
+TARFILE_NAME=redland-$(REDLANDVERSION)
+TARFILE_MD5=ca66e26082cab8bb817185a116db809b
+
+ADDITIONAL_FILES=librdf/makefile.mk librdf/rdf_config.h
+
+OOO_PATCH_FILES= \
+ $(TARFILE_NAME).patch.legal \
+ $(TARFILE_NAME).patch.autotools \
+ $(TARFILE_NAME).patch.dmake \
+ $(TARFILE_NAME).patch.ooo_build \
+ $(TARFILE_NAME).patch.win32 \
+ redland-aix.patch
+
+PATCH_FILES=$(OOO_PATCH_FILES) \
+
+
+.IF "$(OS)"=="OS2"
+BUILD_ACTION=dmake
+BUILD_DIR=$(CONFIGURE_DIR)$/librdf
+.ELIF "$(OS)"=="WNT"
+.IF "$(COM)"=="GCC"
+redland_CC=$(CC) -mthreads
+.IF "$(MINGW_SHARED_GCCLIB)"=="YES"
+redland_CC+=-shared-libgcc
+.ENDIF
+redland_LIBS=
+.IF "$(MINGW_SHARED_GXXLIB)"=="YES"
+redland_LIBS+=$(MINGW_SHARED_LIBSTDCPP)
+.ENDIF
+
+CONFIGURE_DIR=
+CONFIGURE_ACTION=.$/configure PATH="..$/..$/..$/bin:$$PATH"
+CONFIGURE_FLAGS=--disable-static --disable-gtk-doc --with-openssl-digests --with-xml-parser=libxml --with-raptor=system --with-rasqual=system --without-bdb --without-sqlite --without-mysql --without-postgresql --without-threestore --with-regex-library=posix --with-decimal=none --with-www=xml --build=i586-pc-mingw32 --host=i586-pc-mingw32 lt_cv_cc_dll_switch="-shared" CC="$(redland_CC)" CPPFLAGS="-nostdinc $(INCLUDE)" LDFLAGS="-no-undefined -Wl,--enable-runtime-pseudo-reloc-v2,--export-all-symbols -L$(ILIB:s/;/ -L/)" LIBS="$(redland_LIBS)" OBJDUMP="$(WRAPCMD) objdump" LIBXML2LIB=$(LIBXML2LIB) XSLTLIB="$(XSLTLIB)"
+BUILD_ACTION=$(GNUMAKE)
+BUILD_FLAGS+= -j$(EXTMAXPROCESS)
+BUILD_DIR=$(CONFIGURE_DIR)
+.ELSE
+# there is no wntmsci build environment in the tarball; we use custom dmakefile
+BUILD_ACTION=dmake
+BUILD_DIR=$(CONFIGURE_DIR)$/librdf
+.ENDIF
+.ELSE # "WNT"
+
+.IF "$(OS)$(COM)"=="LINUXGCC" || "$(OS)$(COM)"=="FREEBSDGCC"
+LDFLAGS:=-Wl,-rpath,'$$$$ORIGIN:$$$$ORIGIN/../ure-link/lib' -Wl,-noinhibit-exec
+.ENDIF # "$(OS)$(COM)"=="LINUXGCC"
+.IF "$(OS)$(COM)"=="SOLARISC52"
+LDFLAGS:=-Wl,-R'$$$$ORIGIN:$$$$ORIGIN/../ure-link/lib'
+.ENDIF # "$(OS)$(COM)"=="SOLARISC52"
+
+.IF "$(COM)"=="C52" && "$(CPU)"=="U"
+CFLAGS=-m64
+.EXPORT: CFLAGS
+.ENDIF
+
+# NB: SOLARDIR before SYSBASE, because linux SYSBASE contains obsolete libcrypto
+CPPFLAGS+:=-I$(PWD)$/$(INCCOM) -I$(SOLARINCDIR)$/external
+LDFLAGS+:=-L$(PWD)$/$(LB) -L$(SOLARLIBDIR)
+
+.IF "$(OS)"=="AIX"
+LDFLAGS+:=$(LINKFLAGS) $(LINKFLAGSRUNPATH_OOO)
+.ENDIF
+
+.IF "$(SYSBASE)"!=""
+CPPFLAGS+:=-I$(SYSBASE)$/usr$/include
+.IF "$(OS)"=="SOLARIS" || "$(OS)"=="LINUX"
+LDFLAGS+:=-L$(SYSBASE)$/lib -L$(SYSBASE)$/usr$/lib -lpthread -ldl
+.ENDIF
+.ENDIF # "$(SYSBASE)"!=""
+
+.IF "$(OS)"=="MACOSX"
+LDFLAGS+:=-Wl,-dylib_file,@loader_path/libraptor.1.dylib:$(PWD)/$(LB)/libraptor.1.dylib
+.ENDIF
+
+CPPFLAGS+:=$(EXTRA_CDEFS) $(EXTRA_CFLAGS)
+LDFLAGS+:=$(EXTRA_LINKFLAGS)
+XSLTLIB!:=$(XSLTLIB) # expand dmake variables for xslt-config
+
+.EXPORT: CPPFLAGS
+.EXPORT: LDFLAGS
+.EXPORT: LIBXML2LIB
+.EXPORT: XSLTLIB
+
+CONFIGURE_DIR=
+CONFIGURE_ACTION=.$/configure PATH="..$/..$/..$/bin:$$PATH"
+CONFIGURE_FLAGS=--disable-static --disable-gtk-doc --with-threads --with-openssl-digests --with-xml-parser=libxml --with-raptor=system --with-rasqual=system --without-bdb --without-sqlite --without-mysql --without-postgresql --without-threestore --with-regex-library=posix --with-decimal=none --with-www=xml
+BUILD_ACTION=$(AUGMENT_LIBRARY_PATH) $(GNUMAKE)
+BUILD_FLAGS+= -j$(EXTMAXPROCESS)
+BUILD_DIR=$(CONFIGURE_DIR)
+.ENDIF
+
+
+OUT2INC+=librdf$/*.h
+
+.IF "$(OS)"=="MACOSX"
+OUT2LIB+=librdf$/.libs$/librdf.$(REDLAND_MAJOR).dylib
+.ELIF "$(OS)"=="WNT"
+.IF "$(COM)"=="GCC"
+OUT2LIB+=librdf$/.libs$/*.a
+OUT2BIN+=librdf$/.libs$/*.dll
+.ELSE
+# if we use dmake, this is done automagically
+.ENDIF
+.ELIF "$(OS)"=="OS2"
+# if we use dmake, this is done automagically
+.ELSE
+OUT2LIB+=librdf$/.libs$/librdf.so.$(REDLAND_MAJOR)
+.ENDIF
+
+# --- Targets ------------------------------------------------------
+
+.INCLUDE : set_ext.mk
+.INCLUDE : target.mk
+.INCLUDE : tg_ext.mk
+
diff --git a/redland/redland/redland-1.0.8.patch.autotools b/redland/redland/redland-1.0.8.patch.autotools
new file mode 100644
index 000000000000..5b29d0b7708b
--- /dev/null
+++ b/redland/redland/redland-1.0.8.patch.autotools
@@ -0,0 +1,58 @@
+--- misc/redland-1.0.8/configure Fri Jul 4 18:00:39 2008
++++ misc/build/redland-1.0.8/configure Wed Feb 18 13:27:43 2009
+@@ -4671,7 +4671,7 @@
+
+ cygwin*)
+ # func_win32_libid is a shell function defined in ltmain.sh
+- lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
++ lt_cv_deplibs_check_method='file_magic ^x86 archive|^x86 DLL'
+ lt_cv_file_magic_cmd='func_win32_libid'
+ ;;
+
+@@ -4680,7 +4680,7 @@
+ # func_win32_libid shell function, so use a weaker test based on 'objdump',
+ # unless we find 'file', for example because we are cross-compiling.
+ if ( file / ) >/dev/null 2>&1; then
+- lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
++ lt_cv_deplibs_check_method='file_magic ^x86 archive|^x86 DLL'
+ lt_cv_file_magic_cmd='func_win32_libid'
+ else
+ lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
+--- misc/redland-1.0.8/ltmain.sh Tue Apr 29 23:33:55 2008
++++ misc/build/redland-1.0.8/ltmain.sh Wed Feb 18 13:28:39 2009
+@@ -1565,6 +1565,11 @@
+ [\\/]* | [A-Za-z]:[\\/]*) ;;
+ *)
+ absdir=`cd "$dir" && pwd`
++ case $host_os in
++ mingw*)
++ absdir=`cygpath -m $absdir`
++ ;;
++ esac
+ if test -z "$absdir"; then
+ $echo "$modename: cannot determine absolute directory name of \`$dir'" 1>&2
+ absdir="$dir"
+@@ -3262,9 +3267,9 @@
+ revision="$number_revision"
+ ;;
+ freebsd-aout|freebsd-elf|sunos)
+- current="$number_major"
+- revision="$number_minor"
+- age="0"
++ current=`expr $number_major + $number_minor`
++ age="$number_minor"
++ revision="$number_revision"
+ ;;
+ irix|nonstopux)
+ current=`expr $number_major + $number_minor`
+@@ -3344,8 +3349,8 @@
+ ;;
+
+ freebsd-elf)
+- major=".$current"
+- versuffix=".$current";
++ major=.`expr $current - $age`
++ versuffix="$major.$age.$revision"
+ ;;
+
+ irix | nonstopux)
diff --git a/redland/redland/redland-1.0.8.patch.dmake b/redland/redland/redland-1.0.8.patch.dmake
new file mode 100644
index 000000000000..34ba51d1c29a
--- /dev/null
+++ b/redland/redland/redland-1.0.8.patch.dmake
@@ -0,0 +1,115 @@
+--- misc/redland-1.0.8/librdf/makefile.mk Mon Jun 16 19:32:46 2008
++++ misc/build/redland-1.0.8/librdf/makefile.mk Mon Jun 16 19:26:20 2008
+@@ -1,1 +1,111 @@
+-dummy
++#*************************************************************************
++#
++# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
++#
++# Copyright 2000, 2010 Oracle and/or its affiliates.
++#
++# OpenOffice.org - a multi-platform office productivity suite
++#
++# This file is part of OpenOffice.org.
++#
++# OpenOffice.org is free software: you can redistribute it and/or modify
++# it under the terms of the GNU Lesser General Public License version 3
++# only, as published by the Free Software Foundation.
++#
++# OpenOffice.org is distributed in the hope that it will be useful,
++# but WITHOUT ANY WARRANTY; without even the implied warranty of
++# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
++# GNU Lesser General Public License version 3 for more details
++# (a copy is included in the LICENSE file that accompanied this code).
++#
++# You should have received a copy of the GNU Lesser General Public License
++# version 3 along with OpenOffice.org. If not, see
++# <http://www.openoffice.org/license.html>
++# for a copy of the LGPLv3 License.
++#
++#*************************************************************************
++
++PRJ=..$/..$/..$/..$/..
++
++PRJNAME=redland
++TARGET=librdf
++LIBTARGET=NO
++UWINAPILIB=
++
++EXTERNAL_WARNINGS_NOT_ERRORS=TRUE
++
++
++# --- Settings -----------------------------------------------------
++
++.INCLUDE : settings.mk
++
++CDEFS+=-DLIBRDF_INTERNAL -DWIN32 -DNDEBUG -D_WINDOWS -D_USRDLL -DWIN32_EXPORTS
++
++# --- Files --------------------------------------------------------
++
++SLOFILES = \
++ $(SLO)$/rdf_concepts.obj \
++ $(SLO)$/rdf_digest.obj \
++ $(SLO)$/rdf_digest_md5.obj \
++ $(SLO)$/rdf_digest_openssl.obj \
++ $(SLO)$/rdf_digest_sha1.obj \
++ $(SLO)$/rdf_files.obj \
++ $(SLO)$/rdf_hash.obj \
++ $(SLO)$/rdf_hash_cursor.obj \
++ $(SLO)$/rdf_hash_memory.obj \
++ $(SLO)$/rdf_heuristics.obj \
++ $(SLO)$/rdf_init.obj \
++ $(SLO)$/rdf_iterator.obj \
++ $(SLO)$/rdf_list.obj \
++ $(SLO)$/rdf_log.obj \
++ $(SLO)$/rdf_model.obj \
++ $(SLO)$/rdf_model_storage.obj \
++ $(SLO)$/rdf_node.obj \
++ $(SLO)$/rdf_parser.obj \
++ $(SLO)$/rdf_parser_raptor.obj \
++ $(SLO)$/rdf_query.obj \
++ $(SLO)$/rdf_query_rasqal.obj \
++ $(SLO)$/rdf_query_results.obj \
++ $(SLO)$/rdf_query_triples.obj \
++ $(SLO)$/rdf_serializer.obj \
++ $(SLO)$/rdf_serializer_raptor.obj \
++ $(SLO)$/rdf_statement.obj \
++ $(SLO)$/rdf_storage.obj \
++ $(SLO)$/rdf_storage_file.obj \
++ $(SLO)$/rdf_storage_list.obj \
++ $(SLO)$/rdf_storage_hashes.obj \
++ $(SLO)$/rdf_stream.obj \
++ $(SLO)$/rdf_uri.obj \
++ $(SLO)$/rdf_utf8.obj \
++
++
++# $(SLO)$/rdf_hash_bdb.obj \
++# $(SLO)$/rdf_storage_mysql.obj \
++# $(SLO)$/rdf_storage_sqlite.obj \
++
++
++SHL1DEPN= makefile.mk
++SHL1OBJS= $(SLOFILES)
++
++#SHL1TARGET= $(TARGET)$(DLLPOSTFIX)
++SHL1TARGET= $(TARGET)
++SHL1IMPLIB= $(TARGET)
++SHL1USE_EXPORTS=name
++
++#SHL1VERSIONMAP=../service/exports.map
++SHL1DEF=$(MISC)$/$(SHL1TARGET).def
++DEF1NAME=$(SHL1TARGET)
++
++SHL1STDLIBS= \
++ $(OPENSSLLIB) \
++ $(PRJ)$/$(INPATH)$/lib$/libraptor.lib \
++ $(PRJ)$/$(INPATH)$/lib$/librasqal.lib \
++
++
++#$(LIBXML2LIB) \
++# $(XSLTLIB) \
++
++# --- Targets ------------------------------------------------------
++
++.INCLUDE : target.mk
++
diff --git a/redland/redland/redland-1.0.8.patch.legal b/redland/redland/redland-1.0.8.patch.legal
new file mode 100644
index 000000000000..9e9a25bef78e
--- /dev/null
+++ b/redland/redland/redland-1.0.8.patch.legal
@@ -0,0 +1,54 @@
+--- misc/redland-1.0.8/LICENSE.txt Tue Jul 1 07:55:28 2008
++++ misc/build/redland-1.0.8/LICENSE.txt Thu Nov 6 12:44:39 2008
+@@ -76,3 +76,15 @@
+ 10. NOTICE
+ 11. http://www.dajobe.org/
+ 12. http://www.bristol.ac.uk/
++
++
++LGPL Disclaimer
++
++For the avoidance of doubt, except that if any license choice other
++than GPL or LGPL is available it will apply instead, Sun elects to
++use only the Lesser General Public License version 2.1 (LGPLv2) at
++this time for any software where a choice of LGPL license versions
++is made available with the language indicating that LGPLv2.1 or any
++later version may be used, or where a choice of which version of the
++LGPL is applied is otherwise unspecified.
++
+--- misc/redland-1.0.8/raptor/LICENSE.txt Sun Mar 30 06:52:22 2008
++++ misc/build/redland-1.0.8/raptor/LICENSE.txt Thu Nov 6 12:44:39 2008
+@@ -60,3 +60,15 @@
+
+ Copyright (C) 2000-2008 David Beckett
+ Copyright (C) 2000-2005 University of Bristol
++
++
++LGPL Disclaimer
++
++For the avoidance of doubt, except that if any license choice other
++than GPL or LGPL is available it will apply instead, Sun elects to
++use only the Lesser General Public License version 2.1 (LGPLv2) at
++this time for any software where a choice of LGPL license versions
++is made available with the language indicating that LGPLv2.1 or any
++later version may be used, or where a choice of which version of the
++LGPL is applied is otherwise unspecified.
++
+--- misc/redland-1.0.8/rasqal/LICENSE.txt Fri Jun 27 04:24:52 2008
++++ misc/build/redland-1.0.8/rasqal/LICENSE.txt Thu Nov 6 12:44:40 2008
+@@ -60,3 +60,15 @@
+
+ Copyright (C) 2003-2008 Dave Beckett
+ Copyright (C) 2003-2005 University of Bristol
++
++
++LGPL Disclaimer
++
++For the avoidance of doubt, except that if any license choice other
++than GPL or LGPL is available it will apply instead, Sun elects to
++use only the Lesser General Public License version 2.1 (LGPLv2) at
++this time for any software where a choice of LGPL license versions
++is made available with the language indicating that LGPLv2.1 or any
++later version may be used, or where a choice of which version of the
++LGPL is applied is otherwise unspecified.
++
diff --git a/redland/redland/redland-1.0.8.patch.ooo_build b/redland/redland/redland-1.0.8.patch.ooo_build
new file mode 100644
index 000000000000..805a88d49ea2
--- /dev/null
+++ b/redland/redland/redland-1.0.8.patch.ooo_build
@@ -0,0 +1,22 @@
+--- misc/redland-1.0.8/Makefile.am 2010-02-12 08:47:40.000000000 +0000
++++ misc/build/redland-1.0.8/Makefile.am 2010-02-12 08:47:51.000000000 +0000
+@@ -48,7 +48,7 @@
+ # to ensure that the raptor and rasqal subdirectories are called
+ # as CONFIG_SUBDIR directories.
+ #
+-SUBDIRS=@LOCAL_SUBDIRS@ librdf examples utils demos docs data
++SUBDIRS=@LOCAL_SUBDIRS@ librdf examples demos docs data
+
+ EXTRA_DIST=ChangeLog ChangeLog.1 ChangeLog.2 ChangeLog.3 ChangeLog.4 \
+ ChangeLog.5 ChangeLog.6 ChangeLog.7 \
+--- misc/redland-1.0.8/Makefile.in 2010-02-12 08:47:39.000000000 +0000
++++ misc/build/redland-1.0.8/Makefile.in 2010-02-12 08:47:55.000000000 +0000
+@@ -283,7 +283,7 @@
+ # to ensure that the raptor and rasqal subdirectories are called
+ # as CONFIG_SUBDIR directories.
+ #
+-SUBDIRS = @LOCAL_SUBDIRS@ librdf examples utils demos docs data
++SUBDIRS = @LOCAL_SUBDIRS@ librdf examples demos docs data
+ EXTRA_DIST = ChangeLog ChangeLog.1 ChangeLog.2 ChangeLog.3 ChangeLog.4 \
+ ChangeLog.5 ChangeLog.6 ChangeLog.7 \
+ README NEWS LICENSE.txt TODO \
diff --git a/redland/redland/redland-1.0.8.patch.win32 b/redland/redland/redland-1.0.8.patch.win32
new file mode 100644
index 000000000000..41d3503dcc98
--- /dev/null
+++ b/redland/redland/redland-1.0.8.patch.win32
@@ -0,0 +1,154 @@
+--- misc/redland-1.0.8/librdf/win32_rdf_config.h Tue Jul 1 05:10:26 2008
++++ misc/build/redland-1.0.8/librdf/win32_rdf_config.h Wed Feb 18 13:31:07 2009
+@@ -43,7 +43,8 @@
+ #define HAVE_STRICMP 1
+
+ /* MS names for these functions */
+-#define vsnprintf _vsnprintf
++// next line breaks build on wntmsci12
++//#define vsnprintf _vsnprintf
+ #define snprintf _snprintf
+ #define access _access
+ #define stricmp _stricmp
+@@ -72,40 +73,40 @@
+ */
+
+ /* BDB has close method with 2 args */
+-#define HAVE_BDB_CLOSE_2_ARGS 1
++// #define HAVE_BDB_CLOSE_2_ARGS 1
+
+ /* BDB defines DBC */
+-#define HAVE_BDB_CURSOR 1
++// #define HAVE_BDB_CURSOR 1
+
+ /* BDB cursor method has 4 arguments */
+-#define HAVE_BDB_CURSOR_4_ARGS 1
++// #define HAVE_BDB_CURSOR_4_ARGS 1
+
+ /* BDB defines DB_TXN */
+-#define HAVE_BDB_DB_TXN 1
++// #define HAVE_BDB_DB_TXN 1
+
+ /* BDB has fd method with 2 args */
+-#define HAVE_BDB_FD_2_ARGS 1
++// #define HAVE_BDB_FD_2_ARGS 1
+
+ /* Have BDB hash support */
+-#define HAVE_BDB_HASH 1
++// #define HAVE_BDB_HASH 1
+
+ /* BDB has open method with 6 args */
+ /* #undef HAVE_BDB_OPEN_6_ARGS */
+
+ /* BDB has open method with 7 args */
+-#define HAVE_BDB_OPEN_7_ARGS 1
++// #define HAVE_BDB_OPEN_7_ARGS 1
+
+ /* BDB has set_flags method */
+-#define HAVE_BDB_SET_FLAGS 1
++// #define HAVE_BDB_SET_FLAGS 1
+
+ /* BDB has dbopen method */
+ /* #undef HAVE_DBOPEN */
+
+ /* BDB has db_create method */
+-#define HAVE_DB_CREATE 1
++// #define HAVE_DB_CREATE 1
+
+ /* Define to 1 if you have the <db.h> header file. */
+-#define HAVE_DB_H 1
++// #define HAVE_DB_H 1
+
+ /* Define to 1 if you have the <dlfcn.h> header file. */
+ /* undef HAVE_DLFCN_H */
+@@ -141,13 +142,13 @@
+ /* #undef HAVE_LIBWWW */
+
+ /* Have local MD5 digest */
+-#define HAVE_LOCAL_MD5_DIGEST 1
++// #define HAVE_LOCAL_MD5_DIGEST 1
+
+ /* Have local RIPEMD160 digest */
+ /* #undef HAVE_LOCAL_RIPEMD160_DIGEST */
+
+ /* Have local SHA1 digest */
+-#define HAVE_LOCAL_SHA1_DIGEST 1
++// #define HAVE_LOCAL_SHA1_DIGEST 1
+
+ /* Define to 1 if you have the <memory.h> header file. */
+ #define HAVE_MEMORY_H 1
+@@ -159,25 +160,33 @@
+ #define HAVE_MKTEMP 1
+
+ /* MySQL libraries are present */
+-#define HAVE_MYSQL 1
++// #define HAVE_MYSQL 1
+
+ /* Define to 1 if you have the <openssl/crypto.h> header file. */
+ /* #undef HAVE_OPENSSL_CRYPTO_H */
++#define HAVE_OPENSSL_CRYPTO_H 1
+
+ /* Have openssl MD5 digest */
+ /* #undef HAVE_OPENSSL_CRYPTO_MD5_DIGEST */
++#define HAVE_OPENSSL_CRYPTO_MD5_DIGEST 1
+
+ /* Have openssl RIPEMD160 digest */
+ /* #undef HAVE_OPENSSL_CRYPTO_RIPEMD160_DIGEST */
++#define HAVE_OPENSSL_CRYPTO_RIPEMD160_DIGEST 1
+
+ /* Have openssl SHA1 digest */
+ /* #undef HAVE_OPENSSL_CRYPTO_SHA1_DIGEST */
++#define HAVE_OPENSSL_CRYPTO_SHA1_DIGEST 1
+
+ /* Have openssl digests */
+ /* #undef HAVE_OPENSSL_DIGESTS */
++#define HAVE_OPENSSL_DIGESTS 1
+
+ /* Define to 1 if you have the <pthread.h> header file. */
+ /* #undef HAVE_PTHREAD_H */
++#ifdef __MINGW32__
++#undef HAVE_PTHREAD_H
++#endif
+
+ /* Define to 1 if you have the <stdint.h> header file. */
+ #define HAVE_STDINT_H 1
+@@ -246,7 +255,7 @@
+ #define SIZEOF_UNSIGNED_LONG_LONG 8
+
+ /* SQLite API version */
+-#define SQLITE_API 3
++// #define SQLITE_API 3
+
+ /* Define to 1 if you have the ANSI C header files. */
+ #define STDC_HEADERS 1
+@@ -254,14 +263,17 @@
+ /* Building file storage */
+ #define STORAGE_FILE 1
+
++#define STORAGE_HASHES 1
++#define STORAGE_MEMORY 1
++
+ /* Building MySQL storage */
+-#define STORAGE_MYSQL 1
++// #define STORAGE_MYSQL 1
+
+ /* Building PostgreSQL storage */
+ /*#undef STORAGE_POSTGRESQL*/
+
+ /* Building SQLite storage */
+-#define STORAGE_SQLITE 1
++// #define STORAGE_SQLITE 1
+
+ /* Building 3store storage */
+ /*#undef STORAGE_TSTORE*/
+--- misc/redland-1.0.8/utils/rdfproc.c Tue Jul 1 05:10:25 2008
++++ misc/build/redland-1.0.8/utils/rdfproc.c Wed Feb 18 13:26:41 2009
+@@ -28,7 +28,7 @@
+ #endif
+
+ #ifdef WIN32
+-#include <win32_config.h>
++#include <win32_rdf_config.h>
+ #endif
+
+ #include <stdio.h>
diff --git a/redland/redland/redland-aix.patch b/redland/redland/redland-aix.patch
new file mode 100644
index 000000000000..20d52e4787f0
--- /dev/null
+++ b/redland/redland/redland-aix.patch
@@ -0,0 +1,21 @@
+--- misc/redland-1.0.8/config.guess 2010-09-16 03:21:03.000000000 -0500
++++ misc/build/redland-1.0.8/config.guess 2010-09-16 03:22:33.000000000 -0500
+@@ -532,7 +532,7 @@
+ echo rs6000-ibm-aix3.2
+ fi
+ exit ;;
+- *:AIX:*:[456])
++ *:AIX:*:[4567])
+ IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
+ if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then
+ IBM_ARCH=rs6000
+@@ -544,6 +544,9 @@
+ else
+ IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
+ fi
++ if [ "$IBM_REV" == "V7BETA" ]; then
++ IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
++ fi
+ echo ${IBM_ARCH}-ibm-aix${IBM_REV}
+ exit ;;
+ *:AIX:*:*)
diff --git a/redland/redland/redland2.map b/redland/redland/redland2.map
new file mode 100644
index 000000000000..5798f461684b
--- /dev/null
+++ b/redland/redland/redland2.map
@@ -0,0 +1,316 @@
+UDK_3_0_0 {
+global:
+GetVersionInfo;
+librdf_get_concept_resource_by_index;
+librdf_get_concept_uri_by_index;
+librdf_new_digest;
+librdf_digest_update_string;
+librdf_digest_final;
+librdf_digest_print;
+librdf_digest_to_string;
+librdf_free_digest;
+librdf_digest_get_digest_length;
+librdf_digest_get_digest;
+librdf_digest_update;
+librdf_digest_init;
+librdf_new_hash_from_string;
+librdf_new_hash_from_array_of_strings;
+librdf_hash_get_del;
+librdf_hash_get_as_boolean;
+librdf_hash_get_as_long;
+librdf_hash_get;
+librdf_hash_interpret_template;
+librdf_hash_print;
+librdf_hash_print_keys;
+librdf_hash_print_values;
+librdf_new_hash_from_hash;
+librdf_free_hash;
+librdf_hash_put_strings;
+librdf_version_decimal;
+librdf_version_release;
+librdf_version_minor;
+librdf_version_major;
+librdf_version_string;
+librdf_copyright_string;
+librdf_short_copyright_string;
+librdf_init_world;
+librdf_new_world;
+librdf_destroy_world;
+librdf_free_world;
+librdf_world_open;
+librdf_world_init_mutex;
+librdf_world_set_feature;
+librdf_world_get_feature;
+librdf_world_set_digest;
+librdf_world_set_logger;
+librdf_world_set_warning;
+librdf_world_set_error;
+librdf_iterator_have_elements;
+librdf_iterator_end;
+librdf_iterator_next;
+librdf_iterator_get_object;
+librdf_iterator_get_context;
+librdf_iterator_get_key;
+librdf_iterator_get_value;
+librdf_free_iterator;
+librdf_iterator_add_map;
+librdf_new_iterator;
+librdf_new_empty_iterator;
+librdf_log_message_locator;
+librdf_log_message_message;
+librdf_log_message_facility;
+librdf_log_message_level;
+librdf_log_message_code;
+librdf_new_model;
+librdf_new_model_with_options;
+librdf_model_enumerate;
+librdf_free_model;
+librdf_model_add_typed_literal_statement;
+librdf_model_add_string_literal_statement;
+librdf_model_add;
+librdf_model_get_source;
+librdf_model_get_arc;
+librdf_model_get_target;
+librdf_model_add_submodel;
+librdf_model_remove_submodel;
+librdf_model_print;
+librdf_model_add_statement;
+librdf_model_remove_statement;
+librdf_model_contains_statement;
+librdf_model_context_add_statements;
+librdf_model_context_add_statement;
+librdf_model_context_remove_statements;
+librdf_model_context_remove_statement;
+librdf_model_find_statements_with_options;
+librdf_model_find_statements_in_context;
+librdf_new_model_from_model;
+librdf_model_size;
+librdf_model_add_statements;
+librdf_model_as_stream;
+librdf_model_serialise;
+librdf_model_find_statements;
+librdf_model_get_sources;
+librdf_model_get_arcs;
+librdf_model_get_targets;
+librdf_model_get_arcs_in;
+librdf_model_get_arcs_out;
+librdf_model_has_arc_in;
+librdf_model_has_arc_out;
+librdf_model_contains_context;
+librdf_model_context_as_stream;
+librdf_model_context_serialize;
+librdf_model_query_execute;
+librdf_model_sync;
+librdf_model_get_storage;
+librdf_model_get_contexts;
+librdf_model_get_feature;
+librdf_model_set_feature;
+librdf_model_load;
+librdf_model_to_string;
+librdf_model_to_counted_string;
+librdf_model_transaction_get_handle;
+librdf_model_transaction_rollback;
+librdf_model_transaction_commit;
+librdf_model_transaction_start_with_handle;
+librdf_model_transaction_start;
+librdf_new_node_from_uri_local_name;
+librdf_new_node_from_normalised_uri_string;
+librdf_node_decode;
+librdf_new_node_from_uri_string;
+librdf_new_node_from_uri;
+librdf_new_node_from_literal;
+librdf_new_node_from_typed_literal;
+librdf_new_node_from_typed_counted_literal;
+librdf_new_node;
+librdf_new_node_from_blank_identifier;
+librdf_free_node;
+librdf_node_get_literal_value_as_latin1;
+librdf_node_get_literal_value_is_wf_xml;
+librdf_node_get_li_ordinal;
+librdf_node_print;
+librdf_node_to_string;
+librdf_node_to_counted_string;
+librdf_node_encode;
+librdf_node_static_iterator_create;
+librdf_new_node_from_node;
+librdf_node_get_uri;
+librdf_node_get_type;
+librdf_node_get_literal_value;
+librdf_node_get_literal_value_as_counted_string;
+librdf_node_get_literal_value_language;
+librdf_node_get_literal_value_datatype_uri;
+librdf_node_get_blank_identifier;
+librdf_node_is_resource;
+librdf_node_is_literal;
+librdf_node_is_blank;
+librdf_node_equals;
+librdf_parser_register_factory;
+librdf_new_parser;
+librdf_parser_enumerate;
+librdf_new_parser_from_factory;
+librdf_free_parser;
+librdf_parser_parse_as_stream;
+librdf_parser_parse_into_model;
+librdf_parser_parse_string_as_stream;
+librdf_parser_parse_string_into_model;
+librdf_parser_parse_counted_string_as_stream;
+librdf_parser_parse_counted_string_into_model;
+librdf_parser_get_feature;
+librdf_parser_set_feature;
+librdf_parser_guess_name;
+librdf_parser_get_uri_filter;
+librdf_parser_set_uri_filter;
+librdf_parser_get_namespaces_seen_count;
+librdf_parser_get_namespaces_seen_uri;
+librdf_parser_get_namespaces_seen_prefix;
+librdf_parser_get_accept_header;
+librdf_parser_set_warning;
+librdf_parser_set_error;
+librdf_query_register_factory;
+librdf_new_query;
+librdf_new_query_from_query;
+librdf_new_query_from_factory;
+librdf_free_query;
+librdf_query_execute;
+librdf_query_set_offset;
+librdf_query_get_offset;
+librdf_query_set_limit;
+librdf_query_get_limit;
+librdf_free_query_results;
+librdf_query_results_to_string;
+librdf_query_results_to_counted_string;
+librdf_query_results_to_file;
+librdf_query_results_to_file_handle;
+librdf_query_results_get_count;
+librdf_query_results_next;
+librdf_query_results_finished;
+librdf_query_results_get_bindings;
+librdf_query_results_get_binding_value;
+librdf_query_results_get_binding_name;
+librdf_query_results_get_binding_value_by_name;
+librdf_query_results_get_bindings_count;
+librdf_query_results_is_bindings;
+librdf_query_results_is_boolean;
+librdf_query_results_is_graph;
+librdf_query_results_is_syntax;
+librdf_query_results_get_boolean;
+librdf_query_results_as_stream;
+librdf_query_results_formats_check;
+librdf_query_results_formats_enumerate;
+librdf_query_results_formatter_write;
+librdf_free_query_results_formatter;
+librdf_new_query_results_formatter_by_mime_type;
+librdf_new_query_results_formatter;
+librdf_serializer_register_factory;
+librdf_new_serializer;
+librdf_serializer_enumerate;
+librdf_new_serializer_from_factory;
+librdf_free_serializer;
+librdf_serializer_serialize_stream_to_file;
+librdf_serializer_serialize_model_to_file;
+librdf_serializer_set_namespace;
+librdf_serializer_serialize_stream_to_file_handle;
+librdf_serializer_serialize_model;
+librdf_serializer_serialize_model_to_file_handle;
+librdf_serializer_serialize_stream_to_counted_string;
+librdf_serializer_serialize_model_to_counted_string;
+librdf_serializer_serialize_stream_to_string;
+librdf_serializer_serialize_model_to_string;
+librdf_serializer_serialize_stream_to_iostream;
+librdf_serializer_serialize_model_to_iostream;
+librdf_serializer_get_feature;
+librdf_serializer_set_feature;
+librdf_serializer_set_warning;
+librdf_serializer_set_error;
+librdf_new_statement_from_statement;
+librdf_new_statement_from_nodes;
+librdf_new_statement;
+librdf_statement_init;
+librdf_free_statement;
+librdf_statement_is_complete;
+librdf_statement_print;
+librdf_statement_to_string;
+librdf_statement_equals;
+librdf_statement_match;
+librdf_statement_encode;
+librdf_statement_encode_parts;
+librdf_statement_decode;
+librdf_statement_decode_parts;
+librdf_statement_clear;
+librdf_statement_get_subject;
+librdf_statement_set_subject;
+librdf_statement_get_predicate;
+librdf_statement_set_predicate;
+librdf_statement_get_object;
+librdf_statement_set_object;
+librdf_storage_register_factory;
+librdf_new_storage;
+librdf_new_storage_with_options;
+librdf_storage_enumerate;
+librdf_new_storage_from_factory;
+librdf_storage_context_add_statements;
+librdf_storage_add_statements;
+librdf_storage_context_add_statement;
+librdf_storage_add_statement;
+librdf_storage_contains_statement;
+librdf_storage_find_statements;
+librdf_storage_has_arc_in;
+librdf_storage_get_sources;
+librdf_storage_get_arcs;
+librdf_storage_has_arc_out;
+librdf_storage_get_targets;
+librdf_storage_get_arcs_in;
+librdf_storage_get_arcs_out;
+librdf_new_storage_from_storage;
+librdf_storage_remove_reference;
+librdf_free_storage;
+librdf_storage_context_remove_statements;
+librdf_storage_find_statements_with_options;
+librdf_storage_find_statements_in_context;
+librdf_storage_open;
+librdf_storage_close;
+librdf_storage_size;
+librdf_storage_remove_statement;
+librdf_storage_context_remove_statement;
+librdf_storage_context_serialise;
+librdf_storage_context_as_stream;
+librdf_storage_supports_query;
+librdf_storage_query_execute;
+librdf_storage_sync;
+librdf_storage_get_contexts;
+librdf_storage_get_feature;
+librdf_storage_set_feature;
+librdf_storage_transaction_get_handle;
+librdf_storage_transaction_rollback;
+librdf_storage_transaction_commit;
+librdf_storage_transaction_start_with_handle;
+librdf_storage_transaction_start;
+librdf_storage_serialise;
+librdf_storage_add_reference;
+librdf_free_stream;
+librdf_stream_print;
+librdf_stream_end;
+librdf_stream_next;
+librdf_stream_get_object;
+librdf_stream_get_context;
+librdf_stream_add_map;
+librdf_new_stream_from_node_iterator;
+librdf_new_stream;
+librdf_new_empty_stream;
+librdf_new_uri_from_uri_local_name;
+librdf_new_uri_normalised_to_base;
+librdf_new_uri_relative_to_base;
+librdf_new_uri_from_filename;
+librdf_new_uri;
+librdf_free_uri;
+librdf_uri_print;
+librdf_uri_to_string;
+librdf_uri_to_counted_string;
+librdf_uri_is_file_uri;
+librdf_uri_to_filename;
+librdf_new_uri_from_uri;
+librdf_uri_as_string;
+librdf_uri_as_counted_string;
+librdf_uri_equals;
+librdf_uri_compare;
+};
diff --git a/redland/redlandversion.mk b/redland/redlandversion.mk
new file mode 100644
index 000000000000..e5389da3b419
--- /dev/null
+++ b/redland/redlandversion.mk
@@ -0,0 +1,32 @@
+#*************************************************************************
+#
+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+#
+# Copyright 2000, 2010 Oracle and/or its affiliates.
+#
+# OpenOffice.org - a multi-platform office productivity suite
+#
+# This file is part of OpenOffice.org.
+#
+# OpenOffice.org is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License version 3
+# only, as published by the Free Software Foundation.
+#
+# OpenOffice.org is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License version 3 for more details
+# (a copy is included in the LICENSE file that accompanied this code).
+#
+# You should have received a copy of the GNU Lesser General Public License
+# version 3 along with OpenOffice.org. If not, see
+# <http://www.openoffice.org/license.html>
+# for a copy of the LGPLv3 License.
+#
+#*************************************************************************
+
+RAPTOR_MAJOR=1
+RASQAL_MAJOR=1
+# redland has no stable abi
+REDLAND_MAJOR=0
+