Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 2 Sep 2013 05:41:50 +0000 (UTC)
From:      Boris Samorodov <bsam@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r325937 - in head: Mk/Uses devel/common_lib devel/liblangtag emulators/vice hebrew/hunspell japanese/gjiten japanese/platex-japanese sysutils/djmount ukrainian/hunspell
Message-ID:  <201309020541.r825fojI091526@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: bsam
Date: Mon Sep  2 05:41:50 2013
New Revision: 325937
URL: http://svnweb.freebsd.org/changeset/ports/325937

Log:
  1. Introduce using iconv with arguments:
  . lib (default, implicit);
  . build,
  . patch.
  
  The default is the same, all existing ports stay valid.
  
  2. Introduce variable ICONV_CMD with default to ${LOCALBASE}/bin/iconv.
  It is intended to get the value of /usr/bin/iconv at recent 10.x.
  
  3. Adopt all ports to using USES+= icomv:build and iconv:patch and
  change iconv (executable) at Makefile commands to ${ICONV_CMD} at those ports.
  
  Submitted by:	bsam (me, via e-mail)
  Approved by:	portmgr (bapt)

Modified:
  head/Mk/Uses/iconv.mk
  head/devel/common_lib/Makefile
  head/devel/liblangtag/Makefile
  head/emulators/vice/Makefile
  head/hebrew/hunspell/Makefile
  head/japanese/gjiten/Makefile
  head/japanese/platex-japanese/Makefile
  head/sysutils/djmount/Makefile
  head/ukrainian/hunspell/Makefile

Modified: head/Mk/Uses/iconv.mk
==============================================================================
--- head/Mk/Uses/iconv.mk	Mon Sep  2 05:40:37 2013	(r325936)
+++ head/Mk/Uses/iconv.mk	Mon Sep  2 05:41:50 2013	(r325937)
@@ -5,17 +5,25 @@
 # MAINTAINER: portmgr@FreeBSD.org
 #
 # Feature:	iconv
-# Usage:	USES=iconv
-# Valid ARGS:	does not require args
+# Usage:	USES=iconv or USES=iconv:ARGS
+# Valid ARGS:	lib (default, implicit), build, patch
 #
 #
 .if !defined(_INCLUDE_USES_ICONV_MK)
 _INCLUDE_USES_ICONV_MK=	yes
 
-.if defined(iconv_ARGS)
-IGNORE=	USES=iconv does not require args
+ICONV_CMD=	${LOCALBASE}/bin/iconv
+
+.if !defined(iconv_ARGS)
+iconv_ARGS=     lib
 .endif
 
+.if ${iconv_ARGS} == "lib"
 LIB_DEPENDS+=	libiconv.so.3:${PORTSDIR}/converters/libiconv
+.elif ${iconv_ARGS} == "build"
+BUILD_DEPENDS+=	${ICONV_CMD}:${PORTSDIR}/converters/libiconv
+.elif ${iconv_ARGS} == "patch"
+PATCH_DEPENDS+=	${ICONV_CMD}:${PORTSDIR}/converters/libiconv
+.endif
 
 .endif

Modified: head/devel/common_lib/Makefile
==============================================================================
--- head/devel/common_lib/Makefile	Mon Sep  2 05:40:37 2013	(r325936)
+++ head/devel/common_lib/Makefile	Mon Sep  2 05:41:50 2013	(r325937)
@@ -9,8 +9,7 @@ MAINTAINER=	olgeni@FreeBSD.org
 COMMENT=	Library of commonly used Erlang functions
 
 BUILD_DEPENDS=	erlc:${PORTSDIR}/lang/erlang \
-		txt2tags:${PORTSDIR}/textproc/txt2tags \
-		iconv:${PORTSDIR}/converters/libiconv
+		txt2tags:${PORTSDIR}/textproc/txt2tags
 RUN_DEPENDS=	erl:${PORTSDIR}/lang/erlang
 
 PLIST_SUB=	VERSION="${PORTVERSION}"
@@ -24,6 +23,7 @@ GH_TAGNAME=	${PORTVERSION}
 USE_GMAKE=	yes
 USE_DOS2UNIX=	Makefile
 ALL_TARGET=	compile doc
+USES=		iconv:build
 
 MAN1=		common_lib.1
 MAN3=		cl_application.3 cl_binary.3 cl_calendar.3 cl_consumer.3 \
@@ -37,7 +37,7 @@ post-extract:
 
 do-install:
 .for manpage in ${MAN1} ${MAN3}
