Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 17 Dec 2013 02:47:22 +0900
From:      KATO Tsuguru <tkato432@yahoo.com>
To:        FreeBSD-gnats-submit@FreeBSD.org
Subject:   ports/184886: devel/pas2dox: Fix build on -current
Message-ID:  <20131217024722.8a58a85032c3249e980e594d@yahoo.com>
Resent-Message-ID: <201312161810.rBGIAO7T016519@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         184886
>Category:       ports
>Synopsis:       devel/pas2dox: Fix build on -current
>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:   Mon Dec 16 18:10:24 UTC 2013
>Closed-Date:
>Last-Modified:
>Originator:     KATO Tsuguru
>Release:        FreeBSD 8.4-RELEASE-p4 i386
>Organization:
>Environment:
>Description:
- Fix build on -current
- Add LICENSE

>How-To-Repeat:
>Fix:

diff -urN /usr/ports/devel/pas2dox/Makefile devel/pas2dox/Makefile
--- /usr/ports/devel/pas2dox/Makefile	2013-11-06 21:49:47.000000000 +0900
+++ devel/pas2dox/Makefile	2013-12-17 00:00:00.000000000 +0900
@@ -9,22 +9,34 @@
 MAINTAINER=	ports@FreeBSD.org
 COMMENT=	Preprocessor to use doxygen with Pascal sources
 
+LICENSE=	GPLv2
+
 WRKSRC=		${WRKDIR}/${PORTNAME}
 
-USE_GMAKE=	yes
+USES=		gmake
 ALL_TARGET=	${PORTNAME}
 
-PLIST_FILES=	bin/pas2dox
+PLIST_FILES=	bin/${PORTNAME}
+
+.include <bsd.port.pre.mk>
+
+.if ${OSVERSION} < 1000033
+BUILD_DEPENDS=	flex>0:${PORTSDIR}/textproc/flex
+MAKE_ENV=	LEX="${LOCALBASE}/bin/flex"
+.endif
 
-NO_STAGE=	yes
 post-patch:
-	${REINPLACE_CMD} 's,^CC=.*$$,CC=$${CXX} $${CPPFLAGS} $${CXXFLAGS},' ${WRKSRC}/Makefile
+	@${REINPLACE_CMD} -e \
+		's|^LEX=|LEX?=| ; \
+		 s|$${CC} $$<|$${CXX} $${CXXFLAGS} $$<|' ${WRKSRC}/Makefile
+	@${REINPLACE_CMD} -e \
+		's|yy_flex_realloc|yyrealloc|' ${WRKSRC}/${PORTNAME}.l
 
 pre-build:
-	${MAKE} -C ${WRKSRC} clean
+	@${RM} -f ${WRKSRC}/${PORTNAME}.cpp
 
 do-install:
-	${MKDIR} ${PREFIX}/bin
-	${INSTALL_PROGRAM} ${WRKSRC}/pas2dox ${PREFIX}/bin
+	(cd ${WRKSRC} && ${INSTALL_PROGRAM} ${PORTNAME} \
+		${STAGEDIR}${PREFIX}/bin)
 
 .include <bsd.port.mk>
>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20131217024722.8a58a85032c3249e980e594d>