source: trunk/base/doc/portgroup.7 @ 26976

Last change on this file since 26976 was 26976, checked in by sfiera@…, 13 years ago

Moved port.1 to base/doc, replaced some stray references to old ports.conf

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 9.6 KB
Line 
1.\" portgroup.7
2.\"
3.\" Copyright (c) 2005 Paul Guyot <pguyot@kallisys.net>
4.\" All rights reserved.
5.\"
6.\" Redistribution and use in source and binary forms, with or without
7.\" modification, are permitted provided that the following conditions
8.\" are met:
9.\" 1. Redistributions of source code must retain the above copyright
10.\"    notice, this list of conditions and the following disclaimer.
11.\" 2. Redistributions in binary form must reproduce the above copyright
12.\"    notice, this list of conditions and the following disclaimer in the
13.\"    documentation and/or other materials provided with the distribution.
14.\" 3. Neither the name of Apple Computer, Inc. nor the names of its
15.\"    contributors may be used to endorse or promote products derived from
16.\"    this software without specific prior written permission.
17.\"
18.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
19.\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
20.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
21.\" ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
22.\" LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
23.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
24.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
25.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
26.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
27.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
28.\" POSSIBILITY OF SUCH DAMAGE.
29.\"
30.Dd February 5, 2007
31.Dt XCODE 7 "MacPorts"
32.Os
33.Sh NAME
34.Nm PortGroup
35.Nd MacPorts PortGroup command reference
36.Sh SYNOPSIS
37.Nm PortGroup gnustep 1.0
38.Nm PortGroup perl5 1.0
39.Nm PortGroup python 1.0
40.Nm PortGroup python24 1.0
41.Nm PortGroup ruby 1.0
42.Nm PortGroup xcode 1.0
43.Sh DESCRIPTION
44MacPorts defines the notion of PortGroup classes with the PortGroup command.
45These classes factorize the work for similar ports.  Port maintainers willing to
46use
47.Nm PortGroup
48need to have some notion of Portfiles. See
49.Xr portfile 7
50.Pp
51.Sh XCODE PORTGROUP
52.Nm PortGroup xcode
53is here to easily port Xcode-based opensource software. It handles
54configuration, build and destroot phases. It also defines some values
55for Xcode-based software. A minimum Portfile using the xcode PortGroup class
56only defines the fetch and the checksum phases.
57.Pp
58Using
59.Nm PortGroup xcode
60is a way to make your port more robust to Xcode version updates as the PortGroup
61is tested against all supported Mac OS X and Xcode versions.
62.Sh XCODE PORTGROUP SUGAR
63Portfiles using xcode PortGroup do not need to define the following variables:
64.Bl -tag -width lc
65.It Ic categories
66.Sy Default:
67.Em aqua
68.br
69.It Ic platforms
70.Sy Default:
71.Em macosx
72.br
73.It Ic use_configure
74.Sy Default:
75.Em no
76.El
77.br
78Moreover, Portfiles using
79.Nm PortGroup xcode
80do not need to define any build or destroot phase.  Some options are provided
81for tailoring these phases to what the software requires.
82.Sh XCODE PORTGROUP SPECIFIC VARIABLES
83Portfiles using xcode PortGroup may define the following variables:
84.Bl -tag -width lc
85.It Ic xcode.project
86path (relative to ${build.dir} and ${destroot.dir}) of the Xcode project. If
87unset, let xcode tool figure it out. It usually succeeds if there is a single
88project in the directory.
89.br
90.Sy Type:
91.Em optional
92.br
93.Sy Example:
94.Dl xcode.project ${name}.xcode
95.br
96.It Ic xcode.configuration
97Project configuration/buildstyle to use.
98.br
99.Sy Type:
100.Em optional
101.br
102.Sy Default:
103.Em Deployment
104.br
105.Sy Example:
106.Dl xcode.configuration Main
107.br
108.It Ic xcode.target
109If present, overrides build.target and destroot.target.
110.br
111.Sy Type:
112.Em optional
113.br
114.It Ic xcode.build.settings
115Additional settings passed to the xcode build tool during the build phase.
116These settings should be in the X=Y form.
117.br
118.Sy Type:
119.Em optional
120.br
121.Sy Example:
122.Bd -literal -offset indent -compact
123xcode.build.settings FRAMEWORK_SEARCH_PATHS=${prefix}/Library/Frameworks
124.Ed
125.It Ic xcode.destroot.type
126Type of project that will be installed. This tells Xcode PortGroup how to
127destroot the project. Correct values are application and framework.
128.br
129.Sy Type:
130.Em optional
131.br
132.Sy Default:
133.Em application
134.br
135.Sy Example:
136.Dl xcode.destroot.type framework
137.It Ic xcode.destroot.path
138Where to install the build product.
139.br
140.Sy Type:
141.Em optional
142.br
143.Sy Default:
144.Em /Library/Frameworks
145or
146.Em /Application/MacPorts depending on xcode.destroot.type
147.br
148.It Ic xcode.destroot.settings
149Additional settings passed to the xcode build tool during the destroot phase.
150These settings should be in the X=Y form.
151.br
152.Sy Type:
153.Em optional
154.br
155.Sy Example:
156.Bd -literal -offset indent -compact
157xcode.destroot.settings SKIP_INSTALL=NO
158.Ed
159.El
160.Sh STANDARD PORTFILE VARIABLES AFFECTING XCODE PORTGROUP
161The following standard Portfile variables actually affect
162.Nm xcode PortGroup.
163In most cases, you will not need to set any of these variables in the Portfile.
164.Bl -tag -width lc
165.It Ic destroot
166Where to destroot the project.
167.br
168.It Ic build.cmd
169The command to invoke to build the project.
170.Nm xcode PortGroup
171sets this variable to ${xcodebuildcmd}.
172.br
173.It Ic build.target
174The Xcode target to build.
175.Nm xcode PortGroup
176sets this variable to "", thus building all targets. This variable will be
177ignored if xcode.target is set.
178.br
179.It Ic build.pre_args
180Additional parameters for ${build.cmd}.
181.br
182.Sy Default:
183none
184.br
185.It Ic build.args
186Main parameters for ${build.cmd}.
187.br
188.Sy Default:
189.Em build
190.br
191.It Ic build.post_args
192Additional parameters for ${build.cmd}.
193.br
194.Sy Default:
195none
196.br
197.It Ic build.dir
198Where to build the project from (i.e. where the Xcode project is).
199.br
200.Sy Default:
201${worksrcpath}
202.br
203.It Ic destroot.cmd
204The command to invoke to destroot the project.
205.Nm xcode PortGroup
206sets this variable to xcodebuildcmd.
207.br
208.It Ic destroot.target
209The Xcode target to install.
210.Nm xcode PortGroup
211sets this variable to "", thus installing all targets. This variable will be
212ignored if xcode.target is set.
213.br
214.It Ic destroot.pre_args
215Additional parameters for ${destroot.cmd}.
216.br
217.Sy Default:
218none
219.br
220.It Ic destroot.args
221Main parameters for ${destroot.cmd}.
222.br
223.Sy Default:
224.Em install
225.br
226.It Ic destroot.post_args
227Additional parameters for ${destroot.cmd}.
228.br
229.Sy Default:
230none
231.br
232.It Ic destroot.dir
233Where to destroot the project from (i.e. where the Xcode project is).
234.br
235.Sy Default:
236${worksrcpath}
237.br
238.El
239.Sh GNUSTEP PORTGROUP
240.Nm PortGroup gnustep
241is here to easily port GNUstep-based opensource software using the GNU
242objective-C runtime. It handles configuration, build and destroot phases.
243It also defines some values for GNUstep-based software. A minimum Portfile
244using the gnustep PortGroup class only defines the fetch and the checksum phases.
245.Sh GNUSTEP FILESYSTEM LAYOUTS
246.Nm PortGroup gnustep
247also supports both the traditionnal gnustep file layout and the new fhs file layout.
248However, the ports themselves do not necessarily support both.
249The Portfiles have access to many procedures in dealing with these two layouts :
250.Bl -tag -width lc
251.It Ic set_gnustep_make
252Sets GNUSTEP_MAKEFILES according to the FilesystemLayout
253.br
254.It Ic set_gnustep_env
255Sets DYLD_LIBRARY_PATH and PATH for the gnustep FilesystemLayout
256.br
257.It Ic gnustep_layout
258Returns true (1) if current file layout is gnustep
259.br
260.It Ic set_system_library
261Sets GNUSTEP_SYSTEM_LIBRARY according to the FilesystemLayout
262.br
263.It Ic set_local_library
264Sets GNUSTEP_LOCAL_LIBRARY according to the FilesystemLayout
265.br
266.Pp
267.Sh GNUSTEP PORTGROUP SUGAR
268Portfiles using gnustep PortGroup do not need to define the following variables:
269.Bl -tag -width lc
270.It Ic categories
271.Sy Default:
272.Em gnustep
273.br
274.It Ic homepage
275.Sy Default:
276.Em http://www.gnustep.org/
277.br
278.It Ic master_sites
279.Sy Default:
280.Em gnustep:core
281.br
282.It Ic depends_lib
283.Sy Default:
284.Em gnustep-core
285.br
286.It Ic use_configure
287.Sy Default:
288.Em no
289.It Ic configure.env
290.Sy Default:
291.Em DYLD_LIBRARY_PATH PATH
292.It Ic configure.pre_args-append
293.Sy Default:
294.Em CC=gcc-mp-4.2 GNUSTEP_MAKEFILES
295.br
296.It Ic build.type
297.Sy Default:
298.Em gnu
299.br
300.It Ic build.env
301.Sy Default:
302.Em DYLD_LIBRARY_PATH PATH
303.It Ic build.pre_args-append
304.Sy Default:
305.Em messages=yes
306.br
307.It Ic destroot.env
308.Sy Default:
309.Em DYLD_LIBRARY_PATH PATH
310.It Ic destroot.pre_args-append
311.Sy Default:
312.Em messages=yes
313.br
314.br
315.El
316.br
317Moreover, Portfiles using
318.Nm PortGroup gnustep
319do not need to define any build or destroot phase.  Some options are provided
320for tailoring these phases to what the software requires.  A mechanism is also
321provided to ease the patch process.
322.Sh GNUSTEP PORTGROUP SPECIFIC VARIABLES
323Portfiles using
324.Nm gnustep PortGroup
325may define the following variables:
326.Bl -tag -width lc
327.It Ic gnustep.post_flags
328an associative array which specifies the sub-directories relative to ${worksrcpath}
329and the SHARED_LD_POSTFLAGS variables to be added to GNUmakefile.preamble in those
330sub-directories.  This helps making the patching process easier on Darwin.
331.br
332.Sy Type:
333.Em optional
334.br
335.Sy Example:
336.Dl platform darwin {
337.Dl             array set gnustep.post_flags {
338.Dl                     BundleSubDir  """-lfoo -lbar""
339.Dl             }
340.Dl }
341.br
342.It Ic gnustep.cc
343.br
344.Sy Type:
345.Em optional
346.br
347.Sy Default:
348.Em gcc-mp-4.2
349.br
350.Sy Example:
351.Dl gnustep.cc gcc-mp-4.3
352.br
353.It Ic variant with_docs
354Many GNUstep packages include a Documentation sub-directory that is not
355built by default.  Enabling this variant builds and installs the included
356documentation.
357.br
358.Sy Type:
359.Em optional
360.br
361.Sy Example:
362.Dl port install gnustep-gui +with_docs
363.br
364.El
365.Sh SEE ALSO
366.Xr port 1 ,
367.Xr macports.conf 5 ,
368.Xr portfile 7 ,
369.Xr portstyle 7 ,
370.Xr porthier 7
371.Sh AUTHORS
372.An "Paul Guyot" Aq pguyot@kallisys.net
373.An "Yves de Champlain" Aq yves@macports.org
Note: See TracBrowser for help on using the repository browser.