fixed c_standards tests
and added entry "make list"
This commit is contained in:
parent
a902127613
commit
2012e4de9e
24
Makefile
24
Makefile
@ -56,7 +56,10 @@ endif
|
|||||||
default: lib lz4-release
|
default: lib lz4-release
|
||||||
|
|
||||||
.PHONY: all
|
.PHONY: all
|
||||||
all: default examples manuals
|
all: allmost manuals
|
||||||
|
|
||||||
|
.PHONY: allmost
|
||||||
|
allmost: lib lz4 examples
|
||||||
|
|
||||||
.PHONY: lib
|
.PHONY: lib
|
||||||
lib:
|
lib:
|
||||||
@ -68,7 +71,7 @@ lz4 lz4-release: lib
|
|||||||
@cp $(PRGDIR)/lz4$(EXT) .
|
@cp $(PRGDIR)/lz4$(EXT) .
|
||||||
|
|
||||||
.PHONY: examples
|
.PHONY: examples
|
||||||
examples: lib lz4-release
|
examples: lib lz4
|
||||||
$(MAKE) -C $(EXDIR) test
|
$(MAKE) -C $(EXDIR) test
|
||||||
|
|
||||||
.PHONY: manuals
|
.PHONY: manuals
|
||||||
@ -116,6 +119,10 @@ endif
|
|||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
ifneq (,$(filter $(HOST_OS),MSYS POSIX))
|
ifneq (,$(filter $(HOST_OS),MSYS POSIX))
|
||||||
|
|
||||||
|
.PHONY: list
|
||||||
|
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
|
.PHONY: test
|
||||||
test:
|
test:
|
||||||
$(MAKE) -C $(TESTDIR) $@
|
$(MAKE) -C $(TESTDIR) $@
|
||||||
@ -166,13 +173,10 @@ gpptest32: clean
|
|||||||
CC=g++ $(MAKE) -C $(TESTDIR) native CFLAGS="-m32 -O3 -Wall -Wextra -Wundef -Wshadow -Wcast-align -Werror"
|
CC=g++ $(MAKE) -C $(TESTDIR) native CFLAGS="-m32 -O3 -Wall -Wextra -Wundef -Wshadow -Wcast-align -Werror"
|
||||||
|
|
||||||
c_standards: clean
|
c_standards: clean
|
||||||
$(MAKE) all MOREFLAGS="-std=gnu90 -Werror"
|
# note : lz4 is not C90 compatible, because it requires long long support
|
||||||
$(MAKE) clean
|
CFLAGS="-std=gnu90 -Werror" $(MAKE) clean allmost
|
||||||
$(MAKE) all MOREFLAGS="-std=c99 -Werror"
|
CFLAGS="-std=c99 -Werror" $(MAKE) clean allmost
|
||||||
$(MAKE) clean
|
CFLAGS="-std=gnu99 -Werror" $(MAKE) clean allmost
|
||||||
$(MAKE) all MOREFLAGS="-std=gnu99 -Werror"
|
CFLAGS="-std=c11 -Werror" $(MAKE) clean allmost
|
||||||
$(MAKE) clean
|
|
||||||
$(MAKE) all MOREFLAGS="-std=c11 -Werror"
|
|
||||||
$(MAKE) clean
|
|
||||||
|
|
||||||
endif
|
endif
|
||||||
|
@ -290,7 +290,8 @@ int basicTests(U32 seed, double compressibility)
|
|||||||
{ size_t nullSize = 0;
|
{ size_t nullSize = 0;
|
||||||
size_t const fiError = LZ4F_getFrameInfo(dCtx, &fi, ip, &nullSize);
|
size_t const fiError = LZ4F_getFrameInfo(dCtx, &fi, ip, &nullSize);
|
||||||
if (LZ4F_getErrorCode(fiError) != LZ4F_ERROR_frameHeader_incomplete) {
|
if (LZ4F_getErrorCode(fiError) != LZ4F_ERROR_frameHeader_incomplete) {
|
||||||
DISPLAYLEVEL(3, "incorrect error : %s != ERROR_frameHeader_incomplete \n", LZ4F_getErrorName(fiError));
|
DISPLAYLEVEL(3, "incorrect error : %s != ERROR_frameHeader_incomplete \n",
|
||||||
|
LZ4F_getErrorName(fiError));
|
||||||
goto _output_error;
|
goto _output_error;
|
||||||
}
|
}
|
||||||
DISPLAYLEVEL(3, " correctly failed : %s \n", LZ4F_getErrorName(fiError));
|
DISPLAYLEVEL(3, " correctly failed : %s \n", LZ4F_getErrorName(fiError));
|
||||||
|
Loading…
Reference in New Issue
Block a user