svn commit: r46354 - head/en_US.ISO8859-1/books/porters-handbook/makefiles

Brad Davis <[email protected]>
Newsgroups gmane.os.freebsd.devel.cvs.doc
Message-ID <[email protected]>
Author: brd
Date: Wed Mar 18 22:36:22 2015
New Revision: 46354
URL: https://svnweb.freebsd.org/changeset/doc/46354

Log:
  Clean up all the formatting in <programlisting> blocks for The Porters Handbook

Modified:
  head/en_US.ISO8859-1/books/porters-handbook/makefiles/chapter.xml

Modified: head/en_US.ISO8859-1/books/porters-handbook/makefiles/chapter.xml
==============================================================================
--- head/en_US.ISO8859-1/books/porters-handbook/makefiles/chapter.xml	Wed Mar 18 20:52:46 2015	(r46353)
+++ head/en_US.ISO8859-1/books/porters-handbook/makefiles/chapter.xml	Wed Mar 18 22:36:22 2015	(r46354)
@@ -261,7 +261,7 @@
 	  collection:</para>
 
 	<programlisting>PORTNAME=	gtkmumble
-	  PORTVERSION=	0.10</programlisting>
+PORTVERSION=	0.10</programlisting>
 
 	<para><varname>PKGNAME</varname> becomes
 	  <literal>gtkmumble-0.10</literal>.</para>
@@ -271,8 +271,8 @@
 	  accordingly.</para>
 
 	<programlisting>PORTNAME=	gtkmumble
-	  PORTVERSION=	0.10
-	  PORTREVISION=	1</programlisting>
+PORTVERSION=	0.10
+PORTREVISION=	1</programlisting>
 
 	<para><varname>PKGNAME</varname> becomes
 	  <literal>gtkmumble-0.10_1</literal></para>
@@ -291,8 +291,8 @@
 	  removed from the <filename>Makefile</filename>).</para>
 
 	<programlisting>PORTNAME=	gtkmumble
-	  PORTVERSION=	0.2
-	  PORTEPOCH=	1</programlisting>
+PORTVERSION=	0.2
+PORTEPOCH=	1</programlisting>
 
 	<para><varname>PKGNAME</varname> becomes
 	  <literal>gtkmumble-0.2,1</literal></para>
@@ -302,8 +302,8 @@
 	  variables are now:</para>
 
 	<programlisting>PORTNAME=	gtkmumble
-	  PORTVERSION=	0.3
-	  PORTEPOCH=	1</programlisting>
+PORTVERSION=	0.3
+PORTEPOCH=	1</programlisting>
 
 	<para><varname>PKGNAME</varname> becomes
 	  <literal>gtkmumble-0.3,1</literal></para>
@@ -1657,7 +1657,7 @@
 	really is no reason to do so:</para>
 
       <programlisting>MASTER_SITES=		${MASTER_SITE_GNU}
-	MASTER_SITE_SUBDIR=	make</programlisting>
+MASTER_SITE_SUBDIR=	make</programlisting>
 
       <para>These values and variables are defined in
 	<filename>/usr/ports/Mk/bsd.sites.mk</filename>.  There are
@@ -1679,7 +1679,7 @@
       <para>This can also be written as</para>
 
       <programlisting>MASTER_SITES=	SF
-	MASTER_SITE_SUBDIR=	stardict/WyabdcRealPeopleTTS/${PORTVERSION}</programlisting>
+MASTER_SITE_SUBDIR=	stardict/WyabdcRealPeopleTTS/${PORTVERSION}</programlisting>
 
       <table frame="none" xml:id="makefile-master_sites-popular">
 	<title>Popular Magic <varname>MASTER_SITES</varname>
@@ -1860,11 +1860,11 @@
 	    this (slightly stripped for the example):</para>
 
 	  <programlisting>PORTNAME=	pkg
-	    PORTVERSION=	1.2.7
+PORTVERSION=	1.2.7
 
-	    USE_GITHUB=	yes
-	    GH_ACCOUNT=	freebsd
-	    GH_COMMIT=	f53e577</programlisting>
+USE_GITHUB=	yes
+GH_ACCOUNT=	freebsd
+GH_COMMIT=	f53e577</programlisting>
 
 	  <para>It will automatically have
 	    <varname>MASTER_SITES</varname> set to <literal>GH
@@ -1884,13 +1884,13 @@
 	    this (slightly stripped for the example):</para>
 
 	  <programlisting>PORTNAME=	pkg-devel
