ports/172024: japansese/xjtext: Fix build

KATO Tsuguru tkato432 at yahoo.com
Tue Sep 25 18:10:32 UTC 2012


>Number:         172024
>Category:       ports
>Synopsis:       japansese/xjtext: Fix build
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Tue Sep 25 18:10:31 UTC 2012
>Closed-Date:
>Last-Modified:
>Originator:     KATO Tsuguru
>Release:        FreeBSD 7.4-RELEASE-p10 i386
>Organization:
>Environment:
>Description:
- Fix build
- Add MAKE_JOBS_SAFE

>How-To-Repeat:
>Fix:

diff -urN /usr/ports/japanese/xjtext/Makefile japanese/xjtext/Makefile
--- /usr/ports/japanese/xjtext/Makefile	2012-06-14 05:55:51.000000000 +0900
+++ japanese/xjtext/Makefile	2012-09-25 03:35:39.000000000 +0900
@@ -1,9 +1,5 @@
-# New ports collection makefile for:	xjtext
-# Date created:		8 July 2000
-# Whom:			sada
-#
+# Created by: sada
 # $FreeBSD: ports/japanese/xjtext/Makefile,v 1.22 2012/06/13 20:55:51 pav Exp $
-#
 
 PORTNAME=	xjtext
 PORTVERSION=	1.3
@@ -15,26 +11,28 @@
 MAINTAINER=	ports at FreeBSD.org
 COMMENT=	A text viewer for Japanese vertical writings
 
-BROKEN=		does not compile
+OPTIONS_DEFINE=	DOCS EXAMPLES
 
 USE_BISON=	build
 USE_GNOME=	imlib
+MAKE_JOBS_SAFE=	yes
 
 SUB_FILES=	pkg-message
-PLIST_FILES=	bin/xjtext
+
 PORTDOCS=	README.txt
 PORTEXAMPLES=	FSS README YAMA Ao.png Back2.png Brown.png Royal.png Royal2.png
+PLIST_FILES=	bin/xjtext
+
+.include <bsd.port.options.mk>
 
 do-install:
 	${INSTALL_PROGRAM} ${WRKSRC}/xjtext ${PREFIX}/bin
-
-post-install:
-.if !defined(NOPORTDOCS)
-	${MKDIR} ${DOCSDIR}
+.if ${PORT_OPTIONS:MDOCS}
+	@${MKDIR} ${DOCSDIR}
 	cd ${WRKSRC} && ${INSTALL_DATA} ${PORTDOCS} ${DOCSDIR}
 .endif
-.if !defined(NOPORTEXAMPLES)
-	${MKDIR} ${EXAMPLESDIR}
+.if ${PORT_OPTIONS:MEXAMPLES}
+	@${MKDIR} ${EXAMPLESDIR}
 	cd ${WRKSRC} && ${INSTALL_DATA} ${PORTEXAMPLES} ${EXAMPLESDIR}
 .endif
 	@${CAT} ${PKGMESSAGE}
diff -urN /usr/ports/japanese/xjtext/files/patch-aa japanese/xjtext/files/patch-aa
--- /usr/ports/japanese/xjtext/files/patch-aa	2008-04-20 02:51:14.000000000 +0900
+++ japanese/xjtext/files/patch-aa	2012-09-11 04:28:50.000000000 +0900
@@ -1,10 +1,9 @@
---- Makefile.orig	Sat Sep  4 22:45:16 1999
-+++ Makefile	Mon May 16 15:30:41 2005
-@@ -1,9 +1,9 @@
--CC	=g++
+--- Makefile.orig	1999-09-04 22:45:16.000000000 +0900
++++ Makefile	2012-09-11 04:28:11.000000000 +0900
+@@ -1,27 +1,27 @@
+ CC	=g++
 -CFLAGS	=-c -g -O 
 -INCDIRS	=-I/usr/X11R6/include -I/usr/local/include
-+CC	=${CXX}
 +CFLAGS	=${CXXFLAGS} -c
 +INCDIRS	=-I${LOCALBASE}/include `imlib-config --cflags`
  LIBS 	=-lX11 -lXext  -lm -lfl 
@@ -15,12 +14,43 @@
  OBJS	=xwindow.o xfont.o xtext.o xjtext.o lex.yy.o parser.tab.o xjtext-main.o
  
  all: xjtext
-@@ -39,7 +39,7 @@
- 	${CC} ${CFLAGS} ${INCDIRS} lex.yy.c
+ 
+ xwindow.o: xwindow.h xwindow.c 
+-	${CC} ${CFLAGS} ${INCDIRS} xwindow.c
++	${CXX} ${CFLAGS} ${INCDIRS} xwindow.c
+ 
+ xfont.o: xwindow.h xfont.h xfont.c 
+-	${CC} ${CFLAGS} ${INCDIRS} xfont.c
++	${CXX} ${CFLAGS} ${INCDIRS} xfont.c
+ 
+ xtext.o: xwindow.h xfont.h xtext.h xtext.c
+-	${CC} ${CFLAGS} ${INCDIRS} xtext.c
++	${CXX} ${CFLAGS} ${INCDIRS} xtext.c
+ 
+ xjtext.o: xwindow.h xfont.h xtext.h xjtext.h xjtext.c
+-	${CC} ${CFLAGS} ${INCDIRS} xjtext.c
++	${CXX} ${CFLAGS} ${INCDIRS} xjtext.c
+ 
+ xjtext-main.o: xwindow.h xfont.h xtext.h xjtext.h xjtext-main.c
+-	${CC} ${CFLAGS} ${INCDIRS} xjtext-main.c
++	${CXX} ${CFLAGS} ${INCDIRS} xjtext-main.c
+ 
+ parser.tab.c: xwindow.h xfont.h xtext.h xjtext.h parsing.h parser.y
+ 	bison -dv parser.y
+@@ -33,13 +33,13 @@
+ 	flex lex.l
+ 
+ parser.tab.o: parser.tab.c
+-	${CC} ${CFLAGS} ${INCDIRS} parser.tab.c
++	${CXX} ${CFLAGS} ${INCDIRS} parser.tab.c
+ 
+ lex.yy.o: xwindow.h xfont.h xtext.h xjtext.h parsing.h parser.tab.h lex.yy.c
+-	${CC} ${CFLAGS} ${INCDIRS} lex.yy.c
++	${CXX} ${CFLAGS} ${INCDIRS} lex.yy.c
  
  xjtext: ${OBJS}
 -	LD_RUN_PATH=/usr/X11R6/lib/ ${CC} ${OBJS} ${LIBDIRS} ${LIBS} ${IMLIBS}\
-+	LD_RUN_PATH=${LOCALBASE}/lib/ ${CC} ${OBJS} ${LIBDIRS} ${LIBS} ${IMLIBS}\
++	LD_RUN_PATH=${LOCALBASE}/lib/ ${CXX} ${OBJS} ${LIBDIRS} ${LIBS} ${IMLIBS}\
  	-o xjtext
  
  clean:
diff -urN /usr/ports/japanese/xjtext/files/patch-xjtext_main.c japanese/xjtext/files/patch-xjtext_main.c
--- /usr/ports/japanese/xjtext/files/patch-xjtext_main.c	2005-05-18 09:17:35.000000000 +0900
+++ japanese/xjtext/files/patch-xjtext_main.c	2012-09-11 04:24:19.000000000 +0900
@@ -1,6 +1,13 @@
---- xjtext-main.c.orig	Sat Sep  4 22:45:16 1999
-+++ xjtext-main.c	Mon May 16 15:58:11 2005
-@@ -9,7 +9,7 @@
+--- xjtext-main.c.orig	1999-09-04 22:45:16.000000000 +0900
++++ xjtext-main.c	2012-09-11 04:23:11.000000000 +0900
+@@ -3,13 +3,13 @@
+ xJTextWindow*   XWin;
+ 
+ char            FileName[256];
+-main            (int ArgCnt,char** ArgVal)
++int main            (int ArgCnt,char** ArgVal)
+ {
+   if(ArgCnt<2){ yyin=stdin;strcpy(FileName,"stdin");}
    else
      {
        if(NULL==(yyin=fopen(ArgVal[1],"r")))
>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the freebsd-ports-bugs mailing list