summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/opkg/opkg_svn.bb
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-devtools/opkg/opkg_svn.bb')
-rw-r--r--meta/recipes-devtools/opkg/opkg_svn.bb57
1 files changed, 57 insertions, 0 deletions
diff --git a/meta/recipes-devtools/opkg/opkg_svn.bb b/meta/recipes-devtools/opkg/opkg_svn.bb
new file mode 100644
index 0000000000..518c767354
--- /dev/null
+++ b/meta/recipes-devtools/opkg/opkg_svn.bb
@@ -0,0 +1,57 @@
1require opkg.inc
2
3PROVIDES += "virtual/update-alternatives"
4RPROVIDES_update-alternatives-cworth += "update-alternatives"
5RCONFLICTS_update-alternatives-cworth = "update-alternatives-dpkg"
6RDEPENDS_${PN} = "${VIRTUAL-RUNTIME_update-alternatives} opkg-config-base"
7RDEPENDS_${PN}_virtclass-native = ""
8RDEPENDS_${PN}_virtclass-nativesdk = ""
9PACKAGE_ARCH_update-alternatives-cworth = "all"
10
11SRC_URI = "svn://opkg.googlecode.com/svn;module=trunk;proto=http \
12 file://opkg_unarchive.patch \
13 file://add_vercmp.patch \
14 file://headerfix.patch \
15 file://logfix.patch"
16
17S = "${WORKDIR}/trunk"
18
19PV = "0.0+svnr${SRCREV}"
20PR = "r15"
21
22PACKAGES =+ "libopkg-dev libopkg update-alternatives-cworth"
23
24FILES_update-alternatives-cworth = "${bindir}/update-alternatives"
25FILES_libopkg-dev = "${libdir}/*.a ${libdir}/*.la ${libdir}/*.so"
26FILES_libopkg = "${libdir}/*.so.* ${localstatedir}/lib/opkg/"
27
28# We need to create the lock directory
29do_install_append() {
30 install -d ${D}${localstatedir}/lib/opkg
31}
32
33# Define a variable to allow distros to run configure earlier.
34# (for example, to enable loading of ethernet kernel modules before networking starts)
35OPKG_INIT_POSITION = "98"
36OPKG_INIT_POSITION_slugos = "41"
37
38pkg_postinst_${PN} () {
39#!/bin/sh
40if [ "x$D" != "x" ]; then
41 install -d ${IMAGE_ROOTFS}/${sysconfdir}/rcS.d
42 # this happens at S98 where our good 'ole packages script used to run
43 echo "#!/bin/sh
44opkg-cl configure
45rm -f /${sysconfdir}/rcS.d/S${OPKG_INIT_POSITION}configure
46" > $D${sysconfdir}/rcS.d/S${OPKG_INIT_POSITION}configure
47 chmod 0755 $D${sysconfdir}/rcS.d/S${OPKG_INIT_POSITION}configure
48fi
49
50update-alternatives --install ${bindir}/opkg opkg ${bindir}/opkg-cl 100
51}
52
53pkg_postrm_${PN} () {
54#!/bin/sh
55update-alternatives --remove opkg ${bindir}/opkg-cl
56}
57