diff options
Diffstat (limited to 'classes')
-rw-r--r-- | classes/base.bbclass | 77 | ||||
-rw-r--r-- | classes/distutils-base.bbclass | 15 | ||||
-rw-r--r-- | classes/distutils.bbclass | 7 | ||||
-rw-r--r-- | classes/kernel-arch.bbclass | 2 | ||||
-rw-r--r-- | classes/kernel.bbclass | 2 | ||||
-rw-r--r-- | classes/mono.bbclass | 9 | ||||
-rw-r--r-- | classes/nylon-mirrors.bbclass | 8 | ||||
-rw-r--r-- | classes/oplinux-mirrors.bbclass | 16 | ||||
-rw-r--r-- | classes/package.bbclass | 4 | ||||
-rw-r--r-- | classes/package_deb.bbclass | 4 | ||||
-rw-r--r-- | classes/package_ipk.bbclass | 4 | ||||
-rw-r--r-- | classes/qt3e.bbclass | 4 | ||||
-rw-r--r-- | classes/qt3x11.bbclass | 2 | ||||
-rw-r--r-- | classes/rm_work.bbclass | 20 | ||||
-rw-r--r-- | classes/rootfs_deb.bbclass | 8 | ||||
-rw-r--r-- | classes/sanity.bbclass | 66 | ||||
-rw-r--r-- | classes/sdl.bbclass | 2 | ||||
-rw-r--r-- | classes/seppuku.bbclass | 2 | ||||
-rw-r--r-- | classes/sip.bbclass | 2 | ||||
-rw-r--r-- | classes/sip3.bbclass | 2 | ||||
-rw-r--r-- | classes/tinderclient.bbclass | 2 |
21 files changed, 177 insertions, 81 deletions
diff --git a/classes/base.bbclass b/classes/base.bbclass index 3250e0ca43..089cd5acd3 100644 --- a/classes/base.bbclass +++ b/classes/base.bbclass @@ -85,7 +85,7 @@ def base_chk_file(parser, pn, pv, src_uri, localpath, data): def base_dep_prepend(d): - import bb; + import bb # # Ideally this will check a flag so we will operate properly in # the case where host == build == target, for now we don't work in @@ -424,13 +424,21 @@ python base_do_clean() { os.system('rm -f '+ dir) } +#Uncomment this for bitbake 1.8.12 +#addtask rebuild after do_${BB_DEFAULT_TASK} addtask rebuild do_rebuild[dirs] = "${TOPDIR}" do_rebuild[nostamp] = "1" python base_do_rebuild() { """rebuild a package""" - bb.build.exec_task('do_clean', d) - bb.build.exec_task('do_' + bb.data.getVar('BB_DEFAULT_TASK', d, 1), d) + from bb import __version__ + try: + from distutils.version import LooseVersion + except ImportError: + def LooseVersion(v): print "WARNING: sanity.bbclass can't compare versions without python-distutils"; return 1 + if (LooseVersion(__version__) < LooseVersion('1.8.11')): + bb.build.exec_func('do_clean', d) + bb.build.exec_task('do_' + bb.data.getVar('BB_DEFAULT_TASK', d, 1), d) } addtask mrproper @@ -442,7 +450,7 @@ python base_do_mrproper() { if dir == '/': bb.build.FuncFailed("wrong DATADIR") bb.debug(2, "removing " + dir) os.system('rm -rf ' + dir) - bb.build.exec_task('do_clean', d) + bb.build.exec_func('do_clean', d) } addtask fetch @@ -663,6 +671,17 @@ python base_eventhandler() { if pesteruser: bb.fatal('The following variable(s) were not set: %s\nPlease set them directly, or choose a MACHINE or DISTRO that sets them.' % ', '.join(pesteruser)) + # + # Handle removing stamps for 'rebuild' task + # + if name.startswith("StampUpdate"): + for (fn, task) in e.targets: + #print "%s %s" % (task, fn) + if task == "do_rebuild": + dir = "%s.*" % e.stampPrefix[fn] + bb.note("Removing stamps: " + dir) + os.system('rm -f '+ dir) + if not data in e.__dict__: return NotHandled @@ -777,8 +796,10 @@ def get_subpkgedata_fn(pkg, d): import bb, os archs = bb.data.expand("${PACKAGE_ARCHS}", d).split(" ") archs.reverse() + pkgdata = bb.data.expand('${STAGING_DIR}/pkgdata/', d) + targetdir = bb.data.expand('${TARGET_VENDOR}-${TARGET_OS}/runtime/', d) for arch in archs: - fn = bb.data.expand('${STAGING_DIR}/pkgdata/' + arch + '${TARGET_VENDOR}-${TARGET_OS}/runtime/%s' % pkg, d) + fn = pkgdata + arch + targetdir + pkg if os.path.exists(fn): return fn return bb.data.expand('${PKGDATA_DIR}/runtime/%s' % pkg, d) @@ -814,6 +835,20 @@ python read_subpackage_metadata () { bb.data.setVar(key, sdata[key], d) } +# Make sure MACHINE isn't exported +# (breaks binutils at least) +MACHINE[unexport] = "1" + +# Make sure TARGET_ARCH isn't exported +# (breaks Makefiles using implicit rules, e.g. quilt, as GNU make has this +# in them, undocumented) +TARGET_ARCH[unexport] = "1" + +# Make sure DISTRO isn't exported +# (breaks sysvinit at least) +DISTRO[unexport] = "1" + + def base_after_parse(d): import bb, os, exceptions @@ -833,8 +868,6 @@ def base_after_parse(d): if this_machine and not re.match(need_machine, this_machine): raise bb.parse.SkipPackage("incompatible with machine %s" % this_machine) - - pn = bb.data.getVar('PN', d, 1) # OBSOLETE in bitbake 1.7.4 @@ -846,22 +879,6 @@ def base_after_parse(d): if use_nls != None: bb.data.setVar('USE_NLS', use_nls, d) - # Make sure MACHINE isn't exported - # (breaks binutils at least) - bb.data.delVarFlag('MACHINE', 'export', d) - bb.data.setVarFlag('MACHINE', 'unexport', 1, d) - - # Make sure TARGET_ARCH isn't exported - # (breaks Makefiles using implicit rules, e.g. quilt, as GNU make has this - # in them, undocumented) - bb.data.delVarFlag('TARGET_ARCH', 'export', d) - bb.data.setVarFlag('TARGET_ARCH', 'unexport', 1, d) - - # Make sure DISTRO isn't exported - # (breaks sysvinit at least) - bb.data.delVarFlag('DISTRO', 'export', d) - bb.data.setVarFlag('DISTRO', 'unexport', 1, d) - # Git packages should DEPEND on git-native srcuri = bb.data.getVar('SRC_URI', d, 1) if "git://" in srcuri: @@ -891,7 +908,7 @@ def base_after_parse(d): if len(paths) == 0: return - for s in bb.data.getVar('SRC_URI', d, 1).split(): + for s in srcuri.split(): if not s.startswith("file://"): continue local = bb.data.expand(bb.fetch.localpath(s, d), d) @@ -902,7 +919,19 @@ def base_after_parse(d): return python () { + import bb + from bb import __version__ base_after_parse(d) + + # Remove this for bitbake 1.8.12 + try: + from distutils.version import LooseVersion + except ImportError: + def LooseVersion(v): print "WARNING: sanity.bbclass can't compare versions without python-distutils"; return 1 + if (LooseVersion(__version__) >= LooseVersion('1.8.11')): + deps = bb.data.getVarFlag('do_rebuild', 'deps', d) or [] + deps.append('do_' + bb.data.getVar('BB_DEFAULT_TASK', d, 1)) + bb.data.setVarFlag('do_rebuild', 'deps', deps, d) } def check_app_exists(app, d): diff --git a/classes/distutils-base.bbclass b/classes/distutils-base.bbclass index 5150be76b9..c4551ace83 100644 --- a/classes/distutils-base.bbclass +++ b/classes/distutils-base.bbclass @@ -11,8 +11,17 @@ def python_dir(d): raise "No Python in STAGING_INCDIR. Forgot to build python-native ?" PYTHON_DIR = "${@python_dir(d)}" + +PACKAGES = "${PN}-dev ${PN}-dbg ${PN}-doc ${PN}" + FILES_${PN} = "${bindir}/* ${libdir}/* ${libdir}/${PYTHON_DIR}/*" -FILES_${PN}-dbg = "${libdir}/${PYTHON_DIR}/site-packages/.debug \ - ${libdir}/${PYTHON_DIR}/site-packages/*/.debug \ - ${libdir}/${PYTHON_DIR}/site-packages/*/*/.debug" +FILES_${PN}-dev += "\ + ${libdir}/pkgconfig \ + ${libdir}/${PYTHON_DIR}/site-packages/*.la \ +" +FILES_${PN}-dbg = "\ + ${libdir}/${PYTHON_DIR}/site-packages/.debug \ + ${libdir}/${PYTHON_DIR}/site-packages/*/.debug \ + ${libdir}/${PYTHON_DIR}/site-packages/*/*/.debug \ +" diff --git a/classes/distutils.bbclass b/classes/distutils.bbclass index 18aee09a26..fa34565eaf 100644 --- a/classes/distutils.bbclass +++ b/classes/distutils.bbclass @@ -13,16 +13,15 @@ distutils_do_compile() { } distutils_stage_headers() { - install -d ${STAGING_DIR_HOST}${layout_prefix}/lib/${PYTHON_DIR}/site-packages + install -d ${STAGING_DIR_HOST}${layout_libdir}/${PYTHON_DIR}/site-packages BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \ ${STAGING_BINDIR_NATIVE}/python setup.py install_headers ${DISTUTILS_STAGE_HEADERS_ARGS} || \ oefatal "python setup.py install_headers execution failed." } distutils_stage_all() { - install -d ${STAGING_DIR_HOST}${layout_prefix}/lib/${PYTHON_DIR}/site-packages - # is this missing a lib below? - PYTHONPATH=${STAGING_DIR_HOST}${layout_prefix}/${PYTHON_DIR}/site-packages \ + install -d ${STAGING_DIR_HOST}${layout_libdir}/${PYTHON_DIR}/site-packages + PYTHONPATH=${STAGING_DIR_HOST}${layout_libdir}/${PYTHON_DIR}/site-packages \ BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \ ${STAGING_BINDIR_NATIVE}/python setup.py install ${DISTUTILS_STAGE_ALL_ARGS} || \ oefatal "python setup.py install (stage) execution failed." diff --git a/classes/kernel-arch.bbclass b/classes/kernel-arch.bbclass index b45f3f9696..5e5d9a94a8 100644 --- a/classes/kernel-arch.bbclass +++ b/classes/kernel-arch.bbclass @@ -5,7 +5,7 @@ # valid_archs = "alpha cris ia64 \ - x86_64,i386 x86 \ + x86_64 i386 x86 \ m68knommu m68k ppc powerpc ppc64 \ sparc sparc64 \ arm arm26 \ diff --git a/classes/kernel.bbclass b/classes/kernel.bbclass index 1e325323df..459c553ffe 100644 --- a/classes/kernel.bbclass +++ b/classes/kernel.bbclass @@ -70,7 +70,7 @@ INITRAMFS_IMAGE_TARGET ?= "initramfs-image" do_builtin_initramfs() { unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS MACHINE - cp "${DEPLOY_DIR_IMAME}/${INITRAMFS_SYMLINK_NAME}" usr/initramfs_data.cpio.gz + cp "${DEPLOY_DIR_IMAGE}/${INITRAMFS_SYMLINK_NAME}" usr/initramfs_data.cpio.gz oe_runmake ${KERNEL_IMAGETYPE} CC="${KERNEL_CC}" LD="${KERNEL_LD}" install -d ${DEPLOY_DIR_IMAGE} install -m 0644 ${KERNEL_OUTPUT} ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGE_BASE_NAME}-initramfs.bin diff --git a/classes/mono.bbclass b/classes/mono.bbclass index ccb16d9acc..cf8dd15bdf 100644 --- a/classes/mono.bbclass +++ b/classes/mono.bbclass @@ -52,6 +52,8 @@ def mono_find_provides_and_requires(files, d): requires = [e for e in requires if not e in provides] return provides, requires +CLILIBSDIR = "${STAGING_DIR_HOST}/clilibs" + python mono_do_clilibs() { import bb, os, re, os.path @@ -70,14 +72,9 @@ python mono_do_clilibs() { bb.error("WORKDIR not defined") return - staging = bb.data.getVar('STAGING_DIR', d, 1) - if not staging: - bb.error("STAGING_DIR not defined") - return - pkgdest = bb.data.getVar('PKGDEST', d, 1) - clilibs_dir = os.path.join(staging, "clilibs") + clilibs_dir = bb.data.getVar('CLILIBSDIR', d, 1) bb.mkdirhier(clilibs_dir) provides, requires = {}, {} diff --git a/classes/nylon-mirrors.bbclass b/classes/nylon-mirrors.bbclass index 25a8b87d9b..02fddc01ba 100644 --- a/classes/nylon-mirrors.bbclass +++ b/classes/nylon-mirrors.bbclass @@ -1,6 +1,6 @@ MIRRORS_append () { -ftp://.*/.*/ http://meshcube.org/nylon/stable/sources/ -https?://.*/.*/ http://meshcube.org/nylon/stable/sources/ -ftp://.*/.*/ http://meshcube.org/nylon/unstable/sources/ -https?://.*/.*/ http://meshcube.org/nylon/unstable/sources/ +ftp://.*/.* http://meshcube.org/nylon/stable/sources/ +https?://.*/.* http://meshcube.org/nylon/stable/sources/ +ftp://.*/.* http://meshcube.org/nylon/unstable/sources/ +https?://.*/.* http://meshcube.org/nylon/unstable/sources/ }
\ No newline at end of file diff --git a/classes/oplinux-mirrors.bbclass b/classes/oplinux-mirrors.bbclass index c76e822ce3..59c199485c 100644 --- a/classes/oplinux-mirrors.bbclass +++ b/classes/oplinux-mirrors.bbclass @@ -2,13 +2,13 @@ # Released under the MIT license (see packages/COPYING) MIRRORS_append () { -ftp://.*/.*/ http://digital-opsis.com/oplinux/stable/sources/ -https?://.*/.*/ http://digital-opsis.com/oplinux/stable/sources/ -ftp://.*/.*/ http://digital-opsis.com/oplinux/unstable/sources/ -https?://.*/.*/ http://digital-opsis.com/oplinux/unstable/sources/ +ftp://.*/.* http://digital-opsis.com/oplinux/stable/sources/ +https?://.*/.* http://digital-opsis.com/oplinux/stable/sources/ +ftp://.*/.* http://digital-opsis.com/oplinux/unstable/sources/ +https?://.*/.* http://digital-opsis.com/oplinux/unstable/sources/ -ftp://.*/.*/ http://digital-opsis.com/oplinux-uclibc/stable/sources/ -https?://.*/.*/ http://digital-opsis.com/oplinux-uclibc/stable/sources/ -ftp://.*/.*/ http://digital-opsis.com/oplinux-uclibc/unstable/sources/ -https?://.*/.*/ http://digital-opsis.com/oplinux-uclibc/unstable/sources/ +ftp://.*/.* http://digital-opsis.com/oplinux-uclibc/stable/sources/ +https?://.*/.* http://digital-opsis.com/oplinux-uclibc/stable/sources/ +ftp://.*/.* http://digital-opsis.com/oplinux-uclibc/unstable/sources/ +https?://.*/.* http://digital-opsis.com/oplinux-uclibc/unstable/sources/ } diff --git a/classes/package.bbclass b/classes/package.bbclass index e267478561..325c0b52f5 100644 --- a/classes/package.bbclass +++ b/classes/package.bbclass @@ -515,11 +515,11 @@ emit_pkgdata[dirs] = "${PKGDATA_DIR}/runtime" ldconfig_postinst_fragment() { if [ x"$D" = "x" ]; then - ldconfig + [ -x /sbin/ldconfig ] && /sbin/ldconfig fi } -SHLIBSDIR = "${STAGING_DIR}/${HOST_SYS}/shlibs" +SHLIBSDIR = "${STAGING_DIR_HOST}/shlibs" python package_do_shlibs() { import os, re, os.path diff --git a/classes/package_deb.bbclass b/classes/package_deb.bbclass index 1a3622c3bb..22b6166685 100644 --- a/classes/package_deb.bbclass +++ b/classes/package_deb.bbclass @@ -28,7 +28,7 @@ python do_package_deb_install () { pkgfn = bb.data.getVar('PKGFN', d, 1) rootfs = bb.data.getVar('IMAGE_ROOTFS', d, 1) debdir = bb.data.getVar('DEPLOY_DIR_DEB', d, 1) - stagingdir = bb.data.getVar('STAGING_DIR', d, 1) + apt_config = bb.data.expand('${STAGING_ETCDIR_NATIVE}/apt/apt.conf', d) stagingbindir = bb.data.getVar('STAGING_BINDIR_NATIVE', d, 1) tmpdir = bb.data.getVar('TMPDIR', d, 1) @@ -55,7 +55,7 @@ python do_package_deb_install () { # Set up environment apt_config_backup = os.getenv('APT_CONFIG') - os.putenv('APT_CONFIG', os.path.join(stagingdir, 'etc', 'apt', 'apt.conf')) + os.putenv('APT_CONFIG', apt_config) path = os.getenv('PATH') os.putenv('PATH', '%s:%s' % (stagingbindir, os.getenv('PATH'))) diff --git a/classes/package_ipk.bbclass b/classes/package_ipk.bbclass index de7f0fe0c4..2feaeba3b3 100644 --- a/classes/package_ipk.bbclass +++ b/classes/package_ipk.bbclass @@ -12,6 +12,10 @@ python package_ipk_fn () { } python package_ipk_install () { + # + # Warning - this function is not multimachine safe (see stagingdir reference)! + # + import os, sys pkg = bb.data.getVar('PKG', d, 1) pkgfn = bb.data.getVar('PKGFN', d, 1) diff --git a/classes/qt3e.bbclass b/classes/qt3e.bbclass index 98c47adb90..35958b34ab 100644 --- a/classes/qt3e.bbclass +++ b/classes/qt3e.bbclass @@ -1,8 +1,8 @@ # # override variables set by qmake_base to compile Qt/X11 apps # -export QTDIR="${STAGING_DIR}/${HOST_SYS}/qte3" -export QTEDIR="${STAGING_DIR}/${HOST_SYS}/qte3" +export QTDIR="${STAGING_DIR_HOST}/qte3" +export QTEDIR="${STAGING_DIR_HOST}/qte3" export OE_QMAKE_UIC="${STAGING_BINDIR_NATIVE}/uic3" export OE_QMAKE_MOC="${STAGING_BINDIR_NATIVE}/moc3" export OE_QMAKE_CXXFLAGS="${CXXFLAGS} " diff --git a/classes/qt3x11.bbclass b/classes/qt3x11.bbclass index 67f2cf7348..5408b7f342 100644 --- a/classes/qt3x11.bbclass +++ b/classes/qt3x11.bbclass @@ -3,7 +3,7 @@ EXTRA_QMAKEVARS_POST += "CONFIG+=thread" # # override variables set by qmake_base to compile Qt/X11 apps # -export QTDIR = "${STAGING_DIR}/${HOST_SYS}/qt3" +export QTDIR = "${STAGING_DIR_HOST}/qt3" export OE_QMAKE_UIC = "${STAGING_BINDIR_NATIVE}/uic3" export OE_QMAKE_MOC = "${STAGING_BINDIR_NATIVE}/moc3" export OE_QMAKE_CXXFLAGS = "${CXXFLAGS} -DQT_NO_XIM" diff --git a/classes/rm_work.bbclass b/classes/rm_work.bbclass index 4efd39c557..97de5e2774 100644 --- a/classes/rm_work.bbclass +++ b/classes/rm_work.bbclass @@ -25,3 +25,23 @@ do_rm_work_all () { } do_rm_work_all[recrdeptask] = "do_rm_work" addtask rm_work_all after do_rm_work + + +addhandler rmwork_stampfixing_eventhandler +python rmwork_stampfixing_eventhandler() { + from bb.event import getName + import os + + if getName(e) == "StampUpdate": + for (fn, task) in e.targets: + if task == 'rm_work_all': + continue + stamp = "%s.do_rm_work" % e.stampPrefix[fn] + if os.path.exists(stamp): + dir = "%s.*" % e.stampPrefix[fn] + bb.note("Removing stamps: " + dir) + os.system('rm -f '+ dir) + + return NotHandled +} + diff --git a/classes/rootfs_deb.bbclass b/classes/rootfs_deb.bbclass index c2c4a764e4..5237285e4c 100644 --- a/classes/rootfs_deb.bbclass +++ b/classes/rootfs_deb.bbclass @@ -10,12 +10,8 @@ fakeroot rootfs_deb_do_rootfs () { mkdir -p ${IMAGE_ROOTFS}/var/dpkg/info mkdir -p ${IMAGE_ROOTFS}/var/dpkg/updates - mkdir -p ${STAGING_ETCDIR_NATIVE}/apt/ - rm -f ${STAGING_ETCDIR_NATIVE}/apt/sources.list.rev rm -f ${STAGING_ETCDIR_NATIVE}/apt/preferences - > ${STAGING_ETCDIR_NATIVE}/apt/sources.list.rev - > ${STAGING_ETCDIR_NATIVE}/apt/preferences > ${IMAGE_ROOTFS}/var/dpkg/status > ${IMAGE_ROOTFS}/var/dpkg/available # > ${STAGING_DIR}/var/dpkg/status @@ -40,9 +36,9 @@ fakeroot rootfs_deb_do_rootfs () { priority=$(expr $priority + 5) done - tac ${STAGING_ETCDIR_NATIVE}/apt/sources.list.rev > ${STAGING_DIR}/etc/apt/sources.list + tac ${STAGING_ETCDIR_NATIVE}/apt/sources.list.rev > ${STAGING_ETCDIR_NATIVE}/apt/sources.list - cat "${STAGING_DIR}/etc/apt/apt.conf.sample" \ + cat "${STAGING_ETCDIR_NATIVE}/apt/apt.conf.sample" \ | sed -e 's#Architecture ".*";#Architecture "${TARGET_ARCH}";#' \ > "${STAGING_ETCDIR_NATIVE}/apt/apt-rootfs.conf" diff --git a/classes/sanity.bbclass b/classes/sanity.bbclass index 9994febf0d..44c74a0354 100644 --- a/classes/sanity.bbclass +++ b/classes/sanity.bbclass @@ -31,7 +31,7 @@ def check_sanity(e): from distutils.version import LooseVersion except ImportError: def LooseVersion(v): print "WARNING: sanity.bbclass can't compare versions without python-distutils"; return 1 - import os + import os, commands # Check the bitbake version meets minimum requirements minversion = data.getVar('BB_MIN_VERSION', e.data , True) @@ -64,8 +64,8 @@ def check_sanity(e): # Check that the MACHINE is valid, if it is set if data.getVar('MACHINE', e.data, True): - if not check_conf_exists("conf/machine/${MACHINE}.conf", e.data): - messages = messages + 'Please set a valid MACHINE in your local.conf\n' + if not check_conf_exists("conf/machine/${MACHINE}.conf", e.data): + messages = messages + 'Please set a valid MACHINE in your local.conf\n' # Check that the DISTRO is valid # need to take into account DISTRO renaming DISTRO @@ -85,6 +85,19 @@ def check_sanity(e): required_utilities = "patch help2man diffstat texi2html makeinfo cvs svn bzip2 tar gzip gawk md5sum" + if data.getVar('TARGET_ARCH', e.data, True) == "arm": + # qemu-native needs gcc 3.x + if "qemu-native" not in assume_provided and "gcc3-native" in assume_provided: + gcc_version = commands.getoutput("${BUILD_PREFIX}gcc --version | head -n 1 | cut -f 3 -d ' '") + + if not check_gcc3(e.data) and gcc_version[0] != '3': + messages = messages + "gcc3-native was in ASSUME_PROVIDED but the gcc-3.x binary can't be found in PATH" + missing = missing + "gcc-3.x (needed for qemu-native)," + + if "qemu-native" in assume_provided: + if not check_app_exists("qemu-arm", e.data): + messages = messages + "qemu-native was in ASSUME_PROVIDED but the QEMU binaries (qemu-arm) can't be found in PATH" + for util in required_utilities.split(): if not check_app_exists( util, e.data ): missing = missing + "%s," % util @@ -100,7 +113,40 @@ def check_sanity(e): oes_bb_conf = data.getVar( 'OES_BITBAKE_CONF', e.data, True ) if not oes_bb_conf: - messages = messages + 'You do not include OpenEmbeddeds version of conf/bitbake.conf\n' + messages = messages + 'You do not include OpenEmbeddeds version of conf/bitbake.conf. This means your environment is misconfigured, in particular check BBPATH.\n' + + # + # Check that TMPDIR hasn't changed location since the last time we were run + # + tmpdir = data.getVar('TMPDIR', e.data, True) + checkfile = os.path.join(tmpdir, "saved_tmpdir") + if os.path.exists(checkfile): + f = file(checkfile, "r") + if (f.read().strip() != tmpdir): + messages = messages + "Error, TMPDIR has changed location. You need to either move it back to %s or rebuild\n" % tmpdir + else: + f = file(checkfile, "w") + f.write(tmpdir) + f.close() + + # + # Check the 'ABI' of TMPDIR + # + current_abi = data.getVar('SANITY_ABI', e.data, True) + abifile = data.getVar('SANITY_ABIFILE', e.data, True) + if os.path.exists(abifile): + f = file(abifile, "r") + abi = f.read().strip() + if not abi.isdigit(): + f = file(abifile, "w") + f.write(current_abi) + elif (abi != current_abi): + # Code to convert from one ABI to another could go here if possible. + messages = messages + "Error, TMPDIR has changed ABI (%s to %s) and you need to either rebuild, revert or adjust it at your own risk.\n" % (abi, current_abi) + else: + f = file(abifile, "w") + f.write(current_abi) + f.close() if messages != "": raise_sanity_error(messages) @@ -110,17 +156,7 @@ python check_sanity_eventhandler() { from bb import note, error, data, __version__ from bb.event import getName - try: - from distutils.version import LooseVersion - except ImportError: - def LooseVersion(v): print "WARNING: sanity.bbclass can't compare versions without python-distutils"; return 1 - - if (LooseVersion(bb.__version__) > LooseVersion("1.8.6")): - if getName(e) == "ConfigParsed": - check_sanity(e) - return NotHandled - - if getName(e) == "BuildStarted": + if getName(e) == "ConfigParsed": check_sanity(e) return NotHandled diff --git a/classes/sdl.bbclass b/classes/sdl.bbclass index 23cbf10919..dc4cd8ffa2 100644 --- a/classes/sdl.bbclass +++ b/classes/sdl.bbclass @@ -8,6 +8,8 @@ APPDESKTOP ?= "${WORKDIR}/${PN}.desktop" APPNAME ?= "${PN}" APPIMAGE ?= "${WORKDIR}/${PN}.png" +export SDL_CONFIG = "${STAGING_BINDIR_CROSS}/sdl-config" + sdl_do_sdl_install() { install -d ${D}${datadir}/applications install -d ${D}${datadir}/pixmaps diff --git a/classes/seppuku.bbclass b/classes/seppuku.bbclass index 834bee34b4..2e097a812e 100644 --- a/classes/seppuku.bbclass +++ b/classes/seppuku.bbclass @@ -303,7 +303,7 @@ python seppuku_eventhandler() { if name == "PkgFailed": if not bb.data.getVar('SEPPUKU_AUTOBUILD', data, True) == "0": - build.exec_task('do_clean', data) + build.exec_func('do_clean', data) elif name == "TaskFailed": cj = cookielib.CookieJar() opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(cj)) diff --git a/classes/sip.bbclass b/classes/sip.bbclass index ae186bd04a..30c08b1ed9 100644 --- a/classes/sip.bbclass +++ b/classes/sip.bbclass @@ -55,6 +55,8 @@ sip_do_generate() { done } +do_generate[deptask] = "do_populate_staging" + EXPORT_FUNCTIONS do_generate addtask generate after do_unpack do_patch before do_configure diff --git a/classes/sip3.bbclass b/classes/sip3.bbclass index 1dd42ba86b..7ecc63bf02 100644 --- a/classes/sip3.bbclass +++ b/classes/sip3.bbclass @@ -53,6 +53,8 @@ sip3_do_generate() { done } +do_generate[deptask] = "do_populate_staging" + EXPORT_FUNCTIONS do_generate addtask generate after do_unpack do_patch before do_configure diff --git a/classes/tinderclient.bbclass b/classes/tinderclient.bbclass index bc004efb26..0b7fc1d843 100644 --- a/classes/tinderclient.bbclass +++ b/classes/tinderclient.bbclass @@ -328,7 +328,7 @@ def tinder_do_tinder_report(event): log += "<--- TINDERBOX Package %s done (SUCCESS)\n" % data.getVar('PF', event.data, True) elif name == "PkgFailed": if not data.getVar('TINDER_AUTOBUILD', event.data, True) == "0": - build.exec_task('do_clean', event.data) + build.exec_func('do_clean', event.data) log += "<--- TINDERBOX Package %s failed (FAILURE)\n" % data.getVar('PF', event.data, True) status = 200 # remember the failure for the -k case |