vdr: fix dependency for libintl
[openembedded.git] / recipes / apt / apt-native.inc
blob4e4771a9cdc8e4f62429997e417d7e4fc787c39c
1 require apt.inc
2 inherit native
4 DEPENDS = "perl-native dpkg-native gettext-native"
5 FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/apt-${PV}"
6 PACKAGES = ""
7 USE_NLS = "yes"
9 SRC_URI += "file://db_linking_hack.patch;patch=1"
11 python do_stage () {
12         bb.build.exec_func('do_stage_base', d)
13         bb.build.exec_func('do_stage_config', d)
16 python do_stage_config () {
17         indir = os.path.dirname(bb.data.getVar('FILE',d,1))
18         infile = file(os.path.join(indir, 'files', 'apt.conf'), 'r')
19         data = infile.read()
20         infile.close()
22         data = bb.data.expand(data, d)
24         outdir = os.path.join(bb.data.getVar('sysconfdir', d, 1), 'apt')
25         if not os.path.exists(outdir):
26                 os.makedirs(outdir)
27         outpath = os.path.join(outdir, 'apt.conf.sample')
29         outfile = file(outpath, 'w')
30         outfile.write(data)
31         outfile.close()
34 do_stage_base () {
35         install -d ${bindir}
36         install -m 0755 bin/apt-cdrom ${bindir}/
37         install -m 0755 bin/apt-get ${bindir}/
38         install -m 0755 bin/apt-config ${bindir}/
39         install -m 0755 bin/apt-cache ${bindir}/
40         install -m 0755 bin/apt-sortpkgs ${bindir}/
41         install -m 0755 bin/apt-extracttemplates ${bindir}/
43         eval `cat environment.mak | grep ^GLIBC_VER | sed -e's, = ,=,'`
44         oe_libinstall -so -C bin libapt-pkg$GLIBC_VER-6 ${libdir}/
45         ln -sf libapt-pkg$GLIBC_VER-6.so ${libdir}/libapt-pkg.so
46         oe_libinstall -so -C bin libapt-inst$GLIBC_VER-6 ${libdir}/
47         ln -sf libapt-inst$GLIBC_VER-6.so ${libdir}/libapt-inst.so
49         install -d ${libdir}/apt/methods
50         install -m 0755 bin/methods/* ${libdir}/apt/methods/
52         install -d ${libdir}/dpkg/methods/apt
53         install -m 0644 dselect/desc.apt ${libdir}/dpkg/methods/apt/ 
54         install -m 0644 dselect/names ${libdir}/dpkg/methods/apt/ 
55         install -m 0755 dselect/install ${libdir}/dpkg/methods/apt/ 
56         install -m 0755 dselect/setup ${libdir}/dpkg/methods/apt/ 
57         install -m 0755 dselect/update ${libdir}/dpkg/methods/apt/ 
59         install -d ${sysconfdir}/apt
60         install -d ${localstatedir}/lib/apt/lists/partial
61         install -d ${localstatedir}/cache/apt/archives/partial
63         install -d ${localstatedir}/log/apt/