Bug 184889 - deskutils/tpb: Fix build with clang
Summary: deskutils/tpb: Fix build with clang
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Pawel Pekala
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-12-16 18:10 UTC by tkato432
Modified: 2013-12-21 10:30 UTC (History)
0 users

See Also:


Attachments
file.diff (2.18 KB, patch)
2013-12-16 18:10 UTC, tkato432
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description tkato432 2013-12-16 18:10:25 UTC
- Fix build with clang
- Add LICENSE
Comment 1 Pawel Pekala freebsd_committer 2013-12-20 21:09:41 UTC
Responsible Changed
From-To: freebsd-ports-bugs->pawel

I'll take it.
Comment 2 dfilter service freebsd_committer 2013-12-20 21:48:22 UTC
Author: pawel
Date: Fri Dec 20 21:48:14 2013
New Revision: 337092
URL: http://svnweb.freebsd.org/changeset/ports/337092

Log:
  - Fix build with clang
  - Add LICENSE
  - Define OPTIONS, use options subs and helpers
  - Support staging
  
  PR:		ports/184889
  Submitted by:	KATO Tsuguru <tkato432@yahoo.com>

Modified:
  head/deskutils/tpb/Makefile
  head/deskutils/tpb/pkg-plist   (contents, props changed)

Modified: head/deskutils/tpb/Makefile
==============================================================================
--- head/deskutils/tpb/Makefile	Fri Dec 20 21:17:13 2013	(r337091)
+++ head/deskutils/tpb/Makefile	Fri Dec 20 21:48:14 2013	(r337092)
@@ -5,45 +5,44 @@ PORTNAME=	tpb
 PORTVERSION=	0.6.4
 PORTREVISION=	10
 CATEGORIES=	deskutils
-MASTER_SITES=	${MASTER_SITE_SAVANNAH}
-MASTER_SITE_SUBDIR=	${PORTNAME}
+MASTER_SITES=	SAVANNAH
 
 MAINTAINER=	ports@FreeBSD.org
 COMMENT=	On-Screen-Display for hotkeys of IBM ThinkPads
 
+LICENSE=	GPLv2
+
 LIB_DEPENDS=	libxosd.so:${PORTSDIR}/misc/xosd
 
+OPTIONS_DEFINE=	DOCS NLS
+OPTIONS_SUB=	yes
+
 ONLY_FOR_ARCHS=	i386 amd64
 
+USES=		bison gmake iconv pkgconfig
 GNU_CONFIGURE=	yes
-USES=		bison iconv gmake pkgconfig
-
 CONFIGURE_ARGS=	${ICONV_CONFIGURE_ARG}
 
-MAN1=		tpb.1
-
-NO_STAGE=	yes
-.include <bsd.port.options.mk>
+CPPFLAGS+=	-I${LOCALBASE}/include
+LDFLAGS+=	-L${LOCALABASE}/lib
 
-.if ${PORT_OPTIONS:MNLS}
-USES+=		gettext
-PLIST_SUB+=	NLS=""
-.else
-CONFIGURE_ARGS+=--disable-nls
-PLIST_SUB+=	NLS="@comment "
-.endif
+NLS_USES=		gettext
+NLS_CONFIGURE_OFF=	--disable-nls
 
 post-patch:
-	@${REINPLACE_CMD} -e 's|%%PREFIX%%|${PREFIX}|g; \
-		s|%%LOCALBASE%%|${LOCALBASE}|g' \
-		${WRKSRC}/src/cfg.h \
-		${WRKSRC}/man/tpb.1
+.for i in man/tpb.1 src/cfg.h
+	@${REINPLACE_CMD} -e \
+		's|%%PREFIX%%|${PREFIX}|g ; \
+		 s|%%LOCALBASE%%|${LOCALBASE}|g' ${WRKSRC}/${i}
+.endfor
+	@${REINPLACE_CMD} -e \
+		's|void test()||' ${WRKSRC}/configure
 
 post-install:
-	${INSTALL_DATA} ${WRKSRC}/doc/tpbrc ${PREFIX}/etc/tpbrc.default
-.if ${PORT_OPTIONS:MDOCS}
-	${MKDIR} ${DOCSDIR}
-	${INSTALL_SCRIPT} ${WRKSRC}/doc/callback_example.sh ${DOCSDIR}
-.endif
+	(cd ${WRKSRC}/doc && ${INSTALL_DATA} tpbrc \
+		${STAGEDIR}${PREFIX}/etc/tpbrc.default)
+	@${MKDIR} ${STAGEDIR}${DOCSDIR}
+	(cd ${WRKSRC}/doc && ${INSTALL_DATA} callback_example.sh \
+		${STAGEDIR}${DOCSDIR})
 
 .include <bsd.port.mk>

Modified: head/deskutils/tpb/pkg-plist
==============================================================================
--- head/deskutils/tpb/pkg-plist	Fri Dec 20 21:17:13 2013	(r337091)
+++ head/deskutils/tpb/pkg-plist	Fri Dec 20 21:48:14 2013	(r337092)
@@ -1,5 +1,6 @@
 bin/tpb
 etc/tpbrc.default
+man/man1/tpb.1.gz
 %%PORTDOCS%%%%DOCSDIR%%/callback_example.sh
 %%NLS%%share/locale/da/LC_MESSAGES/tpb.mo
 %%NLS%%share/locale/de/LC_MESSAGES/tpb.mo
