1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/media/libcubeb/update.sh Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,43 @@ 1.4 +# Usage: sh update.sh <upstream_src_directory> 1.5 +set -e 1.6 + 1.7 +cp $1/include/cubeb/cubeb.h include 1.8 +cp $1/src/cubeb.c src 1.9 +cp $1/src/cubeb-internal.h src 1.10 +cp $1/src/cubeb_alsa.c src 1.11 +cp $1/src/cubeb_winmm.c src 1.12 +cp $1/src/cubeb_audiounit.c src 1.13 +cp $1/src/cubeb_pulse.c src 1.14 +cp $1/src/cubeb_sndio.c src 1.15 +cp $1/src/cubeb_opensl.c src 1.16 +cp $1/src/cubeb_audiotrack.c src 1.17 +cp $1/src/cubeb_wasapi.cpp src 1.18 +cp $1/src/cubeb-speex-resampler.h src 1.19 +cp $1/src/android/audiotrack_definitions.h src/android 1.20 +cp $1/src/android/sles_definitions.h src/android 1.21 +cp $1/LICENSE . 1.22 +cp $1/README . 1.23 +cp $1/AUTHORS . 1.24 +cp $1/test/common.h tests/common.h 1.25 +cp $1/test/test_audio.c tests/test_audio.cpp 1.26 +cp $1/test/test_tone.c tests/test_tone.cpp 1.27 +cp $1/test/test_sanity.c tests/test_sanity.cpp 1.28 +cp $1/test/test_latency.c tests/test_latency.cpp 1.29 + 1.30 +if [ -d $1/.git ]; then 1.31 + rev=$(cd $1 && git rev-parse --verify HEAD) 1.32 + dirty=$(cd $1 && git diff-index --name-only HEAD) 1.33 +fi 1.34 + 1.35 +if [ -n "$rev" ]; then 1.36 + version=$rev 1.37 + if [ -n "$dirty" ]; then 1.38 + version=$version-dirty 1.39 + echo "WARNING: updating from a dirty git repository." 1.40 + fi 1.41 + sed -i.bak -e "/The git commit ID used was/ s/[0-9a-f]\{40\}\(-dirty\)\{0,1\}\./$version./" README_MOZILLA 1.42 + rm README_MOZILLA.bak 1.43 +else 1.44 + echo "Remember to update README_MOZILLA with the version details." 1.45 +fi 1.46 +