Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 26 Apr 2013 23:30:37 +0000 (UTC)
From:      Jason Helfman <jgh@FreeBSD.org>
To:        doc-committers@freebsd.org, svn-doc-all@freebsd.org, svn-doc-head@freebsd.org
Subject:   svn commit: r41507 - head/en_US.ISO8859-1/books/porters-handbook
Message-ID:  <201304262330.r3QNUbeK000912@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: jgh (ports committer)
Date: Fri Apr 26 23:30:36 2013
New Revision: 41507
URL: http://svnweb.freebsd.org/changeset/doc/41507

Log:
  - document USES=gettext
  
  PR:		178169
  Reviewed by:	remko

Modified:
  head/en_US.ISO8859-1/books/porters-handbook/book.xml
  head/en_US.ISO8859-1/books/porters-handbook/uses.xml

Modified: head/en_US.ISO8859-1/books/porters-handbook/book.xml
==============================================================================
--- head/en_US.ISO8859-1/books/porters-handbook/book.xml	Fri Apr 26 16:44:44 2013	(r41506)
+++ head/en_US.ISO8859-1/books/porters-handbook/book.xml	Fri Apr 26 23:30:36 2013	(r41507)
@@ -5781,17 +5781,12 @@ CMAKE_SOURCE_PATH=	&dollar;{WRKSRC}/subp
       <sect2>
 	<title>Basic Usage</title>
 
-	<para>If your port requires <literal>gettext</literal>,
-	  just set <makevar>USE_GETTEXT</makevar> to
-	  <literal>yes</literal>, and your port will grow the
-	  dependency on <filename
-	    role="package">devel/gettext</filename>.  The value of
-	  <makevar>USE_GETTEXT</makevar> can also specify the required
-	  version of the <literal>libintl</literal> library, the basic
-	  part of <literal>gettext</literal>, but using this feature
-	  is <emphasis>strongly discouraged</emphasis>: Your port
-	  should work with just the current version of <filename
-	    role="package">devel/gettext</filename>.</para>
+	<para>If your port requires <literal>gettext</literal>, set
+	  <literal>USES= gettext</literal>, and your
+	  port will inherit a dependency on <filename
+	    role="package">devel/gettext</filename>. Other values for
+	  <literal>gettext</literal> usage are listed in <xref
+	  linkend="uses-values"/>.</para>
 
 	<para>A rather common case is a port using
 	  <literal>gettext</literal> and <command>configure</command>.
@@ -5802,7 +5797,7 @@ CMAKE_SOURCE_PATH=	&dollar;{WRKSRC}/subp
 	  <envar>CPPFLAGS</envar> and <envar>LDFLAGS</envar> as
 	  follows:</para>
 
-	<programlisting>USE_GETTEXT=	yes
+	<programlisting>USES=	gettext
 CPPFLAGS+=	-I${LOCALBASE}/include
 LDFLAGS+=	-L${LOCALBASE}/lib
 
@@ -5811,7 +5806,7 @@ GNU_CONFIGURE=	yes</programlisting>
 	<para>Of course, the code can be more compact if there are no
 	  more flags to pass to <command>configure</command>:</para>
 
-	<programlisting>USE_GETTEXT=	yes
+	<programlisting>USES=	gettext
 GNU_CONFIGURE=	yes</programlisting>
       </sect2>
 
@@ -5832,7 +5827,7 @@ GNU_CONFIGURE=	yes</programlisting>
 .include &lt;bsd.port.options.mk&gt;
 
 .if ${PORT_OPTIONS:MNLS}
-USE_GETTEXT=		yes
+USES+=			gettext
 PLIST_SUB+=		NLS=""
 .else
 CONFIGURE_ARGS+=	--disable-nls

Modified: head/en_US.ISO8859-1/books/porters-handbook/uses.xml
==============================================================================
--- head/en_US.ISO8859-1/books/porters-handbook/uses.xml	Fri Apr 26 16:44:44 2013	(r41506)
+++ head/en_US.ISO8859-1/books/porters-handbook/uses.xml	Fri Apr 26 23:30:36 2013	(r41507)
@@ -63,6 +63,19 @@
 </row>
 
 <row>
+  <entry><literal>gettext</literal></entry>
+  <entry>none, <literal>lib</literal>, <literal>build</literal>,
+    <literal>run</literal></entry>
+  <entry>Implies that the port uses <filename
+      role="package">devel/gettext</filename> in one way or another.  By
+    default, with no arguments or with the <literal>lib</literal>
+    argument, implies <command>gettext</command> with build-time and 
+    run-time dependencies, <literal>build</literal> implies a build-time
+    dependency, and <literal>run</literal> implies a run-time
+    dependency.</entry>
+</row>
+
+<row>
   <entry><literal>pathfix</literal></entry>
   <entry>none</entry>
   <entry>Look for the <filename>Makefile.in</filename> and



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