summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcin Juszkiewicz <hrw@openembedded.org>2007-09-04 10:00:44 +0000
committerMarcin Juszkiewicz <hrw@openembedded.org>2007-09-04 10:00:44 +0000
commit617dadee6dbd649099783a4224f706b3d5fe657c (patch)
tree039e93e5b59fb5bf508d0d7654e97501cafc58e6
parent188444b135f86d16839d2852e7bff5228dd1d773 (diff)
parent093291a6d79b3e6228981b6a9dbc8cc31af01573 (diff)
merge of '0e25c8665bca3c8d9e7c99e4432c9ce60811994c'
and '72c178b1440b044fcf6acdbb1cd21921f80d5b9b'
-rw-r--r--classes/base.bbclass18
-rw-r--r--classes/debian.bbclass5
-rw-r--r--classes/multimachine.bbclass4
-rw-r--r--classes/package.bbclass55
-rw-r--r--classes/package_deb.bbclass5
-rw-r--r--classes/package_ipk.bbclass5
-rw-r--r--classes/package_rpm.bbclass3
-rw-r--r--classes/package_tar.bbclass5
-rw-r--r--classes/rm_work.bbclass4
-rw-r--r--classes/rootfs_deb.bbclass2
-rw-r--r--classes/rootfs_ipk.bbclass2
-rw-r--r--conf/bitbake.conf2
-rw-r--r--packages/madwifi/madwifi-ng_r2702-20070903.bb14
13 files changed, 55 insertions, 69 deletions
diff --git a/classes/base.bbclass b/classes/base.bbclass
index 1a3739f383..9bcf212e95 100644
--- a/classes/base.bbclass
+++ b/classes/base.bbclass
@@ -374,6 +374,12 @@ oe_machinstall() {
fi
}
+# Remove and re-create ${D} so that is it guaranteed to be empty
+do_install_prepend() {
+ rm -rf ${D}
+ mkdir -p ${D}
+}
+
addtask listtasks
do_listtasks[nostamp] = "1"
python do_listtasks() {
@@ -576,10 +582,6 @@ python base_do_unpack() {
local = bb.data.expand(bb.fetch.localpath(url, localdata), localdata)
except bb.MalformedUrl, e:
raise FuncFailed('Unable to generate local path for malformed uri: %s' % e)
- # dont need any parameters for extraction, strip them off
- # RP: Insane. localpath shouldn't have parameters
- # RP: Scehdule for removal with bitbake 1.8.8
- local = re.sub(';.*$', '', local)
local = os.path.realpath(local)
ret = oe_unpack_file(local, localdata, url)
if not ret:
@@ -871,14 +873,6 @@ python () {
base_after_parse(d)
}
-# Remove me when we switch to bitbake 1.8.8
-def base_get_srcrev(d):
- import bb
-
- if hasattr(bb.fetch, "get_srcrev"):
- return bb.fetch.get_srcrev(d)
- return "NOT IMPLEMENTED"
-
# Patch handling
inherit patch
diff --git a/classes/debian.bbclass b/classes/debian.bbclass
index 403c38c752..a38f10d629 100644
--- a/classes/debian.bbclass
+++ b/classes/debian.bbclass
@@ -7,7 +7,10 @@ STAGING_PKGMAPS_DIR = "${STAGING_DIR}/pkgmaps/debian"
#
# Better expressed as ensure all RDEPENDS package before we package
# This means we can't have circular RDEPENDS/RRECOMMENDS
-do_package_write[rdeptask] = "do_package"
+do_package_write_ipk[rdeptask] = "do_package"
+do_package_write_deb[rdeptask] = "do_package"
+do_package_write_tar[rdeptask] = "do_package"
+do_package_write_rpm[rdeptask] = "do_package"
python debian_package_name_hook () {
import glob, copy, stat, errno, re
diff --git a/classes/multimachine.bbclass b/classes/multimachine.bbclass
index 0286a29515..945d22bfe0 100644
--- a/classes/multimachine.bbclass
+++ b/classes/multimachine.bbclass
@@ -1,9 +1,7 @@
STAMP = "${TMPDIR}/stamps/${MULTIMACH_ARCH}${TARGET_VENDOR}-${TARGET_OS}/${PF}"
WORKDIR = "${TMPDIR}/work/${MULTIMACH_ARCH}${TARGET_VENDOR}-${TARGET_OS}/${PF}"
STAGING_KERNEL_DIR = "${STAGING_DIR}/${MULTIMACH_ARCH}${TARGET_VENDOR}-${TARGET_OS}/kernel"
-# Enable me to fix pkgdata problems with multimachine
-# Requires all install tasks to rerun (wipe all install stamps from tmp/stamps/
-#PKGDATA_DIR = "${STAGING_DIR}/pkgdata/${MULTIMACH_ARCH}${TARGET_VENDOR}-${TARGET_OS}"
+PKGDATA_DIR = "${STAGING_DIR}/pkgdata/${MULTIMACH_ARCH}${TARGET_VENDOR}-${TARGET_OS}"
# Find any machine specific sub packages and if present, mark the
# whole package as machine specific for multimachine purposes.
diff --git a/classes/package.bbclass b/classes/package.bbclass
index fe48ec6afd..5233fa363c 100644
--- a/classes/package.bbclass
+++ b/classes/package.bbclass
@@ -2,6 +2,8 @@
# General packaging help functions
#
+PKGDEST = "${WORKDIR}/install"
+
def legitimize_package_name(s):
"""
Make sure package names are legitimate strings
@@ -120,18 +122,12 @@ PACKAGE_DEPENDS += "file-native"
python () {
import bb
-
if bb.data.getVar('PACKAGES', d, True) != '':
deps = bb.data.getVarFlag('do_package', 'depends', d) or ""
for dep in (bb.data.getVar('PACKAGE_DEPENDS', d, True) or "").split():
deps += " %s:do_populate_staging" % dep
bb.data.setVarFlag('do_package', 'depends', deps, d)
- deps = bb.data.getVarFlag('do_package_write', 'depends', d) or ""
- for dep in (bb.data.getVar('PACKAGE_EXTRA_DEPENDS', d, True) or "").split():
- deps += " %s:do_populate_staging" % dep
- bb.data.setVarFlag('do_package_write', 'depends', deps, d)
-
# shlibs requires any DEPENDS to have already packaged for the *.list files
bb.data.setVarFlag('do_package', 'deptask', 'do_package', d)
}
@@ -380,25 +376,21 @@ python populate_packages () {
if not os.path.islink(file) and not os.path.isdir(file) and isexec(file):
runstrip(file, d)
+ pkgdest = bb.data.getVar('PKGDEST', d, 1)
+ os.system('rm -rf %s' % pkgdest)
+
for pkg in package_list:
localdata = bb.data.createCopy(d)
- root = os.path.join(workdir, "install", pkg)
-
- os.system('rm -rf %s' % root)
+ root = os.path.join(pkgdest, pkg)
+ bb.mkdirhier(root)
- bb.data.setVar('ROOT', '', localdata)
- bb.data.setVar('ROOT_%s' % pkg, root, localdata)
bb.data.setVar('PKG', pkg, localdata)
-
overrides = bb.data.getVar('OVERRIDES', localdata, 1)
if not overrides:
raise bb.build.FuncFailed('OVERRIDES not defined')
- bb.data.setVar('OVERRIDES', overrides+':'+pkg, localdata)
-
+ bb.data.setVar('OVERRIDES', overrides + ':' + pkg, localdata)
bb.data.update_data(localdata)
- root = bb.data.getVar('ROOT', localdata, 1)
- bb.mkdirhier(root)
filesvar = bb.data.getVar('FILES', localdata, 1) or ""
files = filesvar.split()
for file in files:
@@ -451,7 +443,7 @@ python populate_packages () {
for pkg in package_list:
dangling_links[pkg] = []
pkg_files[pkg] = []
- inst_root = os.path.join(workdir, "install", pkg)
+ inst_root = os.path.join(pkgdest, pkg)
for root, dirs, files in os.walk(inst_root):
for f in files:
path = os.path.join(root, f)
@@ -572,6 +564,8 @@ python package_do_shlibs() {
bb.error("TARGET_SYS not defined")
return
+ pkgdest = bb.data.getVar('PKGDEST', d, 1)
+
shlibs_dir = os.path.join(staging, target_sys, "shlibs")
old_shlibs_dir = os.path.join(staging, "shlibs")
bb.mkdirhier(shlibs_dir)
@@ -584,7 +578,7 @@ python package_do_shlibs() {
needed[pkg] = []
sonames = list()
- top = os.path.join(workdir, "install", pkg)
+ top = os.path.join(pkgdest, pkg)
for root, dirs, files in os.walk(top):
for file in files:
soname = None
@@ -670,7 +664,7 @@ python package_do_shlibs() {
else:
bb.note("Couldn't find shared library provider for %s" % n)
- deps_file = os.path.join(workdir, "install", pkg + ".shlibdeps")
+ deps_file = os.path.join(pkgdest, pkg + ".shlibdeps")
if os.path.exists(deps_file):
os.remove(deps_file)
if len(deps):
@@ -703,6 +697,8 @@ python package_do_pkgconfig () {
bb.error("TARGET_SYS not defined")
return
+ pkgdest = bb.data.getVar('PKGDEST', d, 1)
+
shlibs_dir = os.path.join(staging, target_sys, "shlibs")
old_shlibs_dir = os.path.join(staging, "shlibs")
bb.mkdirhier(shlibs_dir)
@@ -716,7 +712,7 @@ python package_do_pkgconfig () {
for pkg in packages.split():
pkgconfig_provided[pkg] = []
pkgconfig_needed[pkg] = []
- top = os.path.join(workdir, "install", pkg)
+ top = os.path.join(pkgdest, pkg)
for root, dirs, files in os.walk(top):
for file in files:
m = pc_re.match(file)
@@ -779,7 +775,7 @@ python package_do_pkgconfig () {
found = True
if found == False:
bb.note("couldn't find pkgconfig module '%s' in any package" % n)
- deps_file = os.path.join(workdir, "install", pkg + ".pcdeps")
+ deps_file = os.path.join(pkgdest, pkg + ".pcdeps")
if os.path.exists(deps_file):
os.remove(deps_file)
if len(deps):
@@ -793,14 +789,14 @@ python read_shlibdeps () {
packages = (bb.data.getVar('PACKAGES', d, 1) or "").split()
for pkg in packages:
rdepends = explode_deps(bb.data.getVar('RDEPENDS_' + pkg, d, 0) or bb.data.getVar('RDEPENDS', d, 0) or "")
- shlibsfile = bb.data.expand("${WORKDIR}/install/" + pkg + ".shlibdeps", d)
+ shlibsfile = bb.data.expand("${PKGDEST}/" + pkg + ".shlibdeps", d)
if os.access(shlibsfile, os.R_OK):
fd = file(shlibsfile)
lines = fd.readlines()
fd.close()
for l in lines:
rdepends.append(l.rstrip())
- pcfile = bb.data.expand("${WORKDIR}/install/" + pkg + ".pcdeps", d)
+ pcfile = bb.data.expand("${PKGDEST}/" + pkg + ".pcdeps", d)
if os.access(pcfile, os.R_OK):
fd = file(pcfile)
lines = fd.readlines()
@@ -906,21 +902,14 @@ python package_do_package () {
do_package[dirs] = "${D}"
addtask package before do_build after do_install
-
-
-PACKAGE_WRITE_FUNCS ?= "read_subpackage_metadata"
-
-python package_do_package_write () {
- for f in (bb.data.getVar('PACKAGE_WRITE_FUNCS', d, 1) or '').split():
- bb.build.exec_func(f, d)
+# Dummy task to mark when all packaging is complete
+do_package_write () {
+ :
}
-do_package_write[dirs] = "${D}"
addtask package_write before do_build after do_package
-
EXPORT_FUNCTIONS do_package do_package_write
-
#
# Helper functions for the package writing classes
#
diff --git a/classes/package_deb.bbclass b/classes/package_deb.bbclass
index 94db9238c2..2ab537f174 100644
--- a/classes/package_deb.bbclass
+++ b/classes/package_deb.bbclass
@@ -4,11 +4,8 @@
inherit package
-PACKAGE_EXTRA_DEPENDS += "dpkg-native fakeroot-native"
-
BOOTSTRAP_EXTRA_RDEPENDS += "dpkg"
DISTRO_EXTRA_RDEPENDS += "dpkg"
-PACKAGE_WRITE_FUNCS += "do_package_deb"
IMAGE_PKGTYPE ?= "deb"
python package_deb_fn () {
@@ -271,5 +268,5 @@ python do_package_write_deb () {
bb.build.exec_func("do_package_deb", d)
}
do_package_write_deb[dirs] = "${D}"
-#addtask package_write_deb before do_package_write after do_package
+addtask package_write_deb before do_package_write after do_package
diff --git a/classes/package_ipk.bbclass b/classes/package_ipk.bbclass
index 3468680882..e9e21456dd 100644
--- a/classes/package_ipk.bbclass
+++ b/classes/package_ipk.bbclass
@@ -1,9 +1,6 @@
inherit package
-PACKAGE_EXTRA_DEPENDS += "ipkg-utils-native fakeroot-native"
-
BOOTSTRAP_EXTRA_RDEPENDS += "ipkg-collateral ipkg"
-PACKAGE_WRITE_FUNCS += "do_package_ipk"
IMAGE_PKGTYPE ?= "ipk"
IPKGCONF_TARGET = "${STAGING_ETCDIR_NATIVE}/ipkg.conf"
@@ -313,4 +310,4 @@ python do_package_write_ipk () {
bb.build.exec_func("do_package_ipk", d)
}
do_package_write_ipk[dirs] = "${D}"
-
+addtask package_write_ipk before do_package_write after do_package
diff --git a/classes/package_rpm.bbclass b/classes/package_rpm.bbclass
index bd4a0c2798..7fc5e8ea96 100644
--- a/classes/package_rpm.bbclass
+++ b/classes/package_rpm.bbclass
@@ -2,7 +2,6 @@ inherit package
inherit rpm_core
RPMBUILD="rpmbuild --short-circuit ${RPMOPTS}"
-PACKAGE_WRITE_FUNCS += "do_package_rpm"
IMAGE_PKGTYPE ?= "rpm"
python write_specfile() {
@@ -144,4 +143,4 @@ python do_package_write_rpm () {
bb.build.exec_func("do_package_rpm", d)
}
do_package_write_rpm[dirs] = "${D}"
-#addtask package_write_rpm before do_build after do_package
+addtask package_write_rpm before do_build after do_package
diff --git a/classes/package_tar.bbclass b/classes/package_tar.bbclass
index a56f2e2b00..cb4c42b261 100644
--- a/classes/package_tar.bbclass
+++ b/classes/package_tar.bbclass
@@ -1,8 +1,5 @@
inherit package
-PACKAGE_EXTRA_DEPENDS += "tar-native"
-
-PACKAGE_WRITE_FUNCS += "do_package_tar"
IMAGE_PKGTYPE ?= "tar"
python package_tar_fn () {
@@ -111,4 +108,4 @@ python do_package_write_tar () {
bb.build.exec_func("do_package_tar", d)
}
do_package_write_tar[dirs] = "${D}"
-#addtask package_write_tar before do_build after do_package
+addtask package_write_tar before do_build after do_package
diff --git a/classes/rm_work.bbclass b/classes/rm_work.bbclass
index 2ec7d305f2..8569148212 100644
--- a/classes/rm_work.bbclass
+++ b/classes/rm_work.bbclass
@@ -20,9 +20,7 @@ do_rm_work () {
fi
done
}
-# Uncomment me when we can use bitbake 1.8.8
-#addtask rm_work after do_${RMWORK_ORIG_TASK}
-addtask rm_work after do_build
+addtask rm_work after do_${RMWORK_ORIG_TASK}
do_rm_work_all () {
:
diff --git a/classes/rootfs_deb.bbclass b/classes/rootfs_deb.bbclass
index 6db02fa150..d3e5832251 100644
--- a/classes/rootfs_deb.bbclass
+++ b/classes/rootfs_deb.bbclass
@@ -3,7 +3,7 @@
#
do_rootfs[depends] += "dpkg-native:do_populate_staging apt-native:do_populate_staging"
-do_rootfs[recrdeptask] += "do_package_write"
+do_rootfs[recrdeptask] += "do_package_write_deb"
fakeroot rootfs_deb_do_rootfs () {
set +e
diff --git a/classes/rootfs_ipk.bbclass b/classes/rootfs_ipk.bbclass
index 8154318311..6babee30a2 100644
--- a/classes/rootfs_ipk.bbclass
+++ b/classes/rootfs_ipk.bbclass
@@ -6,7 +6,7 @@
#
do_rootfs[depends] += "ipkg-native:do_populate_staging ipkg-utils-native:do_populate_staging"
-do_rootfs[recrdeptask] += "do_package_write"
+do_rootfs[recrdeptask] += "do_package_write_ipk"
IPKG_ARGS = "-f ${IPKGCONF_TARGET} -o ${IMAGE_ROOTFS} ${@base_conditional("PACKAGE_INSTALL_NO_DEPS", "1", "-nodeps", "", d)}"
diff --git a/conf/bitbake.conf b/conf/bitbake.conf
index 5f8f91240d..a72dd75fdc 100644
--- a/conf/bitbake.conf
+++ b/conf/bitbake.conf
@@ -383,7 +383,7 @@ UPDATECOMMAND = "ERROR, this must be a BitBake bug"
UPDATECOMMAND_cvs = "/usr/bin/env cvs -d${CVSROOT} update -d -P ${CVSCOOPTS}"
UPDATECOMMAND_svn = "/usr/bin/env svn update ${SVNCOOPTS}"
SRCDATE = "${DATE}"
-SRCREV = "${@base_get_srcrev(d)}"
+SRCREV = "${@bb.fetch.get_srcrev(d)}"
AUTOREV = "${@bb.fetch.get_srcrev(d)}"
SRC_URI = "file://${FILE}"
diff --git a/packages/madwifi/madwifi-ng_r2702-20070903.bb b/packages/madwifi/madwifi-ng_r2702-20070903.bb
new file mode 100644
index 0000000000..cf614c96ae
--- /dev/null
+++ b/packages/madwifi/madwifi-ng_r2702-20070903.bb
@@ -0,0 +1,14 @@
+# Bitbake recipe for the madwifi-ng driver
+
+# Don't use this unless you know what you're doing -- this version does
+# *NOT* build on BE kernels.
+DEFAULT_PREFERENCE = "-1"
+
+# Disable stripping of kernel modules, since this action strips too
+# much out, and the resulting module won't load.
+INHIBIT_PACKAGE_STRIP = "1"
+
+require madwifi-ng_r.inc
+
+# PR set after the include, to override what's set in the included file.
+PR = "r0"