]>
Commit | Line | Data |
---|---|---|
9c14e3d6 AL |
1 | // -*- mode: cpp; mode: fold -*- |
2 | // Description /*{{{*/ | |
b35d2f5f | 3 | // $Id: init.cc,v 1.4 1998/07/26 04:49:26 jgg Exp $ |
9c14e3d6 AL |
4 | /* ###################################################################### |
5 | ||
6 | Init - Initialize the package library | |
7 | ||
8 | ##################################################################### */ | |
9 | /*}}}*/ | |
10 | // Include files /*{{{*/ | |
094a497d | 11 | #include <apt-pkg/init.h> |
9c14e3d6 AL |
12 | /*}}}*/ |
13 | ||
8efa2a3b | 14 | // pkgInitialize - Initialize the configuration class /*{{{*/ |
9c14e3d6 AL |
15 | // --------------------------------------------------------------------- |
16 | /* Directories are specified in such a way that the FindDir function will | |
17 | understand them. That is, if they don't start with a / then their parent | |
18 | is prepended, this allows a fair degree of flexability. */ | |
8efa2a3b | 19 | bool pkgInitialize(Configuration &Cnf) |
9c14e3d6 AL |
20 | { |
21 | // General APT things | |
22 | Cnf.Set("APT::Architecture","i386"); | |
23 | ||
24 | // State | |
25 | Cnf.Set("Dir::State","/var/state/apt/"); | |
26 | Cnf.Set("Dir::State::lists","lists/"); | |
b35d2f5f AL |
27 | |
28 | /* These really should be jammed into a generic 'Local Database' engine | |
29 | which is yet to be determined. The functions in pkgcachegen should | |
30 | be the only users of these */ | |
9c14e3d6 | 31 | Cnf.Set("Dir::State::xstatus","xstatus"); |
b35d2f5f AL |
32 | Cnf.Set("Dir::State::userstatus","status.user"); |
33 | Cnf.Set("Dir::State::status","/var/lib/dpkg/status"); | |
9c14e3d6 AL |
34 | |
35 | // Cache | |
b35d2f5f | 36 | Cnf.Set("Dir::Cache","/tmp/"); |
9c14e3d6 AL |
37 | Cnf.Set("Dir::Cache::archives","archives/"); |
38 | Cnf.Set("Dir::Cache::srcpkgcache","srcpkgcache"); | |
b35d2f5f | 39 | Cnf.Set("Dir::Cache::pkgcache","pkgcache"); |
9c14e3d6 AL |
40 | |
41 | // Configuration | |
42 | Cnf.Set("Dir::Etc","/etc/apt/"); | |
43 | Cnf.Set("Dir::Etc::sourcelist","sources.list"); | |
44 | Cnf.Set("Dir::Etc::main","apt.conf"); | |
45 | ||
46 | return true; | |
47 | } | |
48 | /*}}}*/ |