-	    PORTVERSION=	1.3.0.a.20140411
+PORTVERSION=	1.3.0.a.20140411
 
-	    USE_GITHUB=	yes
-	    GH_ACCOUNT=	freebsd
-	    GH_PROJECT=	pkg
-	    GH_TAGNAME=	${GH_COMMIT}
-	    GH_COMMIT=	6dbb17b</programlisting>
+USE_GITHUB=	yes
+GH_ACCOUNT=	freebsd
+GH_PROJECT=	pkg
+GH_TAGNAME=	${GH_COMMIT}
+GH_COMMIT=	6dbb17b</programlisting>
 
 	  <para>It will automatically have
 	    <varname>MASTER_SITES</varname> set to <literal>GH
@@ -1913,7 +1913,7 @@
 	<filename>foo.tar.gz</filename>, write:</para>
 
       <programlisting>DISTNAME=	foo
-	EXTRACT_SUFX=	.tar.gzip</programlisting>
+EXTRACT_SUFX=	.tar.gzip</programlisting>
 
       <para>The
 	<literal>USES=tar[:<replaceable>xxx</replaceable>]</literal>,
@@ -1960,7 +1960,7 @@
 	<varname>EXTRACT_ONLY</varname>.</para>
 
       <programlisting>DISTFILES=	source.tar.gz manual.html
-	EXTRACT_ONLY=	source.tar.gz</programlisting>
+EXTRACT_ONLY=	source.tar.gz</programlisting>
 
       <para>When none of the <varname>DISTFILES</varname> need to be
 	uncompressed, set <varname>EXTRACT_ONLY</varname> to the empty
@@ -2123,10 +2123,10 @@
 	  <title>Simplified Use of <literal>MASTER_SITES:n</literal>
 	    with One File Per Site</title>
 
-	  <programlisting>MASTER_SITES=	ftp://ftp.example1.com/:source1 \
-	    ftp://ftp.example2.com/:source2
-	    DISTFILES=	source1.tar.gz:source1 \
-	    source2.tar.gz:source2</programlisting>
+	  <programlisting>MASTER_SITES=	ftp://ftp1.example.com/:source1 \
+		http://www.example.com/:source2
+DISTFILES=	source1.tar.gz:source1 \
+		source2.tar.gz:source2</programlisting>
 	</example>
 
 	<para>Multiple distribution files can have the same tag.
@@ -2144,11 +2144,11 @@
 	  <title>Simplified Use of <literal>MASTER_SITES:n</literal>
 	    with More Than One File Per Site</title>
 
-	  <programlisting>MASTER_SITES=	ftp://ftp.example1.com/:source1 \
-	    ftp://ftp.example2.com/:source2
-	    DISTFILES=	source1.tar.gz:source1 \
-	    source2.tar.gz:source2 \
-	    source3.tar.gz:source2</programlisting>
+	  <programlisting>MASTER_SITES=	ftp://ftp.example.com/:source1 \
+		http://www.example.com/:source2
+DISTFILES=	source1.tar.gz:source1 \
+		source2.tar.gz:source2 \
+		source3.tar.gz:source2</programlisting>
 	</example>
       </sect3>
 
@@ -2325,17 +2325,17 @@
 		    Multiple Subdirectories</title>
 
 		  <programlisting>MASTER_SITES=	http://site1/%SUBDIR%/ http://site2/:DEFAULT \
-		    http://site3/:group3 http://site4/:group4 \
-		    http://site5/:group5 http://site6/:group6 \
-		    http://site7/:DEFAULT,group6 \
-		    http://site8/%SUBDIR%/:group6,group7 \
-		    http://site9/:group8
-		    DISTFILES=	file1 file2:DEFAULT file3:group3 \
-		    file4:group4,group5,group6 file5:grouping \
-		    file6:group7
-		    MASTER_SITE_SUBDIR=	directory-trial:1 directory-n/:groupn \
-		    directory-one/:group6,DEFAULT \
-		    directory</programlisting>
+		http://site3/:group3 http://site4/:group4 \
+		http://site5/:group5 http://site6/:group6 \
+		http://site7/:DEFAULT,group6 \
+		http://site8/%SUBDIR%/:group6,group7 \
+		http://site9/:group8
+DISTFILES=	file1 file2:DEFAULT file3:group3 \
+		file4:group4,group5,group6 file5:grouping \
+		file6:group7
+MASTER_SITE_SUBDIR=	directory-trial:1 directory-n/:groupn \
+		directory-one/:group6,DEFAULT \
+		directory</programlisting>
 
 		  <para>The previous example results in this
 		    fine grained fetching.  Sites are listed in the
