summaryrefslogtreecommitdiffstats
path: root/meta/classes/externalsrc.bbclass
blob: 7e00ef8d127316a3b86ee44b663f620e438f60d5 (plain)
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
# Copyright (C) 2012 Linux Foundation
# Author: Richard Purdie
# Some code and influence taken from srctree.bbclass:
# Copyright (C) 2009 Chris Larson <clarson@kergoth.com>
# Released under the MIT license (see COPYING.MIT for the terms)
#
# externalsrc.bbclass enables use of an existing source tree, usually external to 
# the build system to build a piece of software rather than the usual fetch/unpack/patch
# process.
#
# To use, set S to point at the directory you want to use containing the sources
# e.g. S = "/path/to/my/source/tree"
#
# If the class is to work for both target and native versions (or with multilibs/
# cross or other BBCLASSEXTEND variants), its expected that setting B to point to 
# where to place the compiled binaries will work (split source and build directories).
# This is the default but B can be set to S if circumstaces dictate.
#

SRC_URI = ""
SRCTREECOVEREDTASKS ?= "do_patch do_unpack do_fetch"
B = "${WORKDIR}/${BPN}-${PV}/"

def remove_tasks(tasks, deltasks, d):
    for task in tasks:
        deps = d.getVarFlag(task, "deps")
        for preptask in deltasks:
            if preptask in deps:
                deps.remove(preptask)
        d.setVarFlag(task, "deps", deps)
    # Poking around bitbake internal variables is evil but there appears to be no better way :(
    tasklist = d.getVar('__BBTASKS') or []
    for task in deltasks:
        d.delVarFlag(task, "task")
        if task in tasklist:
            tasklist.remove(task)
    d.setVar('__BBTASKS', tasklist)

python () {
    tasks = filter(lambda k: d.getVarFlag(k, "task"), d.keys())
    covered = d.getVar("SRCTREECOVEREDTASKS", True).split()

    for task in tasks:
        if task.endswith("_setscene"):
            # sstate is never going to work for external source trees, disable it
            covered.append(task)
        else:
            # Since configure will likely touch ${S}, ensure only we lock so one task has access at a time
            d.appendVarFlag(task, "lockfiles", "${S}/singletask.lock")

    remove_tasks(tasks, covered, d)
}
path: root/meta-oe/recipes-connectivity/wvdial/wvstreams_4.6.1.bb
blob: 90d64a8bbfa869b7279127f822024a6d768274fb (plain)
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
HOMEPAGE = "http://alumnit.ca/wiki/index.php?page=WvStreams"
SUMMARY = "WvStreams is a network programming library in C++"

LICENSE = "LGPLv2"
LIC_FILES_CHKSUM = "file://LICENSE;md5=55ca817ccb7d5b5b66355690e9abc605"

DEPENDS = "zlib openssl (>= 0.9.8)"

SRC_URI = "http://${PN}.googlecode.com/files/${PN}-${PV}.tar.gz \
           file://04_signed_request.diff \
           file://05_gcc.diff \
           file://06_gcc-4.7.diff \
           file://07_buildflags.diff \
          "

SRC_URI[md5sum] = "2760dac31a43d452a19a3147bfde571c"
SRC_URI[sha256sum] = "8403f5fbf83aa9ac0c6ce15d97fd85607488152aa84e007b7d0621b8ebc07633"

inherit autotools pkgconfig

PARALLEL_MAKE = ""

LDFLAGS_append = " -Wl,-rpath-link,${CROSS_DIR}/${TARGET_SYS}/lib"

EXTRA_OECONF = " --without-tcl --without-qt --without-pam --without-valgrind"

PACKAGES_prepend = "libuniconf libuniconf-dbg "
PACKAGES_prepend = "uniconfd uniconfd-dbg "
PACKAGES_prepend = "libwvstreams-base libwvstreams-base-dbg "
PACKAGES_prepend = "libwvstreams-extras libwvstreams-extras-dbg "

FILES_libuniconf     = "${libdir}/libuniconf.so.*"
FILES_libuniconf-dbg = "${libdir}/.debug/libuniconf.so.*"

FILES_uniconfd     = "${sbindir}/uniconfd ${sysconfdir}/uniconf.conf ${localstatedir}/uniconf"
FILES_uniconfd-dbg = "${sbindir}/.debug/uniconfd"

FILES_libwvstreams-base     = "${libdir}/libwvutils.so.*"
FILES_libwvstreams-base-dbg = "${libdir}/.debug/libwvutils.so.*"

FILES_libwvstreams-extras     = "${libdir}/libwvbase.so.* ${libdir}/libwvstreams.so.*"
FILES_libwvstreams-extras-dbg = "${libdir}/.debug/libwvbase.so.* ${libdir}/.debug/libwvstreams.so.*"