Unified · Split
| @@ -6,8 +6,11 @@ pushd $CUR_DIR/.. · 5 unmodified lines | |||
| 6 | 6 | ||
| 7 | set -e | 7 | set -e |
| 8 | 8 | ||
| 9 | CFLAGS="-O2 -std=c89 -Wall -Wextra -Wmissing-prototypes -Werror -fno-asynchronous-unwind-tables -fno-stack-protector \ | ||
| 10 | -ffunction-sections -fdata-sections -Wl,--gc-sections" | ||
| 11 | |||
| 9 | echo testing mp4 mode... | 12 | echo testing mp4 mode... |
| 10 | gcc -O2 -std=c89 -DMP4_MODE -o minimp3 minimp3_test.c -lm | 13 | gcc $CFLAGS -DMP4_MODE -o minimp3 minimp3_test.c -lm |
| 11 | scripts/test_mp4_mode.sh | 14 | scripts/test_mp4_mode.sh |
| 12 | 15 | ||
| 13 | echo testing coverage x86 w sse... | 16 | echo testing coverage x86 w sse... |
| @@ -20,44 +23,36 @@ set -e · 6 unmodified lines | |||
| 20 | gcov minimp3_test.c | 23 | gcov minimp3_test.c |
| 21 | 24 | ||
| 22 | echo testing x86 w/o sse... | 25 | echo testing x86 w/o sse... |
| 23 | gcc -O2 -m32 -std=c89 -Wall -Wextra -Wmissing-prototypes -Werror -fno-asynchronous-unwind-tables -fno-stack-protector \ | 26 | gcc $CFLAGS -m32 -o minimp3 minimp3_test.c -lm |
| 24 | -ffunction-sections -fdata-sections -Wl,--gc-sections -o minimp3 minimp3_test.c -lm | ||
| 25 | scripts/test.sh | 27 | scripts/test.sh |
| 26 | 28 | ||
| 27 | echo testing x64... | 29 | echo testing x64... |
| 28 | gcc -O2 -std=c89 -Wall -Wextra -Wmissing-prototypes -Werror -fno-asynchronous-unwind-tables -fno-stack-protector \ | 30 | gcc $CFLAGS -o minimp3 minimp3_test.c -lm |
| 29 | -ffunction-sections -fdata-sections -Wl,--gc-sections -o minimp3 minimp3_test.c -lm | 31 | scripts/test.sh |
| 32 | |||
| 33 | echo testing x64 with float output... | ||
| 34 | gcc $CFLAGS -DMINIMP3_FLOAT_OUTPUT -o minimp3 minimp3_test.c -lm | ||
| 30 | scripts/test.sh | 35 | scripts/test.sh |
| 31 | 36 | ||
| 32 | echo testing arm w/o neon... | 37 | echo testing arm w/o neon... |
| 33 | arm-none-eabi-gcc -O2 -std=c89 -Wall -Wextra -Wmissing-prototypes -Werror -fno-asynchronous-unwind-tables -fno-stack-protector \ | 38 | arm-none-eabi-gcc $CFLAGS -mthumb -mcpu=arm9e -o minimp3_arm minimp3_test.c --specs=rdimon.specs -lm |
| 34 | -mthumb -mcpu=arm9e \ | ||
| 35 | -ffunction-sections -fdata-sections -Wl,--gc-sections -o minimp3_arm minimp3_test.c --specs=rdimon.specs -lm | ||
| 36 | qemu-arm ./minimp3_arm | 39 | qemu-arm ./minimp3_arm |
| 37 | 40 | ||
| 38 | echo testing arm w neon... | 41 | echo testing arm w neon... |
| 39 | arm-none-eabi-gcc -O2 -std=c89 -Wall -Wextra -Wmissing-prototypes -Werror -fno-asynchronous-unwind-tables -fno-stack-protector \ | 42 | arm-none-eabi-gcc $CFLAGS -marm -mcpu=cortex-a15 -mfpu=neon -mfloat-abi=softfp -o minimp3_arm minimp3_test.c --specs=rdimon.specs -lm |
| 40 | -marm -mcpu=cortex-a15 -mfpu=neon -mfloat-abi=softfp \ | ||
| 41 | -ffunction-sections -fdata-sections -Wl,--gc-sections -o minimp3_arm minimp3_test.c --specs=rdimon.specs -lm | ||
| 42 | qemu-arm ./minimp3_arm | 43 | qemu-arm ./minimp3_arm |
| 43 | 44 | ||
| 44 | echo testing arm64... | 45 | echo testing arm64... |
| 45 | aarch64-linux-gnu-gcc -O2 -std=c89 -Wall -Wextra -Wmissing-prototypes -Werror -fno-asynchronous-unwind-tables -fno-stack-protector \ | 46 | aarch64-linux-gnu-gcc $CFLAGS -static -march=armv8-a -o minimp3_arm minimp3_test.c -lm |
| 46 | -static -march=armv8-a \ | ||
| 47 | -ffunction-sections -fdata-sections -Wl,--gc-sections -o minimp3_arm minimp3_test.c -lm | ||
| 48 | qemu-aarch64 ./minimp3_arm | 47 | qemu-aarch64 ./minimp3_arm |
| 49 | 48 | ||
| 50 | echo testing powerpc... | 49 | echo testing powerpc... |
| 51 | powerpc-linux-gnu-gcc -O2 -std=c89 -Wall -Wextra -Wmissing-prototypes -Werror -fno-asynchronous-unwind-tables -fno-stack-protector \ | 50 | powerpc-linux-gnu-gcc $CFLAGS -static -o minimp3_ppc minimp3_test.c -lm |
| 52 | -static \ | ||
| 53 | -ffunction-sections -fdata-sections -Wl,--gc-sections -o minimp3_ppc minimp3_test.c -lm | ||
| 54 | qemu-ppc ./minimp3_ppc | 51 | qemu-ppc ./minimp3_ppc |
| 55 | 52 | ||
| 56 | if [ ! "$TRAVIS" = "true" ]; then | 53 | if [ ! "$TRAVIS" = "true" ]; then |
| 57 | echo testing powerpc64... | 54 | echo testing powerpc64... |
| 58 | powerpc64-linux-gnu-gcc -O2 -std=c89 -Wall -Wextra -Wmissing-prototypes -Werror -fno-asynchronous-unwind-tables -fno-stack-protector \ | 55 | powerpc64-linux-gnu-gcc $CFLAGS -static -o minimp3_ppc minimp3_test.c -lm |
| 59 | -static \ | ||
| 60 | -ffunction-sections -fdata-sections -Wl,--gc-sections -o minimp3_ppc minimp3_test.c -lm | ||
| 61 | qemu-ppc64 ./minimp3_ppc | 56 | qemu-ppc64 ./minimp3_ppc |
| 62 | fi | 57 | fi |
| 63 | 58 | ||