diff options
-rw-r--r-- | meta/packages/qemu/qemu-gcc3-check.inc | 20 | ||||
-rw-r--r-- | meta/packages/qemu/qemu-native_20070613.bb | 14 | ||||
-rw-r--r-- | meta/packages/qemu/qemu-native_cvs.bb | 14 |
3 files changed, 22 insertions, 26 deletions
diff --git a/meta/packages/qemu/qemu-gcc3-check.inc b/meta/packages/qemu/qemu-gcc3-check.inc new file mode 100644 index 000000000..96b79fdf1 --- /dev/null +++ b/meta/packages/qemu/qemu-gcc3-check.inc @@ -0,0 +1,20 @@ +python __anonymous() { + from bb import which, data + + path = data.getVar('PATH', d) + oldOeConf = data.getVar('EXTRA_OECONF', d) + if not oldOeConf: oldOeConf = "" + if len(which(path, 'gcc-3.4')) != 0: + data.setVar('EXTRA_OECONF', oldOeConf + " --cc=gcc-3.4", d) + elif len(which(path, 'gcc34')) != 0: + data.setVar('EXTRA_OECONF', oldOeConf + " --cc=gcc34", d) + elif len(which(path, 'gcc33')) != 0: + data.setVar('EXTRA_OECONF', oldOeConf + " --cc=gcc33", d) + elif len(which(path, 'gcc-3.3')) != 0: + data.setVar('EXTRA_OECONF', oldOeConf + " --cc=gcc-3.3", d) + elif len(which(path, 'gcc-3.3.6')) != 0: + data.setVar('EXTRA_OECONF', oldOeConf + " --cc=gcc-3.3.6", d) + elif len(which(path, 'gcc-3.4.6')) != 0: + data.setVar('EXTRA_OECONF', oldOeConf + " --cc=gcc-3.4.6", d) +} + diff --git a/meta/packages/qemu/qemu-native_20070613.bb b/meta/packages/qemu/qemu-native_20070613.bb index 03a433b23..a6a5bda58 100644 --- a/meta/packages/qemu/qemu-native_20070613.bb +++ b/meta/packages/qemu/qemu-native_20070613.bb @@ -3,16 +3,4 @@ inherit native DEPENDS = "zlib-native" prefix = "${STAGING_DIR}/${BUILD_SYS}" -python __anonymous() { - from bb import which, data - - path = data.getVar('PATH', d) - oeconf = data.getVar('EXTRA_OECONF', d) or '' - if len(which(path, 'gcc-3.4')) != 0: - data.setVar('EXTRA_OECONF', oeconf + " --cc=gcc-3.4", d) - elif len(which(path, 'gcc34')) != 0: - data.setVar('EXTRA_OECONF', oeconf + " --cc=gcc34", d) - elif len(which(path, 'gcc-3.3')) != 0: - data.setVar('EXTRA_OECONF', oeconf + " --cc=gcc-3.3", d) - #data.setVarFlag('PKG_CONFIG_PATH', 'unexport', '1', d) -} +require qemu-gcc3-check.inc diff --git a/meta/packages/qemu/qemu-native_cvs.bb b/meta/packages/qemu/qemu-native_cvs.bb index 01cc9c181..fae6ca2f1 100644 --- a/meta/packages/qemu/qemu-native_cvs.bb +++ b/meta/packages/qemu/qemu-native_cvs.bb @@ -3,16 +3,4 @@ inherit native DEPENDS = "zlib-native" prefix = "${STAGING_DIR}/${BUILD_SYS}" -python __anonymous() { - from bb import which, data - - path = data.getVar('PATH', d) - oeconf = data.getVar('EXTRA_OECONF', d) or '' - if len(which(path, 'gcc-3.4')) != 0: - data.setVar('EXTRA_OECONF', oeconf + " --cc=gcc-3.4", d) - elif len(which(path, 'gcc34')) != 0: - data.setVar('EXTRA_OECONF', oeconf + " --cc=gcc34", d) - elif len(which(path, 'gcc-3.3')) != 0: - data.setVar('EXTRA_OECONF', oeconf + " --cc=gcc-3.3", d) - #data.setVarFlag('PKG_CONFIG_PATH', 'unexport', '1', d) -} +require qemu-gcc3-check.inc |