_______________________________________________
svn-ports-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-ports-all
To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"
Comment 3 Pawel Pekala freebsd_committer 2013-12-20 21:48:26 UTC
State Changed
From-To: open->closed

Committed. Thanks!
Comment 4 dfilter service freebsd_committer 2013-12-21 10:26:33 UTC
Author: mat
Date: Sat Dec 21 10:26:24 2013
New Revision: 337126
URL: http://svnweb.freebsd.org/changeset/ports/337126

Log:
  MFH: r337092
  
  - Fix build with clang
  - Add LICENSE
  - Define OPTIONS, use options subs and helpers
  - Support staging
  
  PR:		ports/184889
  Submitted by:	KATO Tsuguru <tkato432@yahoo.com>
  Approved by:	portmgr (implicit)

Modified:
  branches/2014Q1/deskutils/tpb/Makefile
  branches/2014Q1/deskutils/tpb/pkg-plist   (contents, props changed)
Directory Properties:
  branches/2014Q1/   (props changed)

Modified: branches/2014Q1/deskutils/tpb/Makefile
==============================================================================
--- branches/2014Q1/deskutils/tpb/Makefile	Sat Dec 21 10:25:23 2013	(r337125)
+++ branches/2014Q1/deskutils/tpb/Makefile	Sat Dec 21 10:26:24 2013	(r337126)
@@ -5,45 +5,44 @@ PORTNAME=	tpb
 PORTVERSION=	0.6.4
 PORTREVISION=	10
 CATEGORIES=	deskutils
-MASTER_SITES=	${MASTER_SITE_SAVANNAH}
-MASTER_SITE_SUBDIR=	${PORTNAME}
+MASTER_SITES=	SAVANNAH
 
 MAINTAINER=	ports@FreeBSD.org
 COMMENT=	On-Screen-Display for hotkeys of IBM ThinkPads
 
+LICENSE=	GPLv2
+
 LIB_DEPENDS=	libxosd.so:${PORTSDIR}/misc/xosd
 
+OPTIONS_DEFINE=	DOCS NLS
+OPTIONS_SUB=	yes
+
 ONLY_FOR_ARCHS=	i386 amd64
 
+USES=		bison gmake iconv pkgconfig
 GNU_CONFIGURE=	yes
-USES=		bison iconv gmake pkgconfig
-
 CONFIGURE_ARGS=	${ICONV_CONFIGURE_ARG}
 
-MAN1=		tpb.1
-
-NO_STAGE=	yes
-.include <bsd.port.options.mk>
+CPPFLAGS+=	-I${LOCALBASE}/include
+LDFLAGS+=	-L${LOCALABASE}/lib
 
-.if ${PORT_OPTIONS:MNLS}
-USES+=		gettext
-PLIST_SUB+=	NLS=""
-.else
-CONFIGURE_ARGS+=--disable-nls
-PLIST_SUB+=	NLS="@comment "
-.endif
+NLS_USES=		gettext
+NLS_CONFIGURE_OFF=	--disable-nls
 
 post-patch:
-	@${REINPLACE_CMD} -e 's|%%PREFIX%%|${PREFIX}|g; \
-		s|%%LOCALBASE%%|${LOCALBASE}|g' \
-		${WRKSRC}/src/cfg.h \
-		${WRKSRC}/man/tpb.1
+.for i in man/tpb.1 src/cfg.h
+	@${REINPLACE_CMD} -e \
+		's|%%PREFIX%%|${PREFIX}|g ; \
+		 s|%%LOCALBASE%%|${LOCALBASE}|g' ${WRKSRC}/${i}
+.endfor
+	@${REINPLACE_CMD} -e \
+		's|void test()||' ${WRKSRC}/configure
 
 post-install:
-	${INSTALL_DATA} ${WRKSRC}/doc/tpbrc ${PREFIX}/etc/tpbrc.default
-.if ${PORT_OPTIONS:MDOCS}
-	${MKDIR} ${DOCSDIR}
-	${INSTALL_SCRIPT} ${WRKSRC}/doc/callback_example.sh ${DOCSDIR}
-.endif
+	(cd ${WRKSRC}/doc && ${INSTALL_DATA} tpbrc \
+		${STAGEDIR}${PREFIX}/etc/tpbrc.default)
+	@${MKDIR} ${STAGEDIR}${DOCSDIR}
+	(cd ${WRKSRC}/doc && ${INSTALL_DATA} callback_example.sh \
+		${STAGEDIR}${DOCSDIR})
 
 .include <bsd.port.mk>

Modified: branches/2014Q1/deskutils/tpb/pkg-plist
==============================================================================
--- branches/2014Q1/deskutils/tpb/pkg-plist	Sat Dec 21 10:25:23 2013	(r337125)
+++ branches/2014Q1/deskutils/tpb/pkg-plist	Sat Dec 21 10:26:24 2013	(r337126)
@@ -1,5 +1,6 @@
 bin/tpb
 etc/tpbrc.default
+man/man1/tpb.1.gz
 %%PORTDOCS%%%%DOCSDIR%%/callback_example.sh
 %%NLS%%share/locale/da/LC_MESSAGES/tpb.mo
 %%NLS%%share/locale/de/LC_MESSAGES/tpb.mo
_______________________________________________
svn-ports-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-ports-all
To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"