apfree-wifidog: fix compilation with GCC10 12701/head
authorRosen Penev <rosenp@gmail.com>
Thu, 2 Jul 2020 23:50:07 +0000 (16:50 -0700)
committerRosen Penev <rosenp@gmail.com>
Fri, 3 Jul 2020 02:16:30 +0000 (19:16 -0700)
Signed-off-by: Rosen Penev <rosenp@gmail.com>
net/apfree-wifidog/Makefile
net/apfree-wifidog/patches/020-gcc10.patch [new file with mode: 0644]

index 370ba70b6e75cc69a6cce95bde450a80d8252f8b..1c549191735bff17883c3ce02afd2e3246cf774b 100644 (file)
@@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=apfree-wifidog
 PKG_VERSION:=3.11.1716
-PKG_RELEASE:=4
+PKG_RELEASE:=5
 
 PKG_SOURCE_PROTO:=git
 PKG_SOURCE_URL:=https://github.com/liudf0716/apfree_wifidog.git
diff --git a/net/apfree-wifidog/patches/020-gcc10.patch b/net/apfree-wifidog/patches/020-gcc10.patch
new file mode 100644 (file)
index 0000000..0fd1476
--- /dev/null
@@ -0,0 +1,36 @@
+--- a/src/conf.h
++++ b/src/conf.h
+@@ -430,12 +430,12 @@ void clear_trusted_ip_list(void);
+ void del_trusted_ip_list(const char *);
+ // online clients
+-int   g_online_clients; // total connected client count
+-char  *g_version;
+-char  *g_type; // hardware type
+-char  *g_name; // firmware name
+-char  *g_channel_path;
+-char  *g_ssid;
++extern int    g_online_clients; // total connected client count
++extern char   *g_version;
++extern char   *g_type; // hardware type
++extern char   *g_name; // firmware name
++extern char   *g_channel_path;
++extern char   *g_ssid;
+ #define       LOCK_DOMAIN() do { \
+       debug(LOG_INFO, "Locking domain"); \
+--- a/src/ping_thread.c
++++ b/src/ping_thread.c
+@@ -43,6 +43,12 @@
+ #include "wd_client.h"
+ extern time_t started_time;
++int g_online_clients;
++char *g_version;
++char *g_type;
++char *g_name;
++char *g_channel_path;
++char *g_ssid;
+ static void fw_init_delay();
+ static void ping_work_cb(evutil_socket_t, short, void *);