diff options
Diffstat (limited to 'meta/recipes-devtools/gcc/gcc-common.inc')
-rw-r--r-- | meta/recipes-devtools/gcc/gcc-common.inc | 32 |
1 files changed, 30 insertions, 2 deletions
diff --git a/meta/recipes-devtools/gcc/gcc-common.inc b/meta/recipes-devtools/gcc/gcc-common.inc index a3fa234422..7bf036cd86 100644 --- a/meta/recipes-devtools/gcc/gcc-common.inc +++ b/meta/recipes-devtools/gcc/gcc-common.inc | |||
@@ -37,10 +37,38 @@ ${GNU_MIRROR}/gcc/ http://gcc.get-software.com/releases/ \n \ | |||
37 | # | 37 | # |
38 | gcclibdir = "${libdir}/gcc" | 38 | gcclibdir = "${libdir}/gcc" |
39 | BINV = "${PV}" | 39 | BINV = "${PV}" |
40 | S = "${WORKDIR}/gcc-${PV}" | 40 | #S = "${WORKDIR}/gcc-${PV}" |
41 | B = "${S}/build.${HOST_SYS}.${TARGET_SYS}" | 41 | S = "${TMPDIR}/work-shared/gcc-${PV}/gcc-${PV}" |
42 | B = "${WORKDIR}/gcc-${PV}/build.${HOST_SYS}.${TARGET_SYS}" | ||
43 | |||
44 | # SS means Shared Stamps directory | ||
45 | SS = "${TMPDIR}/stamps/work-shared/gcc-${PV}" | ||
46 | do_fetch[stamp-base] = "${SS}" | ||
47 | do_unpack[stamp-base] = "${SS}" | ||
48 | do_patch[stamp-base] = "${SS}" | ||
49 | |||
50 | # SW means Shared Work directory | ||
51 | SW = "${TMPDIR}/work-shared/gcc-${PV}" | ||
52 | WORKDIR_task-unpack = "${SW}" | ||
53 | WORKDIR_task-patch = "${SW}" | ||
42 | 54 | ||
43 | target_includedir ?= "${includedir}" | 55 | target_includedir ?= "${includedir}" |
44 | target_libdir ?= "${libdir}" | 56 | target_libdir ?= "${libdir}" |
45 | target_base_libdir ?= "${base_libdir}" | 57 | target_base_libdir ?= "${base_libdir}" |
46 | target_prefix ?= "${prefix}" | 58 | target_prefix ?= "${prefix}" |
59 | |||
60 | CLEANFUNCS += "workshared_clean" | ||
61 | # The do_clean should be exclusive since share ${S} | ||
62 | do_clean[lockfiles] = "${TMPDIR}/stamps/work-shared/gcc-${PV}.clean.lock" | ||
63 | |||
64 | python workshared_clean () { | ||
65 | """clear the source directory""" | ||
66 | dir = bb.data.expand("${SW}", d) | ||
67 | bb.note("Removing " + dir) | ||
68 | oe.path.remove(dir) | ||
69 | |||
70 | """clear the the stamps in work-shared""" | ||
71 | dir = "%s.*" % bb.data.expand(d.getVarFlag('do_fetch', 'stamp-base', True), d) | ||
72 | bb.note("Removing " + dir) | ||
73 | oe.path.remove(dir) | ||
74 | } | ||