summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libs/files/domc-0.7.1.tar.gzbin120156 -> 0 bytes
-rw-r--r--libs/files/domc-0.8.0.tar.gzbin0 -> 122571 bytes
-rw-r--r--libs/files/domc-library.patch360
3 files changed, 33 insertions, 327 deletions
diff --git a/libs/files/domc-0.7.1.tar.gz b/libs/files/domc-0.7.1.tar.gz
deleted file mode 100644
index 94ffa6e..0000000
--- a/libs/files/domc-0.7.1.tar.gz
+++ /dev/null
Binary files differ
diff --git a/libs/files/domc-0.8.0.tar.gz b/libs/files/domc-0.8.0.tar.gz
new file mode 100644
index 0000000..e88f962
--- /dev/null
+++ b/libs/files/domc-0.8.0.tar.gz
Binary files differ
diff --git a/libs/files/domc-library.patch b/libs/files/domc-library.patch
index 2dcc9d0..3f24dda 100644
--- a/libs/files/domc-library.patch
+++ b/libs/files/domc-library.patch
@@ -1,8 +1,8 @@
Only in domc/: libdomc.a
-Only in domc/: libdomc.so.0.7.1
-diff -r -U3 domc-0.7.1/Makefile domc/Makefile
---- domc-0.7.1/Makefile 2004-08-05 22:32:24.000000000 -0600
-+++ domc/Makefile 2004-09-01 11:00:30.657569070 -0600
+Only in domc/: libdomc.so.0.8.0
+diff -r -U3 domc-0.8.0/Makefile domc/Makefile
+--- domc-0.8.0/Makefile 2004-09-09 16:31:42.000000000 -0600
++++ domc/Makefile 2004-12-02 10:27:01.085453866 -0700
@@ -1,7 +1,8 @@
-prefix = /usr/local
-includedir = $(prefix)/include
@@ -15,13 +15,13 @@ diff -r -U3 domc-0.7.1/Makefile domc/Makefile
+mandir = $(prefix)
CC = gcc
LIBNAME = domc
- MAJVERSION = 0.7
+ MAJVERSION = 0.8
@@ -11,7 +12,7 @@
SOVERSION = lib$(LIBNAME).so.$(MAJVERSION)
DISTRO = $(LIBNAME)-$(MINVERSION)
RPM_OPT_FLAGS = -O2
--CFLAGS = -Wall -W -DMSGNO $(RPM_OPT_FLAGS) -I$(includedir) -L$(libdir)
-+CFLAGS = -Wall -W -DMSGNO $(RPM_OPT_FLAGS) $(_EXTRA) -I$(includedir) -L$(libdir)
+-CFLAGS = -Wall -W -g -DMSGNO $(RPM_OPT_FLAGS) -I$(includedir) -L$(libdir)
++CFLAGS = -Wall -W -g -DMSGNO $(RPM_OPT_FLAGS) $(_EXTRA) -I$(includedir) -L$(libdir)
#CFLAGS = -Wall -W -DMSGNO -I$(includedir) -L$(libdir) $(RPM_OPT_FLAGS) -ansi -pedantic -Wbad-function-cast -Wcast-align -Wcast-qual -Wchar-subscripts -Winline -Wmissing-prototypes -Wnested-externs -Wpointer-arith -Wredundant-decls -Wshadow -Wstrict-prototypes -Wwrite-strings -Wtraditional -Wconversion -Waggregate-return -Wno-parentheses
OBJS = src/expatls.o src/events.o src/node.o src/nodelist.o src/namednodemap.o src/dom.o src/timestamp.o src/wcwidth.o src/mbs.o
MAN = DOM_CharacterData.3m.gz DOM_Document.3m.gz DOM_Element.3m.gz DOM_Implementation.3m.gz DOM_NamedNodeMap.3m.gz DOM_Node.3m.gz DOM_NodeList.3m.gz DOM_Text.3m.gz
@@ -41,9 +41,9 @@ diff -r -U3 domc-0.7.1/Makefile domc/Makefile
- cd $(mandir)/man3 && rm -f $(MAN)
+ # cd $(mandir)/man3 && rm -f $(MAN)
-diff -r -U3 domc-0.7.1/Makefile.msvc domc/Makefile.msvc
---- domc-0.7.1/Makefile.msvc 2004-08-04 17:20:02.000000000 -0600
-+++ domc/Makefile.msvc 2004-09-01 11:00:30.659568751 -0600
+diff -r -U3 domc-0.8.0/Makefile.msvc domc/Makefile.msvc
+--- domc-0.8.0/Makefile.msvc 2004-08-04 17:20:02.000000000 -0600
++++ domc/Makefile.msvc 2004-12-02 10:27:01.086453660 -0700
@@ -1,22 +1,29 @@
!include <win32.mak>
-LIBMBA=..\libmba-0.8.9
@@ -80,9 +80,9 @@ diff -r -U3 domc-0.7.1/Makefile.msvc domc/Makefile.msvc
clean:
del domc.dll domc.lib domc.exp $(OBJS)
-diff -r -U3 domc-0.7.1/src/defines.h domc/src/defines.h
---- domc-0.7.1/src/defines.h 2003-03-22 16:35:36.000000000 -0700
-+++ domc/src/defines.h 2004-09-01 11:00:30.673566512 -0600
+diff -r -U3 domc-0.8.0/src/defines.h domc/src/defines.h
+--- domc-0.8.0/src/defines.h 2003-03-22 16:35:36.000000000 -0700
++++ domc/src/defines.h 2004-12-02 10:27:01.086453660 -0700
@@ -7,7 +7,7 @@
#define HAVE_ENCDEC 0
#define HAVE_STRDUP 1
@@ -110,24 +110,10 @@ diff -r -U3 domc-0.7.1/src/defines.h domc/src/defines.h
#define HAVE_MBSTATE 1
#define HAVE_WCWIDTH 1
#define HAVE_SNPRINTF 1
-diff -r -U3 domc-0.7.1/src/domc.h domc/src/domc.h
---- domc-0.7.1/src/domc.h 2004-08-04 17:32:30.000000000 -0600
-+++ domc/src/domc.h 2004-09-01 11:00:30.675566192 -0600
-@@ -41,6 +41,13 @@
- #include <stdint.h>
- #endif
-
-+/* Enable this for hashing and fast access to large child node lists */
-+#define FAST_NODELIST 1
-+
-+#if FAST_NODELIST
-+#include <mba/hashmap.h>
-+#endif
-+
- /* DOM_String
- */
-
-@@ -185,6 +192,8 @@
+diff -r -U3 domc-0.8.0/src/domc.h domc/src/domc.h
+--- domc-0.8.0/src/domc.h 2004-09-09 15:52:10.000000000 -0600
++++ domc/src/domc.h 2004-12-02 10:29:08.870136502 -0700
+@@ -192,6 +192,8 @@
DOM_String *data;
} ProcessingInstruction;
} u;
@@ -136,18 +122,15 @@ diff -r -U3 domc-0.7.1/src/domc.h domc/src/domc.h
};
DOM_Node *DOM_Node_insertBefore(DOM_Node *node, DOM_Node *newChild, DOM_Node *refChild);
-@@ -212,6 +221,10 @@
- NodeEntry *last;
- unsigned short filter;
- struct DOM_NodeList *list; /* Used for entities and notations */
-+#if FAST_NODELIST
-+ struct hashmap* _map;
-+#endif
+@@ -222,6 +224,7 @@
+ #if FAST_NODELIST
+ struct hashmap* _map;
+ #endif
+ unsigned int rtfxRefCount; /* Reference counting added for RTFX */
};
DOM_Node *DOM_NodeList_item(const DOM_NodeList *nl, int index);
-@@ -286,8 +299,10 @@
+@@ -296,8 +299,10 @@
* described in the latest W3C drafts at all.
*/
@@ -160,59 +143,19 @@ diff -r -U3 domc-0.7.1/src/domc.h domc/src/domc.h
Only in domc/src: dom.o
Only in domc/src: events.o
-diff -r -U3 domc-0.7.1/src/expatls.c domc/src/expatls.c
---- domc-0.7.1/src/expatls.c 2004-08-04 17:28:49.000000000 -0600
-+++ domc/src/expatls.c 2004-09-01 11:01:50.710764140 -0600
-@@ -70,6 +70,14 @@
-
- DOM_Node *Document_createNode(DOM_Document *doc, unsigned short nodeType);
-
-+static int
-+fputds(const DOM_String *s, FILE *stream)
-+{
-+ return fputs(s, stream);
-+}
-+
-+#if HAVE_EXPAT > 0
-+
- struct user_data {
- DOM_String *buf;
- size_t siz;
-@@ -115,14 +123,6 @@
- return n;
- }
-
--static int
--fputds(const DOM_String *s, FILE *stream)
--{
-- return fputs(s, stream);
--}
--
--#if HAVE_EXPAT > 0
--
- static void
- xmldecl_fn(void *userData, const XML_Char *version, const XML_Char *encoding, int standalone)
- {
-@@ -711,7 +711,7 @@
- size_t l;
-
- while (*s) {
-- l = strcspn(s, "<>&\"'");
-+ l = strcspn(s, "<>&\"");
- if (l > 0) {
- fwrite((void*)s, 1, sizeof(DOM_String) * l, stream);
- s += l;
-@@ -731,9 +731,6 @@
- case '"':
- fputs("&quot;", stream);
+diff -r -U3 domc-0.8.0/src/expatls.c domc/src/expatls.c
+--- domc-0.8.0/src/expatls.c 2004-09-09 16:08:26.000000000 -0600
++++ domc/src/expatls.c 2004-12-02 10:27:01.087453455 -0700
+@@ -724,7 +724,7 @@
+ fputs("&gt;", stream);
break;
-- case '\'':
-- fputs("&squot;", stream);
-- break;
- default:
- AMSG("");
+ case '&':
+- fputs("&apos;", stream);
++ fputs("&amp;", stream);
break;
-@@ -853,11 +850,6 @@
+ case '"':
+ fputs("&quot;", stream);
+@@ -848,11 +848,6 @@
fputs(" version=\"", stream);
fputds(node->u.Document.version ? node->u.Document.version : "1.0", stream);
fputc('\"', stream);
@@ -227,243 +170,6 @@ diff -r -U3 domc-0.7.1/src/expatls.c domc/src/expatls.c
Only in domc/src: expatls.o
Only in domc/src: mbs.o
Only in domc/src: namednodemap.o
-diff -r -U3 domc-0.7.1/src/node.c domc/src/node.c
---- domc-0.7.1/src/node.c 2004-08-04 17:29:12.000000000 -0600
-+++ domc/src/node.c 2004-09-01 11:00:30.691563633 -0600
-@@ -337,7 +337,6 @@
- DOM_Node *
- DOM_Node_replaceChild(DOM_Node *node, DOM_Node *newChild, DOM_Node *oldChild)
- {
-- DOM_Node *tmp;
- DOM_MutationEvent evt;
-
- if (node == NULL || newChild == NULL || oldChild == NULL) {
-@@ -352,12 +351,7 @@
- return NULL;
- }
-
-- for (tmp = node->firstChild;
-- tmp != NULL && tmp != oldChild;
-- tmp = tmp->nextSibling) {
-- ;
-- }
-- if (tmp != oldChild) {
-+ if (!NodeList_exists(node->childNodes, oldChild)) {
- DOM_Exception = DOM_NOT_FOUND_ERR;
- PMNO(DOM_Exception);
- return NULL;
-diff -r -U3 domc-0.7.1/src/nodelist.c domc/src/nodelist.c
---- domc-0.7.1/src/nodelist.c 2004-08-04 17:19:25.000000000 -0600
-+++ domc/src/nodelist.c 2004-09-01 11:00:30.711560434 -0600
-@@ -30,6 +30,68 @@
- #include "domc.h"
- #include "dom.h"
-
-+#if FAST_NODELIST
-+
-+/* The number of nodes required in a list before hashing starts */
-+#define FAST_FILLFACTOR 16
-+
-+static void _removeFromMap(DOM_NodeList* nl, DOM_Node* key)
-+{
-+ if (nl->_map) {
-+ if (hashmap_get(nl->_map, key) != NULL) {
-+ void* d = NULL;
-+ void* k = key;
-+ hashmap_remove(nl->_map, &k, &d);
-+ }
-+ }
-+}
-+
-+static int _addToMap(DOM_NodeList* nl, DOM_Node* key, NodeEntry* val)
-+{
-+ if (!nl->_map && nl->length > FAST_FILLFACTOR) {
-+
-+ nl->_map = hashmap_new(0, NULL, NULL, NULL);
-+
-+ /* Hash what we currently have */
-+ if (nl->_map) {
-+ NodeEntry *e = nl->first;
-+ while (e) {
-+ _addToMap(nl, e->node, e);
-+ e = e->next;
-+ }
-+ }
-+ }
-+
-+ if (nl->_map) {
-+ _removeFromMap(nl, key);
-+
-+ if (hashmap_put(nl->_map, key, val) == -1) {
-+ DOM_Exception = errno;
-+ return -1;
-+ }
-+ }
-+
-+ return 0;
-+}
-+
-+#endif
-+
-+static NodeEntry* _lookupNode(DOM_NodeList* nl, DOM_Node* node)
-+{
-+ NodeEntry* s;
-+
-+#if FAST_NODELIST
-+ if (nl->_map)
-+ s = (NodeEntry*)hashmap_get(nl->_map, node);
-+ else
-+#endif
-+ for (s = nl->first; s != NULL && s->node != node; s = s->next) {
-+ ;
-+ }
-+
-+ return s;
-+}
-+
- /* NodeList
- */
-
-@@ -63,6 +125,12 @@
- free(tmp);
- }
- }
-+
-+#if FAST_NODELIST
-+ if(nl->_map)
-+ hashmap_del(nl->_map, NULL, NULL, NULL);
-+#endif
-+
- free(nl);
- }
- }
-@@ -110,6 +178,7 @@
- NodeList_insert(DOM_NodeList *nl, DOM_Node *newChild, DOM_Node *refChild)
- {
- NodeEntry *e;
-+ NodeEntry *s = NULL;
-
- if (nl == NULL) {
- DOM_Exception = NULL_POINTER_ERR;
-@@ -122,12 +191,30 @@
- return NULL;
- }
-
-+ if(refChild != NULL)
-+ {
-+ s = _lookupNode(nl, refChild);
-+ if(s == NULL || s->node != refChild) {
-+ DOM_Exception = DOM_NOT_FOUND_ERR;
-+ PMNO(DOM_Exception);
-+ return NULL;
-+ }
-+ }
-+
- if ((e = calloc(sizeof *e, 1)) == NULL) {
- DOM_Exception = errno;
- PMNO(DOM_Exception);
- return NULL;
- }
-
-+#if FAST_NODELIST
-+ if (_addToMap(nl, newChild, e) == -1) {
-+ PMNO(DOM_Exception);
-+ free(e);
-+ return NULL;
-+ }
-+#endif
-+
- e->node = newChild;
- if (nl->length == 0) {
- nl->first = nl->last = e;
-@@ -136,18 +223,6 @@
- nl->last->next = e;
- nl->last = e;
- } else {
-- NodeEntry *s;
--
-- for (s = nl->first; s != NULL && s->node != refChild; s = s->next) {
-- ;
-- }
-- if (s == NULL || s->node != refChild) {
-- DOM_Exception = DOM_NOT_FOUND_ERR;
-- PMNO(DOM_Exception);
-- free(e);
-- return NULL;
-- }
--
- e->prev = s->prev;
- e->next = s;
- if (s == nl->first) {
-@@ -184,14 +259,21 @@
- return NULL;
- }
-
-- for (e = nl->first; e != NULL && e->node != oldChild; e = e->next) {
-- ;
-- }
-+ e = _lookupNode(nl, oldChild);
- if (e == NULL) {
- DOM_Exception = DOM_NOT_FOUND_ERR;
- PMNO(DOM_Exception);
- return NULL;
- }
-+
-+#if FAST_NODELIST
-+ _removeFromMap(nl, oldChild);
-+ if(_addToMap(nl, newChild, e) == -1) {
-+ PMNO(DOM_Exception);
-+ return NULL;
-+ }
-+#endif
-+
- e->node = newChild;
-
- if (oldChild->nodeType == DOM_ATTRIBUTE_NODE) {
-@@ -216,12 +298,14 @@
- return NULL;
- }
-
-- for (e = nl->first; e != NULL && e->node != oldChild; e = e->next) {
-- ;
-- }
-+ e = _lookupNode(nl, oldChild);
- if (e == NULL) {
- return NULL;
- }
-+
-+#if FAST_NODELIST
-+ _removeFromMap(nl, oldChild);
-+#endif
-
- if (nl->first == nl->last) {
- nl->first = nl->last = NULL;
-@@ -269,6 +353,14 @@
- return NULL;
- }
-
-+#if FAST_NODELIST
-+ if(_addToMap(nl, newChild, e) == -1) {
-+ PMNO(DOM_Exception);
-+ free(e);
-+ return NULL;
-+ }
-+#endif
-+
- e->node = newChild;
- if (nl->first == NULL) {
- nl->first = nl->last = e;
-@@ -311,9 +403,7 @@
- return 0;
- }
-
-- for (e = nl->first; e != NULL && e->node != child; e = e->next) {
-- ;
-- }
-+ e = _lookupNode(nl, child);
- return e != NULL;
- }
-
Only in domc/src: nodelist.o
Only in domc/src: node.o
Only in domc/src: timestamp.o