@@ -2522,7 +2522,7 @@
 		<varname>MASTER_SITE_SOURCEFORGE</varname></title>
 
 	      <programlisting>MASTER_SITES=	http://site1/ ${MASTER_SITE_SOURCEFORGE:S/$/:sourceforge,TEST/}
-		DISTFILES=	something.tar.gz:sourceforge</programlisting>
+DISTFILES=	something.tar.gz:sourceforge</programlisting>
 	    </example>
 
 	    <para><filename>something.tar.gz</filename> will be
@@ -2549,7 +2549,7 @@
 		<varname>PATCH_SITES</varname></title>
 
 	      <programlisting>PATCH_SITES=	http://site1/ http://site2/:test
-		PATCHFILES=	patch1:test</programlisting>
+PATCHFILES=	patch1:test</programlisting>
 	    </example>
 	  </listitem>
 	</orderedlist>
@@ -2727,9 +2727,9 @@
 	  <varname>ALWAYS_KEEP_DISTFILES</varname></title>
 
 	<programlisting>.if defined(PACKAGE_BUILDING)
-	  DISTFILES+=		<replaceable>foo.tar.gz</replaceable>
-	  ALWAYS_KEEP_DISTFILES=	yes
-	  .endif</programlisting>
+DISTFILES+=		<replaceable>foo.tar.gz</replaceable>
+ALWAYS_KEEP_DISTFILES=	yes
+.endif</programlisting>
       </example>
 
       <para>When adding extra files to <varname>DISTFILES</varname>,
@@ -2992,7 +2992,7 @@
       <para>For example,</para>
 
       <programlisting>RUN_DEPENDS=	${LOCALBASE}/news/bin/innd:${PORTSDIR}/news/inn \
-	xmlcatmgr:${PORTSDIR}/textproc/xmlcatmgr</programlisting>
+xmlcatmgr:${PORTSDIR}/textproc/xmlcatmgr</programlisting>
 
       <para>will check if the file or directory
 	<filename>/usr/local/news/bin/innd</filename> exists, and
@@ -3362,9 +3362,9 @@
 	<title>Correct Declaration of an Optional Dependency</title>
 
 	<programlisting>OPTIONS_DEFINE=	BAR
-	  BAR_DESC=	Calling cellphones via bar
+BAR_DESC=	Calling cellphones via bar
 
-	  BAR_LIB_DEPENDS=	libbar.so:${PORTSDIR}/foo/bar</programlisting>
+BAR_LIB_DEPENDS=	libbar.so:${PORTSDIR}/foo/bar</programlisting>
       </example>
 
       <para>Testing option variables is the correct method.  It will
@@ -3432,18 +3432,18 @@
       of <filename>japanese/xdvi300/Makefile</filename>;</para>
 
     <programlisting>PORTNAME=	xdvi
-      PORTVERSION=	17
-      PKGNAMEPREFIX=	ja-
-      PKGNAMESUFFIX=	${RESOLUTION}
-      :
-      # default
-      RESOLUTION?=	300
-      .if ${RESOLUTION} != 118 &amp;&amp; ${RESOLUTION} != 240 &amp;&amp; \
-      ${RESOLUTION} != 300 &amp;&amp; ${RESOLUTION} != 400
-      @${ECHO_MSG} "Error: invalid value for RESOLUTION: \"${RESOLUTION}\""
-      @${ECHO_MSG} "Possible values are: 118, 240, 300 (default) and 400."
-      @${FALSE}
-      .endif</programlisting>
+PORTVERSION=	17
+PKGNAMEPREFIX=	ja-
+PKGNAMESUFFIX=	${RESOLUTION}
+
+# default
+RESOLUTION?=	300
+.if ${RESOLUTION} != 118 &amp;&amp; ${RESOLUTION} != 240 &amp;&amp; \
+${RESOLUTION} != 300 &amp;&amp; ${RESOLUTION} != 400
+@${ECHO_MSG} "Error: invalid value for RESOLUTION: \"${RESOLUTION}\""
+@${ECHO_MSG} "Possible values are: 118, 240, 300 (default) and 400."
+@${FALSE}
+.endif</programlisting>
 
     <para><package role="port">japanese/xdvi300</package> also has all
       the regular patches, package files, etc.  Running
@@ -3455,9 +3455,9 @@
       <filename>xdvi118/Makefile</filename>:</para>
 
     <programlisting>RESOLUTION=	118
