File: dbp.getstart.html

package info (click to toggle)
darcs-buildpackage 0.5.12.2
  • links: PTS
  • area: main
  • in suites: squeeze
  • size: 716 kB
  • ctags: 2
  • sloc: haskell: 452; sh: 62; makefile: 56
file content (343 lines) | stat: -rw-r--r-- 6,735 bytes parent folder | download | duplicates (2)
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
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN""http://www.w3.org/TR/html4/loose.dtd">
<HTML
><HEAD
><TITLE
>Getting Started</TITLE
><META
NAME="GENERATOR"
CONTENT="Modular DocBook HTML Stylesheet Version 1.79"><LINK
REL="HOME"
TITLE="Building Debian Packages with darcs-buildpackage"
HREF="dbp.html"><LINK
REL="PREVIOUS"
TITLE="Introduction"
HREF="dbp.intro.html"><LINK
REL="NEXT"
TITLE="Importing Packages"
HREF="dbp.import.html"><STYLE
TYPE="text/css"
>.synopsis, .classsynopsis {
    background: #eeeeee;
    border: solid 1px #aaaaaa;
    padding: 0.5em;
}
.programlisting {
    background: #eeeeff;
    border: solid 1px #aaaaff;
    padding: 0.5em;
}
.variablelist {
    padding: 4px;
    margin-left: 3em;
}
.navigation {
    background: #ffeeee;
    border: solid 1px #ffaaaa;
    margin-top: 0.5em;
    margin-bottom: 0.5em;
}
.navigation a {
    color: #770000;
}
.navigation a:visited {
    color: #550000;
}
.navigation .title {
    font-size: 200%;
}</STYLE
></HEAD
><BODY
CLASS="CHAPTER"
BGCOLOR="#FFFFFF"
TEXT="#000000"
LINK="#0000FF"
VLINK="#840084"
ALINK="#0000FF"
><TABLE
WIDTH="100%"
CLASS="navigation"
SUMMARY="Navigation header"
CELLPADDING="2"
CELLSPACING="2"
><TR
VALIGN="middle"
><TD
><A
ACCESSKEY="p"
HREF="dbp.intro.html"
><IMG
SRC="left.png"
WIDTH="24"
HEIGHT="24"
BORDER="0"
ALT="Prev"></A
></TD
><TD
><A
ACCESSKEY="h"
HREF="dbp.html"
><IMG
SRC="home.png"
WIDTH="24"
HEIGHT="24"
BORDER="0"
ALT="Home"></A
></TD
><TH
WIDTH="100%"
align="center"
>Building Debian Packages with darcs-buildpackage</TH
><TD
><A
ACCESSKEY="n"
HREF="dbp.import.html"
><IMG
SRC="right.png"
WIDTH="24"
HEIGHT="24"
BORDER="0"
ALT="Next"></A
></TD
></TR
></TABLE
><DIV
CLASS="CHAPTER"
><H1
><A
NAME="DBP.GETSTART"
></A
>Getting Started</H1
><DIV
CLASS="TOC"
><DL
><DT
><B
>Table of Contents</B
></DT
><DT
><A
HREF="dbp.getstart.html#DBP.LAYOUT"
>The <SPAN
CLASS="APPLICATION"
>darcs-buildpackage</SPAN
> Repository Layout</A
></DT
><DT
><A
HREF="dbp.getstart.html#DBP.CONFIGFILE"
>The Configuration File</A
></DT
></DL
></DIV
><P
>      Getting started with <SPAN
CLASS="APPLICATION"
>darcs-buildpackage</SPAN
> is pretty simple.  This chapter shows
      you how.
    </P
><BR
CLEAR="all"><DIV
CLASS="SECT1"
><H1
CLASS="SECT1"
><A
NAME="DBP.LAYOUT"
>The <SPAN
CLASS="APPLICATION"
>darcs-buildpackage</SPAN
> Repository Layout</A
></H1
><P
>        <SPAN
CLASS="APPLICATION"
>darcs-buildpackage</SPAN
> assumes that you have two "canonical" repositories for
        every Debian package.  These repositories correspond to the
        upstream and the Debian versions of the package's source.  The
        upstream repository tracks unmodified upstream versions.  The
        Debian repository pulls in upstream patches, and also has the
        Debian-specific patches for your package.  (Debian-native
        packages have no upstream version and thus no upstream repository.)
      </P
