From 91bbf116d75d79b481924c8ee54b78a07da41ace Mon Sep 17 00:00:00 2001 From: Philipp Zabel Date: Mon, 20 Aug 2007 11:04:29 +0000 Subject: task.bbclass: add a task class that sets common task recipe variables and automates adding -dev and -dbg packages --- classes/task.bbclass | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 classes/task.bbclass (limited to 'classes') diff --git a/classes/task.bbclass b/classes/task.bbclass new file mode 100644 index 0000000000..4edd704829 --- /dev/null +++ b/classes/task.bbclass @@ -0,0 +1,27 @@ +# Task packages are only used to pull in other packages +# via their dependencies. They are empty. +ALLOW_EMPTY = "1" + +# By default, only the task package itself is in PACKAGES. +# -dbg and -dev flavours are handled by the anonfunc below. +# This means that task recipes used to build multiple task +# packages have to modify PACKAGES after inheriting task.bbclass. +PACKAGES = "${PN}" + +# By default, task packages do not depend on a certain architecture. +# Only if dependencies are modified by MACHINE_FEATURES, packages +# need to be set to MACHINE_ARCH after inheriting task.bbclass +PACKAGE_ARCH = "all" + +# This automatically adds -dbg and -dev flavours of all PACKAGES +# to the list. Their dependencies (RRECOMMENDS) are handled as usual +# by package_depchains in a following step. +python () { + packages = bb.data.getVar('PACKAGES', d, 1).split() + genpackages = [] + for pkg in packages: + for postfix in ['-dbg', '-dev']: + genpackages.append(pkg+postfix) + bb.data.setVar('PACKAGES', ' '.join(packages+genpackages), d) +} + -- cgit v1.2.3 From 3511d4c1ba15270dbfd6ee5455273fa70850aa18 Mon Sep 17 00:00:00 2001 From: Michael Lauer Date: Mon, 20 Aug 2007 20:37:01 +0000 Subject: classes/distutils.bbclass: add a staging task (to be called explicitly) --- classes/distutils.bbclass | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'classes') diff --git a/classes/distutils.bbclass b/classes/distutils.bbclass index d23c2a3b2e..9f699bc7f0 100644 --- a/classes/distutils.bbclass +++ b/classes/distutils.bbclass @@ -9,7 +9,14 @@ distutils_do_compile() { distutils_stage_headers() { BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \ ${STAGING_BINDIR_NATIVE}/python setup.py install_headers --install-dir=${STAGING_INCDIR}/${PYTHON_DIR} || \ - oefatal "python setup.py install execution failed." + oefatal "python setup.py install_headers execution failed." +} + +distutils_stage_all() { + PYTHONPATH=${STAGING_INCDIR}/../${PYTHON_DIR}/site-packages \ + BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \ + ${STAGING_BINDIR_NATIVE}/python setup.py install --prefix=${STAGING_INCDIR}/.. --install-data=${STAGING_INCDIR}/../share || \ + oefatal "python setup.py install (stage) execution failed." } distutils_do_install() { -- cgit v1.2.3 From ba720f508ea2650e7e4c1da9c582ae4d1529724b Mon Sep 17 00:00:00 2001 From: Stelios Koroneos Date: Tue, 21 Aug 2007 13:27:03 +0000 Subject: classes/xilinx-bsp.bbclass : Add a class to handle xilinx kernel requirments --- classes/xilinx-bsp.bbclass | 53 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 classes/xilinx-bsp.bbclass (limited to 'classes') diff --git a/classes/xilinx-bsp.bbclass b/classes/xilinx-bsp.bbclass new file mode 100644 index 0000000000..fd09946061 --- /dev/null +++ b/classes/xilinx-bsp.bbclass @@ -0,0 +1,53 @@ +# Copyright (C) 2007, Stelios Koroneos - Digital OPSiS, All Rights Reserved +# Released under the MIT license (see packages/COPYING) +# +#This class handles all the intricasies of getting the required files from the +#ISE/EDK/project to the kernel and prepare the kernel for compilation. +#The Xilinx EDK supports 2 different architectures : PowerPC (ppc 405) and Microblaze +#Only the PowerPC BSP has been tested so far +#For this to work correctly you need to add XILINX_BSP_PATH and XILINX_BOARD to your +#local.conf +#XILINX_BSP_PATH should have the complete path to your project dir +#XILINX_BOARD should have the board type i.e ML403 +# +#Currently supported boards +#Xilinx ML403 +#More to come soon ;) + +do_configure_prepend() { + + +#first check that the XILINX_BSP_PATH and XILINX_BOARD have been defined in local.conf +if [ -z "${XILINX_BSP_PATH}" ]; then + oefatal "XILINX_BSP_PATH not defined ! Exiting..." + exit 1 + +else + if [ -z "${XILINX_BOARD}" ]; then + oefatal "XILINX_BOARD not defined ! Exiting" + exit 1 + fi + +fi +#now depending on the board type and arch do what is nessesary + +case "${XILINX_BOARD}" in + ML403) + oenote "ML403 board setup" + cp -a ${XILINX_BSP_PATH}/ppc405_0/libsrc/linux_2_6_v1_00_a/linux/arch/ppc/platforms/4xx/xparameters/xparameters_ml40x.h \ + ${S}/arch/ppc/platforms/4xx/xparameters/xparameters_ml403.h + ;; + + * ) + oefatal "! Unknow Xilinx board ! Exiting..." + exit 1 + ;; +esac + + +} + + + + + -- cgit v1.2.3 From aaaac4c545623d8818de2d3fa71d9d63b717c575 Mon Sep 17 00:00:00 2001 From: Michael Lauer Date: Tue, 21 Aug 2007 15:08:10 +0000 Subject: classes/distutils.bbclass: remove easy-install.pth, since this ends up in every package and Python 2.5 seems to be able to import .egg packages even without it --- classes/distutils.bbclass | 1 + 1 file changed, 1 insertion(+) (limited to 'classes') diff --git a/classes/distutils.bbclass b/classes/distutils.bbclass index 9f699bc7f0..8a34594a70 100644 --- a/classes/distutils.bbclass +++ b/classes/distutils.bbclass @@ -42,6 +42,7 @@ distutils_do_install() { done fi + rm -f ${D}${libdir}/${PYTHON_DIR}/site-packages/easy-install.pth } EXPORT_FUNCTIONS do_compile do_install -- cgit v1.2.3 From caa3f3523c30f1c3e333c9866e290b97f3536c6d Mon Sep 17 00:00:00 2001 From: Stefan Schmidt Date: Tue, 21 Aug 2007 21:42:40 +0000 Subject: fic-gta01.conf: Drop EXTRA_IMAGEDEPENDS on sjf2410-linux-native to let the OpenMoko build work on big endian machines. We do not need sjf2410 anymore atm. --- classes/openmoko2.bbclass | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'classes') diff --git a/classes/openmoko2.bbclass b/classes/openmoko2.bbclass index 872dd4915c..ef734e4311 100644 --- a/classes/openmoko2.bbclass +++ b/classes/openmoko2.bbclass @@ -29,5 +29,5 @@ S = "${WORKDIR}/${PN}" FILES_${PN} += "${datadir}/icons" -# SVNREV = "r${SRCREV}" -SVNREV = "${SRCDATE}" +SVNREV = "r${SRCREV}" +#SVNREV = "${SRCDATE}" -- cgit v1.2.3 From 02660bf2a86ce4fbc3ecedaa0e836572702be013 Mon Sep 17 00:00:00 2001 From: Stefan Schmidt Date: Tue, 21 Aug 2007 21:43:07 +0000 Subject: disapproval of revision 'badf9d8b62f79360108e71d3657a6dd7abe98d03' --- classes/openmoko2.bbclass | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'classes') diff --git a/classes/openmoko2.bbclass b/classes/openmoko2.bbclass index ef734e4311..872dd4915c 100644 --- a/classes/openmoko2.bbclass +++ b/classes/openmoko2.bbclass @@ -29,5 +29,5 @@ S = "${WORKDIR}/${PN}" FILES_${PN} += "${datadir}/icons" -SVNREV = "r${SRCREV}" -#SVNREV = "${SRCDATE}" +# SVNREV = "r${SRCREV}" +SVNREV = "${SRCDATE}" -- cgit v1.2.3 From 1ad1eead848e02c6eea27c34e869126d81cb6355 Mon Sep 17 00:00:00 2001 From: Michael Lauer Date: Wed, 22 Aug 2007 13:47:30 +0000 Subject: distutils.bbclass: always install staging directory before calling python --- classes/distutils.bbclass | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'classes') diff --git a/classes/distutils.bbclass b/classes/distutils.bbclass index 8a34594a70..c07a9911cd 100644 --- a/classes/distutils.bbclass +++ b/classes/distutils.bbclass @@ -13,7 +13,8 @@ distutils_stage_headers() { } distutils_stage_all() { - PYTHONPATH=${STAGING_INCDIR}/../${PYTHON_DIR}/site-packages \ + install -d ${STAGING_INCDIR}/../${PYTHON_DIR}/site-packages + PYTHONPATH=${STAGING_INCDIR}/../${PYTHON_DIR}/site-packages \ BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \ ${STAGING_BINDIR_NATIVE}/python setup.py install --prefix=${STAGING_INCDIR}/.. --install-data=${STAGING_INCDIR}/../share || \ oefatal "python setup.py install (stage) execution failed." -- cgit v1.2.3 From 24aa0782880ea230c41957aedb9517583af31406 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Wed, 22 Aug 2007 15:15:51 +0000 Subject: image/rootfs_ipk: Remove uneeded mkdir calls --- classes/image.bbclass | 1 - classes/rootfs_ipk.bbclass | 1 - 2 files changed, 2 deletions(-) (limited to 'classes') diff --git a/classes/image.bbclass b/classes/image.bbclass index 248ccab60b..aa0c73adb7 100644 --- a/classes/image.bbclass +++ b/classes/image.bbclass @@ -71,7 +71,6 @@ fakeroot do_rootfs () { rm -rf ${IMAGE_ROOTFS} if [ "${USE_DEVFS}" != "1" ]; then - mkdir -p ${IMAGE_ROOTFS}/dev for devtable in ${@get_devtable_list(d)}; do makedevs -r ${IMAGE_ROOTFS} -D $devtable done diff --git a/classes/rootfs_ipk.bbclass b/classes/rootfs_ipk.bbclass index 75c85e8f3d..53b0162eac 100644 --- a/classes/rootfs_ipk.bbclass +++ b/classes/rootfs_ipk.bbclass @@ -37,7 +37,6 @@ fakeroot rootfs_ipk_do_rootfs () { rootfs_ipk_do_indexes - mkdir -p ${IMAGE_ROOTFS}/dev mkdir -p ${T} #Add deploy/ipk as well for backward compat -- cgit v1.2.3 From 681a42f0f9ed259fa6d1747f9282044d5b799ef4 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Wed, 22 Aug 2007 16:14:59 +0000 Subject: image.bbclass: Add the mkdir back in a different form. This proves nobody uses USE_DEVFS and we should consider removing it, --- classes/image.bbclass | 1 + 1 file changed, 1 insertion(+) (limited to 'classes') diff --git a/classes/image.bbclass b/classes/image.bbclass index aa0c73adb7..91e63262cd 100644 --- a/classes/image.bbclass +++ b/classes/image.bbclass @@ -69,6 +69,7 @@ do_build[nostamp] = "1" fakeroot do_rootfs () { set -x rm -rf ${IMAGE_ROOTFS} + mkdir -p ${IMAGE_ROOTFS} if [ "${USE_DEVFS}" != "1" ]; then for devtable in ${@get_devtable_list(d)}; do -- cgit v1.2.3 From 8f4ca08c42769081860c4f89d41d079fad9681c8 Mon Sep 17 00:00:00 2001 From: Koen Kooi Date: Thu, 23 Aug 2007 08:28:07 +0000 Subject: seppuku.bbclass: add more debugging and keep attaching buildlogs for known bugs --- classes/seppuku.bbclass | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) (limited to 'classes') diff --git a/classes/seppuku.bbclass b/classes/seppuku.bbclass index 7241ae3e7a..101f621303 100644 --- a/classes/seppuku.bbclass +++ b/classes/seppuku.bbclass @@ -335,16 +335,23 @@ python seppuku_eventhandler() { (bug_open, bug_number) = seppuku_find_bug_report(debug_file, opener, query, product, component, bugname) print >> debug_file, "Bug is open: %s and bug number: %s" % (bug_open, bug_number) - # The bug is present and still open, no need to attach an error log + # The bug is present and still open, attach an error log if bug_number and bug_open: print >> debug_file, "The bug is known as '%s'" % bug_number + if file: + if not seppuku_create_attachment(debug_file, poster, attach, product, component, bug_number, text, file): + print >> debug_file, "Failed to attach the build log for bug #%s" % bug_number + else: + print >> debug_file, "Created an attachment for '%s' '%s' '%s'" % (product, component, bug_number) + else: + print >> debug_file, "Not trying to create an attachment for bug #%s" % bug_number return NotHandled if bug_number and not bug_open: if not seppuku_reopen_bug(poster, reopen, product, component, bug_number, bugname, text): - print >> debug_file, "Failed to reopen the bug report" + print >> debug_file, "Failed to reopen the bug #%s" % bug_number else: - print >> debug_file, "Reopened the bug report" + print >> debug_file, "Reopened the bug #%s" % bug_number else: bug_number = seppuku_file_bug(poster, newbug, product, component, bugname, text) if not bug_number: @@ -354,11 +361,11 @@ python seppuku_eventhandler() { if bug_number and file: if not seppuku_create_attachment(debug_file, poster, attach, product, component, bug_number, text, file): - print >> debug_file, "Failed to attach the build log" + print >> debug_file, "Failed to attach the build log for bug #%" % bug_number else: print >> debug_file, "Created an attachment for '%s' '%s' '%s'" % (product, component, bug_number) else: - print >> debug_file, "Not trying to create an attachment" + print >> debug_file, "Not trying to create an attachment for bug #%" % bug_number return NotHandled } -- cgit v1.2.3 From 19c8ebf2a5176ea4b109b56422fae53b9b926edc Mon Sep 17 00:00:00 2001 From: Stefan Schmidt Date: Sat, 25 Aug 2007 09:45:00 +0000 Subject: rm_work.bbclass: Make sure all hidden directories get also removed. (.pc for example) --- classes/rm_work.bbclass | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'classes') diff --git a/classes/rm_work.bbclass b/classes/rm_work.bbclass index 45812bbb81..2ec7d305f2 100644 --- a/classes/rm_work.bbclass +++ b/classes/rm_work.bbclass @@ -14,7 +14,7 @@ do_rm_work () { for dir in * do if [ `basename ${S}` = $dir ]; then - rm -rf $dir/* + rm -rf $dir elif [ $dir != 'temp' ]; then rm -rf $dir fi -- cgit v1.2.3 From 579019b1aef8fe103cf266d418bb90532c635e4b Mon Sep 17 00:00:00 2001 From: Koen Kooi Date: Tue, 28 Aug 2007 03:32:37 +0000 Subject: rootfs*.bbclass: uclibc doesn't provides glibc-locale* and locale-base*, so don't try to install it --- classes/rootfs_deb.bbclass | 28 +++++++++++++++------------- classes/rootfs_ipk.bbclass | 24 +++++++++++++++--------- 2 files changed, 30 insertions(+), 22 deletions(-) (limited to 'classes') diff --git a/classes/rootfs_deb.bbclass b/classes/rootfs_deb.bbclass index 67fa661308..32b1c57f1a 100644 --- a/classes/rootfs_deb.bbclass +++ b/classes/rootfs_deb.bbclass @@ -53,19 +53,21 @@ fakeroot rootfs_deb_do_rootfs () { _getflag () { cat ${IMAGE_ROOTFS}/var/dpkg/status | sed -n -e "/^Package: $2\$/{n; s/Status: install ok .*/$1/; p}" } - - if [ ! -z "${LINGUAS_INSTALL}" ]; then - apt-get install glibc-localedata-i18n --force-yes --allow-unauthenticated - if [ $? -ne 0 ]; then - exit $? - fi - for i in ${LINGUAS_INSTALL}; do - apt-get install $i --force-yes --allow-unauthenticated - if [ $? -ne 0 ]; then - exit $? - fi - done - fi + + if [ x${TARGET_OS} = "xlinux" ] || [ x${TARGET_OS} = "xlinux-gnueabi" ] ; then + if [ ! -z "${LINGUAS_INSTALL}" ]; then + apt-get install glibc-localedata-i18n --force-yes --allow-unauthenticated + if [ $? -ne 0 ]; then + exit $? + fi + for i in ${LINGUAS_INSTALL}; do + apt-get install $i --force-yes --allow-unauthenticated + if [ $? -ne 0 ]; then + exit $? + fi + done + fi + fi if [ ! -z "${PACKAGE_INSTALL}" ]; then for i in ${PACKAGE_INSTALL}; do diff --git a/classes/rootfs_ipk.bbclass b/classes/rootfs_ipk.bbclass index 53b0162eac..9a58777ade 100644 --- a/classes/rootfs_ipk.bbclass +++ b/classes/rootfs_ipk.bbclass @@ -52,15 +52,21 @@ fakeroot rootfs_ipk_do_rootfs () { fi done ipkg-cl ${IPKG_ARGS} update - if [ ! -z "${LINGUAS_INSTALL}" ]; then - ipkg-cl ${IPKG_ARGS} install glibc-localedata-i18n - for i in ${LINGUAS_INSTALL}; do - ipkg-cl ${IPKG_ARGS} install $i - done - fi - if [ ! -z "${PACKAGE_INSTALL}" ]; then - ipkg-cl ${IPKG_ARGS} install ${PACKAGE_INSTALL} - fi + + # Uclibc builds don't provide this stuff... + # + if [ x${TARGET_OS} = "xlinux" ] || [ x${TARGET_OS} = "xlinux-gnueabi" ] ; then + if [ ! -z "${LINGUAS_INSTALL}" ]; then + ipkg-cl ${IPKG_ARGS} install glibc-localedata-i18n + for i in ${LINGUAS_INSTALL}; do + ipkg-cl ${IPKG_ARGS} install $i + done + fi + fi + if [ ! -z "${PACKAGE_INSTALL}" ]; then + ipkg-cl ${IPKG_ARGS} install ${PACKAGE_INSTALL} + fi + export D=${IMAGE_ROOTFS} export OFFLINE_ROOT=${IMAGE_ROOTFS} -- cgit v1.2.3 From 3d3a28aadb8a66111e337944ed43fd50d1357968 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Wed, 29 Aug 2007 12:46:38 +0000 Subject: kernel.bbclass: Allow machines to override the kernel-base runtime dependencies --- classes/kernel.bbclass | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'classes') diff --git a/classes/kernel.bbclass b/classes/kernel.bbclass index 0670da678d..b25275e702 100644 --- a/classes/kernel.bbclass +++ b/classes/kernel.bbclass @@ -179,7 +179,9 @@ FILES = "" FILES_kernel-image = "/boot/${KERNEL_IMAGETYPE}*" FILES_kernel-dev = "/boot/System.map* /boot/config*" RDEPENDS_kernel = "kernel-base" -RDEPENDS_kernel-base = "kernel-image" +# Allow machines to override this dependency if kernel image files are +# not wanted in images as standard +RDEPENDS_kernel-base ?= "kernel-image" PKG_kernel-image = "kernel-image-${KERNEL_VERSION}" PKG_kernel-base = "kernel-${KERNEL_VERSION}" ALLOW_EMPTY_kernel = "1" -- cgit v1.2.3 From 1230116f8d9c7e4a6c5ee6cdbaf617caa53d0ce9 Mon Sep 17 00:00:00 2001 From: Michael Lauer Date: Wed, 29 Aug 2007 14:49:03 +0000 Subject: efl_base.bbclass: presource task is no longer necessary --- classes/efl_base.bbclass | 6 ------ 1 file changed, 6 deletions(-) (limited to 'classes') diff --git a/classes/efl_base.bbclass b/classes/efl_base.bbclass index 7f170d70f2..3865441779 100644 --- a/classes/efl_base.bbclass +++ b/classes/efl_base.bbclass @@ -1,10 +1,5 @@ inherit autotools pkgconfig -#do_prepsources () { -# make clean distclean || true -#} -#addtask prepsources after do_fetch before do_unpack - SECTION = "e/libs" HOMEPAGE = "http://www.enlightenment.org" SRCNAME = "${@bb.data.getVar('PN', d, 1).replace('-native', '')}" @@ -17,4 +12,3 @@ do_stage() { PACKAGES = "${PN}-dbg ${PN} ${PN}-themes ${PN}-dev" FILES_${PN}-dev += "${bindir}/${PN}-config ${libdir}/pkgconfig/* ${libdir}/lib*.?a ${libdir}/lib*.a" - -- cgit v1.2.3 From 3aded69ae48453e4929d42994c9f66abcb2dd47e Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Thu, 30 Aug 2007 07:23:50 +0000 Subject: classes: Remove bitbake 1.6 compatibility code --- classes/base.bbclass | 47 ----------------------------------------------- classes/debian.bbclass | 3 +-- classes/image.bbclass | 1 - classes/meta.bbclass | 1 - classes/native.bbclass | 3 --- 5 files changed, 1 insertion(+), 54 deletions(-) (limited to 'classes') diff --git a/classes/base.bbclass b/classes/base.bbclass index 9998982bd1..32f7fcbe31 100644 --- a/classes/base.bbclass +++ b/classes/base.bbclass @@ -864,54 +864,7 @@ def base_after_parse(d): bb.data.setVar('PACKAGE_ARCH', "${MACHINE_ARCH}", d) return -# -# Various backwards compatibility stuff to be removed -# when we switch to bitbake 1.8.2+ as a minimum version -# -def base_oldbitbake_workarounds(d): - import bb - from bb import __version__ - from distutils.version import LooseVersion - - if (LooseVersion(__version__) > "1.8.0"): - return - - pn = bb.data.getVar('PN', d, True) - srcdate = bb.data.getVar('SRCDATE_%s' % pn, d, True) - if srcdate != None: - bb.data.setVar('SRCDATE', srcdate, d) - depends = bb.data.getVar('DEPENDS', d, False) - patchdeps = bb.data.getVar("PATCHTOOL", d, True) - if patchdeps: - patchdeps = "%s-native " % patchdeps - if not patchdeps in bb.data.getVar("PROVIDES", d, True): - depends = patchdeps + depends - if bb.data.inherits_class('rootfs_ipk', d): - depends = "ipkg-native ipkg-utils-native fakeroot-native " + depends - if bb.data.inherits_class('rootfs_deb', d): - depends = "dpkg-native apt-native fakeroot-native " + depends - if bb.data.inherits_class('image', d): - depends = "makedevs-native " + depends - for type in (bb.data.getVar('IMAGE_FSTYPES', d, True) or "").split(): - deps = bb.data.getVar('IMAGE_DEPENDS_%s' % type, d) or "" - if deps: - depends = depends + " %s" % deps - for dep in (bb.data.getVar('EXTRA_IMAGEDEPENDS', d, True) or "").split(): - depends = depends + " %s" % dep - - packages = bb.data.getVar('PACKAGES', d, True) - if packages != '': - if bb.data.inherits_class('package_ipk', d): - depends = "ipkg-utils-native " + depends - if bb.data.inherits_class('package_deb', d): - depends = "dpkg-native " + depends - if bb.data.inherits_class('package', d): - depends = "${PACKAGE_DEPENDS} fakeroot-native " + depends - - bb.data.setVar('DEPENDS', depends, d) - python () { - base_oldbitbake_workarounds(d) base_after_parse(d) } diff --git a/classes/debian.bbclass b/classes/debian.bbclass index a0c78a25f4..403c38c752 100644 --- a/classes/debian.bbclass +++ b/classes/debian.bbclass @@ -4,8 +4,7 @@ STAGING_PKGMAPS_DIR = "${STAGING_DIR}/pkgmaps/debian" # We therefore have to make sure we build all runtime packages # before building the current package to make the packages runtime # depends are correct -BUILD_ALL_DEPS = "1" - +# # 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" diff --git a/classes/image.bbclass b/classes/image.bbclass index 91e63262cd..38e19df7eb 100644 --- a/classes/image.bbclass +++ b/classes/image.bbclass @@ -3,7 +3,6 @@ inherit rootfs_${IMAGE_PKGTYPE} PACKAGES = "" # We need to recursively follow RDEPENDS and RRECOMMENDS for images -BUILD_ALL_DEPS = "1" do_rootfs[recrdeptask] = "do_package_write do_deploy do_populate_staging" # Images are generally built explicitly, do not need to be part of world. diff --git a/classes/meta.bbclass b/classes/meta.bbclass index f7d41eec26..d35c40bccd 100644 --- a/classes/meta.bbclass +++ b/classes/meta.bbclass @@ -1,5 +1,4 @@ PACKAGES = "" -BUILD_ALL_DEPS = "1" do_build[recrdeptask] = "do_build" \ No newline at end of file diff --git a/classes/native.bbclass b/classes/native.bbclass index 43000f96bf..16026f53c9 100644 --- a/classes/native.bbclass +++ b/classes/native.bbclass @@ -11,9 +11,6 @@ PACKAGE_ARCH = "${BUILD_ARCH}" # RPROVIDES becomes unnecessary. RPROVIDES = "${PN}" -# Need to resolve package RDEPENDS as well as DEPENDS -BUILD_ALL_DEPS = "1" - # Break the circular dependency as a result of DEPENDS # in package.bbclass PACKAGE_DEPENDS = "" -- cgit v1.2.3 From c55327daed509bd8ce3b81d0b154c2bb3ce65f3c Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Sat, 1 Sep 2007 15:08:16 +0000 Subject: package.bbclass: Improve strip function and convert to python (from poky) --- classes/package.bbclass | 112 ++++++++++++++++++++++-------------------------- 1 file changed, 51 insertions(+), 61 deletions(-) (limited to 'classes') diff --git a/classes/package.bbclass b/classes/package.bbclass index 95e4acd4d6..bc69dc9f8f 100644 --- a/classes/package.bbclass +++ b/classes/package.bbclass @@ -136,59 +136,57 @@ python () { bb.data.setVarFlag('do_package', 'deptask', 'do_package', d) } -# file(1) output to match to consider a file an unstripped executable -FILE_UNSTRIPPED_MATCH ?= "not stripped" -#FIXME: this should be "" when any errors are gone! -IGNORE_STRIP_ERRORS ?= "1" - -runstrip() { - # Function to strip a single file, called from RUNSTRIP in populate_packages below - # A working 'file' (one which works on the target architecture) - # is necessary for this stuff to work, hence the addition to do_package[depends] - - local ro st - - st=0 - if { file "$1" || { - oewarn "file $1: failed (forced strip)" >&2 - echo '${FILE_UNSTRIPPED_MATCH}' - } - } | grep -q '${FILE_UNSTRIPPED_MATCH}' - then - oenote "${STRIP} $1" - ro= - test -w "$1" || { - ro=1 - chmod +w "$1" - } - mkdir -p $(dirname "$1")/.debug - debugfile="$(dirname "$1")/.debug/$(basename "$1")" - '${OBJCOPY}' --only-keep-debug "$1" "$debugfile" - '${STRIP}' "$1" - st=$? - '${OBJCOPY}' --add-gnu-debuglink="$debugfile" "$1" - test -n "$ro" && chmod -w "$1" - if test $st -ne 0 - then - oewarn "runstrip: ${STRIP} $1: strip failed" >&2 - if [ x${IGNORE_STRIP_ERRORS} = x1 ] - then - #FIXME: remove this, it's for error detection - if file "$1" 2>/dev/null >&2 - then - (oefatal "${STRIP} $1: command failed" >/dev/tty) - else - (oefatal "file $1: command failed" >/dev/tty) - fi - st=0 - fi - fi - else - oenote "runstrip: skip $1" - fi - return $st -} +def runstrip(file, d): + # Function to strip a single file, called from populate_packages below + # A working 'file' (one which works on the target architecture) + # is necessary for this stuff to work, hence the addition to do_package[depends] + + import bb, os, commands, stat + + pathprefix = "export PATH=%s; " % bb.data.getVar('PATH', d, 1) + + ret, result = commands.getstatusoutput("%sfile '%s'" % (pathprefix, file)) + + if ret: + bb.error("runstrip: 'file %s' failed (forced strip)" % file) + + if "not stripped" not in result: + bb.debug(1, "runstrip: skip %s" % file) + return 0 + + strip = bb.data.getVar("STRIP", d, 1) + objcopy = bb.data.getVar("OBJCOPY", d, 1) + + newmode = None + if not os.access(file, os.W_OK): + origmode = os.stat(file)[stat.ST_MODE] + newmode = origmode | stat.S_IWRITE + os.chmod(file, newmode) + + extraflags = "" + if ".so" in file and "shared" in result: + extraflags = "--remove-section=.comment --remove-section=.note --strip-unneeded" + elif "shared" in result or "executable" in result: + extraflags = "--remove-section=.comment --remove-section=.note" + + bb.mkdirhier(os.path.join(os.path.dirname(file), ".debug")) + debugfile=os.path.join(os.path.dirname(file), ".debug", os.path.basename(file)) + + stripcmd = "'%s' %s '%s'" % (strip, extraflags, file) + bb.debug(1, "runstrip: %s" % stripcmd) + + os.system("%s'%s' --only-keep-debug '%s' '%s'" % (pathprefix, objcopy, file, debugfile)) + ret = os.system("%s%s" % (pathprefix, stripcmd)) + os.system("%s'%s' --add-gnu-debuglink='%s' '%s'" % (pathprefix, objcopy, debugfile, file)) + + if newmode: + os.chmod(file, origmode) + + if ret: + bb.error("runstrip: '%s' strip command failed" % stripcmd) + + return 1 # # Package data handling routines @@ -376,19 +374,11 @@ python populate_packages () { package_list.append(pkg) if (bb.data.getVar('INHIBIT_PACKAGE_STRIP', d, 1) != '1'): - stripfunc = "" for root, dirs, files in os.walk(dvar): for f in files: file = os.path.join(root, f) if not os.path.islink(file) and not os.path.isdir(file) and isexec(file): - stripfunc += "\trunstrip %s || st=1\n" % (file) - if not stripfunc == "": - from bb import build - localdata = bb.data.createCopy(d) - # strip - bb.data.setVar('RUNSTRIP', '\tlocal st\n\tst=0\n%s\treturn $st' % stripfunc, localdata) - bb.data.setVarFlag('RUNSTRIP', 'func', 1, localdata) - bb.build.exec_func('RUNSTRIP', localdata) + runstrip(file, d) for pkg in package_list: localdata = bb.data.createCopy(d) -- cgit v1.2.3 From eb4534607c691fa07f62c054dea9cc18baf3d9a2 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Sat, 1 Sep 2007 15:16:50 +0000 Subject: classes: Convert to PKGDATA_DIR variable (from poky) --- classes/base.bbclass | 10 +++++----- classes/package.bbclass | 8 ++++---- classes/package_ipk.bbclass | 3 --- classes/package_tar.bbclass | 7 +------ 4 files changed, 10 insertions(+), 18 deletions(-) (limited to 'classes') diff --git a/classes/base.bbclass b/classes/base.bbclass index 32f7fcbe31..23ca444fe6 100644 --- a/classes/base.bbclass +++ b/classes/base.bbclass @@ -724,7 +724,7 @@ def explode_deps(s): def packaged(pkg, d): import os, bb - return os.access(bb.data.expand('${STAGING_DIR}/pkgdata/runtime/%s.packaged' % pkg, d), os.R_OK) + return os.access(bb.data.expand('${PKGDATA_DIR}/runtime/%s.packaged' % pkg, d), os.R_OK) def read_pkgdatafile(fn): pkgdata = {} @@ -750,23 +750,23 @@ def read_pkgdatafile(fn): def has_subpkgdata(pkg, d): import bb, os - fn = bb.data.expand('${STAGING_DIR}/pkgdata/runtime/%s' % pkg, d) + fn = bb.data.expand('${PKGDATA_DIR}/runtime/%s' % pkg, d) return os.access(fn, os.R_OK) def read_subpkgdata(pkg, d): import bb, os - fn = bb.data.expand('${STAGING_DIR}/pkgdata/runtime/%s' % pkg, d) + fn = bb.data.expand('${PKGDATA_DIR}/runtime/%s' % pkg, d) return read_pkgdatafile(fn) def has_pkgdata(pn, d): import bb, os - fn = bb.data.expand('${STAGING_DIR}/pkgdata/%s' % pn, d) + fn = bb.data.expand('${PKGDATA_DIR}/%s' % pn, d) return os.access(fn, os.R_OK) def read_pkgdata(pn, d): import bb, os - fn = bb.data.expand('${STAGING_DIR}/pkgdata/%s' % pn, d) + fn = bb.data.expand('${PKGDATA_DIR}/%s' % pn, d) return read_pkgdatafile(fn) python read_subpackage_metadata () { diff --git a/classes/package.bbclass b/classes/package.bbclass index bc69dc9f8f..fe48ec6afd 100644 --- a/classes/package.bbclass +++ b/classes/package.bbclass @@ -503,13 +503,13 @@ python emit_pkgdata() { if not packages: return - data_file = bb.data.expand("${STAGING_DIR}/pkgdata/${PN}", d) + data_file = bb.data.expand("${PKGDATA_DIR}/${PN}", d) f = open(data_file, 'w') f.write("PACKAGES: %s\n" % packages) f.close() for pkg in packages.split(): - subdata_file = bb.data.expand("${STAGING_DIR}/pkgdata/runtime/%s" % pkg, d) + subdata_file = bb.data.expand("${PKGDATA_DIR}/runtime/%s" % pkg, d) sf = open(subdata_file, 'w') write_if_exists(sf, pkg, 'DESCRIPTION') write_if_exists(sf, pkg, 'RDEPENDS') @@ -528,7 +528,7 @@ python emit_pkgdata() { write_if_exists(sf, pkg, 'pkg_prerm') sf.close() } -emit_pkgdata[dirs] = "${STAGING_DIR}/pkgdata/runtime" +emit_pkgdata[dirs] = "${PKGDATA_DIR}/runtime" ldconfig_postinst_fragment() { if [ x"$D" = "x" ]; then @@ -830,7 +830,7 @@ python package_depchains() { def pkg_addrrecs(pkg, base, suffix, getname, rdepends, d): def packaged(pkg, d): - return os.access(bb.data.expand('${STAGING_DIR}/pkgdata/runtime/%s.packaged' % pkg, d), os.R_OK) + return os.access(bb.data.expand('${PKGDATA_DIR}/runtime/%s.packaged' % pkg, d), os.R_OK) #bb.note('rdepends for %s is %s' % (base, rdepends)) diff --git a/classes/package_ipk.bbclass b/classes/package_ipk.bbclass index 9200055495..b7d378b20c 100644 --- a/classes/package_ipk.bbclass +++ b/classes/package_ipk.bbclass @@ -231,8 +231,6 @@ python do_package_ipk () { if ret != 0: raise bb.build.FuncFailed("ipkg-build execution failed") - file(bb.data.expand('${STAGING_DIR}/pkgdata/runtime/%s.packaged' % pkg, d), 'w').close() - for script in ["preinst", "postinst", "prerm", "postrm", "control" ]: scriptfile = os.path.join(controldir, script) try: @@ -243,5 +241,4 @@ python do_package_ipk () { os.rmdir(controldir) except OSError: pass - del localdata } diff --git a/classes/package_tar.bbclass b/classes/package_tar.bbclass index e94e763150..ced7400ac8 100644 --- a/classes/package_tar.bbclass +++ b/classes/package_tar.bbclass @@ -78,7 +78,7 @@ python do_package_tar () { bb.data.setVar('OVERRIDES', '%s:%s' % (overrides, pkg), localdata) bb.data.update_data(localdata) -# stuff + root = bb.data.getVar('ROOT', localdata) bb.mkdirhier(root) basedir = os.path.dirname(root) @@ -97,9 +97,4 @@ python do_package_tar () { ret = os.system("tar -czvf %s %s" % (tarfn, '.')) if ret != 0: bb.error("Creation of tar %s failed." % tarfn) - - file(bb.data.expand('${STAGING_DIR}/pkgdata/runtime/%s.packaged' % pkg, d), 'w').close() - -# end stuff - del localdata } -- cgit v1.2.3 From 956f5bb2c9a104582f87b5831a71bfad349cf2b0 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Sat, 1 Sep 2007 15:25:00 +0000 Subject: multimachine.bbclass: Add PKGDATA_DIR defintion, disabled for now (from poky) --- classes/multimachine.bbclass | 3 +++ 1 file changed, 3 insertions(+) (limited to 'classes') diff --git a/classes/multimachine.bbclass b/classes/multimachine.bbclass index 4187a00ec3..0286a29515 100644 --- a/classes/multimachine.bbclass +++ b/classes/multimachine.bbclass @@ -1,6 +1,9 @@ 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}" # Find any machine specific sub packages and if present, mark the # whole package as machine specific for multimachine purposes. -- cgit v1.2.3 From cbd7193c0ca7157d04e0ad0ee9649998a9bb7527 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Sat, 1 Sep 2007 15:30:38 +0000 Subject: base.bbclass: Fix SRC_URI overrides handling, lower the priority of local file url checksum messages, correct populate_staging dependencies (from poky) --- classes/base.bbclass | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'classes') diff --git a/classes/base.bbclass b/classes/base.bbclass index 23ca444fe6..1a3739f383 100644 --- a/classes/base.bbclass +++ b/classes/base.bbclass @@ -482,8 +482,11 @@ python base_do_fetch() { (type,host,path,_,_,_) = bb.decodeurl(url) uri = "%s://%s%s" % (type,host,path) try: - if not base_chk_file(parser, pn, pv,uri, localpath, d): - bb.note("%s-%s-%s has no section, not checking URI" % (pn,pv,uri)) + if not base_chk_file(parser, pn, pv,uri, localpath, d): + if type != "file": + bb.note("%s-%s-%s has no section, not checking URI" % (pn,pv,uri)) + else: + bb.debug("%s-%s-%s has no section, not checking URI" % (pn,pv,uri)) except Exception: raise bb.build.FuncFailed("Checksum of '%s' failed" % uri) } @@ -681,7 +684,8 @@ do_populate_staging[dirs] = "${STAGING_DIR}/${TARGET_SYS}/bin ${STAGING_DIR}/${T ${STAGING_DATADIR} \ ${S} ${B}" -addtask populate_staging after do_package_write +# Could be compile but populate_staging and do_install shouldn't run at the same time +addtask populate_staging after do_install python do_populate_staging () { bb.build.exec_func('do_stage', d) @@ -847,7 +851,6 @@ def base_after_parse(d): paths = [] for p in [ "${PF}", "${P}", "${PN}", "files", "" ]: - paths.append(bb.data.expand(os.path.join("${FILE_DIRNAME}", p, "${MACHINE}"), d)) path = bb.data.expand(os.path.join("${FILE_DIRNAME}", p, "${MACHINE}"), d) if os.path.isdir(path): paths.append(path) -- cgit v1.2.3 From 3f5c5adb8df219b69ad3a3788eee3a6384c249a0 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Sat, 1 Sep 2007 16:55:44 +0000 Subject: rootfs_{deb|ipk}.bbclass: Fix whitespace damage, remove bashisms, sync with poky --- classes/rootfs_deb.bbclass | 38 ++++++++++++++++++++------------------ classes/rootfs_ipk.bbclass | 41 ++++++++++++++++++++++------------------- 2 files changed, 42 insertions(+), 37 deletions(-) (limited to 'classes') diff --git a/classes/rootfs_deb.bbclass b/classes/rootfs_deb.bbclass index 32b1c57f1a..35e29b3e45 100644 --- a/classes/rootfs_deb.bbclass +++ b/classes/rootfs_deb.bbclass @@ -3,10 +3,12 @@ # do_rootfs[depends] += "dpkg-native:do_populate_staging apt-native:do_populate_staging" +do_rootfs[recrdeptask] += "do_package_write" fakeroot rootfs_deb_do_rootfs () { set +e - mkdir -p ${IMAGE_ROOTFS}/var/dpkg/{info,updates} + mkdir -p ${IMAGE_ROOTFS}/var/dpkg/info + mkdir -p ${IMAGE_ROOTFS}/var/dpkg/updates rm -f ${STAGING_DIR}/etc/apt/sources.list.rev rm -f ${STAGING_DIR}/etc/apt/preferences @@ -53,26 +55,26 @@ fakeroot rootfs_deb_do_rootfs () { _getflag () { cat ${IMAGE_ROOTFS}/var/dpkg/status | sed -n -e "/^Package: $2\$/{n; s/Status: install ok .*/$1/; p}" } - - if [ x${TARGET_OS} = "xlinux" ] || [ x${TARGET_OS} = "xlinux-gnueabi" ] ; then - if [ ! -z "${LINGUAS_INSTALL}" ]; then - apt-get install glibc-localedata-i18n --force-yes --allow-unauthenticated - if [ $? -ne 0 ]; then - exit $? - fi - for i in ${LINGUAS_INSTALL}; do - apt-get install $i --force-yes --allow-unauthenticated - if [ $? -ne 0 ]; then - exit $? - fi - done - fi - fi + + if [ x${TARGET_OS} = "xlinux" ] || [ x${TARGET_OS} = "xlinux-gnueabi" ] ; then + if [ ! -z "${LINGUAS_INSTALL}" ]; then + apt-get install glibc-localedata-i18n --force-yes --allow-unauthenticated + if [ $? -ne 0 ]; then + exit 1 + fi + for i in ${LINGUAS_INSTALL}; do + apt-get install $i --force-yes --allow-unauthenticated + if [ $? -ne 0 ]; then + exit 1 + fi + done + fi + fi if [ ! -z "${PACKAGE_INSTALL}" ]; then for i in ${PACKAGE_INSTALL}; do apt-get install $i --force-yes --allow-unauthenticated - if [ $? -eq 1 ]; then + if [ $? -ne 0 ]; then exit 1 fi find ${IMAGE_ROOTFS} -name \*.dpkg-new | for i in `cat`; do @@ -132,7 +134,7 @@ rootfs_deb_log_check() { echo -e "log_check: Matched keyword: [$keyword_die]\n" echo "$lf_txt" | grep -v log_check | grep -C 5 -i "$keyword_die" echo "" - do_exit=1 + do_exit=1 fi done test "$do_exit" = 1 && exit 1 diff --git a/classes/rootfs_ipk.bbclass b/classes/rootfs_ipk.bbclass index 9a58777ade..e445c0dd07 100644 --- a/classes/rootfs_ipk.bbclass +++ b/classes/rootfs_ipk.bbclass @@ -6,6 +6,7 @@ # do_rootfs[depends] += "ipkg-native:do_populate_staging ipkg-utils-native:do_populate_staging" +do_rootfs[recrdeptask] += "do_package_write" IPKG_ARGS = "-f ${T}/ipkg.conf -o ${IMAGE_ROOTFS} ${@base_conditional("PACKAGE_INSTALL_NO_DEPS", "1", "-nodeps", "", d)}" @@ -17,10 +18,10 @@ rootfs_ipk_do_indexes () { ipkgarchs="${PACKAGE_ARCHS}" - if [ -z "${DEPLOY_KEEP_PACKAGES}" ]; then - touch ${DEPLOY_DIR_IPK}/Packages - ipkg-make-index -r ${DEPLOY_DIR_IPK}/Packages -p ${DEPLOY_DIR_IPK}/Packages -l ${DEPLOY_DIR_IPK}/Packages.filelist -m ${DEPLOY_DIR_IPK} - fi + if [ -z "${DEPLOY_KEEP_PACKAGES}" ]; then + touch ${DEPLOY_DIR_IPK}/Packages + ipkg-make-index -r ${DEPLOY_DIR_IPK}/Packages -p ${DEPLOY_DIR_IPK}/Packages -l ${DEPLOY_DIR_IPK}/Packages.filelist -m ${DEPLOY_DIR_IPK} + fi for arch in $ipkgarchs; do if [ -z "${DEPLOY_KEEP_PACKAGES}" ]; then @@ -52,21 +53,19 @@ fakeroot rootfs_ipk_do_rootfs () { fi done ipkg-cl ${IPKG_ARGS} update - - # Uclibc builds don't provide this stuff... - # - if [ x${TARGET_OS} = "xlinux" ] || [ x${TARGET_OS} = "xlinux-gnueabi" ] ; then - if [ ! -z "${LINGUAS_INSTALL}" ]; then - ipkg-cl ${IPKG_ARGS} install glibc-localedata-i18n - for i in ${LINGUAS_INSTALL}; do - ipkg-cl ${IPKG_ARGS} install $i - done - fi - fi - if [ ! -z "${PACKAGE_INSTALL}" ]; then - ipkg-cl ${IPKG_ARGS} install ${PACKAGE_INSTALL} - fi - + + # Uclibc builds don't provide this stuff... + if [ x${TARGET_OS} = "xlinux" ] || [ x${TARGET_OS} = "xlinux-gnueabi" ] ; then + if [ ! -z "${LINGUAS_INSTALL}" ]; then + ipkg-cl ${IPKG_ARGS} install glibc-localedata-i18n + for i in ${LINGUAS_INSTALL}; do + ipkg-cl ${IPKG_ARGS} install $i + done + fi + fi + if [ ! -z "${PACKAGE_INSTALL}" ]; then + ipkg-cl ${IPKG_ARGS} install ${PACKAGE_INSTALL} + fi export D=${IMAGE_ROOTFS} export OFFLINE_ROOT=${IMAGE_ROOTFS} @@ -112,3 +111,7 @@ rootfs_ipk_log_check() { test "$do_exit" = 1 && exit 1 true } + +remove_packaging_data_files() { + rm -rf ${IMAGE_ROOTFS}/usr/lib/ipkg/ +} -- cgit v1.2.3 From 344ad5e784560c0e88bc8c73ee6fcc2d96e1f56d Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Sat, 1 Sep 2007 16:57:37 +0000 Subject: images: Clean up image .bb files, moving functionality to image.bbclass (LICENCE default, setup of RDEPENDS and default IMAGE_BASENAME) --- classes/image.bbclass | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'classes') diff --git a/classes/image.bbclass b/classes/image.bbclass index 38e19df7eb..c1eaf9ffe2 100644 --- a/classes/image.bbclass +++ b/classes/image.bbclass @@ -1,6 +1,11 @@ inherit rootfs_${IMAGE_PKGTYPE} +LICENSE = "MIT" PACKAGES = "" +RDEPENDS += "${IMAGE_INSTALL}" + +export IMAGE_BASENAME ?= "${PN}" +export PACKAGE_INSTALL ?= "${IMAGE_INSTALL}" # We need to recursively follow RDEPENDS and RRECOMMENDS for images do_rootfs[recrdeptask] = "do_package_write do_deploy do_populate_staging" @@ -50,15 +55,14 @@ def get_devtable_list(d): return str IMAGE_POSTPROCESS_COMMAND ?= "" +MACHINE_POSTPROCESS_COMMAND ?= "" +ROOTFS_POSTPROCESS_COMMAND ?= "" # some default locales IMAGE_LINGUAS ?= "de-de fr-fr en-gb" LINGUAS_INSTALL = "${@" ".join(map(lambda s: "locale-base-%s" % s, bb.data.getVar('IMAGE_LINGUAS', d, 1).split()))}" -ROOTFS_POSTPROCESS_COMMAND ?= "" -MACHINE_POSTPROCESS_COMMAND ?= "" - do_rootfs[nostamp] = "1" do_rootfs[dirs] = "${TOPDIR}" do_build[nostamp] = "1" -- cgit v1.2.3 From c2ac91ada421a7af725524bb42024249d82c64a5 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Sat, 1 Sep 2007 17:07:03 +0000 Subject: native.bbclass: PACKAGE_DEPENDS no longer need be unset, add extra options to PKG_CONFIG_PATH if EXTRA_NATIVE_PKGCONFIG_PATH is set (from poky) --- classes/native.bbclass | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'classes') diff --git a/classes/native.bbclass b/classes/native.bbclass index 16026f53c9..104d5a49da 100644 --- a/classes/native.bbclass +++ b/classes/native.bbclass @@ -11,10 +11,6 @@ PACKAGE_ARCH = "${BUILD_ARCH}" # RPROVIDES becomes unnecessary. RPROVIDES = "${PN}" -# Break the circular dependency as a result of DEPENDS -# in package.bbclass -PACKAGE_DEPENDS = "" - TARGET_ARCH = "${BUILD_ARCH}" TARGET_OS = "${BUILD_OS}" TARGET_VENDOR = "${BUILD_VENDOR}" @@ -95,3 +91,5 @@ do_stage () { do_install () { true } + +PKG_CONFIG_PATH .= "${EXTRA_NATIVE_PKGCONFIG_PATH}" -- cgit v1.2.3 From 5d6952960f72d834c5f350055a2a07ed4d98ef84 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Sat, 1 Sep 2007 17:07:36 +0000 Subject: image.bbclass: Append to do_rootfs[recrdeptask] --- classes/image.bbclass | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'classes') diff --git a/classes/image.bbclass b/classes/image.bbclass index c1eaf9ffe2..04e26e4b35 100644 --- a/classes/image.bbclass +++ b/classes/image.bbclass @@ -8,7 +8,7 @@ export IMAGE_BASENAME ?= "${PN}" export PACKAGE_INSTALL ?= "${IMAGE_INSTALL}" # We need to recursively follow RDEPENDS and RRECOMMENDS for images -do_rootfs[recrdeptask] = "do_package_write do_deploy do_populate_staging" +do_rootfs[recrdeptask] += "do_deploy do_populate_staging" # Images are generally built explicitly, do not need to be part of world. EXCLUDE_FROM_WORLD = "1" -- cgit v1.2.3 From 037acf7547f75c72ab10a1af7662182440da6da2 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Sat, 1 Sep 2007 17:13:47 +0000 Subject: sdk.bbclass: Use variables from bitbake.conf (from Poky) --- classes/sdk.bbclass | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'classes') diff --git a/classes/sdk.bbclass b/classes/sdk.bbclass index 0050b2e48e..0950e3293b 100644 --- a/classes/sdk.bbclass +++ b/classes/sdk.bbclass @@ -2,8 +2,6 @@ # or indirectly via dependency. No need to be in 'world'. EXCLUDE_FROM_WORLD = "1" -SDK_NAME = "${DISTRO}/${TARGET_ARCH}" - OLD_PACKAGE_ARCH := ${PACKAGE_ARCH} PACKAGE_ARCH = "${BUILD_ARCH}-${OLD_PACKAGE_ARCH}-sdk" @@ -18,7 +16,7 @@ CFLAGS = "${BUILD_CFLAGS}" CXXFLAGS = "${BUILD_CFLAGS}" LDFLAGS = "${BUILD_LDFLAGS}" -prefix = "/usr/local/${SDK_NAME}" +prefix = "${SDK_PREFIX}" exec_prefix = "${prefix}" base_prefix = "${exec_prefix}" -- cgit v1.2.3 From e4d7738fbc91777724b46be25d401c08ad31d9c1 Mon Sep 17 00:00:00 2001 From: Koen Kooi Date: Sat, 1 Sep 2007 20:11:50 +0000 Subject: rootfs_deb: make sure directories exist before trying to symlink them --- classes/rootfs_deb.bbclass | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) (limited to 'classes') diff --git a/classes/rootfs_deb.bbclass b/classes/rootfs_deb.bbclass index 35e29b3e45..6db02fa150 100644 --- a/classes/rootfs_deb.bbclass +++ b/classes/rootfs_deb.bbclass @@ -112,9 +112,17 @@ fakeroot rootfs_deb_do_rootfs () { if [ -e ${IMAGE_ROOTFS}/usr/dpkg/alternatives ]; then rmdir ${IMAGE_ROOTFS}/usr/dpkg/alternatives fi - ln -s /usr/lib/ipkg/alternatives ${IMAGE_ROOTFS}/usr/dpkg/alternatives - ln -s /usr/dpkg/info ${IMAGE_ROOTFS}/usr/lib/ipkg/info - ln -s /usr/dpkg/status ${IMAGE_ROOTFS}/usr/lib/ipkg/status + if [ ! -e ${IMAGE_ROOTFS}/usr/lib/ipkg ] ; then + mkdir -p ${IMAGE_ROOTFS}/usr/lib/ipkg + fi + + if [ ! -e ${IMAGE_ROOTFS}/etc/ipkg ] ; then + mkdir -p ${IMAGE_ROOTFS}/etc/ipkg + fi + + ln -sf /usr/lib/ipkg/alternatives ${IMAGE_ROOTFS}/usr/dpkg/alternatives + ln -sf /usr/dpkg/info ${IMAGE_ROOTFS}/usr/lib/ipkg/info + ln -sf /usr/dpkg/status ${IMAGE_ROOTFS}/usr/lib/ipkg/status ${ROOTFS_POSTPROCESS_COMMAND} -- cgit v1.2.3 From a932aef56158bdb5922df3d4c3cfd8564759a920 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Sat, 1 Sep 2007 23:01:27 +0000 Subject: package_ipk.bbclass: Sync with poky for locking, code to add package_write_ipk task (not activated yet), change OE: field to use PN (not P), cleanups and conf and index generation functions --- classes/package_ipk.bbclass | 84 +++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 78 insertions(+), 6 deletions(-) (limited to 'classes') diff --git a/classes/package_ipk.bbclass b/classes/package_ipk.bbclass index b7d378b20c..8f963b4dd5 100644 --- a/classes/package_ipk.bbclass +++ b/classes/package_ipk.bbclass @@ -6,6 +6,9 @@ BOOTSTRAP_EXTRA_RDEPENDS += "ipkg-collateral ipkg" PACKAGE_WRITE_FUNCS += "do_package_ipk" IMAGE_PKGTYPE ?= "ipk" +IPKGCONF_TARGET = "${STAGING_ETCDIR_NATIVE}/ipkg.conf" +IPKGCONF_SDK = "${STAGING_ETCDIR_NATIVE}/ipkg-sdk.conf" + python package_ipk_fn () { from bb import data bb.data.setVar('PKGFN', bb.data.getVar('PKG',d), d) @@ -53,7 +56,7 @@ python package_ipk_install () { ret = os.system('ipkg-make-index -p %s %s ' % (os.path.join(ipkdir, "Packages"), ipkdir)) if (ret != 0 ): raise bb.build.FuncFailed - f=open(os.path.join(tmpdir, "stamps" ,"do_packages"),"w") + f=open(os.path.join(tmpdir, "stamps", "do_packages"),"w") f.close() ret = os.system('ipkg-cl -o %s -f %s update' % (rootfs, conffile)) @@ -62,10 +65,53 @@ python package_ipk_install () { raise bb.build.FuncFailed } +# +# Update the Packages index files in ${DEPLOY_DIR_IPK} +# +package_update_index_ipk () { + set -x + + ipkgarchs="${PACKAGE_ARCHS}" + + if [ ! -z "${DEPLOY_KEEP_PACKAGES}" ]; then + return + fi + + touch ${DEPLOY_DIR_IPK}/Packages + ipkg-make-index -r ${DEPLOY_DIR_IPK}/Packages -p ${DEPLOY_DIR_IPK}/Packages -l ${DEPLOY_DIR_IPK}/Packages.filelist -m ${DEPLOY_DIR_IPK} + + for arch in $ipkgarchs; do + if [ -e ${DEPLOY_DIR_IPK}/$arch/ ] ; then + touch ${DEPLOY_DIR_IPK}/$arch/Packages + ipkg-make-index -r ${DEPLOY_DIR_IPK}/$arch/Packages -p ${DEPLOY_DIR_IPK}/$arch/Packages -l ${DEPLOY_DIR_IPK}/$arch/Packages.filelist -m ${DEPLOY_DIR_IPK}/$arch/ + fi + done +} + +# +# Generate an ipkg conf file ${IPKGCONF_TARGET} suitable for use against +# the target system and an ipkg conf file ${IPKGCONF_SDK} suitable for +# use against the host system in sdk builds +# +package_generate_ipkg_conf () { + mkdir -p ${STAGING_ETCDIR_NATIVE}/ + echo "src oe file:${DEPLOY_DIR_IPK}" > ${IPKGCONF_TARGET} + echo "src oe file:${DEPLOY_DIR_IPK}" > ${IPKGCONF_SDK} + ipkgarchs="${PACKAGE_ARCHS}" + priority=1 + for arch in $ipkgarchs; do + echo "arch $arch $priority" >> ${IPKGCONF_TARGET} + echo "arch ${BUILD_ARCH}-$arch-sdk $priority" >> ${IPKGCONF_SDK} + priority=$(expr $priority + 5) + if [ -e ${DEPLOY_DIR_IPK}/$arch/Packages ] ; then + echo "src oe-$arch file:${DEPLOY_DIR_IPK}/$arch" >> ${IPKGCONF_TARGET} + echo "src oe-$arch file:${DEPLOY_DIR_IPK}/$arch" >> ${IPKGCONF_SDK} + fi + done +} + python do_package_ipk () { - import copy # to back up env data - import sys - import re + import sys, re, fcntl, copy workdir = bb.data.getVar('WORKDIR', d, 1) if not workdir: @@ -96,16 +142,27 @@ python do_package_ipk () { tmpdir = bb.data.getVar('TMPDIR', d, 1) # Invalidate the packages file if os.access(os.path.join(tmpdir, "stamps", "do_packages"),os.R_OK): - os.unlink(os.path.join(tmpdir, "stamps" ,"do_packages")) + os.unlink(os.path.join(tmpdir, "stamps", "do_packages")) if packages == []: bb.debug(1, "No packages; nothing to do") return + def lockfile(name): + lf = open(name, "a+") + fcntl.flock(lf.fileno(), fcntl.LOCK_EX) + return lf + + def unlockfile(lf): + fcntl.flock(lf.fileno(), fcntl.LOCK_UN) + lf.close + for pkg in packages.split(): localdata = bb.data.createCopy(d) root = "%s/install/%s" % (workdir, pkg) + lf = lockfile(root + ".lock") + bb.data.setVar('ROOT', '', localdata) bb.data.setVar('ROOT_%s' % pkg, root, localdata) pkgname = bb.data.getVar('PKG_%s' % pkg, localdata, 1) @@ -134,6 +191,7 @@ python do_package_ipk () { if not g and bb.data.getVar('ALLOW_EMPTY', localdata) != "1": from bb import note note("Not creating empty archive for %s-%s-%s" % (pkg, bb.data.getVar('PV', localdata, 1), bb.data.getVar('PR', localdata, 1))) + unlockfile(lf) continue controldir = os.path.join(root, 'CONTROL') @@ -154,7 +212,7 @@ python do_package_ipk () { fields.append(["Priority: %s\n", ['PRIORITY']]) fields.append(["Maintainer: %s\n", ['MAINTAINER']]) fields.append(["Architecture: %s\n", ['PACKAGE_ARCH']]) - fields.append(["OE: %s\n", ['P']]) + fields.append(["OE: %s\n", ['PN']]) fields.append(["Homepage: %s\n", ['HOMEPAGE']]) def pullData(l, d): @@ -241,4 +299,18 @@ python do_package_ipk () { os.rmdir(controldir) except OSError: pass + unlockfile(lf) } + +python () { + import bb + if bb.data.getVar('PACKAGES', d, True) != '': + bb.data.setVarFlag('do_package_write_ipk', 'depends', 'ipkg-utils-native:do_populate_staging fakeroot-native:do_populate_staging', d) +} + +python do_package_write_ipk () { + bb.build.exec_func("read_subpackage_metadata", d) + bb.build.exec_func("do_package_ipk", d) +} +do_package_write_ipk[dirs] = "${D}" + -- cgit v1.2.3 From 1ca50dd988f1cadd4984be6cc3db48e8c9a35b16 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Sat, 1 Sep 2007 23:02:56 +0000 Subject: rootfs_ipk.bbclass: Convert to use package_ipk function --- classes/rootfs_ipk.bbclass | 39 ++++----------------------------------- 1 file changed, 4 insertions(+), 35 deletions(-) (limited to 'classes') diff --git a/classes/rootfs_ipk.bbclass b/classes/rootfs_ipk.bbclass index e445c0dd07..8154318311 100644 --- a/classes/rootfs_ipk.bbclass +++ b/classes/rootfs_ipk.bbclass @@ -8,50 +8,19 @@ do_rootfs[depends] += "ipkg-native:do_populate_staging ipkg-utils-native:do_populate_staging" do_rootfs[recrdeptask] += "do_package_write" -IPKG_ARGS = "-f ${T}/ipkg.conf -o ${IMAGE_ROOTFS} ${@base_conditional("PACKAGE_INSTALL_NO_DEPS", "1", "-nodeps", "", d)}" +IPKG_ARGS = "-f ${IPKGCONF_TARGET} -o ${IMAGE_ROOTFS} ${@base_conditional("PACKAGE_INSTALL_NO_DEPS", "1", "-nodeps", "", d)}" DISTRO_EXTRA_RDEPENDS += " ipkg ipkg-collateral " PACKAGE_INSTALL_NO_DEPS ?= "0" -rootfs_ipk_do_indexes () { - set -x - - ipkgarchs="${PACKAGE_ARCHS}" - - if [ -z "${DEPLOY_KEEP_PACKAGES}" ]; then - touch ${DEPLOY_DIR_IPK}/Packages - ipkg-make-index -r ${DEPLOY_DIR_IPK}/Packages -p ${DEPLOY_DIR_IPK}/Packages -l ${DEPLOY_DIR_IPK}/Packages.filelist -m ${DEPLOY_DIR_IPK} - fi - - for arch in $ipkgarchs; do - if [ -z "${DEPLOY_KEEP_PACKAGES}" ]; then - if [ -e ${DEPLOY_DIR_IPK}/$arch/ ] ; then - touch ${DEPLOY_DIR_IPK}/$arch/Packages - ipkg-make-index -r ${DEPLOY_DIR_IPK}/$arch/Packages -p ${DEPLOY_DIR_IPK}/$arch/Packages -l ${DEPLOY_DIR_IPK}/$arch/Packages.filelist -m ${DEPLOY_DIR_IPK}/$arch/ - fi - fi - done -} - fakeroot rootfs_ipk_do_rootfs () { set -x - rootfs_ipk_do_indexes + package_update_index_ipk + package_generate_ipkg_conf mkdir -p ${T} - #Add deploy/ipk as well for backward compat - echo "src oe file:${DEPLOY_DIR_IPK}" > ${T}/ipkg.conf - ipkgarchs="${PACKAGE_ARCHS}" - - priority=1 - for arch in $ipkgarchs; do - echo "arch $arch $priority" >> ${T}/ipkg.conf - priority=$(expr $priority + 5) - if [ -e ${DEPLOY_DIR_IPK}/$arch/Packages ] ; then - echo "src oe-$arch file:${DEPLOY_DIR_IPK}/$arch" >> ${T}/ipkg.conf - fi - done ipkg-cl ${IPKG_ARGS} update # Uclibc builds don't provide this stuff... @@ -71,7 +40,7 @@ fakeroot rootfs_ipk_do_rootfs () { export OFFLINE_ROOT=${IMAGE_ROOTFS} export IPKG_OFFLINE_ROOT=${IMAGE_ROOTFS} mkdir -p ${IMAGE_ROOTFS}/etc/ipkg/ - grep "^arch" ${T}/ipkg.conf >${IMAGE_ROOTFS}/etc/ipkg/arch.conf + grep "^arch" ${IPKGCONF_TARGET} >${IMAGE_ROOTFS}/etc/ipkg/arch.conf for i in ${IMAGE_ROOTFS}${libdir}/ipkg/info/*.preinst; do if [ -f $i ] && ! sh $i; then -- cgit v1.2.3 From 6d53edfbc3cc84c6ebf88de33fc4fa462ccce825 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Sat, 1 Sep 2007 23:39:49 +0000 Subject: sdk.bbclass: Remove uneeded code --- classes/sdk.bbclass | 20 -------------------- 1 file changed, 20 deletions(-) (limited to 'classes') diff --git a/classes/sdk.bbclass b/classes/sdk.bbclass index 0950e3293b..8067798000 100644 --- a/classes/sdk.bbclass +++ b/classes/sdk.bbclass @@ -24,23 +24,3 @@ FILES_${PN} = "${prefix}" FILES_${PN}-dbg += "${prefix}/bin/.debug \ ${prefix}/sbin/.debug \ " - -sdk_ipk_do_indexes () { - set -x - - ipkgarchs="${PACKAGE_ARCHS}" - - if [ -z "${DEPLOY_KEEP_PACKAGES}" ]; then - touch ${DEPLOY_DIR_IPK}/Packages - ipkg-make-index -r ${DEPLOY_DIR_IPK}/Packages -p ${DEPLOY_DIR_IPK}/Packages -l ${DEPLOY_DIR_IPK}/Packages.filelist -m ${DEPLOY_DIR_IPK} - fi - - for arch in $ipkgarchs; do - if [ -z "${DEPLOY_KEEP_PACKAGES}" ]; then - if [ -e ${DEPLOY_DIR_IPK}/${BUILD_ARCH}-$arch-sdk/ ] ; then - touch ${DEPLOY_DIR_IPK}/${BUILD_ARCH}-$arch-sdk/Packages - ipkg-make-index -r ${DEPLOY_DIR_IPK}/${BUILD_ARCH}-$arch-sdk/Packages -p ${DEPLOY_DIR_IPK}/${BUILD_ARCH}-$arch-sdk/Packages -l ${DEPLOY_DIR_IPK}/${BUILD_ARCH}-$arch-sdk/Packages.filelist -m ${DEPLOY_DIR_IPK}/${BUILD_ARCH}-$arch-sdk/ - fi - fi - done -} -- cgit v1.2.3 From 60ee4a5f135a084051d75dc34ac8987c31703d80 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Sat, 1 Sep 2007 23:40:47 +0000 Subject: package_x.bbclass: Sync with poky preparing for individual package writing tasks --- classes/package_deb.bbclass | 33 +++++++++++++++++++++++++++++---- classes/package_rpm.bbclass | 17 +++++++++++++++-- classes/package_tar.bbclass | 14 ++++++++++++++ 3 files changed, 58 insertions(+), 6 deletions(-) (limited to 'classes') diff --git a/classes/package_deb.bbclass b/classes/package_deb.bbclass index c322af1f15..94db9238c2 100644 --- a/classes/package_deb.bbclass +++ b/classes/package_deb.bbclass @@ -64,9 +64,7 @@ python do_package_deb_install () { } python do_package_deb () { - import copy # to back up env data - import sys - import re + import sys, re, fcntl, copy workdir = bb.data.getVar('WORKDIR', d, 1) if not workdir: @@ -99,10 +97,21 @@ python do_package_deb () { bb.debug(1, "No packages; nothing to do") return + def lockfile(name): + lf = open(name, "a+") + fcntl.flock(lf.fileno(), fcntl.LOCK_EX) + return lf + + def unlockfile(lf): + fcntl.flock(lf.fileno(), fcntl.LOCK_UN) + lf.close + for pkg in packages.split(): localdata = bb.data.createCopy(d) root = "%s/install/%s" % (workdir, pkg) + lf = lockfile(root + ".lock") + bb.data.setVar('ROOT', '', localdata) bb.data.setVar('ROOT_%s' % pkg, root, localdata) pkgname = bb.data.getVar('PKG_%s' % pkg, localdata, 1) @@ -133,6 +142,7 @@ python do_package_deb () { if not g and bb.data.getVar('ALLOW_EMPTY', localdata) != "1": from bb import note note("Not creating empty archive for %s-%s-%s" % (pkg, bb.data.getVar('PV', localdata, 1), bb.data.getVar('PR', localdata, 1))) + unlockfile(lf) continue controldir = os.path.join(root, 'DEBIAN') bb.mkdirhier(controldir) @@ -246,5 +256,20 @@ python do_package_deb () { os.rmdir(controldir) except OSError: pass - del localdata + + unlockfile(lf) } + +python () { + import bb + if bb.data.getVar('PACKAGES', d, True) != '': + bb.data.setVarFlag('do_package_write_deb', 'depends', 'dpkg-native:do_populate_staging fakeroot-native:do_populate_staging', d) +} + +python do_package_write_deb () { + bb.build.exec_func("read_subpackage_metadata", d) + 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 + diff --git a/classes/package_rpm.bbclass b/classes/package_rpm.bbclass index 4955792916..bd4a0c2798 100644 --- a/classes/package_rpm.bbclass +++ b/classes/package_rpm.bbclass @@ -54,7 +54,6 @@ python write_specfile() { except OSError: raise bb.build.FuncFailed("unable to open spec file for writing.") -# fd = sys.__stdout__ fd = specfile for var in out_vartranslate.keys(): if out_vartranslate[var][0] == "%": @@ -123,7 +122,7 @@ python do_package_rpm () { bb.data.setVar('OVERRIDES', '%s:%s' % (overrides, pkg), localdata) bb.data.update_data(localdata) -# stuff + root = bb.data.getVar('ROOT', localdata) basedir = os.path.dirname(root) pkgoutdir = outdir @@ -132,3 +131,17 @@ python do_package_rpm () { bb.build.exec_func('write_specfile', localdata) del localdata } + +python () { + import bb + if bb.data.getVar('PACKAGES', d, True) != '': + bb.data.setVarFlag('do_package_write_rpm', 'depends', 'rpm-native:do_populate_staging', d) +} + + +python do_package_write_rpm () { + bb.build.exec_func("read_subpackage_metadata", d) + bb.build.exec_func("do_package_rpm", d) +} +do_package_write_rpm[dirs] = "${D}" +#addtask package_write_rpm before do_build after do_package diff --git a/classes/package_tar.bbclass b/classes/package_tar.bbclass index ced7400ac8..a56f2e2b00 100644 --- a/classes/package_tar.bbclass +++ b/classes/package_tar.bbclass @@ -98,3 +98,17 @@ python do_package_tar () { if ret != 0: bb.error("Creation of tar %s failed." % tarfn) } + +python () { + import bb + if bb.data.getVar('PACKAGES', d, True) != '': + bb.data.setVarFlag('do_package_write_tar', 'depends', 'tar-native:do_populate_staging', d) +} + + +python do_package_write_tar () { + bb.build.exec_func("read_subpackage_metadata", d) + bb.build.exec_func("do_package_tar", d) +} +do_package_write_tar[dirs] = "${D}" +#addtask package_write_tar before do_build after do_package -- cgit v1.2.3 From ba5230ce01bc589f48a37792b8b33b1e618806ff Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Sun, 2 Sep 2007 00:10:58 +0000 Subject: package_ipk.bbclass: Fix whitespace --- classes/package_ipk.bbclass | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'classes') diff --git a/classes/package_ipk.bbclass b/classes/package_ipk.bbclass index 8f963b4dd5..3468680882 100644 --- a/classes/package_ipk.bbclass +++ b/classes/package_ipk.bbclass @@ -161,7 +161,7 @@ python do_package_ipk () { localdata = bb.data.createCopy(d) root = "%s/install/%s" % (workdir, pkg) - lf = lockfile(root + ".lock") + lf = lockfile(root + ".lock") bb.data.setVar('ROOT', '', localdata) bb.data.setVar('ROOT_%s' % pkg, root, localdata) -- cgit v1.2.3 From a18bd6c9aa2b5c246860a89a7cedffa3825fccef Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Sun, 2 Sep 2007 09:59:50 +0000 Subject: gnome-common: 2.4.0 -> 2.18.0 + associated cleanup (from Poky) --- classes/gnome.bbclass | 2 -- 1 file changed, 2 deletions(-) (limited to 'classes') diff --git a/classes/gnome.bbclass b/classes/gnome.bbclass index 8643989b73..56233578aa 100644 --- a/classes/gnome.bbclass +++ b/classes/gnome.bbclass @@ -13,8 +13,6 @@ FILES_${PN} += "${datadir}/application-registry ${datadir}/mime-info \ inherit autotools pkgconfig gconf -EXTRA_AUTORECONF += "-I ${STAGING_DIR}/${HOST_SYS}/share/aclocal/gnome2-macros" - gnome_stage_includes() { autotools_stage_includes } -- cgit v1.2.3 From 880610a3aada4162a921a77977d1d5d6dfc95d2a Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Sun, 2 Sep 2007 10:24:06 +0000 Subject: Fix PKG_CONFIG_PATH references which should be PKG_CONFIG_DIR --- classes/gtk-binver.bbclass | 2 +- classes/pkgconfig.bbclass | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'classes') diff --git a/classes/gtk-binver.bbclass b/classes/gtk-binver.bbclass index 8398cc5424..52082492e7 100644 --- a/classes/gtk-binver.bbclass +++ b/classes/gtk-binver.bbclass @@ -1,7 +1,7 @@ def gtkbinver_find(d): import bb try: - for line in file( "%s/gtk+-2.0.pc" % bb.data.getVar('PKG_CONFIG_PATH', d, 1) ).readlines(): + for line in file( "%s/gtk+-2.0.pc" % bb.data.getVar('PKG_CONFIG_DIR', d, 1) ).readlines(): if line.startswith( "gtk_binary_version" ): # bb.note( "gtk_binary_version = '%s'" % line.split("=")[1].strip() ) return line.split("=")[1].strip() diff --git a/classes/pkgconfig.bbclass b/classes/pkgconfig.bbclass index 3256977517..c795c8a709 100644 --- a/classes/pkgconfig.bbclass +++ b/classes/pkgconfig.bbclass @@ -31,7 +31,7 @@ do_install_append () { do_stage_append () { for pc in `find ${S} -name '*.pc' -type f | grep -v -- '-uninstalled.pc$'`; do pcname=`basename $pc` - install -d ${PKG_CONFIG_PATH} - cat $pc | sed ${@get_pkgconfig_mangle(d)} -e 's:${D}${libdir}\S*:${STAGING_LIBDIR}:g' -e 's:${D}${prefix}/include\S*:${STAGING_INCDIR}:g' > ${PKG_CONFIG_PATH}/$pcname + install -d ${PKG_CONFIG_DIR} + cat $pc | sed ${@get_pkgconfig_mangle(d)} -e 's:${D}${libdir}\S*:${STAGING_LIBDIR}:g' -e 's:${D}${prefix}/include\S*:${STAGING_INCDIR}:g' > ${PKG_CONFIG_DIR}/$pcname done } -- cgit v1.2.3 From 7217b0c316ec2caacf1d1d7d8eeb539f86dc16e0 Mon Sep 17 00:00:00 2001 From: Holger Freyther Date: Mon, 3 Sep 2007 12:22:20 +0000 Subject: classes/{qmake*,qt4x11}.bbclass: Add a qmake2.bbclass to use qmake version two Add a qmake2.bbclass which currently takes over the role of qt4x11.bbclass with setting the QTDIR, MOC, UIC properly. qmake2 and qmake now share qmake-base.bbclass this is why some var assignments and functions have been moved around. Make webkit-gtk use qmake2 to eliminate the Qt3 and Qt4/X11 dependency. --- classes/qmake-base.bbclass | 66 ++++++++++++++++++++++++++++++++++++++-------- classes/qmake.bbclass | 65 ++++++++------------------------------------- classes/qmake2.bbclass | 20 ++++++++++++++ classes/qt4x11.bbclass | 19 ++----------- 4 files changed, 88 insertions(+), 82 deletions(-) create mode 100644 classes/qmake2.bbclass (limited to 'classes') diff --git a/classes/qmake-base.bbclass b/classes/qmake-base.bbclass index b623b34aaa..52f6d830a0 100644 --- a/classes/qmake-base.bbclass +++ b/classes/qmake-base.bbclass @@ -1,4 +1,3 @@ -DEPENDS_prepend = "qmake-native " OE_QMAKE_PLATFORM = "${TARGET_OS}-oe-