diff options
author | agc <agc@pkgsrc.org> | 2001-05-31 10:54:21 +0000 |
---|---|---|
committer | agc <agc@pkgsrc.org> | 2001-05-31 10:54:21 +0000 |
commit | 37779f01dd9936e9f597480f897e531c13177605 (patch) | |
tree | 7cc68316fe4f2180e3046a83fdf2db3d25d163fe /textproc/biblook/patches | |
parent | f7755a8c889de651c4434b44e3662b6ac2b5faa8 (diff) | |
download | pkgsrc-37779f01dd9936e9f597480f897e531c13177605.tar.gz |
Initial import of biblook-2.9 into the Packages Collection.
Provided in PR 13012 by Stoned Elipot (Stoned.Elipot@script.jussieu.fr)
Minor enhancements made by agc.
Bibindex and biblook are programs for fast lookup in BibTeX
bibliography data bases.
Bibindex converts a .bib file to a .bix file, which is a compact
binary representation of the .bib file containing hash tables for fast
lookup, as well as byte offset positions into the corresponding .bib
file.
Biblook provides an interactive lookup facility using the .bix and
.bib files.
Diffstat (limited to 'textproc/biblook/patches')
-rw-r--r-- | textproc/biblook/patches/patch-aa | 42 | ||||
-rw-r--r-- | textproc/biblook/patches/patch-ab | 13 | ||||
-rw-r--r-- | textproc/biblook/patches/patch-ac | 56 |
3 files changed, 111 insertions, 0 deletions
diff --git a/textproc/biblook/patches/patch-aa b/textproc/biblook/patches/patch-aa new file mode 100644 index 00000000000..737c7934475 --- /dev/null +++ b/textproc/biblook/patches/patch-aa @@ -0,0 +1,42 @@ +$NetBSD: patch-aa,v 1.1.1.1 2001/05/31 10:54:21 agc Exp $ + +--- Makefile.orig Tue Jan 31 21:15:22 1995 ++++ Makefile +@@ -68,12 +68,15 @@ + # [13-Sep-1993] + #======================================================================= + +-DEST = /usr/local ++DEST = $(PREFIX) + + BINDIR = $(DEST)/bin + + CATDIR = $(DEST)/man/cat1 + ++INSTALL_PROGRAM = $(BSD_INSTALL_PROGRAM) ++INSTALL_MAN = $(BSD_INSTALL_MAN) ++ + # Compilation with a C++ compiler is preferable. SunOS 4.1 CC cannot be + # used, however, because of its erroneous function prototypes in stdlib.h + # which use char* instead of void* in many places. There is no such +@@ -243,16 +246,10 @@ + -$(RM) TAGS + + install: bibindex biblook +- -$(CP) bibindex $(BINDIR) +- -$(STRIP) $(BINDIR)/bibindex +- -chmod 775 $(BINDIR)/bibindex +- -$(CP) biblook $(BINDIR) +- -$(STRIP) $(BINDIR)/biblook +- -chmod 775 $(BINDIR)/biblook +- -$(CP) bibindex.man $(MANDIR)/bibindex.$(MANEXT) +- -chmod 774 $(MANDIR)/bibindex.$(MANEXT) +- -$(CP) biblook.man $(MANDIR)/biblook.$(MANEXT) +- -chmod 774 $(MANDIR)/biblook.$(MANEXT) ++ $(INSTALL_PROGRAM) bibindex $(BINDIR) ++ $(INSTALL_PROGRAM) biblook $(BINDIR) ++ $(INSTALL_MAN) bibindex.man $(MANDIR)/bibindex.$(MANEXT) ++ $(INSTALL_MAN) biblook.man $(MANDIR)/biblook.$(MANEXT) + + install-ftp: $(FTPFILES) + -for f in $? ; \ diff --git a/textproc/biblook/patches/patch-ab b/textproc/biblook/patches/patch-ab new file mode 100644 index 00000000000..29ac213a798 --- /dev/null +++ b/textproc/biblook/patches/patch-ab @@ -0,0 +1,13 @@ +$NetBSD: patch-ab,v 1.1.1.1 2001/05/31 10:54:21 agc Exp $ + +--- biblook.h.orig Tue Mar 31 01:31:04 1998 ++++ biblook.h +@@ -206,7 +206,7 @@ + #define MAJOR_VERSION 2 /* program version */ + #define MINOR_VERSION 9 + +-#define MAXWORD 31 /* maximum length of word indexed */ ++#define MAXWORD 255 /* maximum length of word indexed */ + #define MAXSTRING 4095 /* maximum length of line handled */ + typedef char Word[MAXWORD+1]; + typedef char String[MAXSTRING+1]; diff --git a/textproc/biblook/patches/patch-ac b/textproc/biblook/patches/patch-ac new file mode 100644 index 00000000000..930838ffe81 --- /dev/null +++ b/textproc/biblook/patches/patch-ac @@ -0,0 +1,56 @@ +$NetBSD: patch-ac,v 1.1.1.1 2001/05/31 10:54:22 agc Exp $ + +Use mkstemp() in preference to tempnam(). +Note use of snprintf(), as not all platforms have strlcpy(). + +--- biblook.c 2001/05/31 08:55:19 1.1 ++++ biblook.c 2001/05/31 09:02:25 +@@ -1276,6 +1276,8 @@ + putc('\n', ofp); + } + ++#include <sys/param.h> ++ + /* ----------------------------------------------------------------- *\ + | void PrintResults(char *filename) + | +@@ -1288,6 +1290,9 @@ + FILE *ofp; + char *pager; + char *the_tmpfile = (char*)NULL; ++#if (defined(BSD) && BSD >= 199306) ++ char f[MAXPATHLEN]; ++#endif + #if unix + int childpid; + #else +@@ -1315,8 +1320,19 @@ + } + else + { ++#if (defined(BSD) && BSD >= 199306) ++ int fd; ++ ++ (void) snprintf(f, sizeof(f), "/tmp/bibl.XXXXXX"); ++ if ((fd = mkstemp(f)) < 0) { ++ perror("\tCan't open temp file"); ++ return; ++ } ++ ofp = fdopen(fd, "w"); ++#else + the_tmpfile = (char*)tempnam(NULL, "bibl."); + ofp = fopen(the_tmpfile, "w"); ++#endif + if (!ofp) + { + perror("\tCan't open temp file"); +@@ -1386,7 +1402,9 @@ + #endif + + unlink(the_tmpfile); ++#if !(defined(BSD) && BSD >= 199306) + free(the_tmpfile); /* malloc'ed by tempnam() */ ++#endif + putchar('\n'); + } + } |