><P
>        Normally, you would not work directly in the canonical
        repository storage area.  Rather, you would use <B
CLASS="COMMAND"
>darcs
        get</B
> or dbp-get to make a copy of the sources, and
        <B
CLASS="COMMAND"
>darcs push</B
> to push changes back to your
        storage area when done.
      </P
><P
>        The canonical repository need not be on your local machine.
        It could be any repository area that Darcs has access to.
      </P
><BR
CLEAR="all"><DIV
CLASS="SECT2"
><H2
CLASS="SECT2"
><A
NAME="AEN91"
>Upstream Repository</A
></H2
><P
>          The upstream repository tracks changes to the upstream
          program.  You can use dbp-importorig or dbp-importdsc to
          import upstream sources from tarballs, or you can use Darcs
          to track a Darcs-based upstream with <B
CLASS="COMMAND"
>darcs
          get</B
> and <B
CLASS="COMMAND"
>darcs pull</B
>.
        </P
><P
>          Each upstream version should be tagged with
          a tag nammed
          <SPAN
CLASS="PROPERTY"
>UPSTREAM_<TT
CLASS="REPLACEABLE"
><I
>packagename</I
></TT
>_<TT
CLASS="REPLACEABLE"
><I
>version</I
></TT
></SPAN
>.
          Note that the Debian revision doesn't appear in this tag.
          An example would be
          <SPAN
CLASS="PROPERTY"
>UPSTREAM_mypackage_1.0.5</SPAN
>.
          If you use dbp-importorig or dbp-importdsc, this tag will be
          created for you automatically.  If you manage your upstream
          repository manually, you should create the tag yourself
          using <B
CLASS="COMMAND"
>darcs tag</B
>
        </P
></DIV
><BR
CLEAR="all"><DIV
CLASS="SECT2"
><H2
CLASS="SECT2"
><A
NAME="AEN102"
>Debian Repository</A
></H2
><P
>          The Debian repository tracks the Debian-specific package.
          The Debian package is represented as the upstream source
          plus a set of Debian patches.  Upstream patches are normally
          pulled into the Debian repository before beginning on the
          Debian package.
        </P
><P
>          Each Debian version carries a tag similar to the upstream
          version, but the Debian version tags begin with
          <SPAN
CLASS="PROPERTY"
>DEBIAN_</SPAN
> and contain a full Debian revision.  
          An example is <SPAN
CLASS="PROPERTY"
>DEBIAN_mypackage_1.0.5-3</SPAN
>.
        </P
></DIV
></DIV
><BR
CLEAR="all"><DIV
CLASS="SECT1"
><H1
CLASS="SECT1"
><A
NAME="DBP.CONFIGFILE"
>The Configuration File</A
></H1
><P
>        The first thing you must do is create your <SPAN
CLASS="APPLICATION"
>darcs-buildpackage</SPAN
> configuration
        file.  It is called <TT
CLASS="FILENAME"
>.darcs-buildpackage</TT
>
        and stored in your home directory.  The main purpose of the
        configuration file is to specify the location and naming of
        your repositories.
      </P
><P
>        There are two items required in the configuration file:
        <SPAN
CLASS="PROPERTY"
>upstreamrepo</SPAN
> and
        <SPAN
CLASS="PROPERTY"
>debianrepo</SPAN
>.  The special token
        <TT
CLASS="FILENAME"
>%(package)s</TT
> represents the name of a
        specific package.  Thus, a sample file could look like this:
      </P
><PRE
CLASS="SCREEN"
>upstreamrepo = /home/jgoerzen/debdarcs/%(package)s.upstream
debianrepo = /home/jgoerzen/debdarcs/%(package)s
      </PRE
><P
>        More sophisticated configurations are possible.  (FIXME: write
        about them)
      </P
></DIV
></DIV
><TABLE
CLASS="navigation"
WIDTH="100%"
SUMMARY="Navigation footer"
CELLPADDING="2"
CELLSPACING="2"
><TR
VALIGN="middle"
><TD
ALIGN="left"
><A
ACCESSKEY="p"
HREF="dbp.intro.html"
><B
>&lt;&lt;&lt;&nbsp;Introduction</B
></A
></TD
><TD
ALIGN="right"
><A
ACCESSKEY="n"
HREF="dbp.import.html"
><B
>Importing Packages&nbsp;&gt;&gt;&gt;</B
></A
></TD
></TR
></TABLE
></BODY
></HTML
>