summaryrefslogtreecommitdiff
blob: 7bab213bb28fa55b4bac7f9fa4ac27c0b9d98763 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
<section id='package-ebuild-eapi-3_pre2'>
<title>EAPI 3_pre2</title>
<section id='package-ebuild-eapi-3_pre2-helpers'>
<title>Helpers</title>
<section id='package-ebuild-eapi-3_pre2-helpers-unpack'>
<title>unpack</title>
<section id='package-ebuild-eapi-3_pre2-helpers-unpack-xz'>
<title>Support for the xz file extension</title>
<para>
The unpack helper now supports the xz file extension.
</para>
</section>
</section>
</section>
<section id='package-ebuild-eapi-3_pre2-prefix'>
<title>Support for installation prefix</title>
<section id='package-ebuild-eapi-3_pre2-prefix-helpers'>
<title>Helpers</title>
<para>
Beginning with EAPI 3, all helpers use ${ED} instead of ${D}
when appropriate. For example, see econf and einstall below.
</para>
<section id='package-ebuild-eapi-3_pre2-prefix-helpers-econf'>
<title>econf</title>
<programlisting>
${ECONF_SOURCE:-.}/configure \
        --prefix="${EPREFIX}"/usr \
        --host="${EPREFIX}${CHOST} \
        --mandir="${EPREFIX}"/usr/share/man \
        --infodir="${EPREFIX}"/usr/share/info \
        --datadir="${EPREFIX}"/usr/share \
        --sysconfdir="${EPREFIX}"/etc \
        --localstatedir="${EPREFIX}"/var/lib \
        ${EXTRA_ECONF} \
        configure options || die "econf failed"
</programlisting>
</section>
<section id='package-ebuild-eapi-3_pre2-prefix-helpers-einstall'>
<title>einstall</title>
<para>
Note that, for make-based packages, 'emake install DESTDIR=${D}' (with
DESTDIR=${D} rather than ${ED}) is still preferred over einstall.
</para>
<programlisting>
make \
        prefix=${ED}/usr \
        datadir=${ED}/usr/share \
        infodir=${ED}/usr/share/info \
        localstatedir=${ED}/var/lib \
        mandir=${ED}/usr/share/man \
        sysconfdir=${ED}/etc \
        ${EXTRA_EINSTALL} \
        make options \
        install
</programlisting>
</section>
</section>
<section id='package-ebuild-eapi-3_pre2-prefix-variables'>
<title>Variables</title>
<table><title>Installation Prefix Variables</title>
	<tgroup cols='2' align='left' >
	<colspec colname='name'/>
	<colspec colname='description'/>
	<thead>
	<row>
		<entry>Variable Name</entry>
		<entry>Description</entry>
	</row>
	</thead>
	<tbody>
	<row>
		<entry>ED</entry>
		<entry>Contains the path
		"${D%/}${EPREFIX}/" for convenience purposes.
		For EAPI values prior to EAPI 3 which do not
		support ${ED}, helpers use ${D} where they would
		otherwise use ${ED}. Do not modify this variable.
		</entry>
	</row>
	<row>
		<entry>EPREFIX</entry>
		<entry>Contains the offset
		that this Portage was configured for during
		installation. The offset is sometimes necessary
		in an ebuild or eclass, and is available in such
		cases as ${EPREFIX}. EPREFIX does not contain a
		trailing slash, therefore an absent offset is
		represented by the empty string. Do not modify
		this variable. </entry>
	</row>
	<row>
		<entry>EROOT</entry>
		<entry>Contains
		"${ROOT%/}${EPREFIX}/" for convenience purposes.
		Do not modify this variable. </entry>
	</row>
	</tbody>
	</tgroup>
</table>
</section>
</section>
</section>