diff options
author | Tudor Florea <tudor.florea@enea.com> | 2015-10-09 22:59:03 +0200 |
---|---|---|
committer | Tudor Florea <tudor.florea@enea.com> | 2015-10-09 22:59:03 +0200 |
commit | 972dcfcdbfe75dcfeb777150c136576cf1a71e99 (patch) | |
tree | 97a61cd7e293d7ae9d56ef7ed0f81253365bb026 /meta/recipes-devtools/apt/apt-native.inc | |
download | poky-972dcfcdbfe75dcfeb777150c136576cf1a71e99.tar.gz |
initial commit for Enea Linux 5.0 arm
Signed-off-by: Tudor Florea <tudor.florea@enea.com>
Diffstat (limited to 'meta/recipes-devtools/apt/apt-native.inc')
-rw-r--r-- | meta/recipes-devtools/apt/apt-native.inc | 68 |
1 files changed, 68 insertions, 0 deletions
diff --git a/meta/recipes-devtools/apt/apt-native.inc b/meta/recipes-devtools/apt/apt-native.inc new file mode 100644 index 0000000000..fede8694c4 --- /dev/null +++ b/meta/recipes-devtools/apt/apt-native.inc | |||
@@ -0,0 +1,68 @@ | |||
1 | require apt.inc | ||
2 | inherit native | ||
3 | |||
4 | DEPENDS += "dpkg-native gettext-native db-native curl-native" | ||
5 | PACKAGES = "" | ||
6 | USE_NLS = "yes" | ||
7 | |||
8 | SRC_URI += "file://db_linking_hack.patch" | ||
9 | |||
10 | python do_install () { | ||
11 | bb.build.exec_func('do_install_base', d) | ||
12 | bb.build.exec_func('do_install_config', d) | ||
13 | } | ||
14 | |||
15 | python do_install_config () { | ||
16 | indir = os.path.dirname(d.getVar('FILE',1)) | ||
17 | infile = file(oe.path.join(indir, 'files', 'apt.conf'), 'r') | ||
18 | data = infile.read() | ||
19 | infile.close() | ||
20 | |||
21 | data = d.expand(data) | ||
22 | |||
23 | outdir = oe.path.join(d.getVar('D', True), d.getVar('sysconfdir', True), 'apt') | ||
24 | if not os.path.exists(outdir): | ||
25 | os.makedirs(outdir) | ||
26 | |||
27 | outpath = oe.path.join(outdir, 'apt.conf.sample') | ||
28 | if not os.path.exists(outpath): | ||
29 | outfile = file(outpath, 'w') | ||
30 | outfile.write(data) | ||
31 | outfile.close() | ||
32 | } | ||
33 | |||
34 | do_install_base () { | ||
35 | install -d ${D}${bindir} | ||
36 | install -m 0755 bin/apt-cdrom ${D}${bindir}/ | ||
37 | install -m 0755 bin/apt-get ${D}${bindir}/ | ||
38 | install -m 0755 bin/apt-config ${D}${bindir}/ | ||
39 | install -m 0755 bin/apt-cache ${D}${bindir}/ | ||
40 | install -m 0755 bin/apt-sortpkgs ${D}${bindir}/ | ||
41 | install -m 0755 bin/apt-extracttemplates ${D}${bindir}/ | ||
42 | install -m 0755 bin/apt-ftparchive ${D}${bindir}/ | ||
43 | |||
44 | eval `cat environment.mak | grep ^GLIBC_VER | sed -e's, = ,=,'` | ||
45 | eval `cat environment.mak | grep ^LIBSTDCPP_VER | sed -e's, = ,=,'` | ||
46 | oe_libinstall -so -C bin libapt-pkg$GLIBC_VER$LIBSTDCPP_VER ${D}${libdir}/ | ||
47 | ln -sf libapt-pkg$GLIBC_VER$LIBSTDCPP_VER.so ${D}${libdir}/libapt-pkg.so | ||
48 | oe_libinstall -so -C bin libapt-inst$GLIBC_VER$LIBSTDCPP_VER ${D}${libdir}/ | ||
49 | ln -sf libapt-inst$GLIBC_VER$LIBSTDCPP_VER.so ${D}${libdir}/libapt-inst.so | ||
50 | |||
51 | install -d ${D}${libdir}/apt/methods | ||
52 | install -m 0755 bin/methods/* ${D}${libdir}/apt/methods/ | ||
53 | |||
54 | install -d ${D}${libdir}/dpkg/methods/apt | ||
55 | install -m 0644 ${S}/dselect/desc.apt ${D}${libdir}/dpkg/methods/apt/ | ||
56 | install -m 0644 ${S}/dselect/names ${D}${libdir}/dpkg/methods/apt/ | ||
57 | install -m 0755 ${S}/dselect/install ${D}${libdir}/dpkg/methods/apt/ | ||
58 | install -m 0755 ${S}/dselect/setup ${D}${libdir}/dpkg/methods/apt/ | ||
59 | install -m 0755 ${S}/dselect/update ${D}${libdir}/dpkg/methods/apt/ | ||
60 | |||
61 | install -d ${D}${sysconfdir}/apt | ||
62 | install -d ${D}${sysconfdir}/apt/apt.conf.d | ||
63 | install -d ${D}${sysconfdir}/apt/preferences.d | ||
64 | install -d ${D}${localstatedir}/lib/apt/lists/partial | ||
65 | install -d ${D}${localstatedir}/cache/apt/archives/partial | ||
66 | |||
67 | install -d ${D}${localstatedir}/log/apt/ | ||
68 | } | ||