summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAchim Gottinger <achim@gentoo.org>2001-04-30 09:32:20 +0000
committerAchim Gottinger <achim@gentoo.org>2001-04-30 09:32:20 +0000
commitb39873f8ca85e6ba1539ff191254847455ce426c (patch)
tree51cf9e283edf74874b229c0b315da0c7be177b60 /app-text/sablotron
parentCleanup (diff)
downloadgentoo-2-b39873f8ca85e6ba1539ff191254847455ce426c.tar.gz
gentoo-2-b39873f8ca85e6ba1539ff191254847455ce426c.tar.bz2
gentoo-2-b39873f8ca85e6ba1539ff191254847455ce426c.zip
Cleanup
Diffstat (limited to 'app-text/sablotron')
-rw-r--r--app-text/sablotron/files/digest-sablotron-0.44-r22
-rw-r--r--app-text/sablotron/files/digest-sablotron-0.501
-rw-r--r--app-text/sablotron/files/utf8.cpp133
-rw-r--r--app-text/sablotron/sablotron-0.44-r2.ebuild48
-rw-r--r--app-text/sablotron/sablotron-0.50.ebuild42
5 files changed, 0 insertions, 226 deletions
diff --git a/app-text/sablotron/files/digest-sablotron-0.44-r2 b/app-text/sablotron/files/digest-sablotron-0.44-r2
deleted file mode 100644
index 3ae4b7e2d3b7..000000000000
--- a/app-text/sablotron/files/digest-sablotron-0.44-r2
+++ /dev/null
@@ -1,2 +0,0 @@
-MD5 35874ea80215fea45f1af28a419c2ce2 Sablot-0.44.tar.gz
-MD5 c2607a890d8f31cdd0ab3d3dc6c896a6 Sablot-Expat-1.1.2.tar.gz
diff --git a/app-text/sablotron/files/digest-sablotron-0.50 b/app-text/sablotron/files/digest-sablotron-0.50
deleted file mode 100644
index 7177ce307c1a..000000000000
--- a/app-text/sablotron/files/digest-sablotron-0.50
+++ /dev/null
@@ -1 +0,0 @@
-MD5 c024d6aa21819a9b3ce65d4d33e481c5 Sablot-0.50.tar.gz
diff --git a/app-text/sablotron/files/utf8.cpp b/app-text/sablotron/files/utf8.cpp
deleted file mode 100644
index 5bcfccea6924..000000000000
--- a/app-text/sablotron/files/utf8.cpp
+++ /dev/null
@@ -1,133 +0,0 @@
-/*
-* The contents of this file are subject to the Mozilla Public
-* License Version 1.1 (the "License"); you may not use this file
-* except in compliance with the License. You may obtain a copy of
-* the License at http://www.mozilla.org/MPL/
-*
-* Software distributed under the License is distributed on an "AS
-* IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
-* implied. See the License for the specific language governing
-* rights and limitations under the License.
-*
-* The Original Code is the Sablotron XSLT Processor.
-*
-* The Initial Developer of the Original Code is Ginger Alliance Ltd.
-* Portions created by Ginger Alliance are Copyright (C) 2000 Ginger
-* Alliance Ltd. All Rights Reserved.
-*
-* Contributor(s): Sven Neumann <neo@netzquadrat.de>
-*
-* Alternatively, the contents of this file may be used under the
-* terms of the GNU General Public License Version 2 or later (the
-* "GPL"), in which case the provisions of the GPL are applicable
-* instead of those above. If you wish to allow use of your
-* version of this file only under the terms of the GPL and not to
-* allow others to use your version of this file under the MPL,
-* indicate your decision by deleting the provisions above and
-* replace them with the notice and other provisions required by
-* the GPL. If you do not delete the provisions above, a recipient
-* may use your version of this file under either the MPL or the
-* GPL.
-*/
-
-//
-// utf8.cpp
-//
-
-#include <assert.h>
-#include "utf8.h"
-
-#ifdef HAVE_ICONV_H
-#include <iconv.h>
-#endif
-
-/* This MUST match the Encoding enum defined in utf8.h */
-static char* iconv_encoding[8] =
-{
- "UTF8",
- "UTF16",
- "ASCII",
- "ISO-8859-1",
- "ISO-8859-2",
- "CP1250",
- "EUC-JP",
- "SHIFT-JIS"
-};
-
-int utf8SingleCharLength (const char* text)
-{
- if (!(*text & 0x80)) return 1;
- if (!(*text & 0x40)) return 0;
- for (int len = 2; len < 7; len++)
- if (!(*text & (0x80 >> len))) return len;
- return 0;
-}
-
-// this ought to return the Unicode equivalent of the UTF-8 char
-// (for character references like &#22331;)
-//
-unsigned long utf8CharCode(const char *text)
-{
- int i, len = utf8SingleCharLength(text);
- if (!len) return (unsigned long) -1;
- if (len == 1) return *text;
- unsigned long code = (*text & (0xff >> (len + 1))); // get 1st byte
- for (i = 1; i < len; i++)
- code = (code << 6) | (text[i] & 0x3f);
- return code;
-}
-
-
-int utf8GetChar(char *dest, const char *src)
-{
- int len = utf8SingleCharLength (src);
- memcpy (dest, src, len);
- return len;
-}
-
-Bool utf8CanRecodeTo(const char *destEncoding)
-{
- if (strEqNoCase(destEncoding, "UTF8") ||
- strEqNoCase(destEncoding, "UTF-8"))
- return TRUE;
- // more checks for internally supported encodings can come here
-#if defined(HAVE_ICONV_H)
- iconv_t cd = iconv_open (destEncoding, "UTF-8");
- if (cd != (iconv_t)(-1))
- {
- iconv_close (cd);
- return TRUE;
- }
-#endif
- return FALSE;
-}
-
-int utf8InternalRecode(char *dest, const char *src, Encoding enc)
-{
- if (enc == ENC_UTF8)
- return utf8GetChar(dest, src);
- else
- return 0;
-}
-
-int utf8Recode(char* dest, const char* src, Encoding enc)
-{
- int internal = utf8InternalRecode(dest, src, enc);
- if (internal)
- return internal;
-#if !defined(HAVE_ICONV_H)
- return 0;
-#else
- iconv_t cd;
- size_t inbytesleft = utf8SingleCharLength (src);
- size_t outbytesleft = SMALL_BUFFER_SIZE;
- char *outbuf = dest;
-
- cd = iconv_open (iconv_encoding[enc],"UTF-8");
- assert(cd != (iconv_t)(-1));
- while (inbytesleft &&
- iconv(cd,(char **) &src, &inbytesleft, &outbuf, &outbytesleft) != -1);
- iconv_close (cd);
- return SMALL_BUFFER_SIZE - outbytesleft;
-#endif
-}
diff --git a/app-text/sablotron/sablotron-0.44-r2.ebuild b/app-text/sablotron/sablotron-0.44-r2.ebuild
deleted file mode 100644
index 3624e7df728f..000000000000
--- a/app-text/sablotron/sablotron-0.44-r2.ebuild
+++ /dev/null
@@ -1,48 +0,0 @@
-# Copyright 1999-2000 Gentoo Technologies, Inc.
-# Distributed under the terms of the GNU General Public License, v2 or later
-# Author Achim Gottinger <achim@gentoo.org>
-# $Header: /var/cvsroot/gentoo-x86/app-text/sablotron/sablotron-0.44-r2.ebuild,v 1.2 2000/12/17 20:09:01 achim Exp $
-
-A="Sablot-${PV}.tar.gz Sablot-Expat-1.1.2.tar.gz"
-S=${WORKDIR}/Sablot-${PV}
-DESCRIPTION="An XSLT Parser in C++"
-SRC_URI="http://www.gingerall.com/perl/rd?url=sablot/Sablot-${PV}.tar.gz
- http://www.gingerall.com/perl/rd?url=sablot/Sablot-Expat-1.1.2.tar.gz"
-HOMEPAGE="http://www.gingerall.com/charlie-bin/get/webGA/act/sablotron.act"
-
-DEPEND=">=sys-devel/gcc-2.95.2
- >=sys-libs/glibc-2.1.3"
-
-src_unpack() {
- unpack Sablot-${PV}.tar.gz
- cd ${S}
- unpack Sablot-Expat-1.1.2.tar.gz
- if [ "`use glibc22`" ]
- then
- cp ${FILESDIR}/utf8.cpp Sablot/engine/
- fi
-}
-
-src_compile() {
-
- cd ${S}
- try ./configure --prefix=/usr --host=${CHOST}
- try make
-
-}
-
-src_install () {
-
- cd ${S}
- dodir /usr/lib
- dodir /usr/include
- dodir /usr/bin
- try make prefix=${D}/usr install
- dodoc README
- dodoc Sablot/RELEASE Sablot/TODO
- docinto html/expat
- dodoc Expat/distribution/expat.html
-}
-
-
-
diff --git a/app-text/sablotron/sablotron-0.50.ebuild b/app-text/sablotron/sablotron-0.50.ebuild
deleted file mode 100644
index b34d5d922fb2..000000000000
--- a/app-text/sablotron/sablotron-0.50.ebuild
+++ /dev/null
@@ -1,42 +0,0 @@
-# Copyright 1999-2000 Gentoo Technologies, Inc.
-# Distributed under the terms of the GNU General Public License, v2 or later
-# Author Achim Gottinger <achim@gentoo.org>
-# $Header: /var/cvsroot/gentoo-x86/app-text/sablotron/sablotron-0.50.ebuild,v 1.2 2001/02/10 11:17:24 achim Exp $
-
-A="Sablot-${PV}.tar.gz"
-S=${WORKDIR}/Sablot-${PV}
-DESCRIPTION="An XSLT Parser in C++"
-SRC_URI="http://www.gingerall.com/perl/rd?url=sablot/${A}"
-HOMEPAGE="http://www.gingerall.com/charlie-bin/get/webGA/act/sablotron.act"
-
-DEPEND=">=sys-devel/gcc-2.95.2 >=dev-libs/expat-1.95.1 virtual/glibc"
-
-src_unpack() {
- unpack Sablot-${PV}.tar.gz
- if [ "`use glibc22`" ]
- then
- cd ${S}/Sablot/engine
- cp utf8.cpp utf8.cpp.orig
- sed -e '44d;46d' utf8.cpp.orig > utf8.cpp
- fi
-}
-
-src_compile() {
- cd ${S}
- try ./configure --prefix=/usr --host=${CHOST}
- try pmake
-
-}
-
-src_install () {
- cd ${S}
- dodir /usr/lib
- dodir /usr/include
- dodir /usr/bin
- try make prefix=${D}/usr install
- dodoc README
- dodoc Sablot/RELEASE Sablot/TODO
-}
-
-
-