Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
configure: add nowerror argument (for clang)
  • Loading branch information
perexg committed Mar 8, 2016
1 parent 290adfa commit ddb31c5
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 2 deletions.
5 changes: 4 additions & 1 deletion Makefile
Expand Up @@ -32,7 +32,10 @@ CFLAGS += -g -O2
ifeq ($(CONFIG_W_UNUSED_RESULT),yes)
CFLAGS += -Wunused-result
endif
CFLAGS += -Wall -Werror -Wwrite-strings -Wno-deprecated-declarations
ifneq ($(CFLAGS_NO_WERROR),yes)
CFLAGS += -Werror
endif
CFLAGS += -Wall -Wwrite-strings -Wno-deprecated-declarations
CFLAGS += -Wmissing-prototypes
CFLAGS += -fms-extensions -funsigned-char -fno-strict-aliasing
CFLAGS += -D_FILE_OFFSET_BITS=64
Expand Down
2 changes: 1 addition & 1 deletion configure
Expand Up @@ -88,7 +88,7 @@ for opt do
gzip)
eval "$(toupper ${opt}CMD)=\"$val\""
;;
cc|cflags|ldflags|arch|cpu|platform|python|bzip2)
cc|cflags|ldflags|arch|cpu|platform|python|bzip2|nowerror)
eval "$(toupper $opt)=\"$val\""
;;
enable-*)
Expand Down
6 changes: 6 additions & 0 deletions support/configure.inc
Expand Up @@ -173,6 +173,7 @@ show_help ()
printf " $fmt Build and optimize for specific CPU\n" "--cpu=CPU"
printf " $fmt Build for architecture [$ARCH]\n" "--arch=ARCH"
printf " $fmt Build for platform [$PLATFORM]\n" "--platform=PLATFORM"
printf " $fmt Build without -Werror CFLAGS" "--nowerror"

This comment has been minimized.

Copy link
@clandmeter

clandmeter Mar 8, 2016

Contributor

@perexg I think you missed a newline here.

This comment has been minimized.

Copy link
@perexg

perexg Mar 8, 2016

Author Contributor

Yep, thanks. Fixed in 8900493 .

printf " $fmt Use python binary [$PYTHON]\n" "--python=PYTHON"
echo ""
echo "Options"
Expand Down Expand Up @@ -495,6 +496,11 @@ datadir = ${datadir}
libdir = ${libdir}
EOF

# no -Werror
if test -n "${NOWERROR}"; then
echo "CFLAGS_NO_WERROR = yes" >> "${CONFIG_MK}"
fi

# Create C include
CONFIG_H="${BUILDDIR}/build.h"
cat > "${CONFIG_H}" <<EOF
Expand Down

0 comments on commit ddb31c5

Please sign in to comment.