Merge pull request #4232 from ffainelli/haproxy
authorFlorian Fainelli <f.fainelli@gmail.com>
Tue, 4 Apr 2017 17:51:10 +0000 (10:51 -0700)
committerGitHub <noreply@github.com>
Tue, 4 Apr 2017 17:51:10 +0000 (10:51 -0700)
Haproxy builds fixes

17 files changed:
net/adblock/Makefile
net/adblock/files/README.md
net/adblock/files/adblock.conf
net/adblock/files/adblock.init
net/adblock/files/adblock.sh
net/haproxy/Makefile
net/mdnsresponder/Makefile
net/sslh/Makefile
net/vnstat/Makefile
net/vnstat/patches/001-conf.patch [deleted file]
net/vnstat/patches/002-no_install_strip.patch [deleted file]
net/vnstat/patches/003-no_install_uname.patch [deleted file]
net/vnstat/patches/100-musl-compat.patch [deleted file]
net/vnstat/patches/990-adjust-configuration-defaults.patch [new file with mode: 0644]
net/webui-aria2/Makefile
sound/squeezelite/Makefile
utils/hfsprogs/Makefile

index 8b806acc16f4f234a78a8e4608c8cd7ec2f077ec..ce4421b8146f99977f911c60c44cf6afe3a4a1c1 100644 (file)
@@ -6,8 +6,8 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=adblock
-PKG_VERSION:=2.5.0
-PKG_RELEASE:=2
+PKG_VERSION:=2.5.1
+PKG_RELEASE:=1
 PKG_LICENSE:=GPL-3.0+
 PKG_MAINTAINER:=Dirk Brenken <dev@brenken.org>
 