-	@iconv -f UTF-8 -t ISO-8859-1 ${WRKSRC}/doc/man/${manpage} > ${WRKSRC}/doc/man/${manpage}.iconv
+	@${ICONV_CMD} -f UTF-8 -t ISO-8859-1 ${WRKSRC}/doc/man/${manpage} > ${WRKSRC}/doc/man/${manpage}.iconv
 .endfor
 .for manpage in ${MAN1}
 	@${INSTALL_MAN} ${WRKSRC}/doc/man/${manpage}.iconv ${MAN1PREFIX}/man/man1/${manpage}

Modified: head/devel/liblangtag/Makefile
==============================================================================
--- head/devel/liblangtag/Makefile	Mon Sep  2 05:40:37 2013	(r325936)
+++ head/devel/liblangtag/Makefile	Mon Sep  2 05:41:50 2013	(r325937)
@@ -13,7 +13,6 @@ COMMENT=	An interface library to access 
 LICENSE=	LGPL3 MPL
 LICENSE_COMB=	dual
 
-BUILD_DEPENDS=	iconv:${PORTSDIR}/converters/libiconv
 LIB_DEPENDS=	xml2:${PORTSDIR}/textproc/libxml2
 
 GNU_CONFIGURE=	yes
@@ -21,7 +20,7 @@ USE_AUTOTOOLS=	libtool
 USE_BZIP2=	yes
 USE_GMAKE=	yes
 USE_LDCONFIG=	yes
-USES=		pathfix pkgconfig
+USES=		iconv:build pathfix pkgconfig
 
 CONFIGURE_ARGS=	--disable-introspection
 

Modified: head/emulators/vice/Makefile
==============================================================================
--- head/emulators/vice/Makefile	Mon Sep  2 05:40:37 2013	(r325936)
+++ head/emulators/vice/Makefile	Mon Sep  2 05:41:50 2013	(r325937)
@@ -105,8 +105,7 @@ LIB_DEPENDS+=		avcodec:${PORTSDIR}/multi
 .endif
 
 .if ${PORT_OPTIONS:MNLS}
-USES+=		gettext
-PATCH_DEPENDS+=		${LOCALBASE}/bin/iconv:${PORTSDIR}/converters/libiconv
+USES+=		gettext iconv:patch
 CONFIGURE_ARGS+=	--enable-nls --localedir=${LOCALBASE}/share/locale
 # causes vice to crash:
 #LDFLAGS+=		-lgettextlib
@@ -139,7 +138,7 @@ post-patch:
 		${WRKSRC}/configure
 .for i in da.po de.po fr.po hu.po it.po nl.po pl.po sv.po tr.po
 	${MV} "${WRKSRC}/po/${i}" "${WRKSRC}/po/${i}.latin"
-	${LOCALBASE}/bin/iconv -f latin1 -t utf-8 < "${WRKSRC}/po/${i}.latin" > "${WRKSRC}/po/${i}"
+	${ICONV_CMD} -f latin1 -t utf-8 < "${WRKSRC}/po/${i}.latin" > "${WRKSRC}/po/${i}"
 .endfor
 .if ! ${PORT_OPTIONS:MDOCS}
 	${REINPLACE_CMD} -e 's| doc||' ${WRKSRC}/Makefile.in

Modified: head/hebrew/hunspell/Makefile
==============================================================================
--- head/hebrew/hunspell/Makefile	Mon Sep  2 05:40:37 2013	(r325936)
+++ head/hebrew/hunspell/Makefile	Mon Sep  2 05:41:50 2013	(r325937)
@@ -16,9 +16,7 @@ DIST_SUBDIR=	${PORTNAME}
 MAINTAINER=	office@FreeBSD.org
 COMMENT=	Hebrew hunspell dictionaries
 
-BUILD_DEPENDS=	iconv:${PORTSDIR}/converters/libiconv
-
-USES=		perl5
+USES=		iconv:build perl5
 ALL_TARGET=	hunspell
 CONFIGURE_ARGS=	--enable-fatverb
 GNU_CONFIGURE=	yes

Modified: head/japanese/gjiten/Makefile
==============================================================================
--- head/japanese/gjiten/Makefile	Mon Sep  2 05:40:37 2013	(r325936)
+++ head/japanese/gjiten/Makefile	Mon Sep  2 05:41:50 2013	(r325937)
@@ -46,7 +46,7 @@ RUN_DEPENDS+=	${EDICT_FILE}:${PORTSDIR}/
 EDICT_DIR=	${LOCALBASE}/share/dict/edict
 EDICT_FILE=	${EDICT_DIR}/edict
 RUN_DEPENDS+=	${EDICT_FILE}:${PORTSDIR}/japanese/edict