-      MASTERDIR=	${.CURDIR}/../xdvi300
+MASTERDIR=	${.CURDIR}/../xdvi300
 
-      .include "${MASTERDIR}/Makefile"</programlisting>
+.include "${MASTERDIR}/Makefile"</programlisting>
 
     <para>(<filename>xdvi240/Makefile</filename> and
       <filename>xdvi400/Makefile</filename> are similar).
@@ -3572,11 +3572,11 @@
 	  described (optional, but strongly recommended):</para>
 
 	<programlisting>OPT1_DESC=	Describe OPT1
-	  OPT2_DESC=	Describe OPT2
-	  OPT3_DESC=	Describe OPT3
-	  OPT4_DESC=	Describe OPT4
-	  OPT5_DESC=	Describe OPT5
-	  OPT6_DESC=	Describe OPT6</programlisting>
+OPT2_DESC=	Describe OPT2
+OPT3_DESC=	Describe OPT3
+OPT4_DESC=	Describe OPT4
+OPT5_DESC=	Describe OPT5
+OPT6_DESC=	Describe OPT6</programlisting>
 
 	<para><filename>ports/Mk/bsd.options.desc.mk</filename>
 	  has descriptions for many common <varname>OPTIONS</varname>.
@@ -3607,7 +3607,7 @@
 	  allowed:</para>
 
 	<programlisting>OPTIONS_SINGLE=		SG1
-	  OPTIONS_SINGLE_SG1=	OPT3 OPT4</programlisting>
+OPTIONS_SINGLE_SG1=	OPT3 OPT4</programlisting>
 
 	<warning>
 	  <para>There <emphasis>must</emphasis> be one of each
@@ -4382,7 +4382,7 @@ CFLAGS+=	-DTEST
 	    For example:</para>
 
 	  <programlisting>OPTIONS_DEFINE=	OPT1
-OPT1_USES_OFF=gmake</programlisting>
+OPT1_USES_OFF=	gmake</programlisting>
 
 	  <para>is equivalent to:</para>
 
@@ -4638,16 +4638,16 @@ PORTVERSION=	1.0</programlisting>
 	target.</para>
 
       <programlisting>post-install:
-	  ${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
-	  (cd ${WRKSRC}/examples &amp;&amp; ${COPYTREE_SHARE} . ${STAGEDIR}${EXAMPLESDIR})</programlisting>
+	${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
+	(cd ${WRKSRC}/examples &amp;&amp; ${COPYTREE_SHARE} . ${STAGEDIR}${EXAMPLESDIR})</programlisting>
 
       <para>This example will install the contents of the
 	<filename>examples</filename> directory in the vendor distfile
 	to the proper examples location of the port.</para>
 
       <programlisting>post-install:
-	  ${MKDIR} ${STAGEDIR}${DATADIR}/summer
-	  (cd ${WRKSRC}/temperatures &amp;&amp; ${COPYTREE_SHARE} "June July August" ${STAGEDIR}${DATADIR}/summer)</programlisting>
+	${MKDIR} ${STAGEDIR}${DATADIR}/summer
+	(cd ${WRKSRC}/temperatures &amp;&amp; ${COPYTREE_SHARE} "June July August" ${STAGEDIR}${DATADIR}/summer)</programlisting>
 
       <para>And this example will install the data of summer months to
 	the <filename>summer</filename> subdirectory of a
@@ -4660,7 +4660,7 @@ PORTVERSION=	1.0</programlisting>
 	these commands.</para>
 
       <programlisting>post-install:
-	  ${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
+	${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
 	(cd ${WRKSRC}/examples &amp;&amp; \
 	${COPYTREE_SHARE} . ${STAGEDIR}${EXAMPLESDIR} "! -name Makefile")</programlisting>
 
@@ -4698,8 +4698,8 @@ PORTVERSION=	1.0</programlisting>
 	enough to cause significant I/O overhead.</para>
 
       <programlisting>post-install:
-	  ${MKDIR} ${STAGEDIR}${DOCSDIR}
-	  ${INSTALL_MAN} ${WRKSRC}/docs/xvdocs.ps ${STAGEDIR}${DOCSDIR}</programlisting>
+	${MKDIR} ${STAGEDIR}${DOCSDIR}
+	${INSTALL_MAN} ${WRKSRC}/docs/xvdocs.ps ${STAGEDIR}${DOCSDIR}</programlisting>
 
       <para>Here are some handy variables and how they are expanded by
 	default when used in the <filename>Makefile</filename>:</para>
_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/svn-doc-all
To unsubscribe, send any mail to "[email protected]"
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.