Skip to contentSkip to conversation

Angstrom: weak-assign DEPLOY_DIR

PATCH In review Matthieu Poullet 5 participants 12 messages Mar 22, 2009 – Mar 26, 2009

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Angstrom: weak-assign DEPLOY_DIR

Allow DEPLOY_DIR to be outside of TMPDIR,
so that it can be set in local.conf

---
 conf/distro/include/angstrom.inc |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
conf/distro/include/angstrom.inc +1 -1
index 60f2e55..7493055 100644
@@ -21,7 +21,7 @@ ANGSTROMLIBC ?= "glibc"
 PSTAGE_EXTRAPATH = "${ANGSTROMLIBC}"
 
 CACHE = "${TMPDIR}/cache/${ANGSTROMLIBC}/${MACHINE}"
-DEPLOY_DIR = "${TMPDIR}/deploy/${ANGSTROMLIBC}"
+DEPLOY_DIR ?= "${TMPDIR}/deploy/${ANGSTROMLIBC}"
 require conf/distro/include/angstrom-${ANGSTROMLIBC}.inc
 
 # ARM920T and up can use thumb mode to decrease binary size at the expense of speed
Signature · 1 line
1.5.6.3
#3 lore raw
In reply to Andrea Adami
Quoted 5 lines · Andrea Adami

+1 from me

Cannot cause any trouble!

Andrea

Actually, only yesterday you mentioned about problems packaging a kernel when DEPLOY_DIR is outside of TMPDIR...

Signature · 1 line
Denys
#5 lore raw

Wait a moment:

if we weak-assign DEPLOY_DIR in angstrom.inc
DEPLOY_DIR ?= "${TMPDIR}/deploy/${ANGSTROMLIBC}"

then it takes the value from bitbake.conf?
DEPLOY_DIR ?= "${TMPDIR}/deploy"

Now doubtful...

Andrea

#6 lore raw
Quoted 7 lines · Andrea Adami

Wait a moment:

if we weak-assign DEPLOY_DIR in angstrom.inc
DEPLOY_DIR ?= "${TMPDIR}/deploy/${ANGSTROMLIBC}"

then it takes the value from bitbake.conf?
DEPLOY_DIR ?= "${TMPDIR}/deploy"

Sounds like Angstrom needs:
USER_DEPLOY_DIR ?= "${TMPDIR}/deploy/${ANGSTROMLIBC}" DEPLOY_DIR = "${USER_DEPLOY_DIR}" if users are going to further override what the distro thinks is best.

Signature · 1 line
Tom Rini
#7 lore raw

was: DEPLOY_DIR out of TMPDIR

Quoted 4 lines

Sounds like Angstrom needs:
USER_DEPLOY_DIR ?= "${TMPDIR}/deploy/${ANGSTROMLIBC}" DEPLOY_DIR = "${USER_DEPLOY_DIR}" if users are going to further override what the distro thinks is best.

As pointed out by Denix and me, we need changes to base.bbclass too:

package_stagefile_shell()
...
-destfile=echo $srcfile | sed s#${TMPDIR}#${PSTAGE_TMPDIR_STAGE}# +destfile=echo $srcfile | sed s#${DEPLOY_DIR}#${PSTAGE_TMPDIR_STAGE}#
...

I tested both patches building from scratch and using packaged staging.

Issues: the 5-6 recipes using package_stagefile_shell() are possibly broken...DEPLOY_DIR get sed out and the files are not found. I don't have a list here offhand, just grep...two of them are zaurus-updater and git.

I fixed locally zaurus-updater just avoiding to call the a.m. function

- package_stagefile_shell ${DEPLOY_DIR_IMAGE}/updater.sh.${MACHINE}
+ cp -dp updater.sh ${DEPLOY_DIR_IMAGE}/updater.sh.${MACHINE}

- package_stagefile_shell ${DEPLOY_DIR_IMAGE}/gnu-tar
+ cp -dp gnu-tar ${DEPLOY_DIR_IMAGE}/gnu-tar

Can I proceed and send the set of patches to the mailing list? Better ideas?

Regards

Andrea

#8 lore raw

Review

Quoted 7 lines · Andrea Adami

I fixed locally zaurus-updater just avoiding to call the a.m. function

(quoted diff) +2 -2
-        package_stagefile_shell ${DEPLOY_DIR_IMAGE}/updater.sh.${MACHINE}
+       cp -dp updater.sh ${DEPLOY_DIR_IMAGE}/updater.sh.${MACHINE}
 
-        package_stagefile_shell ${DEPLOY_DIR_IMAGE}/gnu-tar
+       cp -dp gnu-tar ${DEPLOY_DIR_IMAGE}/gnu-tar

That breaks packaged-staging, so no, it isn't a fix.

regards,

Koen

#10 lore raw
Quoted 3 lines · Andrea Adami
Quoted 1 line

that breaks packaged-staging, so no, it isn't a fix.

FWIW packaged-staging *is* already broken wrt these few recipes.

Only if you put deploy outside TMPDIR, which isn't the default and known to cause other issues. Your patch makes to go for "working, but broken for corner-cases" to "completely broken".

regards,

Koen