Added "-Wcast-align" when CRYPTOPP_NO_UNALIGNED_DATA_ACCESS is in effect. Commented out at the moment because its very noisy
parent
8e868bf2e5
commit
cebf5906a9
33
GNUmakefile
33
GNUmakefile
|
|
@ -282,6 +282,20 @@ CXXFLAGS += -DCRYPTOPP_INCLUDE_VECTOR_CC
|
||||||
endif # SUN_CC10_BUGGY
|
endif # SUN_CC10_BUGGY
|
||||||
endif # SUN_COMPILER
|
endif # SUN_COMPILER
|
||||||
|
|
||||||
|
#################################################################
|
||||||
|
# Public service announcement
|
||||||
|
|
||||||
|
# Do not warn for some targets
|
||||||
|
NO_WARN = GNUmakefile.deps dist install install-strip uninstall remove clean distclean
|
||||||
|
ifeq ($(findstring $(MAKECMDGOALS),$(NO_WARN)),)
|
||||||
|
|
||||||
|
UNALIGNED_ACCESS = $(shell $(EGREP) -c "^// \#define CRYPTOPP_NO_UNALIGNED_DATA_ACCESS" config.h)
|
||||||
|
ifneq ($(UNALIGNED_ACCESS),0)
|
||||||
|
$(info WARNING: CRYPTOPP_NO_UNALIGNED_DATA_ACCESS is not defined in config.h)
|
||||||
|
endif
|
||||||
|
|
||||||
|
endif # NO_WARN
|
||||||
|
|
||||||
#################################################################
|
#################################################################
|
||||||
# Compiler diagnostics and warnings
|
# Compiler diagnostics and warnings
|
||||||
|
|
||||||
|
|
@ -298,6 +312,11 @@ ifneq ($(CLANG_COMPILER),0)
|
||||||
CXXFLAGS += -Wall -Wextra -Wno-tautological-compare
|
CXXFLAGS += -Wall -Wextra -Wno-tautological-compare
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
# -Wcast-align if not UNALIGNED_ACCESS
|
||||||
|
ifeq ($(UNALIGNED_ACCESS),0)
|
||||||
|
# CXXFLAGS += -Wcast-align
|
||||||
|
endif
|
||||||
|
|
||||||
ifeq ($(findstring -pipe,$(CXXFLAGS)),)
|
ifeq ($(findstring -pipe,$(CXXFLAGS)),)
|
||||||
CXXFLAGS += -pipe
|
CXXFLAGS += -pipe
|
||||||
endif
|
endif
|
||||||
|
|
@ -331,20 +350,6 @@ LIBIMPORTOBJS = $(LIBOBJS:.o=.import.o)
|
||||||
TESTIMPORTOBJS = $(TESTOBJS:.o=.import.o)
|
TESTIMPORTOBJS = $(TESTOBJS:.o=.import.o)
|
||||||
DLLTESTOBJS = dlltest.dllonly.o
|
DLLTESTOBJS = dlltest.dllonly.o
|
||||||
|
|
||||||
#################################################################
|
|
||||||
# Public service announcement
|
|
||||||
|
|
||||||
# Do not warn for some targets
|
|
||||||
NO_WARN = GNUmakefile.deps dist install install-strip uninstall remove clean distclean
|
|
||||||
ifeq ($(findstring $(MAKECMDGOALS),$(NO_WARN)),)
|
|
||||||
|
|
||||||
UNALIGNED_ACCESS = $(shell $(EGREP) -c "^// \#define CRYPTOPP_NO_UNALIGNED_DATA_ACCESS" config.h)
|
|
||||||
ifneq ($(UNALIGNED_ACCESS),0)
|
|
||||||
$(info WARNING: CRYPTOPP_NO_UNALIGNED_DATA_ACCESS is not defined in config.h)
|
|
||||||
endif
|
|
||||||
|
|
||||||
endif # NO_WARN
|
|
||||||
|
|
||||||
#################################################################
|
#################################################################
|
||||||
# Recipes
|
# Recipes
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue