summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYann Collet <cyan@fb.com>2019-05-16 23:46:16 (GMT)
committerYann Collet <cyan@fb.com>2019-05-16 23:46:16 (GMT)
commite2527ad7254b816e14f2bd8abfbe3e3c8d6034db (patch)
tree0a9a7c2e30610a19430c76cdaef1104678a4eae2
parenta7151324af18216119bf3489f159bef8b74323f2 (diff)
downloadlz4-e2527ad7254b816e14f2bd8abfbe3e3c8d6034db.zip
lz4-e2527ad7254b816e14f2bd8abfbe3e3c8d6034db.tar.gz
lz4-e2527ad7254b816e14f2bd8abfbe3e3c8d6034db.tar.bz2
updated tests
- only play listTest with `make test`, not `make all` which is limited to build - update `clangtest`, so that it's possible to disable O3 optimization, for faster processing
-rw-r--r--.circleci/config.yml4
-rw-r--r--Makefile11
-rw-r--r--tests/Makefile4
3 files changed, 11 insertions, 8 deletions
diff --git a/.circleci/config.yml b/.circleci/config.yml
index 4c08cb2..a620cd1 100644
--- a/.circleci/config.yml
+++ b/.circleci/config.yml
@@ -10,7 +10,7 @@ version: 2
jobs:
build:
working_directory: ~/lz4/lz4
- parallelism: 1
+ parallelism: 2
shell: /bin/bash --login
# CircleCI 2.0 does not support environment variables that refer to each other the same way as 1.0 did.
# If any of these refer to each other, rewrite them so that they don't or see https://circleci.com/docs/2.0/env-vars/#interpolating-environment-variables-to-set-other-environment-variables .
@@ -71,7 +71,7 @@ jobs:
# Test
# This would typically be a build job when using workflows, possibly combined with build
# This is based on your 1.0 configuration file or project settings
- - run: clang -v; make clangtest && make clean
+ - run: CFLAGS= make clangtest && make clean
- run: g++ -v; make gpptest && make clean
- run: gcc -v; make c_standards && make clean
- run: gcc -v; g++ -v; make ctocpptest && make clean
diff --git a/Makefile b/Makefile
index dd731eb..e24cec5 100644
--- a/Makefile
+++ b/Makefile
@@ -125,11 +125,14 @@ test:
$(MAKE) -C $(TESTDIR) $@
$(MAKE) -C $(EXDIR) $@
+clangtest: CFLAGS ?= -O3
+clangtest: CFLAGS += -Werror -Wconversion -Wno-sign-conversion
+clangtest: CC = clang
clangtest: clean
- clang -v
- @CFLAGS="-O3 -Werror -Wconversion -Wno-sign-conversion" $(MAKE) -C $(LZ4DIR) all CC=clang
- @CFLAGS="-O3 -Werror -Wconversion -Wno-sign-conversion" $(MAKE) -C $(PRGDIR) all CC=clang
- @CFLAGS="-O3 -Werror -Wconversion -Wno-sign-conversion" $(MAKE) -C $(TESTDIR) all CC=clang
+ $(CC) -v
+ @CFLAGS="$(CFLAGS)" $(MAKE) -C $(LZ4DIR) all CC=$(CC)
+ @CFLAGS="$(CFLAGS)" $(MAKE) -C $(PRGDIR) all CC=$(CC)
+ @CFLAGS="$(CFLAGS)" $(MAKE) -C $(TESTDIR) all CC=$(CC)
clangtest-native: clean
clang -v
diff --git a/tests/Makefile b/tests/Makefile
index dbb7bd5..a38031a 100644
--- a/tests/Makefile
+++ b/tests/Makefile
@@ -55,7 +55,7 @@ NB_LOOPS ?= -i1
default: all
-all: fullbench fuzzer frametest roundTripTest datagen checkFrame listTest
+all: fullbench fuzzer frametest roundTripTest datagen checkFrame
all32: CFLAGS+=-m32
all32: all
@@ -153,7 +153,7 @@ list:
@$(MAKE) -pRrq -f $(lastword $(MAKEFILE_LIST)) : 2>/dev/null | awk -v RS= -F: '/^# File/,/^# Finished Make data base/ {if ($$1 !~ "^[#.]") {print $$1}}' | sort | egrep -v -e '^[^[:alnum:]]' -e '^$@$$' | xargs
.PHONY: test
-test: test-lz4 test-lz4c test-frametest test-fullbench test-fuzzer test-install test-amalgamation
+test: test-lz4 test-lz4c test-frametest test-fullbench test-fuzzer test-install test-amalgamation listTest
.PHONY: test32
test32: CFLAGS+=-m32