diff --git a/.travis.yml b/.travis.yml index 6bc2e03..6c363b6 100644 --- a/.travis.yml +++ b/.travis.yml @@ -9,4 +9,3 @@ before_install: - cat $ANDROID_NDK_HOME/source.properties script: - bash -e ffmpeg-android-maker.sh - - cat stats/text-relocations.txt diff --git a/ffmpeg-android-maker.sh b/ffmpeg-android-maker.sh index 88caff3..3e0c64f 100755 --- a/ffmpeg-android-maker.sh +++ b/ffmpeg-android-maker.sh @@ -190,7 +190,14 @@ function assemble() { # Saving stats about text relocation presence. # If the result file doesn't have 'TEXTREL' at all, then we are good. - ${CROSS_PREFIX}readelf --dynamic ${BUILD_DIR}/${ABI}/lib/*.so | grep 'TEXTREL\|File' >> ${STATS_DIR}/text-relocations.txt + TEXT_REL_STATS_FILE=${STATS_DIR}/text-relocations.txt + ${CROSS_PREFIX}readelf --dynamic ${BUILD_DIR}/${ABI}/lib/*.so | grep 'TEXTREL\|File' >> ${TEXT_REL_STATS_FILE} + + if grep -q TEXTREL ${TEXT_REL_STATS_FILE}; then + echo "There are text relocations in output files:" + cat ${TEXT_REL_STATS_FILE} + exit 1 + fi cd ${BASE_DIR} }