Date: Fri, 30 Aug 2013 20:00:42 +0000 (UTC) From: Jung-uk Kim <jkim@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r325718 - in head/korean/engdic: . files Message-ID: <201308302000.r7UK0gcm076661@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: jkim Date: Fri Aug 30 20:00:42 2013 New Revision: 325718 URL: http://svnweb.freebsd.org/changeset/ports/325718 Log: Fix build with Clang. Remove defunct master site. Added: head/korean/engdic/files/ head/korean/engdic/files/patch-Makefile (contents, props changed) head/korean/engdic/files/patch-engdic.c (contents, props changed) head/korean/engdic/files/patch-engdic.h (contents, props changed) head/korean/engdic/files/patch-screen.c (contents, props changed) Deleted: head/korean/engdic/pkg-plist Modified: head/korean/engdic/Makefile Modified: head/korean/engdic/Makefile ============================================================================== --- head/korean/engdic/Makefile Fri Aug 30 19:24:37 2013 (r325717) +++ head/korean/engdic/Makefile Fri Aug 30 20:00:42 2013 (r325718) @@ -3,18 +3,24 @@ PORTNAME= engdic PORTVERSION= 0.2 +PORTREVISION= 1 CATEGORIES= korean deskutils -MASTER_SITES= ftp://ftp.holywar.net/pub/engdic/ \ - ftp://ftp.kr.freebsd.org/pub/FreeBSD-kr/distfiles/ +MASTER_SITES= ftp://ftp.kr.freebsd.org/pub/FreeBSD-kr/distfiles/ MAINTAINER= ports@FreeBSD.org COMMENT= English dictionary utility for Korean ALL_TARGET= clean all +PLIST_FILES= bin/edic bin/engdic +PORTDATA= [a-z].dic.gz post-patch: - @for f in ${WRKSRC}/Makefile ${WRKSRC}/engdic.h; do \ - ${REINPLACE_CMD} -e 's,/usr/local,${PREFIX},g' $$f; \ - done + ${REINPLACE_CMD} -e 's|%%DATADIR%%|${DATADIR}|' ${WRKSRC}/engdic.h + +do-install: + ${INSTALL_PROGRAM} ${WRKSRC}/engdic ${PREFIX}/bin + ${LN} -sf ${PREFIX}/bin/engdic ${PREFIX}/bin/edic + ${MKDIR} ${DATADIR} + ${INSTALL_DATA} ${WRKSRC}/data/[a-z].dic.gz ${DATADIR} .include <bsd.port.mk> Added: head/korean/engdic/files/patch-Makefile ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/korean/engdic/files/patch-Makefile Fri Aug 30 20:00:42 2013 (r325718) @@ -0,0 +1,11 @@ +--- Makefile.orig 1999-09-05 22:48:50.000000000 -0400 ++++ Makefile 2013-08-30 15:19:45.000000000 -0400 +@@ -28,7 +28,7 @@ + DESTDIR = /usr/local/bin/ + DATA_DESTDIR = /usr/local/share/engdic/ + RM = rm -f *.o +-CC = gcc ++CC ?= cc + + all: engdic + Added: head/korean/engdic/files/patch-engdic.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/korean/engdic/files/patch-engdic.c Fri Aug 30 20:00:42 2013 (r325718) @@ -0,0 +1,46 @@ +--- engdic.c.orig 1999-09-05 22:48:50.000000000 -0400 ++++ engdic.c 2013-08-30 13:54:53.000000000 -0400 +@@ -29,6 +29,7 @@ + #include <termio.h> + #endif + ++#include <ctype.h> + #include <stdio.h> + #include <stdlib.h> + #include <string.h> +@@ -49,7 +50,17 @@ + char get_command(void) ; + struct size_buf get_term(void); + ++void clear_eol(void) ; ++void deinit(void) ; ++void flush(void) ; ++char getchr(void) ; ++void init(void) ; ++void lower_left(void) ; ++int putchr(int) ; + char putstr (char *s) ; ++void raw_mode(int on) ; ++void so_enter(void) ; ++void so_exit(void) ; + char sep[] = ":" ; + static int line = 0 ; + +@@ -68,7 +79,7 @@ + struct stat sb ; + + // type of gzip file // +- register gzFile *gzfp ; ++ register gzFile gzfp ; + + + if (argc > 1) { +@@ -182,7 +193,7 @@ + register int check_cols_count = 0 ; + char ch ; + +- if (tk == NULL || tk2 == NULL) return ; ++ if (tk == NULL || tk2 == NULL) return 0 ; + + putstr(WORD_COLOR) ; putstr("[ ") ; putstr(tk); putchr(']') ; + putstr(NO_COLOR) ; putstr("\r\n") ; Added: head/korean/engdic/files/patch-engdic.h ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/korean/engdic/files/patch-engdic.h Fri Aug 30 20:00:42 2013 (r325718) @@ -0,0 +1,11 @@ +--- engdic.h.orig 1999-09-05 22:48:35.000000000 -0400 ++++ engdic.h 2013-08-30 14:21:04.000000000 -0400 +@@ -20,7 +20,7 @@ + */ + + // Global value +-#define INSTALL_DIC_DATA_DIR "/usr/local/share/engdic" ++#define INSTALL_DIC_DATA_DIR "%%DATADIR%%" + #define MAX_LENGTH 80 + #define COLS_MAX 1024 + Added: head/korean/engdic/files/patch-screen.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/korean/engdic/files/patch-screen.c Fri Aug 30 20:00:42 2013 (r325718) @@ -0,0 +1,258 @@ +--- screen.c.orig 1999-09-05 22:48:35.000000000 -0400 ++++ screen.c 2013-08-30 13:56:48.000000000 -0400 +@@ -45,6 +45,8 @@ + + #include <stdio.h> + #include <string.h> ++#include <term.h> ++#include <unistd.h> + + #define TERMIOS 1 + +@@ -53,7 +55,9 @@ + #else + #if TERMIOS + #include <termios.h> ++#ifndef TAB3 + #define TAB3 0 ++#endif + #include <sys/ioctl.h> + #else + #include <sgtty.h> +@@ -75,6 +79,7 @@ + #endif + + #include <setjmp.h> ++#include <stdlib.h> + #include "engdic.h" + + volatile int reading; +@@ -131,8 +136,12 @@ + /*extern*/ char PC; /* Pad character */ + + int back_scroll; +-char *tgetstr(); +-char *tgoto(); ++ ++void bo_exit(void); ++void flush(void); ++int iread(int, char *, int); ++void so_exit(void); ++void ul_exit(void); + + /* + * Change terminal to "raw mode", or restore to "normal" mode. +@@ -145,8 +154,7 @@ + * etc. are NOT disabled. + * It doesn't matter whether an input \n is mapped to \r, or vice versa. + */ +-raw_mode(on) +- int on; ++void raw_mode(int on) + { + #if TERMIO || TERMIOS + +@@ -245,7 +253,7 @@ + /* + * Get terminal capabilities via termcap. + */ +-struct size_buf get_term() ++struct size_buf get_term(void) + { + char termbuf[2048]; + char *sp; +@@ -260,8 +268,6 @@ + #endif + static char sbuf[1024]; + +- char *getenv(), *strcpy(); +- + struct size_buf sz_buf ; + + /* +@@ -470,12 +476,12 @@ + * terminal-specific screen manipulation. + */ + +-int putchr(); ++int putchr(int); + + /* + * Initialize terminal + */ +-init() ++void init(void) + { + tputs(sc_init, sc_height, putchr); + } +@@ -483,7 +489,7 @@ + /* + * Deinitialize terminal + */ +-deinit() ++void deinit(void) + { + tputs(sc_deinit, sc_height, putchr); + } +@@ -491,7 +497,7 @@ + /* + * Home cursor (move to upper left corner of screen). + */ +-home() ++void home(void) + { + tputs(sc_home, 1, putchr); + } +@@ -500,13 +506,13 @@ + * Add a blank line (called with cursor at home). + * Should scroll the display down. + */ +-add_line() ++void add_line(void) + { + tputs(sc_addline, sc_height, putchr); + } + + int short_file; /* if file less than a screen */ +-lower_left() ++void lower_left(void) + { + if (short_file) { + putchr('\r'); +@@ -517,17 +523,9 @@ + } + + /* +- * Ring the terminal bell. +- */ +-bell() +-{ +- putchr('\7'); +-} +- +-/* + * Clear the screen. + */ +-clear() ++void clear(void) + { + if (mode_flags & M_SO) + so_exit(); +@@ -542,7 +540,7 @@ + * Clear from the cursor to the end of the cursor's line. + * {{ This must not move the cursor. }} + */ +-clear_eol() ++void clear_eol(void) + { + if (mode_flags & M_SO) + so_exit(); +@@ -556,7 +554,7 @@ + /* + * Begin "standout" (bold, underline, or whatever). + */ +-so_enter() ++void so_enter(void) + { + tputs(sc_s_in, 1, putchr); + mode_flags |= M_SO; +@@ -565,7 +563,7 @@ + /* + * End "standout". + */ +-so_exit() ++void so_exit(void) + { + tputs(sc_s_out, 1, putchr); + mode_flags &= ~M_SO; +@@ -575,7 +573,7 @@ + * Begin "underline" (hopefully real underlining, + * otherwise whatever the terminal provides). + */ +-ul_enter() ++void ul_enter(void) + { + tputs(sc_u_in, 1, putchr); + mode_flags |= M_UL; +@@ -584,7 +582,7 @@ + /* + * End "underline". + */ +-ul_exit() ++void ul_exit(void) + { + tputs(sc_u_out, 1, putchr); + mode_flags &= ~M_UL; +@@ -593,7 +591,7 @@ + /* + * Begin "bold" + */ +-bo_enter() ++void bo_enter(void) + { + tputs(sc_b_in, 1, putchr); + mode_flags |= M_BO; +@@ -602,7 +600,7 @@ + /* + * End "bold". + */ +-bo_exit() ++void bo_exit(void) + { + tputs(sc_b_out, 1, putchr); + mode_flags &= ~M_BO; +@@ -612,7 +610,7 @@ + * Erase the character to the left of the cursor + * and move the cursor left. + */ +-backspace() ++void backspace(void) + { + /* + * Try to erase the previous character by overstriking with a space. +@@ -625,28 +623,27 @@ + /* + * Output a plain backspace, without erasing the previous char. + */ +-putbs() ++void putbs(void) + { + tputs(sc_backspace, 1, putchr); + } + +-putchr(c) +- int c; ++int putchr(int c) + { + if (ob >= &obuf[sizeof(obuf)]) + flush(); + *ob++ = c; ++ return (c); + } + +-putstr(s) +- register char *s; ++void putstr(register char *s) + { + while (*s != '\0') + putchr(*s++); + } + + +-flush() ++void flush(void) + { + register int n; + +@@ -676,10 +673,7 @@ + return ((unsigned char)c); + } + +-iread(fd, buf, len) +- int fd; +- char *buf; +- int len; ++int iread(int fd, char *buf, int len) + { + register int n; +
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201308302000.r7UK0gcm076661>