[oe] [PATCH] icecc: base fix for cross and native builds

Roman I Khimov khimov at altell.ru
Fri Feb 13 14:33:44 UTC 2009


Roman I Khimov:
> Another approach could be just reducing the race window, fixing
> create-icecc-env.sh to write to temporary file and then move it to its
> place. Maybe that would be enough.

BTW, this kind of kludge seems to be working, at least for two runs on 
dual-core and quad-core machines.

--- a/create-icecc-env.sh
+++ b/create-icecc-env.sh
@@ -181,12 +181,14 @@ else
  fi
 
 fi
+TEMPFILE=`tempfile`
 cd $tempdir
-tar -czhf "$mydir/$archive_name".tar.gz $target_files || {
+tar -czhf $TEMPFILE $target_files || {
  if test -z "$silent"; then
   echo "Couldn't create archive"
  fi
   exit 3
 }
 cd ..
+mv $TEMPFILE "$mydir/$archive_name".tar.gz
 rm -rf $tempdir




More information about the Openembedded-devel mailing list