1 |
--- |
2 |
Makefile | 4 +--- |
3 |
appendices.tex | 12 ++++++++++-- |
4 |
ebuild-env-state.tex | 32 ++++++++++++++++++++++++++++++-- |
5 |
eclasses.tex | 6 +++--- |
6 |
env-saving.listing | 27 --------------------------- |
7 |
if-else-use.listing | 7 ------- |
8 |
pkg-mgr-commands.tex | 7 ++++--- |
9 |
7 files changed, 48 insertions(+), 47 deletions(-) |
10 |
delete mode 100644 env-saving.listing |
11 |
delete mode 100644 if-else-use.listing |
12 |
|
13 |
diff --git a/Makefile b/Makefile |
14 |
index a20f5ec..83a6f51 100644 |
15 |
--- a/Makefile |
16 |
+++ b/Makefile |
17 |
@@ -8,9 +8,7 @@ clean : |
18 |
maintainer-clean: clean |
19 |
rm -f vc.tex |
20 |
|
21 |
-LATEXFILES := $(filter-out vc.tex,$(wildcard *.tex)) pms.cls |
22 |
-LISTINGFILES := $(wildcard *.listing) |
23 |
-SOURCEFILES = $(LATEXFILES) $(LISTINGFILES) |
24 |
+SOURCEFILES := $(filter-out vc.tex,$(wildcard *.tex)) pms.cls |
25 |
|
26 |
pms.pdf: $(SOURCEFILES) pms.bbl vc.tex eapi-cheatsheet.pdf |
27 |
@# latex chokes on aux files produced by tex4ht, so remove them |
28 |
diff --git a/appendices.tex b/appendices.tex |
29 |
index eb51dc9..0e64bc5 100644 |
30 |
--- a/appendices.tex |
31 |
+++ b/appendices.tex |
32 |
@@ -39,8 +39,16 @@ was met, and the block after the colon would be taken if the condition was not m |
33 |
This feature was deprecated and removed from the tree long before the introduction of \t{EAPI}. |
34 |
|
35 |
\begin{listing} |
36 |
- \caption{If-else use blocks}\label{lst:if-else-use-listing} |
37 |
- \verbatiminput{if-else-use.listing} |
38 |
+\caption{If-else use blocks} \label{lst:if-else-use-listing} |
39 |
+\begin{verbatim} |
40 |
+DEPEND=" |
41 |
+ flag? ( |
42 |
+ taken/if-true |
43 |
+ ) : ( |
44 |
+ taken/if-false |
45 |
+ ) |
46 |
+ " |
47 |
+\end{verbatim} |
48 |
\end{listing} |
49 |
|
50 |
\section{cvs Versions} |
51 |
diff --git a/ebuild-env-state.tex b/ebuild-env-state.tex |
52 |
index 4bc80c7..3ddd1ab 100644 |
53 |
--- a/ebuild-env-state.tex |
54 |
+++ b/ebuild-env-state.tex |
55 |
@@ -20,8 +20,36 @@ in the build sequence. |
56 |
This is demonstrated by code listing~\ref{lst:env-saving}. |
57 |
|
58 |
\begin{listing} |
59 |
- \caption{Environment state between functions}\label{lst:env-saving} |
60 |
- \verbatiminput{env-saving.listing} |
61 |
+\caption{Environment state between functions} \label{lst:env-saving} |
62 |
+\begin{verbatim} |
63 |
+GLOBAL_VARIABLE="a" |
64 |
+ |
65 |
+src_compile() |
66 |
+{ |
67 |
+ GLOBAL_VARIABLE="b" |
68 |
+ DEFAULT_VARIABLE="c" |
69 |
+ export EXPORTED_VARIABLE="d" |
70 |
+ local LOCAL_VARIABLE="e" |
71 |
+} |
72 |
+ |
73 |
+src_install(){ |
74 |
+ [[ ${GLOBAL_VARIABLE} == "a" ]] \ |
75 |
+ || [[ ${GLOBAL_VARIABLE} == "b" ]] \ |
76 |
+ || die "broken env saving for globals" |
77 |
+ |
78 |
+ [[ ${DEFAULT_VARIABLE} == "c" ]] \ |
79 |
+ || die "broken env saving for default" |
80 |
+ |
81 |
+ [[ ${EXPORTED_VARIABLE} == "d" ]] \ |
82 |
+ || die "broken env saving for exported" |
83 |
+ |
84 |
+ [[ $(printenv EXPORTED_VARIABLE ) == "d" ]] \ |
85 |
+ || die "broken env saving for exported" |
86 |
+ |
87 |
+ [[ -z ${LOCAL_VARIABLE} ]] \ |
88 |
+ || die "broken env saving for locals" |
89 |
+} |
90 |
+\end{verbatim} |
91 |
\end{listing} |
92 |
|
93 |
% vim: set filetype=tex fileencoding=utf8 et tw=100 spell spelllang=en : |
94 |
diff --git a/eclasses.tex b/eclasses.tex |
95 |
index 24ff77f..0f172f7 100644 |
96 |
--- a/eclasses.tex |
97 |
+++ b/eclasses.tex |
98 |
@@ -49,8 +49,8 @@ call the eclass-defined version from it. The use of it is best illustrated by an |
99 |
given in listing~\ref{lst:export-functions} and is a snippet from a hypothetical \t{foo.eclass}. |
100 |
|
101 |
\begin{listing} |
102 |
- \caption{EXPORT\_FUNCTIONS example: foo.eclass}\label{lst:export-functions} |
103 |
- \begin{verbatim} |
104 |
+\caption{EXPORT\_FUNCTIONS example: foo.eclass} \label{lst:export-functions} |
105 |
+\begin{verbatim} |
106 |
foo_src_compile() |
107 |
{ |
108 |
econf --enable-gerbil \ |
109 |
@@ -60,7 +60,7 @@ foo_src_compile() |
110 |
} |
111 |
|
112 |
EXPORT_FUNCTIONS src_compile |
113 |
- \end{verbatim} |
114 |
+\end{verbatim} |
115 |
\end{listing} |
116 |
|
117 |
This example defines an eclass \t{src\_compile} function and uses \t{EXPORT\_FUNCTIONS} to alias |
118 |
diff --git a/env-saving.listing b/env-saving.listing |
119 |
deleted file mode 100644 |
120 |
index 1650aa7..0000000 |
121 |
--- a/env-saving.listing |
122 |
+++ /dev/null |
123 |
@@ -1,27 +0,0 @@ |
124 |
-GLOBAL_VARIABLE="a" |
125 |
- |
126 |
-src_compile() |
127 |
-{ |
128 |
- GLOBAL_VARIABLE="b" |
129 |
- DEFAULT_VARIABLE="c" |
130 |
- export EXPORTED_VARIABLE="d" |
131 |
- local LOCAL_VARIABLE="e" |
132 |
-} |
133 |
- |
134 |
-src_install(){ |
135 |
- [[ ${GLOBAL_VARIABLE} == "a" ]] \ |
136 |
- || [[ ${GLOBAL_VARIABLE} == "b" ]] \ |
137 |
- || die "broken env saving for globals" |
138 |
- |
139 |
- [[ ${DEFAULT_VARIABLE} == "c" ]] \ |
140 |
- || die "broken env saving for default" |
141 |
- |
142 |
- [[ ${EXPORTED_VARIABLE} == "d" ]] \ |
143 |
- || die "broken env saving for exported" |
144 |
- |
145 |
- [[ $(printenv EXPORTED_VARIABLE ) == "d" ]] \ |
146 |
- || die "broken env saving for exported" |
147 |
- |
148 |
- [[ -z ${LOCAL_VARIABLE} ]] \ |
149 |
- || die "broken env saving for locals" |
150 |
-} |
151 |
diff --git a/if-else-use.listing b/if-else-use.listing |
152 |
deleted file mode 100644 |
153 |
index 83a2ae8..0000000 |
154 |
--- a/if-else-use.listing |
155 |
+++ /dev/null |
156 |
@@ -1,7 +0,0 @@ |
157 |
-DEPEND=" |
158 |
- flag? ( |
159 |
- taken/if-true |
160 |
- ) : ( |
161 |
- taken/if-false |
162 |
- ) |
163 |
- " |
164 |
diff --git a/pkg-mgr-commands.tex b/pkg-mgr-commands.tex |
165 |
index 83fbd68..d7347fe 100644 |
166 |
--- a/pkg-mgr-commands.tex |
167 |
+++ b/pkg-mgr-commands.tex |
168 |
@@ -224,9 +224,10 @@ current phase function has returned. |
169 |
\t{D} instead of \t{ED} in the command given in Listing~\ref{lst:einstall}. |
170 |
Variable \t{libdir} is an auxiliary local variable whose value is determined by |
171 |
Algorithm~\ref{alg:ebuild-libdir}. |
172 |
+ |
173 |
\begin{listing}[H] |
174 |
- \caption{einstall command}\label{lst:einstall} |
175 |
- \begin{verbatim} |
176 |
+\caption{einstall command} \label{lst:einstall} |
177 |
+\begin{verbatim} |
178 |
emake \ |
179 |
prefix="${ED}"/usr \ |
180 |
datadir="${ED}"/usr/share \ |
181 |
@@ -238,7 +239,7 @@ emake \ |
182 |
-j1 \ |
183 |
"$@" \ |
184 |
install |
185 |
- \end{verbatim} |
186 |
+\end{verbatim} |
187 |
\end{listing} |
188 |
|
189 |
\end{description} |
190 |
-- |
191 |
2.6.2 |