-BUILD_DEPENDS+=	${LOCALBASE}/bin/iconv:${PORTSDIR}/converters/libiconv
+USES+=		iconv:build
 .endif
 
 DICTIONARIES=	kanjidic edict compdic
@@ -72,7 +72,7 @@ post-install:
 .endfor
 .else
 .for f in ${DICTIONARIES}
-	${LOCALBASE}/bin/iconv -c -f EUC-JP -t UTF-8 ${EDICT_DIR}/${f} > ${GJITEN_DICS}/${f}
+	${ICONV_CMD} -c -f EUC-JP -t UTF-8 ${EDICT_DIR}/${f} > ${GJITEN_DICS}/${f}
 .endfor
 .endif
 	-@update-desktop-database

Modified: head/japanese/platex-japanese/Makefile
==============================================================================
--- head/japanese/platex-japanese/Makefile	Mon Sep  2 05:40:37 2013	(r325936)
+++ head/japanese/platex-japanese/Makefile	Mon Sep  2 05:41:50 2013	(r325937)
@@ -18,10 +18,9 @@ DIST_SUBDIR=	latex
 MAINTAINER=	yokota@res.otaru-uc.ac.jp
 COMMENT=	pLaTeX package that literally provides Japanese option to babel
 
-BUILD_DEPENDS=	iconv:${PORTSDIR}/converters/libiconv
-
 USE_ZIP=	yes
 USE_TEX=	latex ptex
+USES=		iconv:build
 
 TEXMFDIR=	share/texmf
 STYDIR=		tex/generic/babel
@@ -33,7 +32,6 @@ SAMPLEFILE=	sample.tex
 PDFFILE=	sample.pdf
 TEXTFILE=	README
 ENCODING?=	EUC-JP
-ICONV=		${LOCALBASE}/bin/iconv
 MKTEXLSR=	${LOCALBASE}/bin/mktexlsr
 
 .SILENT::
@@ -49,7 +47,7 @@ post-configure:
 	   ${SED} -e 's/\(sample\.tex\)/j\1/g' ${INSFILE:S/$/.orig/} \
 	   > ${INSFILE} && \
 	   ${MV} ${DTXFILE} ${DTXFILE}.orig && \
-	   ${ICONV} -f ISO-2022-JP -t ${ENCODING} ${DTXFILE}.orig > ${DTXFILE} )
+	   ${ICONV_CMD} -f ISO-2022-JP -t ${ENCODING} ${DTXFILE}.orig > ${DTXFILE} )
 
 do-build:
 	( cd ${WRKSRC} && platex ${INSFILE} && \

Modified: head/sysutils/djmount/Makefile
==============================================================================
--- head/sysutils/djmount/Makefile	Mon Sep  2 05:40:37 2013	(r325936)
+++ head/sysutils/djmount/Makefile	Mon Sep  2 05:41:50 2013	(r325937)
@@ -11,11 +11,10 @@ MAINTAINER=	eric@camachat.org
 COMMENT=	Mount UPnP A/V Media
 
 LIB_DEPENDS=	upnp.9:${PORTSDIR}/devel/upnp
-BUILD_DEPENDS=	iconv:${PORTSDIR}/converters/libiconv
 
 PLIST_FILES=	bin/${PORTNAME}
 GNU_CONFIGURE=	yes
-USES=		fuse pkgconfig
+USES=		fuse iconv:build pkgconfig
 CONFIGURE_ARGS=	--with-libiconv-prefix=${LOCALBASE} \
 		--with-fuse-prefix=${LOCALBASE} \
 		--with-external-libupnp --with-libupnp-prefix=${LOCALBASE}

Modified: head/ukrainian/hunspell/Makefile
==============================================================================
--- head/ukrainian/hunspell/Makefile	Mon Sep  2 05:40:37 2013	(r325936)
+++ head/ukrainian/hunspell/Makefile	Mon Sep  2 05:41:50 2013	(r325937)
@@ -12,9 +12,7 @@ DIST_SUBDIR=	${PORTNAME}
 MAINTAINER=	office@FreeBSD.org
 COMMENT=	Ukrainian hunspell dictionaries
 
-BUILD_DEPENDS=	iconv:${PORTSDIR}/converters/libiconv
-
-USES=		shebangfix perl5
+USES=		iconv:build shebangfix perl5
 ALL_TARGET=	myspell
 USE_GMAKE=	yes
 USE_PERL5=	build



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