index 2c2ec398214818e812c8b3487bb98d9b585b59bb..10199c606fc906a257f8ec9335b2bfe6a12410d9 100644 (file)
@@ -29,10 +29,14 @@ A lot of people already use adblocker plugins within their desktop browsers, but
     * => daily updates, approx. 15 entries
     * [ransomware tracker](https://ransomwaretracker.abuse.ch)
     * => daily updates, approx. 150 entries
-    * [rolist/easylist](https://easylist-downloads.adblockplus.org/rolist+easylist.txt)
-    * => weekly updates, approx. 600 entries
-    * [ruadlist/easylist](https://code.google.com/p/ruadlist)
-    * => weekly updates, approx. 2.000 entries
+    * [reg_ch](https://easylist-downloads.adblockplus.org/easylistchina+easylist.txt)
+    * => regional blocklist for China, daily updates, approx. 1.600 entries
+    * [reg_pl](http://adblocklist.org)
+    * => regional blocklist for Poland, daily updates, approx. 50 entries
+    * [reg_ro](https://easylist-downloads.adblockplus.org/rolist+easylist.txt)
+    * => regional blocklist for Romania, weekly updates, approx. 600 entries
+    * [reg_ru](https://code.google.com/p/ruadlist)
+    * => regional blocklist for Russia, weekly updates, approx. 2.000 entries
     * [securemecca](http://www.securemecca.com)
     * => infrequent updates, approx. 25.000 entries
     * [shallalist](http://www.shallalist.de) (categories "adv" "costtraps" "spyware" "tracker" "warez" enabled by default)
@@ -67,7 +71,7 @@ A lot of people already use adblocker plugins within their desktop browsers, but
 * procd based init system support (start/stop/restart/reload/suspend/resume/query)
 * procd based hotplug support, the adblock start will be solely triggered by network interface triggers
 * suspend & resume adblock actions temporarily without block list reloading
-* runtime statistics via ubus service call
+* runtime information via ubus service call
 * query function to quickly identify blocked (sub-)domains, e.g. for whitelisting
 * optional: automatic block list backup & restore, backups will be (de-)compressed and restored on the fly in case of any runtime error
 * optional: add new adblock sources on your own via uci config
@@ -75,9 +79,8 @@ A lot of people already use adblocker plugins within their desktop browsers, but
 ## Prerequisites
 * [LEDE project](https://www.lede-project.org), tested with latest stable release (LEDE 17.01) and with current LEDE snapshot
 * a usual setup with an enabled dns backend at minimum - dump AP modes without a working dns backend are _not_ supported
-* a download utility: full versions (with ssl support) of 'wget', 'uclient-fetch', 'aria2c' or 'curl' are supported - the Chaos Calmer built-in busybox wget is not
-    * Chaos Calmer: download & install the external 'wget' package
-    * Designated Driver/Trunk: use built-in 'uclient-fetch' or download & install the external 'wget' package
+* a download utility: full versions (with ssl support) of 'wget', 'uclient-fetch', 'aria2c' or 'curl' are supported
+    * LEDE 17.01 or LEDE snapshot: use built-in 'uclient-fetch' or download & install the external 'wget' package
     * for more configuration options see examples below
 
 ## OpenWrt / LEDE trunk Installation & Usage
@@ -92,13 +95,13 @@ A lot of people already use adblocker plugins within their desktop browsers, but
 * _Thanks to Hannu Nyman for this great adblock LuCI frontend!_
 
 ## Tweaks
-* **status/runtime statistics:** the adblock status and runtime statistics are available via ubus service call (see example below)
+* **runtime information:** the adblock status is available via ubus service call (see example below)
 * **debug logging:** for script debugging please set the config option 'adb\_debug' to '1' and check the runtime output with _logread -e "adblock"_
 * **storage expansion:** to process and store all block list sources at once it might helpful to enlarge your temp directory with a swap partition => see [openwrt wiki](https://wiki.openwrt.org/doc/uci/fstab) for further details
-* **add white-/blacklist entries:** add domain white- or blacklist entries to always-allow or -deny certain (sub) domains, by default both lists are empty and located in _/etc/adblock_. Please add one domain per line - ip addresses, wildcards & regex are _not_ allowed (see example below)
+* **add white- / blacklist entries:** add domain white- or blacklist entries to always-allow or -deny certain (sub) domains, by default both lists are empty and located in _/etc/adblock_. Please add one domain per line - ip addresses, wildcards & regex are _not_ allowed (see example below)
 * **backup & restore block lists:** enable this feature, to restore automatically the latest compressed backup of your block lists in case of any processing error (e.g. a single block list source is not available during update). Please use an (external) solid partition and _not_ your volatile router temp directory for this
 * **scheduled list updates:** for a scheduled call of the adblock service add an appropriate crontab entry (see example below)
-* **restrict/disable procd interface trigger:** to restrict the procd interface trigger to a (list of) certain wan interface(s) or to disable it at all, set 'adb\_iface' to an existing interface like 'wan' or to a non-existing like 'false'
+* **restrict procd interface trigger:** restrict the procd interface trigger to a (list of) certain interface(s) (default: wan). To disable it at all, remove all entries
 * **suspend & resume adblocking:** to quickly switch the adblock service 'on' or 'off', simply use _/etc/init.d/adblock [suspend|resume]_
 * **domain query:** to query the active block lists for a specific domain, please run _/etc/init.d/adblock query `<DOMAIN>`_ (see example below)
 * **divert dns requests:** to force dns requests to your local dns resolver add an appropriate firewall rule (see example below)
@@ -109,12 +112,11 @@ A lot of people already use adblocker plugins within their desktop browsers, but
 * usually the pre-configured adblock setup works quite well and no manual config overrides are needed, all listed options apply to the 'global' config section:
     * adb\_enabled => main switch to enable/disable adblock service (default: '1', enabled)
     * adb\_debug => enable/disable adblock debug output (default: '0', disabled)
-    * adb\_iface => set the procd interface trigger to a (list of) lan/wan interface(s) (default: 'wan wwan lan')
+    * adb\_iface => set the procd interface trigger to a (list of) lan / wan interface(s) (default: 'wan')
     * adb\_fetch => full path to a different download utility, see example below (default: not set, use wget)
     * adb\_fetchparm => options for the download utility, see example below (default: not set, use wget options)
 
 ## Examples
-
 **change default dns backend to 'unbound':**
 <pre><code>
 Adblock detects the presence of an active unbound dns backend and the block lists will be automatically pulled in by unbound.
@@ -143,7 +145,7 @@ curl:
   option adb_fetchparm '-s --connect-timeout 10 --insecure -o'
 </code></pre>
   
-**receive adblock statistics via ubus:**
+**receive adblock runtime information via ubus:**
 <pre><code>
 ubus call service get_data '{"name":"adblock"}
 This will output the active block lists and other runtime information as JSON, e.g.:
@@ -152,35 +154,25 @@ This will output the active block lists and other runtime information as JSON, e
         "adblock": {
             "active_lists": [
                 {
-                    "palevo": "14",
-                    "blacklist": "147",
+                    "reg_pl": "45",
+                    "blacklist": "144",
                     "winspy": "138",
-                    "adaway": "378",
-                    "zeus": "397",
-                    "rolist": "652",
-                    "malwarelist": "1157",
-                    "yoyo": "2272",
-                    "ruadlist": "1793",
-                    "ransomware": "1670",
-                    "dshield": "190",
-                    "openphish": "2672",
-                    "disconnect": "2910",
-                    "spam404": "5715",
-                    "whocares": "8900",
-                    "winhelp": "8528",
-                    "adguard": "10790",
-                    "securemecca": "5080",
-                    "sysctl": "7906",
-                    "malware": "14617",
-                    "hphosts": "12450",
-                    "shalla": "23926"
+                    "adaway": "379",
+                    "zeus": "399",
+                    "reg_ro": "656",
+                    "reg_ch": "1631",
+                    "yoyo": "2320",
+                    "reg_ru": "2397",
+                    "ransomware": "1681",
+                    "disconnect": "5157",
+                    "adguard": "12799"
                 }
             ],
-            "adblock_version": "2.5.0",
-            "blocked_domains": "112302",
+            "adblock_version": "2.5.1",
+            "blocked_domains": "27746",
             "dns_backend": "dnsmasq",
-            "last_rundate": "25.03.2017 21:09:12",
-            "system": "LEDE Reboot SNAPSHOT r3867-313197d707"
+            "last_rundate": "04.04.2017 11:02:40",
+            "system": "LEDE Reboot SNAPSHOT r3904-c3778f2647"
         }
     }
 }
index 0cdb4e1c429b9f958a12b15a2d686a9f0ce7605d..fd3a0855e9e6c6c87d69f649e6b0062477c63a77 100644 (file)
@@ -4,7 +4,7 @@
 config adblock 'global'
        option adb_enabled '1'
        option adb_debug '0'
-       option adb_iface 'wan wwan lan'
+       option adb_iface 'wan'
        option adb_whitelist '/etc/adblock/adblock.whitelist'
        option adb_whitelist_rset '\$1 ~/^([A-Za-z0-9_-]+\.){1,}[A-Za-z]+/{print tolower(\"^\"\$1\"\\\|[.]\"\$1)}'
        option adb_backup '0'
@@ -82,13 +82,25 @@ config source 'ransomware'
        option adb_src_rset '\$1 ~/^([A-Za-z0-9_-]+\.){1,}[A-Za-z]+/{print tolower(\$1)}'
        option adb_src_desc 'focus on ransomware, numerous updates on the same day, approx. 130 entries'
 
-config source 'rolist'
+config source 'reg_ch'
+       option enabled '0'
+       option adb_src 'https://easylist-downloads.adblockplus.org/easylistchina+easylist.txt'
+       option adb_src_rset '{FS=\"[|^]\"} \$0 ~/^\|\|([A-Za-z0-9_-]+\.){1,}[A-Za-z]+\^$/{print tolower(\$3)}'
+       option adb_src_desc 'focus on chinese ads, daily updates, approx. 1.600 entries'
+
+config source 'reg_pl'
+       option enabled '0'
+       option adb_src 'http://adblocklist.org/adblock-pxf-polish.txt'
+       option adb_src_rset '{FS=\"[|^]\"} \$0 ~/^\|\|([A-Za-z0-9_-]+\.){1,}[A-Za-z]+\^$/{print tolower(\$3)}'
+       option adb_src_desc 'focus on polish ads, daily updates, approx. 50 entries'
+
+config source 'reg_ro'
        option enabled '0'
        option adb_src 'https://easylist-downloads.adblockplus.org/rolist+easylist.txt'
        option adb_src_rset '{FS=\"[|^]\"} \$0 ~/^\|\|([A-Za-z0-9_-]+\.){1,}[A-Za-z]+\^$/{print tolower(\$3)}'
        option adb_src_desc 'focus on romanian ads plus generic easylist additions, weekly updates, approx. 600 entries'
 
-config source 'ruadlist'
+config source 'reg_ru'
        option enabled '0'
        option adb_src 'https://easylist-downloads.adblockplus.org/ruadlist+easylist.txt'
        option adb_src_rset '{FS=\"[|^]\"} \$0 ~/^\|\|([A-Za-z0-9_-]+\.){1,}[A-Za-z]+\^$/{print tolower(\$3)}'
index ee1cd075bf6db39f122a06bfac0450e171a805ac..822317e16effb7100d56edb65be2dbd18e5f9679 100755 (executable)
@@ -20,7 +20,7 @@ boot()
     do
         list="${list} network.interface.${name}"
     done
-    ubus -t 60 wait_for network.interface ${list}
+    ubus -t 60 wait_for network.interface ${list} 2>/dev/null
     rc_procd start_service
 }
 
index 6d8d92255b5a7aab70d30a571dc5e2dcee5b5234..b2bda56192f6e8a87752488ac4cf64338896cd0a 100755 (executable)
@@ -10,7 +10,7 @@
 #
 LC_ALL=C
 PATH="/usr/sbin:/usr/bin:/sbin:/bin"
-adb_ver="2.5.0"
+adb_ver="2.5.1"
 adb_sysver="$(ubus -S call system board | jsonfilter -e '@.release.description')"
 adb_enabled=1
 adb_debug=0
index bb767fbf480a38fd1f1eda10077194fa2406c7e4..1f8c1040f0206eb789741641074506701344e7a4 100644 (file)
@@ -9,12 +9,12 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=haproxy
-PKG_VERSION:=1.7.4
-PKG_RELEASE:=02
+PKG_VERSION:=1.7.5
+PKG_RELEASE:=01
 
 PKG_SOURCE:=haproxy-$(PKG_VERSION).tar.gz
 PKG_SOURCE_URL:=http://www.haproxy.org/download/1.7/src/
-PKG_MD5SUM:=dfdb293217f5077696d034564043a3ae
+PKG_MD5SUM:=ed84c80cb97852d2aa3161ed16c48a1c
 
 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION)
 PKG_LICENSE:=GPL-2.0
index 4b2f5be68bb39c75c67db8b609b6f4e36bc342b0..627fd449fc15a594d21a03d166dbc046d73bf8e0 100644 (file)
@@ -86,7 +86,7 @@ endef
 # not found:
 MAKE_FLAGS += \
        LD="$(TARGET_CC)"  \
-       CFLAGS_DEBUG="$(TARGET_CFLAGS)" \
+       CFLAGS_DEBUG="$(TARGET_CFLAGS) $(TARGET_CPPFLAGS)" \
        LINKOPTS=-lc \
        LDCONFIG= \
        ETCBASE="$(PKG_INSTALL_DIR)/etc" \
index b59ff53749ff42827b743c58104571b48bd2a3ef..f4e71088c5f84e0d9197b9f9df9fb8bfe0f75bd3 100644 (file)
@@ -38,6 +38,7 @@ define Build/Compile
        $(MAKE) -C $(PKG_BUILD_DIR) \
                CC="$(TARGET_CC)" \
                CFLAGS="$(TARGET_CFLAGS)" \
+               CPPFLAGS="$(TARGET_CPPFLAGS)" \
                LDFLAGS="$(TARGET_LDFLAGS)" \
                ENABLE_REGEX=1 \
                USELIBCONFIG=1 \
index 921597dcf1512277e44c74b6f745d16c0fc3ca00..d02fbf864ee8b435f6ac5eb6449d31a4ef0e084a 100644 (file)
@@ -8,12 +8,12 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=vnstat
-PKG_VERSION:=1.12
+PKG_VERSION:=1.17
 PKG_RELEASE:=1
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
 PKG_SOURCE_URL:=http://humdi.net/vnstat
-PKG_MD5SUM:=a154b2196771e06a8accd1c24374009c
+PKG_HASH:=18e4c53576ca9e1ef2f0e063a6d83b0c44e3b1cf008560d658745df5c9aa7971
 PKG_MAINTAINER:=Jo-Philipp Wich <jo@mein.io>
 
 PKG_INSTALL:=1
@@ -86,7 +86,7 @@ define Package/vnstat/install
        $(INSTALL_DIR) $(1)/usr/sbin
        $(CP) $(PKG_INSTALL_DIR)/usr/sbin/vnstatd $(1)/usr/sbin/
        $(INSTALL_DIR) $(1)/etc
-       $(INSTALL_CONF) $(PKG_INSTALL_DIR)/etc/vnstat.conf $(1)/etc/
+       $(INSTALL_CONF) $(PKG_BUILD_DIR)/cfg/vnstat.conf $(1)/etc/
        $(INSTALL_DIR) $(1)/etc/config
        $(INSTALL_CONF) ./files/vnstat.config $(1)/etc/config/vnstat
        $(INSTALL_DIR) $(1)/etc/init.d
diff --git a/net/vnstat/patches/001-conf.patch b/net/vnstat/patches/001-conf.patch
deleted file mode 100644 (file)
index 5fb24c3..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
---- a/cfg/vnstat.conf
-+++ b/cfg/vnstat.conf
-@@ -78,13 +78,13 @@ DaemonUser ""
- DaemonGroup ""
- # how often (in seconds) interface data is updated
--UpdateInterval 30
-+UpdateInterval 60
- # how often (in seconds) interface status changes are checked
--PollInterval 5
-+PollInterval 30
- # how often (in minutes) data is saved to file
--SaveInterval 5
-+SaveInterval 30
- # how often (in minutes) data is saved when all interface are offline
- OfflineSaveInterval 30
diff --git a/net/vnstat/patches/002-no_install_strip.patch b/net/vnstat/patches/002-no_install_strip.patch
deleted file mode 100644 (file)
index 8f11de6..0000000
+++ /dev/null
@@ -1,35 +0,0 @@
---- a/Makefile
-+++ b/Makefile
-@@ -66,11 +66,11 @@ install:
- # install everything else
-       install -d -m 755 $(BIN) $(SBIN) $(MAN)/man1 $(MAN)/man5
--      install -s -m 755 src/vnstat $(BIN)
--      install -s -m 755 src/vnstatd $(SBIN)
-+      install -m 755 src/vnstat $(BIN)
-+      install -m 755 src/vnstatd $(SBIN)
-       @if [ -f "src/vnstati" ]; \
--      then echo install -s -m 755 src/vnstati $(BIN); \
--      install -s -m 755 src/vnstati $(BIN); \
-+      then echo install -m 755 src/vnstati $(BIN); \
-+      install -m 755 src/vnstati $(BIN); \
-       fi
- # update man pages, gzip it if previous version was done so   
-@@ -139,12 +139,12 @@ bsdinstall:
- # install binaries
-       install -d -m 755 $(DESTDIR)/var/db/vnstat
--      install -s -m 755 src/vnstat $(BIN_BSD)
--      install -s -m 755 src/vnstatd $(SBIN_BSD)
-+      install -m 755 src/vnstat $(BIN_BSD)
-+      install -m 755 src/vnstatd $(SBIN_BSD)
-       @if [ -f "src/vnstati" ]; \
--      then echo install -s -m 755 src/vnstati $(BIN_BSD); \
--      install -s -m 755 src/vnstati $(BIN_BSD); \
-+      then echo install -m 755 src/vnstati $(BIN_BSD); \
-+      install -m 755 src/vnstati $(BIN_BSD); \
-       fi
- # install default config if such doesn't exist
diff --git a/net/vnstat/patches/003-no_install_uname.patch b/net/vnstat/patches/003-no_install_uname.patch
deleted file mode 100644 (file)
index 14c17d5..0000000
+++ /dev/null
@@ -1,15 +0,0 @@
---- a/Makefile
-+++ b/Makefile
-@@ -33,12 +33,6 @@ debug:
- install:
-       @echo "Installing vnStat..."
--# check that system is really Linux
--      @if [ `uname` != "Linux" ]; \
--      then echo "This isn't a Linux system. Maybe 'make bsdinstall' is what you need?"; \
--      false; \
--      fi
--
- # check that there's something to install
-       @if [ ! -f "src/vnstat" ] || [ ! -f "src/vnstatd" ]; \
-       then echo "Nothing to install, run make first."; \
diff --git a/net/vnstat/patches/100-musl-compat.patch b/net/vnstat/patches/100-musl-compat.patch
deleted file mode 100644 (file)
index 0512389..0000000
+++ /dev/null
@@ -1,10 +0,0 @@
---- a/src/common.h
-+++ b/src/common.h
-@@ -22,6 +22,7 @@
- #include <pwd.h>
- #include <grp.h>
- #include <libgen.h>
-+#include <fcntl.h>
- #if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__APPLE__) || defined(__FreeBSD_kernel__)
- #include <sys/param.h>
diff --git a/net/vnstat/patches/990-adjust-configuration-defaults.patch b/net/vnstat/patches/990-adjust-configuration-defaults.patch
new file mode 100644 (file)
index 0000000..1627b4d
--- /dev/null
@@ -0,0 +1,28 @@
+From: Jo-Philipp Wich <jo@mein.io>
+Date: Thu, 26 Jan 2017 15:30:00 +0100
+Subject: [PATCH] config: adjust default values
+
+Adjust the default interval settings to be better suited for slower embedded
+devices.
+
+Signed-off-by: Jo-Philipp Wich <jo@mein.io>
+
+--- a/cfg/vnstat.conf
++++ b/cfg/vnstat.conf
+@@ -87,13 +87,13 @@ DaemonUser ""
+ DaemonGroup ""
+ # how often (in seconds) interface data is updated
+-UpdateInterval 30
++UpdateInterval 60
+ # how often (in seconds) interface status changes are checked
+-PollInterval 5
++PollInterval 30
+ # how often (in minutes) data is saved to file
+-SaveInterval 5
++SaveInterval 30
+ # how often (in minutes) data is saved when all interface are offline
+ OfflineSaveInterval 30
index ed4be9f2b2da5813f1e71537a430d97b0582d46b..2bc18e3f5d383b4f1151b4512fccfc599e0c9f92 100644 (file)
@@ -8,12 +8,12 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=webui-aria2
+PKG_SOURCE_DATE:=2017-04-02
 PKG_RELEASE:=1
 
 PKG_SOURCE_PROTO:=git
-PKG_SOURCE_URL:=https://github.com/ziahamza/webui-aria2.git
-PKG_SOURCE_DATE:=2017-02-12
-PKG_SOURCE_VERSION:=68c8ad4f86b87a8b713e13f70b4a3a3c7b86c83e
+PKG_SOURCE_URL:=https://github.com/ziahamza/webui-aria2
+PKG_SOURCE_VERSION:=d2a662849a792bb8d7b83519bac1eeee0fcec4e9
 
 PKG_LICENSE:=MIT
 PKG_LICENSE_FILES:=LICENSE
index 6c1b489720fec841bb643421bf3d9d19affdb2df..e3de6a952cb3f062d3344747840bde49e67d6b10 100644 (file)
@@ -128,6 +128,7 @@ TARGET_LDFLAGS+= -lasound -lpthread -lm -lrt
 
 ifeq ($(BUILD_VARIANT),full)
     TARGET_CFLAGS+= -DLINKALL
+    TARGET_LDFLAGS+= -lvorbis -logg
 endif
 
 define Package/squeezelite/install
index 9c44a35586dc2b26ac0cf97ed8b22d1f049a82a4..6b907523cf8f4fd43aaed353ea012fae6f0d42c7 100644 (file)
@@ -29,7 +29,7 @@ define Package/hfsprogs/Default
   SECTION:=utils
   CATEGORY:=Utilities
   SUBMENU:=Filesystem
-  DEPENDS:=+libopenssl
+  DEPENDS:=+libopenssl +USE_GLIBC:libbsd
 endef
 
 define Package/hfsfsck
@@ -59,7 +59,8 @@ define Build/Compile
        $(MAKE) -C $(PKG_BUILD_DIR) \
                -f Makefile.lnx \
                $(TARGET_CONFIGURE_OPTS) \
-               CFLAGS+="$(TARGET_CFLAGS) -I$(PKG_BUILD_DIR)/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1" \
+               CFLAGS+="$(TARGET_CFLAGS) $(TARGET_CPPFLAGS) -I$(PKG_BUILD_DIR)/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1" \
+               LDFLAGS+="$(TARGET_LDFLAGS) -lbsd" \
                all
 endef