2016-11-22 01:18:29 +00:00
|
|
|
language: c
|
2019-01-10 18:20:16 +00:00
|
|
|
|
2016-11-22 01:18:29 +00:00
|
|
|
matrix:
|
|
|
|
fast_finish: true
|
2018-01-14 08:21:43 +00:00
|
|
|
include:
|
|
|
|
# OS X Mavericks
|
2019-01-10 18:20:16 +00:00
|
|
|
- name: (macOS) General Test
|
|
|
|
os: osx
|
2019-01-10 18:39:34 +00:00
|
|
|
compiler: clang
|
2019-01-10 18:20:16 +00:00
|
|
|
script:
|
2019-04-23 19:29:39 +00:00
|
|
|
- make # test library build
|
|
|
|
- make clean
|
2020-08-12 21:39:01 +00:00
|
|
|
- make test MOREFLAGS='-Werror -Wconversion -Wno-sign-conversion' | tee # test scenario where `stdout` is not the console
|
2018-01-14 08:21:43 +00:00
|
|
|
|
|
|
|
# Container-based 12.04 LTS Server Edition 64 bit (doesn't support 32-bit includes)
|
2019-01-10 18:20:16 +00:00
|
|
|
- name: (Precise) benchmark test
|
|
|
|
dist: precise
|
|
|
|
script:
|
|
|
|
- make -C tests test-lz4 test-lz4c test-fullbench
|
2018-01-14 08:21:43 +00:00
|
|
|
|
2019-01-10 18:20:16 +00:00
|
|
|
- name: (Precise) frame and fuzzer test
|
|
|
|
dist: precise
|
|
|
|
install:
|
|
|
|
- sudo sysctl -w vm.mmap_min_addr=4096
|
|
|
|
script:
|
|
|
|
- make -C tests test-frametest test-fuzzer
|
2018-01-14 08:21:43 +00:00
|
|
|
|
2019-06-29 03:55:47 +00:00
|
|
|
- name: ASAN tests with fuzzer and frametest
|
|
|
|
install:
|
|
|
|
- sudo sysctl -w vm.mmap_min_addr=4096
|
|
|
|
script:
|
|
|
|
- CC=clang MOREFLAGS=-fsanitize=address make -C tests test-frametest test-fuzzer
|
|
|
|
|
2020-08-11 21:03:20 +00:00
|
|
|
- name: Custom LZ4_DISTANCE_MAX ; Build lz4-wlib (CLI linked to dynamic library)
|
2019-07-15 19:11:34 +00:00
|
|
|
script:
|
|
|
|
- MOREFLAGS=-DLZ4_DISTANCE_MAX=8000 make check
|
2020-08-11 21:03:20 +00:00
|
|
|
- make clean
|
|
|
|
- make -C programs lz4-wlib
|
2019-07-15 19:11:34 +00:00
|
|
|
|
2019-01-10 18:20:16 +00:00
|
|
|
- name: (Precise) g++ and clang CMake test
|
|
|
|
dist: precise
|
|
|
|
script:
|
|
|
|
- make gpptest
|
|
|
|
- make clean
|
|
|
|
- make examples
|
|
|
|
- make clean cmake
|
|
|
|
- make clean travis-install
|
|
|
|
- make clean clangtest
|
2018-01-14 08:21:43 +00:00
|
|
|
|
2020-10-02 22:43:46 +00:00
|
|
|
- name: x32 compatibility test
|
2018-01-14 08:21:43 +00:00
|
|
|
addons:
|
|
|
|
apt:
|
|
|
|
packages:
|
|
|
|
- gcc-multilib
|
2019-01-10 18:20:16 +00:00
|
|
|
script:
|
|
|
|
- make -C tests test MOREFLAGS=-mx32
|
2018-01-14 08:21:43 +00:00
|
|
|
|
2020-10-02 22:43:46 +00:00
|
|
|
# 14.04 LTS Server Edition 64 bit
|
2018-01-14 08:21:43 +00:00
|
|
|
# presume clang >= v3.9.0
|
2019-01-10 18:20:16 +00:00
|
|
|
- name: (Trusty) USan test
|
2018-01-14 08:21:43 +00:00
|
|
|
dist: trusty
|
2019-01-10 18:39:34 +00:00
|
|
|
compiler: clang
|
2019-01-10 18:20:16 +00:00
|
|
|
script:
|
|
|
|
- make usan MOREFLAGS=-Wcomma -Werror
|
2018-01-14 08:21:43 +00:00
|
|
|
|
2019-01-10 18:20:16 +00:00
|
|
|
- name: (Trusty) valgrind test
|
2018-01-14 08:21:43 +00:00
|
|
|
dist: trusty
|
2019-01-10 18:39:34 +00:00
|
|
|
install:
|
|
|
|
- sudo apt-get install -qq valgrind
|
2019-01-10 18:20:16 +00:00
|
|
|
script:
|
|
|
|
- make c_standards
|
|
|
|
- make -C tests test-lz4 test-mem
|
2018-01-14 08:21:43 +00:00
|
|
|
|
2019-01-10 18:20:16 +00:00
|
|
|
- name: (Trusty) c-to-c++ test
|
2018-05-22 01:36:49 +00:00
|
|
|
dist: trusty
|
2019-01-10 18:20:16 +00:00
|
|
|
script:
|
|
|
|
- make ctocpptest
|
2018-05-22 01:36:49 +00:00
|
|
|
|
2019-01-10 18:20:16 +00:00
|
|
|
- name: (Trusty) i386 benchmark + version test
|
2018-01-14 08:21:43 +00:00
|
|
|
dist: trusty
|
2019-01-10 18:39:34 +00:00
|
|
|
install:
|
|
|
|
- sudo apt-get install -qq python3 libc6-dev-i386 gcc-multilib
|
2019-01-10 18:20:16 +00:00
|
|
|
script:
|
|
|
|
- make -C tests test-lz4c32 test-fullbench32 versionsTest
|
2018-01-14 08:21:43 +00:00
|
|
|
|
2019-01-10 18:20:16 +00:00
|
|
|
- name: (Trusty) i386 frame + fuzzer test
|
2018-01-14 08:21:43 +00:00
|
|
|
dist: trusty
|
2019-01-10 18:20:16 +00:00
|
|
|
install:
|
2019-01-10 18:39:34 +00:00
|
|
|
- sudo apt-get install -qq libc6-dev-i386 gcc-multilib
|
|
|
|
- sudo sysctl -w vm.mmap_min_addr=4096
|
2019-01-10 18:20:16 +00:00
|
|
|
script:
|
|
|
|
- make -C tests test-frametest32 test-fuzzer32
|
2018-01-14 08:21:43 +00:00
|
|
|
|
2019-01-10 18:20:16 +00:00
|
|
|
- name: (Trusty) gcc-6 standard C compilation
|
2018-01-14 08:21:43 +00:00
|
|
|
dist: trusty
|
|
|
|
addons:
|
|
|
|
apt:
|
|
|
|
sources:
|
|
|
|
- ubuntu-toolchain-r-test
|
|
|
|
packages:
|
|
|
|
- gcc-6
|
2019-01-10 18:39:34 +00:00
|
|
|
env:
|
|
|
|
- CC=gcc-6
|
2019-01-10 18:20:16 +00:00
|
|
|
script:
|
|
|
|
- make c_standards
|
|
|
|
- make -C tests test-lz4 MOREFLAGS=-Werror
|
2018-01-14 08:21:43 +00:00
|
|
|
|
2019-01-10 18:20:16 +00:00
|
|
|
- name: (Trusty) arm + aarch64 compilation
|
2018-01-14 08:21:43 +00:00
|
|
|
dist: trusty
|
2019-01-10 18:39:34 +00:00
|
|
|
install:
|
|
|
|
- sudo apt-get install -qq
|
|
|
|
qemu-system-arm
|
|
|
|
qemu-user-static
|
|
|
|
gcc-arm-linux-gnueabi
|
|
|
|
libc6-dev-armel-cross
|
|
|
|
gcc-aarch64-linux-gnu
|
|
|
|
libc6-dev-arm64-cross
|
2019-01-10 18:20:16 +00:00
|
|
|
script:
|
|
|
|
- make platformTest CC=arm-linux-gnueabi-gcc QEMU_SYS=qemu-arm-static
|
|
|
|
- make platformTest CC=aarch64-linux-gnu-gcc QEMU_SYS=qemu-aarch64-static
|
2018-01-14 08:21:43 +00:00
|
|
|
|
2020-08-22 01:12:13 +00:00
|
|
|
- name: aarch64 real-hw tests
|
|
|
|
arch: arm64
|
|
|
|
script:
|
|
|
|
- make test
|
|
|
|
|
|
|
|
- name: PPC64LE real-hw tests
|
|
|
|
arch: ppc64le
|
|
|
|
script:
|
|
|
|
- make test
|
|
|
|
|
|
|
|
- name: IBM s390x real-hw tests
|
|
|
|
arch: s390x
|
|
|
|
script:
|
|
|
|
- make test
|
|
|
|
|
2019-01-10 18:20:16 +00:00
|
|
|
- name: (Xenial) gcc-5 compilation
|
|
|
|
dist: xenial
|
|
|
|
install:
|
2019-01-10 18:39:34 +00:00
|
|
|
- sudo apt-get install -qq libc6-dev-i386 gcc-multilib
|
2019-01-10 18:20:16 +00:00
|
|
|
script:
|
|
|
|
- make -C tests test-lz4 clean test-lz4c32 MOREFLAGS=-Werror
|
2018-01-14 08:21:43 +00:00
|
|
|
|
2019-01-10 18:20:16 +00:00
|
|
|
- name: (Trusty) clang-3.8 compilation
|
2018-01-14 08:21:43 +00:00
|
|
|
dist: trusty
|
|
|
|
addons:
|
|
|
|
apt:
|
|
|
|
sources:
|
|
|
|
- ubuntu-toolchain-r-test
|
|
|
|
- llvm-toolchain-precise-3.8
|
|
|
|
packages:
|
|
|
|
- clang-3.8
|
2019-01-10 18:20:16 +00:00
|
|
|
script:
|
|
|
|
- make -C tests test-lz4 CC=clang-3.8
|
2018-01-14 08:21:43 +00:00
|
|
|
|
2019-01-10 18:20:16 +00:00
|
|
|
- name: (Trusty) PowerPC + PPC64 compilation
|
2018-01-14 08:21:43 +00:00
|
|
|
dist: trusty
|
2019-01-10 18:39:34 +00:00
|
|
|
install:
|
|
|
|
- sudo apt-get install -qq qemu-system-ppc qemu-user-static gcc-powerpc-linux-gnu
|
2019-01-10 18:20:16 +00:00
|
|
|
script:
|
|
|
|
- make platformTest CC=powerpc-linux-gnu-gcc QEMU_SYS=qemu-ppc-static
|
|
|
|
- make platformTest CC=powerpc-linux-gnu-gcc QEMU_SYS=qemu-ppc64-static MOREFLAGS=-m64
|
2018-01-14 08:21:43 +00:00
|
|
|
|
2019-01-10 18:20:16 +00:00
|
|
|
- name: (Trusty) scan-build + cppcheck
|
2018-01-14 08:21:43 +00:00
|
|
|
dist: trusty
|
2019-01-10 18:39:34 +00:00
|
|
|
compiler: clang
|
|
|
|
install:
|
|
|
|
- sudo apt-get install -qq cppcheck
|
2019-01-10 18:20:16 +00:00
|
|
|
script:
|
|
|
|
- make staticAnalyze
|
|
|
|
- make cppcheck
|
2018-01-14 08:21:43 +00:00
|
|
|
|
2019-01-10 18:20:16 +00:00
|
|
|
- name: (Trusty) gcc-4.4 compilation
|
2018-01-14 08:21:43 +00:00
|
|
|
dist: trusty
|
|
|
|
addons:
|
|
|
|
apt:
|
|
|
|
sources:
|
|
|
|
- ubuntu-toolchain-r-test
|
|
|
|
packages:
|
|
|
|
- libc6-dev-i386
|
|
|
|
- gcc-multilib
|
|
|
|
- gcc-4.4
|
2019-01-10 18:20:16 +00:00
|
|
|
script:
|
|
|
|
- make clean all CC=gcc-4.4 MOREFLAGS=-Werror
|
|
|
|
- make clean
|
|
|
|
- CFLAGS=-fPIC LDFLAGS='-pie -fPIE -D_FORTIFY_SOURCE=2' make -C programs
|
2018-01-14 08:21:43 +00:00
|
|
|
|
2018-01-15 00:57:25 +00:00
|
|
|
# tag-specific test
|
2019-01-10 18:20:16 +00:00
|
|
|
- name: tag build
|
|
|
|
if: tag =~ ^v[0-9]\.[0-9]
|
2018-01-15 00:57:25 +00:00
|
|
|
os: linux
|
2019-01-10 18:20:16 +00:00
|
|
|
script:
|
|
|
|
- make -C tests checkTag
|
|
|
|
- tests/checkTag "$TRAVIS_BRANCH"
|
|
|
|
|
|
|
|
- name: (Xenial) Meson + clang build
|
2019-04-26 18:41:03 +00:00
|
|
|
#env: ALLOW_FAILURES=true
|
2019-01-10 18:20:16 +00:00
|
|
|
dist: xenial
|
|
|
|
language: cpp
|
|
|
|
compiler: clang
|
|
|
|
install:
|
|
|
|
- sudo apt-get install -qq python3 tree
|
2019-06-29 13:54:39 +00:00
|
|
|
- |
|
|
|
|
travis_retry curl -o ~/ninja.zip -L 'https://github.com/ninja-build/ninja/releases/download/v1.9.0/ninja-linux.zip' &&
|
|
|
|
unzip ~/ninja.zip -d ~/.local/bin
|
|
|
|
- |
|
|
|
|
travis_retry curl -o ~/get-pip.py 'https://bootstrap.pypa.io/get-pip.py' &&
|
|
|
|
python3 ~/get-pip.py --user &&
|
|
|
|
pip3 install --user meson
|
|
|
|
script:
|
|
|
|
- |
|
|
|
|
meson setup \
|
|
|
|
--buildtype=debug \
|
|
|
|
-Db_lundef=false \
|
|
|
|
-Dauto_features=enabled \
|
|
|
|
-Ddefault_library=both \
|
|
|
|
-Dbin_programs=true \
|
|
|
|
-Dbin_contrib=true \
|
|
|
|
-Dbin_tests=true \
|
|
|
|
-Dbin_examples=true \
|
2019-01-10 18:20:16 +00:00
|
|
|
contrib/meson build
|
2019-04-26 18:41:03 +00:00
|
|
|
- pushd build
|
2019-01-10 18:20:16 +00:00
|
|
|
- DESTDIR=./staging ninja install
|
|
|
|
- tree ./staging
|
2019-06-25 16:22:02 +00:00
|
|
|
|
|
|
|
# oss-fuzz compilation test
|
|
|
|
- name: Compile OSS-Fuzz targets
|
|
|
|
script:
|
|
|
|
- ./ossfuzz/travisoss.sh
|
|
|
|
|
2018-12-01 06:12:51 +00:00
|
|
|
allow_failures:
|
2019-01-10 18:20:16 +00:00
|
|
|
- env: ALLOW_FAILURES=true
|