mirror of
https://github.com/wwarthen/RomWBW.git
synced 2026-02-06 14:11:48 -06:00
linux build: update to Build.sh fix for some platforms
The initialization of the Rom dat file used the pipe (|) operator to build an initial empty file. But the pipe operator | may sometimes return a non-zero exit code for some linux platforms, if the the streams are closed before dd has fully processed the stream. This issue occured on a travis linux ubuntu image. Solution was to change to redirection.
This commit is contained in:
@@ -13,9 +13,9 @@ if [ $1 == '-d' ] ; then
|
||||
diffdir=$1
|
||||
shift
|
||||
if [ -f $diffdir/build.inc ] ; then
|
||||
timestamp=$(grep TIMESTAMP $diffdir/build.inc | awk '{print $3}' | tr -d '\015"')
|
||||
timestamp=$(grep TIMESTAMP $diffdir/build.inc | awk '{print $3}' | tr -d '\015"')
|
||||
echo diff build using $timestamp
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
# positional arguments
|
||||
@@ -65,7 +65,7 @@ romfmt=wbw_rom${romsize}
|
||||
outdir=../../Binary
|
||||
|
||||
echo "creating empty rom disk of size $romsize in $blankfile"
|
||||
LC_CTYPE=en_US.US-ASCII tr '\000' '\345' </dev/zero | dd of=$blankfile bs=1024 count=`expr $romsize - 128`
|
||||
dd of=$blankfile bs=1024 count=`expr $romsize - 128` < <(LC_CTYPE=en_US.US-ASCII tr '\000' '\345' </dev/zero)
|
||||
|
||||
cat <<- EOF > build.inc
|
||||
; RomWBW Configured for $platform $config $timestamp
|
||||
|
||||
Reference in New Issue
Block a user