]> git.ipfire.org Git - thirdparty/tvheadend.git/commitdiff
build: disable strict aliasing
authorAdam Sutton <dev@adamsutton.me.uk>
Tue, 10 Jun 2014 09:57:45 +0000 (10:57 +0100)
committerAdam Sutton <dev@adamsutton.me.uk>
Tue, 10 Jun 2014 09:57:45 +0000 (10:57 +0100)
although can create a minor performance penalty it looks like many projects
disable this as strict aliasing can create annoying warnings that are not
always trivial to overcome at the expense of a relatively minor performance
improvement.

Makefile

index 6f8ab599913910a73cf5c864134e987a07b2b7c0..e02c89d49df01dd2fb1e837fe99998c1f4131211 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -27,9 +27,10 @@ PROG    := $(BUILDDIR)/tvheadend
 # Common compiler flags
 #
 
+CFLAGS  += -g -O2
 CFLAGS  += -Wall -Werror -Wwrite-strings -Wno-deprecated-declarations
-CFLAGS  += -Wmissing-prototypes -fms-extensions
-CFLAGS  += -g -funsigned-char -O2
+CFLAGS  += -Wmissing-prototypes
+CFLAGS  += -fms-extensions -funsigned-char -fno-strict-aliasing
 CFLAGS  += -D_FILE_OFFSET_BITS=64
 CFLAGS  += -I${BUILDDIR} -I${ROOTDIR}/src -I${ROOTDIR}
 LDFLAGS += -ldl -lpthread -lm