From owner-svn-ports-head@FreeBSD.ORG Fri Dec 20 11:56:55 2013 Return-Path: Delivered-To: svn-ports-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id DA278801; Fri, 20 Dec 2013 11:56:55 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id BA85A1CCE; Fri, 20 Dec 2013 11:56:55 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id rBKButwW031671; Fri, 20 Dec 2013 11:56:55 GMT (envelope-from pawel@svn.freebsd.org) Received: (from pawel@localhost) by svn.freebsd.org (8.14.7/8.14.7/Submit) id rBKButjM031667; Fri, 20 Dec 2013 11:56:55 GMT (envelope-from pawel@svn.freebsd.org) Message-Id: <201312201156.rBKButjM031667@svn.freebsd.org> From: Pawel Pekala Date: Fri, 20 Dec 2013 11:56:55 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r336998 - in head/graphics/zgv: . files X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-head@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: SVN commit messages for the ports tree for head List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Dec 2013 11:56:55 -0000 Author: pawel Date: Fri Dec 20 11:56:54 2013 New Revision: 336998 URL: http://svnweb.freebsd.org/changeset/ports/336998 Log: - Fix build with clang - Add LICENSE - Add amd64 to ONLY_FOR_ARCHS - Add option for SDL support - Switch to pkg-plist - Support staging PR: ports/184827 Submitted by: KATO Tsuguru Added: head/graphics/zgv/files/patch-zgv_io.c (contents, props changed) head/graphics/zgv/pkg-plist (contents, props changed) Modified: head/graphics/zgv/Makefile (contents, props changed) Modified: head/graphics/zgv/Makefile ============================================================================== --- head/graphics/zgv/Makefile Fri Dec 20 11:53:44 2013 (r336997) +++ head/graphics/zgv/Makefile Fri Dec 20 11:56:54 2013 (r336998) @@ -5,49 +5,67 @@ PORTNAME= zgv PORTVERSION= 5.9 PORTREVISION= 5 CATEGORIES= graphics -MASTER_SITES= ${MASTER_SITE_SUNSITE} -MASTER_SITE_SUBDIR= apps/graphics/viewers/svga +MASTER_SITES= SUNSITE/apps/graphics/viewers/svga MAINTAINER= ports@FreeBSD.org COMMENT= Graphics viewer for SVGAlib -LIB_DEPENDS= tiff.4:${PORTSDIR}/graphics/tiff \ - vga.1:${PORTSDIR}/graphics/svgalib \ - jpeg.11:${PORTSDIR}/graphics/jpeg \ - png15:${PORTSDIR}/graphics/png +LICENSE= GPLv2 # (or later) -ONLY_FOR_ARCHS= i386 -USE_GMAKE= yes +LIB_DEPENDS= libjpeg.so:${PORTSDIR}/graphics/jpeg \ + libpng15.so:${PORTSDIR}/graphics/png \ + libtiff.so:${PORTSDIR}/graphics/tiff + +OPTIONS_DEFINE= SDL + +USES= gmake ALL_TARGET= zgv info -MAKE_ENV= ZGV_LIBS="${LDFLAGS}" -BINMODE= 4755 -PLIST_FILES= bin/zgv etc/zgvrc.sample -.if !defined(NO_INSTALL_MANPAGES) -MAN1= zgv.1 -.endif -.if !defined(NOPORTDOCS) -INFO= zgv -PORTDOCS= NEWS README SECURITY TODO INSTALL +CPPFLAGS+= -I${LOCALBASE}/include +LDFLAGS+= -L${LOCALBASE}/lib + +.include + +.if ${PORT_OPTIONS:MSDL} +USE_SDL= sdl +MAKE_ENV+= BACKEND=SDL +CPPFLAGS+= $$(${SDL_CONFIG} --cflags) +LDFLAGS+= $$(${SDL_CONFIG} --libs) +.else +LIB_DEPENDS+= libvga.so:${PORTSDIR}/graphics/svgalib +MAKE_ENV+= BACKEND=SVGALIB +ONLY_FOR_ARGS= i386 amd64 .endif -NO_STAGE= yes +post-extract: + @${RM} ${WRKSRC}/doc/zgv + post-patch: - ${RM} ${WRKSRC}/doc/zgv - @${REINPLACE_CMD} -e 's|ZGV_LIBS=|ZGV_LIBS+=|' ${WRKSRC}/src/Makefile + @${REINPLACE_CMD} -e \ + 's|^CC=|#CC=|g ; \ + s|^CFLAGS=|#CFLAGS=|g ; \ + s|^BACKEND=|#BACKEND=|g ; \ + s|^PREFIX=|#PREFIX=|g ; \ + s|/usr/X11R6|$${LOCALBASE}|g' ${WRKSRC}/config.mk + @${REINPLACE_CMD} -e \ + 's|-I/usr/local/include|$${CPPFLAGS}|g ; \ + s|-L/usr/local/lib|$${LDFLAGS}|g ; \ + s|=-lSDL|=|g' ${WRKSRC}/src/Makefile + @${GREP} -lR "SDL/SDL" ${WRKSRC} | ${XARGS} ${REINPLACE_CMD} -e \ + 's|SDL/SDL|SDL|g' do-install: - ${INSTALL_PROGRAM} ${WRKSRC}/src/zgv ${PREFIX}/bin - ${INSTALL_DATA} ${WRKSRC}/doc/sample.zgvrc ${PREFIX}/etc/zgvrc.sample -.if !defined(NOPORTDOCS) - ${INSTALL_DATA} ${WRKSRC}/doc/zgv ${PREFIX}/${INFO_PATH}/zgv.info - ${MKDIR} ${DOCSDIR} -.for i in ${PORTDOCS} - ${INSTALL_DATA} ${WRKSRC}/${i} ${DOCSDIR} + (cd ${WRKSRC}/src && ${INSTALL_PROGRAM} zgv \ + ${STAGEDIR}${PREFIX}/bin/zgv) + (cd ${WRKSRC}/doc && ${INSTALL_MAN} zgv.1 \ + ${STAGEDIR}${MANPREFIX}/man/man1/zgv.1) + (cd ${WRKSRC}/doc && ${INSTALL_DATA} sample.zgvrc \ + ${STAGEDIR}${PREFIX}/etc/zgvrc.sample) + (cd ${WRKSRC}/doc && ${INSTALL_DATA} zgv \ + ${STAGEDIR}${PREFIX}/${INFO_PATH}/zgvrc.info) + @${MKDIR} ${STAGEDIR}${DOCSDIR} +.for i in NEWS README SECURITY TODO INSTALL + (cd ${WRKSRC} && ${INSTALL_DATA} ${i} ${STAGEDIR}${DOCSDIR}) .endfor -.endif -.if !defined(NO_INSTALL_MANPAGES) - ${INSTALL_MAN} ${WRKSRC}/doc/zgv.1 ${MAN1PREFIX}/man/man1 -.endif .include Added: head/graphics/zgv/files/patch-zgv_io.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/graphics/zgv/files/patch-zgv_io.c Fri Dec 20 11:56:54 2013 (r336998) @@ -0,0 +1,11 @@ +--- src/zgv_io.c.orig ++++ src/zgv_io.c +@@ -645,7 +645,7 @@ + case SDLK_INSERT: return(RK_INSERT); + case SDLK_DELETE: return(RK_DELETE); + case SDLK_RETURN: return(RK_ENTER); +- default: ++ default: ; + /* stop complaints */ + } + Added: head/graphics/zgv/pkg-plist ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/graphics/zgv/pkg-plist Fri Dec 20 11:56:54 2013 (r336998) @@ -0,0 +1,12 @@ +@mode 4555 +bin/zgv +@mode +etc/zgvrc.sample +info/zgvrc.info +man/man1/zgv.1.gz +%%PORTDOCS%%%%DOCSDIR%%/INSTALL +%%PORTDOCS%%%%DOCSDIR%%/NEWS +%%PORTDOCS%%%%DOCSDIR%%/README +%%PORTDOCS%%%%DOCSDIR%%/SECURITY +%%PORTDOCS%%%%DOCSDIR%%/TODO +%%PORTDOCS%%@dirrm %%DOCSDIR%%