aboutsummaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authorFlorian Fainelli <f.fainelli@gmail.com>2017-06-18 11:39:44 -0700
committerFlorian Fainelli <f.fainelli@gmail.com>2017-06-18 11:39:44 -0700
commit3b333ec0f94579e0d532dc9052f443668b5b785a (patch)
treedf3729dbf7f482636368f980539e988c66d88617 /net
parent3de228f3ada426bc0ec26f599af240d7ef1debc2 (diff)
fping: Set -std=gnu99 to fix build errors due to C99 constructs
Fixes build errors such as: mipsel-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I.. -I/home/florian/dev/openwrt/trunk/staging_dir/target-mipsel-unknown-linux-gnu_glibc/usr/include -I/home/florian/dev/openwrt/trunk/staging_dir/target-mipsel-unknown-linux-gnu_glibc/include -I/home/florian/dev/toolchains/stbgcc-4.8-1.5/usr/include -I/home/florian/dev/toolchains/stbgcc-4.8-1.5/include -Wall -Wextra -Wno-sign-compare -DIPV6 -Os -pipe -mno-branch-likely -mips32r2 -mtune=24kc -fno-caller-saves -Wno-unused-result -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -MT fping-optparse.o -MD -MP -MF .deps/fping-optparse.Tpo -c -o fping-optparse.o `test -f 'optparse.c' || echo './'`optparse.c optparse.c: In function 'permute': optparse.c:55:5: error: 'for' loop initial declarations are only allowed in C99 mode for (int i = index; i < options->optind - 1; i++) ^ optparse.c:55:5: note: use option -std=c99 or -std=gnu99 to compile your code optparse.c: In function 'optstring_from_long': optparse.c:160:5: error: 'for' loop initial declarations are only allowed in C99 mode for (int i = 0; !longopts_end(longopts, i); i++) { Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Diffstat (limited to 'net')
-rw-r--r--net/fping/Makefile4
1 files changed, 3 insertions, 1 deletions
diff --git a/net/fping/Makefile b/net/fping/Makefile
index 0591b6fd2..b0f3ae722 100644
--- a/net/fping/Makefile
+++ b/net/fping/Makefile
@@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=fping
PKG_VERSION:=4.0
-PKG_RELEASE:=1
+PKG_RELEASE:=2
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=http://fping.org/dist/
@@ -44,6 +44,8 @@ CONFIGURE_ARGS+= \
--enable-ipv4 \
--enable-ipv6
+TARGET_CFLAGS += -std=gnu99
+
define Package/fping/install
$(INSTALL_DIR) $(1)/usr/bin
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/fping $(1)/usr/bin/