1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-28 05:29:48 +00:00

- Fix build

PR:		172725
Submitted by:	ports fury
This commit is contained in:
Martin Wilke 2013-03-29 01:06:58 +00:00
parent a02b09c90a
commit dfaaafdd97
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=315514
2 changed files with 85 additions and 6 deletions

View File

@ -1,9 +1,5 @@
# New ports collection makefile for: skk-tools
# Date created: 31 Oct 1998
# Whom: Shigeyuki FUKUSHIMA <shige@kuis.kyoto-u.ac.jp>
#
# Created by: Shigeyuki FUKUSHIMA <shige@kuis.kyoto-u.ac.jp>
# $FreeBSD$
#
PORTNAME= skk-tools
PORTVERSION= 1.3.2
@ -22,7 +18,6 @@ OPTIONS_DEFINE= EXPR2
OPTIONS_DEFAULT= EXPR2
EXPR2_DESC= Build skkdic-expr2 (needs glib-2.x)
USE_GCC= any
GNU_CONFIGURE= yes
MAKE_JOBS_SAFE= yes
@ -35,6 +30,7 @@ PLIST_FILES= bin/skkdic-count bin/skkdic-expr bin/skkdic-sort
.if ${PORT_OPTIONS:MEXPR2}
USE_GNOME= glib20
USE_PKGCONFIG= build
PORTDOCS+= README.skkdic-expr2
PLIST_FILES+= bin/skkdic-expr2
.else

View File

@ -0,0 +1,83 @@
--- skkdic-expr.c.orig 2011-04-11 04:42:08.000000000 +0900
+++ skkdic-expr.c 2012-10-13 05:40:10.000000000 +0900
@@ -336,7 +336,7 @@
/* 語尾をtkeyにコピー */
for (p = headtop; *s != '/'; s++, p++) {
- if (*s < 0x20) return;
+ if (*s < 0x20) return 0;
*p = *s;
}
tkey.dsize = p - keybuf;
@@ -344,12 +344,12 @@
/* 語幹部分をcontentにコピーする */
p = content;
for( ; *s != ']'; s++, p++) {
- if (*s < 0x20) return;
+ if (*s < 0x20) return 0;
*p = *s;
}
*p = '\0';
if (*++s != '/')
- return ; /* フォーマットエラー */
+ return 0; /* フォーマットエラー */
/* 古いものと比べて必要ならappend */
otails = dbm_fetch(okuriheaddb, tkey);
@@ -555,7 +555,7 @@
/* 語尾をtkeyにコピー */
for (p = headtop; *s != '/'; s++, p++) {
- if (*s < 0x20) return;
+ if (*s < 0x20) return 0;
*p = *s;
}
tkey.dsize = p - keybuf;
@@ -563,12 +563,12 @@
/* 語幹部分をcontentにコピーする */
p = content;
for( ; *s != ']'; s++, p++) {
- if (*s < 0x20) return;
+ if (*s < 0x20) return 0;
*p = *s;
}
*p = '\0';
if (*++s != '/')
- return ; /* フォーマットエラー */
+ return 0; /* フォーマットエラー */
/* 古いものと比べて必要ならreplace/delete */
otails = dbm_fetch(okuriheaddb, tkey);
@@ -600,12 +600,12 @@
goto next;
}
}
- return;
+ return 0;
}
}
next:;
}
- return;
+ return 0;
}
static void
@@ -708,7 +708,7 @@
tails = dbm_fetch(okuritaildb, tkey);
if (tails.dptr == NULL) {
- return;
+ return 0;
} else {
fseek(dbcontent, getpos(tails.dptr), 0);
db_gets(tail_content, BLEN, dbcontent);
@@ -717,7 +717,7 @@
for(e = s; e[1] != '\0'; s = e + 2) {
for (e = s; *e != '/'; e++)
if (*e < 0x20)
- return;
+ return 0;
strncpy(headtop, s, e - s);
tkey.dsize = (headtop - keybuf) + (e - s);