guile-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Nearly finished initial (use-modules (pcre))


From: Rob Browning
Subject: Nearly finished initial (use-modules (pcre))
Date: Sun, 15 Dec 2002 13:25:57 -0600
User-agent: Gnus/5.090008 (Oort Gnus v0.08) Emacs/21.2 (i386-pc-linux-gnu)

I've just about finished up an initial pcre module.  It's designed to
be a nearly direct mapping to the actual libpcre API.  The plan is
that people can either use it directly, or build fancier interfaces on
top.

I've done the first rough pass, and at least simple cases seem to
work, but the docs need help and there are probably a few more things
to add.  So I was thinking about committing it somewhere so others
could mess with/work on it if they want to, but I wasn't sure where.
Would we want this in guile-core (with ./configure time detection of
libpcre), or would we rather have it as an additional top-level CVS
module?  (Actually there may be copyright "issues" -- see below.)

FWIW I wanted a pcre module myself both because I'm quite familiar
with perl regular expressions, and because they're fairly consistent
from platform to platform.

Right now we have:

  ;; Constants.
  (export PCRE_MAJOR)
  (export PCRE_MINOR)

  (export PCRE_ANCHORED)
  (export PCRE_CASELESS)
  (export PCRE_DOLLAR_ENDONLY)
  (export PCRE_DOTALL)
  (export PCRE_EXTENDED)
  (export PCRE_EXTRA)
  (export PCRE_MULTILINE)
  (export PCRE_UNGREEDY)
  (export PCRE_UTF8)

  (export pcre-version)
  (export pcre-compile)
  (export pcre-study)
  (export pcre-exec) ;; returns vector of match pairs or integer
                     ;; result code #[(1 . 12) (2 . 4) (6 . 9)]
  (export pcre-maketables)

WRT the licence, I just noticed that libpcre's not LGPL (see below).
Anyone care to comment on whether or not the libpcremodule could
actually be a part of guile-core when guile switches to LGPL?  For one
thing, is clause 2 transitive?  If we were to use it in guile and add
such a notation to our docs, would that be sufficient, our would that
also require any software built on guile+pcre to include the notation?
If so, then we're no longer just LGPL, we're LGPL+pcre-requirement.

Thanks

PCRE LICENCE
------------

PCRE is a library of functions to support regular expressions whose syntax
and semantics are as close as possible to those of the Perl 5 language.

Written by: Philip Hazel <address@hidden>

University of Cambridge Computing Service,
Cambridge, England. Phone: +44 1223 334714.

Copyright (c) 1997-2000 University of Cambridge

Permission is granted to anyone to use this software for any purpose on any
computer system, and to redistribute it freely, subject to the following
restrictions:

1. This software 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.

2. The origin of this software must not be misrepresented, either by
   explicit claim or by omission. In practice, this means that if you use
   PCRE in software which you distribute to others, commercially or
   otherwise, you must put a sentence like this

     Regular expression support is provided by the PCRE library package,
     which is open source software, written by Philip Hazel, and copyright
     by the University of Cambridge, England.

   somewhere reasonably visible in your documentation and in any relevant
   files or online help data or similar. A reference to the ftp site for
   the source, that is, to

     ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/

   should also be given in the documentation.

3. Altered versions must be plainly marked as such, and must not be
   misrepresented as being the original software.

4. If PCRE is embedded in any software that is released under the GNU
   General Purpose Licence (GPL), then the terms of that licence shall
   supersede any condition above with which it is incompatible.


-- 
Rob Browning
rlb @defaultvalue.org, @linuxdevel.com, and @debian.org
Previously @cs.utexas.edu
GPG starting 2002-11-03 = 14DD 432F AE39 534D B592  F9A0 25C8 D377 8C7E 73A4



reply via email to

[Prev in Thread] Current Thread [Next in Thread]