View | Details | Raw Unified | Return to bug 27807
Collapse All | Expand All

(-)porters-handbook/book.sgml (+36 lines)
Lines 1265-1270 Link Here
1265
        </sect2>
1265
        </sect2>
1266
      </sect1>
1266
      </sect1>
1267
1267
1268
     <sect1>
1269
      <title>Optional dependencies</title>
1270
      
1271
      <para>Some large applications can be built in a number of
1272
	configurations, adding functionality if one of a number of
1273
	libraries or applications is available. Since not all users
1274
	want those libraries or applications, the ports system
1275
	provides hooks that the port author can use to decide which
1276
	configuration should be built. Supporting these properly will
1277
	make uses happy, and effectively provide 2 or more ports for the
1278
	price of one.</para>
1279
	
1280
      <para>The easiest of these to use is
1281
	<literal>WITHOUT_X</literal>. If the port can be built both
1282
	with and without X support, then it should normally be built
1283
	with X support. If <literal>WITHOUT_X</literal> is defined,
1284
	then the version that does not have X support should be
1285
	built.</para>
1286
	
1287
      <para>Various parts of GNOME have such knobs, though they are
1288
	slightly more difficult to use. The variables to use in the
1289
	<filename>Makefile</filename> are <makevar>WANT_*</makevar>
1290
	and <makevar>HAVE_*</makevar>. If the application can be
1291
	built both with or without one of the dependencies listed
1292
	below, then the <filename>Makefile</filename> should set
1293
	<makevar>WANT_PKG</makevar>, and should build the version that
1294
	uses <makevar>PKG</makevar> if <makevar>HAVE_PKG</makevar>
1295
	is defined.</para>
1296
	
1297
      <para>The <makevar>WANT_*</makevar> variables currently
1298
	supported this way are <makevar>WANT_GLIB</makevar>,
1299
	<makevar>WANT_GTK</makevar>, <makevar>WANT_ESOUND</makevar>,
1300
	<makevar>WANT_IMLIB</makevar>, and
1301
	<makevar>WANT_GNOME</makevar>.</para>
1302
      </sect1>
1303
1268
      <sect1>
1304
      <sect1>
1269
        <title>Building mechanisms</title>
1305
        <title>Building mechanisms</title>

Return to bug 27807