1
0
mirror of https://git.FreeBSD.org/ports.git synced 2025-01-23 09:10:43 +00:00

PR: 58597

Submitted by:	Cheng-Lung Sung <clsung@dragon2.net>
Approved by:	maintainer
Fix build step in version 1.9.7
This commit is contained in:
Foxfair Hu 2003-10-28 15:24:03 +00:00
parent 83343193ac
commit 7f69be7b96
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=92456
5 changed files with 34 additions and 44 deletions

View File

@ -12,8 +12,8 @@ MAINTAINER= statue@freebsd.sinica.edu.tw
MASTERDIR= ${.CURDIR}/../../net/dictd
EXTRA_PATCHES= ${.CURDIR}/files/patch-index.c \
${.CURDIR}/files/patch-libmaa::arg.c \
${.CURDIR}/files/patch-dictfmt.c \
${.CURDIR}/files/patch-Makefile.in
${.CURDIR}/files/patch-dictfmt.c
# ${.CURDIR}/files/patch-Makefile.in
#pre-install:
# ${ECHO_CMD} "bin/dictfmt" > ${PLIST}

View File

@ -1,10 +0,0 @@
--- Makefile.in.orig Sun Nov 24 02:01:29 2002
+++ Makefile.in Sun Nov 24 02:01:44 2002
@@ -154,7 +154,6 @@
if test ! -d $(bindir); then $(INSTALL) -d 755 $(bindir); fi
if test ! -d $(man1_prefix); then $(INSTALL) -d 755 $(man1_prefix); fi
$(INSTALL_PROGRAM) dictfmt $(bindir)
- $(INSTALL_PROGRAM) dictfmt_index2suffix $(bindir)
$(INSTALL_DATA) dictfmt.1 $(man1_prefix)/dictfmt.1
install.dictd: dictd

View File

@ -1,14 +1,14 @@
--- dictfmt.c.orig Sun Nov 24 01:25:09 2002
+++ dictfmt.c Sun Nov 24 01:25:23 2002
@@ -208,6 +208,12 @@
--- dictfmt.c.orig Tue Feb 11 03:08:33 2003
+++ dictfmt.c Mon Oct 27 22:03:33 2003
@@ -213,6 +213,12 @@
while (src && src [0]){
ch = *(const unsigned char *)src;
+ if((ch & 0x80) && *(src+1)) {
+ *dest++ = ch;
+ *dest++ = *(src+1);
+ src+=2;
+ continue;
+ *dest++ = ch;
+ *dest++ = *(src+1);
+ src+=2;
+ continue;
+ }
if (isspace (ch)){

View File

@ -1,36 +1,36 @@
--- index.c.orig Sun Nov 24 01:24:10 2002
+++ index.c Sun Nov 24 01:24:21 2002
@@ -91,6 +91,12 @@
--- index.c.orig Mon Mar 10 01:06:16 2003
+++ index.c Mon Oct 27 22:10:18 2003
@@ -103,6 +103,12 @@
for (; *src; ++src) {
c = * (const unsigned char *) src;
+ if((c & 0x80) && *(src+1)) {
+ *dest++ = c;
+ *dest++ = *(src+1);
+ src++;
+ continue;
+ *dest++ = c;
+ *dest++ = *(src+1);
+ src++;
+ continue;
+ }
if (isspace( c )) {
*dest++ = ' ';
@@ -150,7 +156,7 @@
isspacealnumtab_allchars['\t'] = isspacealnumtab_allchars['\n'] = 0; /* special */
@@ -184,7 +190,7 @@
for (i = 0; i <= UCHAR_MAX; i++){
- if (islower (i) || (utf8_mode && i >= 0xC0))
+ if (islower (i) || (utf8_mode && i >= 0xC0) || (i>=0x80))
chartab[charcount++] = i;
}
charcount = 0;
for (i = 0; i <= UCHAR_MAX; i++){
- if (islower (i) || (utf8_mode && i >= 0xC0))
+ if (islower (i) || (utf8_mode && i >= 0xC0) || (i>=0x80))
chartab [charcount++] = i;
}
@@ -317,6 +326,15 @@
@@ -293,6 +299,15 @@
/* FIXME. Optimize this inner loop. */
while (*word && start < end && *start != '\t') {
+ if ((*start & 0x80) && start+1<end && start[1]!='\t') {
+ if(start[0]!=word[0])
+ return ((unsigned)word[0]<(unsigned)start[0])?-2:1;
+ if(start[1]!=word[1])
+ return ((unsigned)word[1]<(unsigned)start[1])?-2:1;
+ if(start[0]!=word[0])
+ return ((unsigned)word[0]<(unsigned)start[0])?-2:1;
+ if(start[1]!=word[1])
+ return ((unsigned)word[1]<(unsigned)start[1])?-2:1;
+ word+=2;
+ start+=2;
+ continue;
@ -38,7 +38,7 @@
if (!dbindex -> isspacealnum[* (const unsigned char *) start]) {
++start;
continue;
@@ -359,6 +377,8 @@
@@ -340,6 +355,8 @@
*start != '\t' &&
!dbindex -> isspacealnum[* (const unsigned char *) start])
{

View File

@ -1,12 +1,12 @@
--- libmaa/arg.c.orig Wed Jul 17 05:21:04 2002
+++ libmaa/arg.c Wed Jul 17 05:13:50 2002
--- libmaa/arg.c.orig Sat Aug 3 03:43:15 2002
+++ libmaa/arg.c Mon Oct 27 22:11:11 2003
@@ -216,6 +216,9 @@
++pt;
for (last = pt, len = 0; *pt; ++pt, ++len) {
+ if((*pt & 0x80) && pt[1]) {
+ ++pt, ++len;
+ } else
+ if((*pt & 0x80) && pt[1]) {
+ ++pt, ++len;
+ } else
switch (*pt) {
case ' ':
case '\t':