From 261948090e9073514ac4b5f64c8715cf0a71eafa Mon Sep 17 00:00:00 2001 From: Marcel Holtmann Date: Thu, 6 Dec 2018 21:28:18 +0100 Subject: [PATCH] build: Move declaration of _GNU_SOURCE back into individual source files --- android/avdtptest.c | 1 + android/avrcp-lib.c | 1 + android/bluetooth.c | 4 ++-- android/client/haltest.c | 1 + android/client/if-audio.c | 1 + android/client/if-av-sink.c | 1 + android/client/if-av.c | 1 + android/client/if-bt.c | 1 + android/client/if-gatt.c | 2 +- android/client/if-hf-client.c | 1 + android/client/if-hf.c | 1 + android/client/if-hh.c | 1 + android/client/if-hl.c | 1 + android/client/if-mce.c | 1 + android/client/if-pan.c | 1 + android/client/if-rc-ctrl.c | 1 + android/client/if-rc.c | 1 + android/client/if-sco.c | 1 + android/client/if-sock.c | 1 + android/client/tabcompletion.c | 1 + android/gatt.c | 6 +++--- android/hal-audio-aptx.c | 1 + android/hal-audio-sbc.c | 1 + android/hal-audio.c | 1 + android/hal-avrcp-ctrl.c | 1 + android/hal-avrcp.c | 1 + android/hal-bluetooth.c | 1 + android/hal-gatt.c | 1 + android/hal-handsfree.c | 1 + android/hal-pan.c | 1 + android/hal-sco.c | 1 + android/hal-socket.c | 1 + android/hal-utils.c | 1 + android/hardware/hardware.c | 1 + android/health.c | 1 + android/ipc-tester.c | 1 + android/main.c | 1 + android/pan.c | 1 + android/system-emulator.c | 1 + android/tester-a2dp.c | 1 + android/tester-avrcp.c | 1 + android/tester-bluetooth.c | 2 ++ android/tester-gatt.c | 1 + android/tester-hdp.c | 1 + android/tester-hidhost.c | 1 + android/tester-main.c | 2 ++ android/tester-map-client.c | 1 + android/tester-pan.c | 1 + android/tester-socket.c | 1 + attrib/att.c | 2 +- attrib/gattrib.c | 2 +- attrib/interactive.c | 3 ++- attrib/utils.c | 2 +- btio/btio.c | 2 +- client/advertising.c | 1 + client/display.c | 1 + client/gatt.c | 1 + client/main.c | 1 + configure.ac | 1 - emulator/amp.c | 1 + emulator/b1ee.c | 1 + emulator/bthost.c | 1 + emulator/hciemu.c | 1 + emulator/phy.c | 1 + emulator/serial.c | 1 + gdbus/client.c | 1 + gobex/gobex.c | 2 +- lib/hci.c | 1 + mesh/appkey.c | 1 + mesh/btmesh.c | 1 + mesh/crypto.c | 1 + mesh/main.c | 1 + mesh/mesh-db.c | 1 + mesh/mesh.c | 1 + mesh/net.c | 1 + mesh/storage.c | 1 + mesh/util.c | 1 + monitor/a2dp.c | 1 + monitor/avctp.c | 1 + monitor/avdtp.c | 1 + monitor/bnep.c | 1 + monitor/broadcom.c | 1 + monitor/control.c | 1 + monitor/display.c | 1 + monitor/ellisys.c | 1 + monitor/hcidump.c | 1 + monitor/hwdb.c | 1 + monitor/intel.c | 1 + monitor/l2cap.c | 1 + monitor/ll.c | 1 + monitor/lmp.c | 1 + monitor/main.c | 1 + monitor/packet.c | 1 + monitor/rfcomm.c | 1 + monitor/sdp.c | 1 + monitor/vendor.c | 1 + obexd/client/driver.c | 1 + obexd/client/ftp.c | 1 + obexd/client/map.c | 1 + obexd/client/mns.c | 1 + obexd/client/pbap.c | 1 + obexd/client/transport.c | 1 + obexd/plugins/filesystem.c | 1 + obexd/plugins/irmc.c | 1 + obexd/plugins/mas.c | 1 + obexd/plugins/phonebook-dummy.c | 1 + obexd/plugins/phonebook-tracker.c | 2 +- obexd/src/log.c | 1 + obexd/src/main.c | 1 + obexd/src/mimetype.c | 1 + peripheral/attach.c | 1 + peripheral/efivars.c | 1 + peripheral/log.c | 1 + peripheral/main.c | 1 + plugins/neard.c | 1 + plugins/sixaxis.c | 1 + profiles/audio/avrcp.c | 1 + profiles/audio/media.c | 1 + profiles/audio/player.c | 1 + profiles/audio/transport.c | 1 + profiles/cups/main.c | 1 + profiles/gap/gas.c | 1 + profiles/health/hdp.c | 3 ++- profiles/health/hdp_util.c | 1 + profiles/health/mcap.c | 4 +++- profiles/iap/main.c | 1 + profiles/input/device.c | 1 + profiles/network/bnep.c | 1 + profiles/network/connection.c | 1 + profiles/network/server.c | 1 + src/adapter.c | 1 + src/advertising.c | 5 +++++ src/device.c | 1 + src/eir.c | 1 + src/gatt-client.c | 1 + src/log.c | 1 + src/main.c | 1 + src/oui.c | 1 + src/profile.c | 1 + src/rfkill.c | 1 + src/sdp-xml.c | 1 + src/sdpd-server.c | 1 + src/shared/ad.c | 8 +++++++- src/shared/btsnoop.c | 1 + src/shared/ecc.c | 2 ++ src/shared/hfp.c | 1 + src/shared/log.c | 1 + src/shared/mainloop-glib.c | 1 + src/shared/mainloop-notify.c | 1 + src/shared/mainloop.c | 1 + src/shared/pcap.c | 1 + src/shared/ringbuf.c | 1 + src/shared/shell.c | 1 + src/shared/tester.c | 1 + src/shared/uhid.c | 1 + src/shared/util.c | 1 + src/storage.c | 1 + src/textfile.c | 1 + src/uuid-helper.c | 1 + tools/bccmd.c | 1 + tools/bcmfw.c | 1 + tools/bluetooth-player.c | 1 + tools/bneptest.c | 1 + tools/btattach.c | 1 + tools/btgatt-client.c | 1 + tools/btgatt-server.c | 1 + tools/btiotest.c | 2 +- tools/btmgmt.c | 1 + tools/btmon-logger.c | 1 + tools/btproxy.c | 1 + tools/btsnoop.c | 1 + tools/check-selftest.c | 1 + tools/ciptool.c | 1 + tools/create-image.c | 1 + tools/csr.c | 1 + tools/csr_bcsp.c | 1 + tools/csr_h4.c | 1 + tools/csr_usb.c | 1 + tools/gatt-service.c | 1 + tools/hciattach.c | 1 + tools/hciattach_ath3k.c | 1 + tools/hciattach_bcm43xx.c | 1 + tools/hciattach_intel.c | 1 + tools/hciattach_qualcomm.c | 1 + tools/hciattach_ti.c | 1 + tools/hciattach_tialt.c | 1 + tools/hciconfig.c | 1 + tools/hcidump.c | 1 + tools/hcitool.c | 1 + tools/hex2hcd.c | 1 + tools/hid2hci.c | 1 + tools/l2ping.c | 1 + tools/l2test.c | 1 + tools/mcaptest.c | 1 + tools/meshctl.c | 1 + tools/mpris-proxy.c | 1 + tools/nokfw.c | 1 + tools/obex-client-tool.c | 3 ++- tools/obex-server-tool.c | 3 ++- tools/obexctl.c | 1 + tools/parser/amp.c | 1 + tools/parser/att.c | 1 + tools/parser/avctp.c | 1 + tools/parser/avdtp.c | 1 + tools/parser/avrcp.c | 1 + tools/parser/bnep.c | 1 + tools/parser/bpa.c | 1 + tools/parser/capi.c | 1 + tools/parser/cmtp.c | 1 + tools/parser/csr.c | 1 + tools/parser/ericsson.c | 1 + tools/parser/hci.c | 1 + tools/parser/hcrp.c | 1 + tools/parser/hidp.c | 1 + tools/parser/l2cap.c | 1 + tools/parser/lmp.c | 1 + tools/parser/obex.c | 1 + tools/parser/parser.c | 1 + tools/parser/ppp.c | 1 + tools/parser/rfcomm.c | 1 + tools/parser/sap.c | 1 + tools/parser/sdp.c | 1 + tools/parser/smp.c | 1 + tools/parser/tcpip.c | 1 + tools/rctest.c | 1 + tools/rfcomm.c | 1 + tools/rtlfw.c | 1 + tools/scotest.c | 1 + tools/sdptool.c | 1 + tools/seq2bseq.c | 1 + tools/test-runner.c | 1 + unit/test-gobex-apparam.c | 2 +- unit/test-gobex-header.c | 2 +- unit/test-gobex-packet.c | 2 +- unit/test-gobex-transfer.c | 2 +- unit/test-gobex.c | 2 +- unit/test-hog.c | 1 + unit/test-lib.c | 5 +++-- unit/test-ringbuf.c | 1 + unit/test-textfile.c | 1 + unit/util.c | 2 +- 241 files changed, 264 insertions(+), 28 deletions(-) diff --git a/android/avdtptest.c b/android/avdtptest.c index ce344437d..98b9ef0fa 100644 --- a/android/avdtptest.c +++ b/android/avdtptest.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/android/avrcp-lib.c b/android/avrcp-lib.c index 4edfd0e9b..2c874952c 100644 --- a/android/avrcp-lib.c +++ b/android/avrcp-lib.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/android/bluetooth.c b/android/bluetooth.c index 9c7ee7440..fb027bf34 100644 --- a/android/bluetooth.c +++ b/android/bluetooth.c @@ -4093,7 +4093,7 @@ bool bt_le_add_advertising(struct adv_instance *adv, DBG("lens: adv=%u sr=%u total=%zu", cp->adv_data_len, cp->scan_rsp_len, len); - cb_data = new0(typeof(*cb_data), 1); + cb_data = new0(__typeof__(*cb_data), 1); cb_data->cb = cb; cb_data->user_data = user_data; @@ -4134,7 +4134,7 @@ bool bt_le_remove_advertising(struct adv_instance *adv, struct addrm_adv_user_data *cb_data; bool ok; - cb_data = new0(typeof(*cb_data), 1); + cb_data = new0(__typeof__(*cb_data), 1); cb_data->cb = cb; cb_data->user_data = user_data; diff --git a/android/client/haltest.c b/android/client/haltest.c index 92cd8114a..e9a92a29a 100644 --- a/android/client/haltest.c +++ b/android/client/haltest.c @@ -19,6 +19,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/android/client/if-audio.c b/android/client/if-audio.c index 65e2f2ff9..630b5e685 100644 --- a/android/client/if-audio.c +++ b/android/client/if-audio.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include #include diff --git a/android/client/if-av-sink.c b/android/client/if-av-sink.c index 3087dcfb1..a6c867985 100644 --- a/android/client/if-av-sink.c +++ b/android/client/if-av-sink.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include "if-main.h" #include "../hal-utils.h" diff --git a/android/client/if-av.c b/android/client/if-av.c index 85c641b00..798a47aff 100644 --- a/android/client/if-av.c +++ b/android/client/if-av.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include "if-main.h" #include "../hal-utils.h" diff --git a/android/client/if-bt.c b/android/client/if-bt.c index c9acf6c83..75403ec4a 100644 --- a/android/client/if-bt.c +++ b/android/client/if-bt.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include diff --git a/android/client/if-gatt.c b/android/client/if-gatt.c index ed14f92c4..fbd938166 100644 --- a/android/client/if-gatt.c +++ b/android/client/if-gatt.c @@ -15,8 +15,8 @@ * */ +#define _GNU_SOURCE #include - #include #include diff --git a/android/client/if-hf-client.c b/android/client/if-hf-client.c index 3f6f7c288..f701a814c 100644 --- a/android/client/if-hf-client.c +++ b/android/client/if-hf-client.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include "if-main.h" #include "../hal-utils.h" diff --git a/android/client/if-hf.c b/android/client/if-hf.c index 6b798f86d..68df00b46 100644 --- a/android/client/if-hf.c +++ b/android/client/if-hf.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include "if-main.h" #include "../hal-utils.h" diff --git a/android/client/if-hh.c b/android/client/if-hh.c index 25519e5d7..04a54dea2 100644 --- a/android/client/if-hh.c +++ b/android/client/if-hh.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include #include diff --git a/android/client/if-hl.c b/android/client/if-hl.c index bd0567111..1498fd5b0 100644 --- a/android/client/if-hl.c +++ b/android/client/if-hl.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include #include diff --git a/android/client/if-mce.c b/android/client/if-mce.c index 5f101e001..ef1968920 100644 --- a/android/client/if-mce.c +++ b/android/client/if-mce.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include "if-main.h" #include "../hal-utils.h" diff --git a/android/client/if-pan.c b/android/client/if-pan.c index b0c4b8410..b3098ba45 100644 --- a/android/client/if-pan.c +++ b/android/client/if-pan.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include "if-main.h" #include "../hal-utils.h" diff --git a/android/client/if-rc-ctrl.c b/android/client/if-rc-ctrl.c index 398076410..39e4b9051 100644 --- a/android/client/if-rc-ctrl.c +++ b/android/client/if-rc-ctrl.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include #include diff --git a/android/client/if-rc.c b/android/client/if-rc.c index ed65600fe..6a5bffb6c 100644 --- a/android/client/if-rc.c +++ b/android/client/if-rc.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include #include diff --git a/android/client/if-sco.c b/android/client/if-sco.c index 5a68ed57a..6b570d229 100644 --- a/android/client/if-sco.c +++ b/android/client/if-sco.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include #include diff --git a/android/client/if-sock.c b/android/client/if-sock.c index ee2c1e87c..a188cf680 100644 --- a/android/client/if-sock.c +++ b/android/client/if-sock.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include #include diff --git a/android/client/tabcompletion.c b/android/client/tabcompletion.c index bcca5fa48..dc6faa887 100644 --- a/android/client/tabcompletion.c +++ b/android/client/tabcompletion.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include #include diff --git a/android/gatt.c b/android/gatt.c index 6b36985d3..9351a667d 100644 --- a/android/gatt.c +++ b/android/gatt.c @@ -5636,7 +5636,7 @@ static struct adv_instance *find_adv_instance(uint32_t client_if) if (!inst) return NULL; - adv = new0(typeof(*adv), 1); + adv = new0(__typeof__(*adv), 1); adv->instance = inst; app->adv = adv; @@ -5834,7 +5834,7 @@ static void handle_client_setup_multi_adv_inst(const void *buf, uint16_t len) adv->ad = adv_data; } - cb_data = new0(typeof(*cb_data), 1); + cb_data = new0(__typeof__(*cb_data), 1); cb_data->client_if = cmd->client_if; cb_data->adv = adv; @@ -5894,7 +5894,7 @@ static void handle_client_disable_multi_adv_inst(const void *buf, uint16_t len) if (!adv) goto out; - cb_data = new0(typeof(*cb_data), 1); + cb_data = new0(__typeof__(*cb_data), 1); cb_data->client_if = cmd->client_if; cb_data->adv = adv; diff --git a/android/hal-audio-aptx.c b/android/hal-audio-aptx.c index a8000759b..bff2331a9 100644 --- a/android/hal-audio-aptx.c +++ b/android/hal-audio-aptx.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include #include diff --git a/android/hal-audio-sbc.c b/android/hal-audio-sbc.c index 7ad3a6a51..9da9575f5 100644 --- a/android/hal-audio-sbc.c +++ b/android/hal-audio-sbc.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include #include diff --git a/android/hal-audio.c b/android/hal-audio.c index 207101fa8..2b25b6e08 100644 --- a/android/hal-audio.c +++ b/android/hal-audio.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include #include diff --git a/android/hal-avrcp-ctrl.c b/android/hal-avrcp-ctrl.c index 46b77fd8f..a6137a5ad 100644 --- a/android/hal-avrcp-ctrl.c +++ b/android/hal-avrcp-ctrl.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include #include diff --git a/android/hal-avrcp.c b/android/hal-avrcp.c index f935eda51..b2127ade9 100644 --- a/android/hal-avrcp.c +++ b/android/hal-avrcp.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include #include diff --git a/android/hal-bluetooth.c b/android/hal-bluetooth.c index 66f4a3774..f22801b04 100644 --- a/android/hal-bluetooth.c +++ b/android/hal-bluetooth.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include #include diff --git a/android/hal-gatt.c b/android/hal-gatt.c index f7217c789..2e706cf24 100644 --- a/android/hal-gatt.c +++ b/android/hal-gatt.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include #include diff --git a/android/hal-handsfree.c b/android/hal-handsfree.c index 3847901a9..af21b675f 100644 --- a/android/hal-handsfree.c +++ b/android/hal-handsfree.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include #include diff --git a/android/hal-pan.c b/android/hal-pan.c index 61d44a930..5e1afc80a 100644 --- a/android/hal-pan.c +++ b/android/hal-pan.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include #include diff --git a/android/hal-sco.c b/android/hal-sco.c index 2c95866e7..f4b4d3160 100644 --- a/android/hal-sco.c +++ b/android/hal-sco.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include #include diff --git a/android/hal-socket.c b/android/hal-socket.c index cfd50d154..b971074f9 100644 --- a/android/hal-socket.c +++ b/android/hal-socket.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include #include diff --git a/android/hal-utils.c b/android/hal-utils.c index e45f6e4a6..74f292756 100644 --- a/android/hal-utils.c +++ b/android/hal-utils.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include #include diff --git a/android/hardware/hardware.c b/android/hardware/hardware.c index 3a45fe1f1..42d03ba52 100644 --- a/android/hardware/hardware.c +++ b/android/hardware/hardware.c @@ -14,6 +14,7 @@ * limitations under the License. */ +#define _GNU_SOURCE #include #include diff --git a/android/health.c b/android/health.c index eb02a64ae..90253ac00 100644 --- a/android/health.c +++ b/android/health.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/android/ipc-tester.c b/android/ipc-tester.c index 3b7f13a0e..c1d0e8ad6 100644 --- a/android/ipc-tester.c +++ b/android/ipc-tester.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/android/main.c b/android/main.c index 03c8760b9..b505c2f77 100644 --- a/android/main.c +++ b/android/main.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/android/pan.c b/android/pan.c index c40a6d3e7..1e6d87641 100644 --- a/android/pan.c +++ b/android/pan.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/android/system-emulator.c b/android/system-emulator.c index 8bcf660e2..edf3e89e0 100644 --- a/android/system-emulator.c +++ b/android/system-emulator.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/android/tester-a2dp.c b/android/tester-a2dp.c index 8397eeff5..554a3941d 100644 --- a/android/tester-a2dp.c +++ b/android/tester-a2dp.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include "emulator/bthost.h" diff --git a/android/tester-avrcp.c b/android/tester-avrcp.c index 737602e5b..e0e7b7f6a 100644 --- a/android/tester-avrcp.c +++ b/android/tester-avrcp.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include "emulator/bthost.h" diff --git a/android/tester-bluetooth.c b/android/tester-bluetooth.c index b42a81db0..6db337a94 100644 --- a/android/tester-bluetooth.c +++ b/android/tester-bluetooth.c @@ -14,6 +14,8 @@ * limitations under the License. * */ + +#define _GNU_SOURCE #include #include "emulator/bthost.h" diff --git a/android/tester-gatt.c b/android/tester-gatt.c index 6400a3f3e..c10609732 100644 --- a/android/tester-gatt.c +++ b/android/tester-gatt.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include "emulator/bthost.h" diff --git a/android/tester-hdp.c b/android/tester-hdp.c index e8498205d..b4d14a339 100644 --- a/android/tester-hdp.c +++ b/android/tester-hdp.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include diff --git a/android/tester-hidhost.c b/android/tester-hidhost.c index 221b122e0..73092cda8 100644 --- a/android/tester-hidhost.c +++ b/android/tester-hidhost.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include "emulator/bthost.h" diff --git a/android/tester-main.c b/android/tester-main.c index 8d9add93c..3c5af299f 100644 --- a/android/tester-main.c +++ b/android/tester-main.c @@ -14,6 +14,8 @@ * limitations under the License. * */ + +#define _GNU_SOURCE #include #include #include diff --git a/android/tester-map-client.c b/android/tester-map-client.c index 695c7971f..ff3f272fc 100644 --- a/android/tester-map-client.c +++ b/android/tester-map-client.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include "emulator/bthost.h" diff --git a/android/tester-pan.c b/android/tester-pan.c index 9da2488ab..74ad107a8 100644 --- a/android/tester-pan.c +++ b/android/tester-pan.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include "emulator/bthost.h" diff --git a/android/tester-socket.c b/android/tester-socket.c index 2264a1f12..ac77e5aeb 100644 --- a/android/tester-socket.c +++ b/android/tester-socket.c @@ -15,6 +15,7 @@ * */ +#define _GNU_SOURCE #include #include #include diff --git a/attrib/att.c b/attrib/att.c index 826b3c183..c0438a382 100644 --- a/attrib/att.c +++ b/attrib/att.c @@ -23,7 +23,7 @@ */ #ifdef HAVE_CONFIG_H -#include "config.h" +#include #endif #include diff --git a/attrib/gattrib.c b/attrib/gattrib.c index 2e1e39ac6..57ca01541 100644 --- a/attrib/gattrib.c +++ b/attrib/gattrib.c @@ -23,7 +23,7 @@ */ #ifdef HAVE_CONFIG_H -#include "config.h" +#include #endif #include diff --git a/attrib/interactive.c b/attrib/interactive.c index 7d4786ac9..9a7976d34 100644 --- a/attrib/interactive.c +++ b/attrib/interactive.c @@ -22,9 +22,10 @@ */ #ifdef HAVE_CONFIG_H -#include "config.h" +#include #endif +#define _GNU_SOURCE #include #include #include diff --git a/attrib/utils.c b/attrib/utils.c index 8e2fc1a42..a74902959 100644 --- a/attrib/utils.c +++ b/attrib/utils.c @@ -22,7 +22,7 @@ */ #ifdef HAVE_CONFIG_H -#include "config.h" +#include #endif #include diff --git a/btio/btio.c b/btio/btio.c index 969cd3a52..af2276db9 100644 --- a/btio/btio.c +++ b/btio/btio.c @@ -23,7 +23,7 @@ */ #ifdef HAVE_CONFIG_H -#include "config.h" +#include #endif #include diff --git a/client/advertising.c b/client/advertising.c index 73f2f3df8..960cdd62d 100644 --- a/client/advertising.c +++ b/client/advertising.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/client/display.c b/client/display.c index bd23e8c17..05613865b 100644 --- a/client/display.c +++ b/client/display.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/client/gatt.c b/client/gatt.c index 9877c4b47..b6b517bdf 100644 --- a/client/gatt.c +++ b/client/gatt.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/client/main.c b/client/main.c index 196b31a4d..a4647f334 100644 --- a/client/main.c +++ b/client/main.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/configure.ac b/configure.ac index f46e38122..1a095a352 100644 --- a/configure.ac +++ b/configure.ac @@ -4,7 +4,6 @@ AC_INIT(bluez, 5.50) AM_INIT_AUTOMAKE([foreign subdir-objects color-tests silent-rules tar-pax no-dist-gzip dist-xz]) AC_CONFIG_HEADERS(config.h) -AC_USE_SYSTEM_EXTENSIONS m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) diff --git a/emulator/amp.c b/emulator/amp.c index c5c6b813d..605c6c825 100644 --- a/emulator/amp.c +++ b/emulator/amp.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/emulator/b1ee.c b/emulator/b1ee.c index 0d5226fcc..377181b01 100644 --- a/emulator/b1ee.c +++ b/emulator/b1ee.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/emulator/bthost.c b/emulator/bthost.c index d37957f33..6482bbecc 100644 --- a/emulator/bthost.c +++ b/emulator/bthost.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/emulator/hciemu.c b/emulator/hciemu.c index bc3677388..1045043f1 100644 --- a/emulator/hciemu.c +++ b/emulator/hciemu.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/emulator/phy.c b/emulator/phy.c index c63dc3830..beb8bbbe4 100644 --- a/emulator/phy.c +++ b/emulator/phy.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/emulator/serial.c b/emulator/serial.c index f404b15cb..1c324d531 100644 --- a/emulator/serial.c +++ b/emulator/serial.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/gdbus/client.c b/gdbus/client.c index dd5d2eb51..86e1c7693 100644 --- a/gdbus/client.c +++ b/gdbus/client.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/gobex/gobex.c b/gobex/gobex.c index ef5355ae9..77f1aaafd 100644 --- a/gobex/gobex.c +++ b/gobex/gobex.c @@ -21,7 +21,7 @@ */ #ifdef HAVE_CONFIG_H -# include "config.h" +#include #endif #include diff --git a/lib/hci.c b/lib/hci.c index 28e53f490..ccaef6b35 100644 --- a/lib/hci.c +++ b/lib/hci.c @@ -27,6 +27,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/mesh/appkey.c b/mesh/appkey.c index 2ddb1eb80..3d445d217 100644 --- a/mesh/appkey.c +++ b/mesh/appkey.c @@ -22,6 +22,7 @@ #include #endif +#define _GNU_SOURCE #include #include "mesh/mesh-defs.h" diff --git a/mesh/btmesh.c b/mesh/btmesh.c index 083947bae..5b724239c 100644 --- a/mesh/btmesh.c +++ b/mesh/btmesh.c @@ -22,6 +22,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/mesh/crypto.c b/mesh/crypto.c index dda867924..e68cc2d5f 100644 --- a/mesh/crypto.c +++ b/mesh/crypto.c @@ -21,6 +21,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/mesh/main.c b/mesh/main.c index db6bee588..173f57a8f 100644 --- a/mesh/main.c +++ b/mesh/main.c @@ -22,6 +22,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/mesh/mesh-db.c b/mesh/mesh-db.c index 7bddab010..86e17ed9a 100644 --- a/mesh/mesh-db.c +++ b/mesh/mesh-db.c @@ -22,6 +22,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/mesh/mesh.c b/mesh/mesh.c index 3fba0140c..d1d409672 100644 --- a/mesh/mesh.c +++ b/mesh/mesh.c @@ -22,6 +22,7 @@ #include #endif +#define _GNU_SOURCE #include #include diff --git a/mesh/net.c b/mesh/net.c index 30dc8032f..97b6f5b16 100644 --- a/mesh/net.c +++ b/mesh/net.c @@ -21,6 +21,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/mesh/storage.c b/mesh/storage.c index 937f801a6..1f3b25886 100644 --- a/mesh/storage.c +++ b/mesh/storage.c @@ -22,6 +22,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/mesh/util.c b/mesh/util.c index 5d771431c..2cdcdf37d 100644 --- a/mesh/util.c +++ b/mesh/util.c @@ -22,6 +22,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/monitor/a2dp.c b/monitor/a2dp.c index 94f9758aa..6a271217b 100644 --- a/monitor/a2dp.c +++ b/monitor/a2dp.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/monitor/avctp.c b/monitor/avctp.c index 94385d252..fe96f6da6 100644 --- a/monitor/avctp.c +++ b/monitor/avctp.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/monitor/avdtp.c b/monitor/avdtp.c index f5ef4c0c7..6a342a282 100644 --- a/monitor/avdtp.c +++ b/monitor/avdtp.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/monitor/bnep.c b/monitor/bnep.c index 1d9d8fcd5..6af54e0c5 100644 --- a/monitor/bnep.c +++ b/monitor/bnep.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/monitor/broadcom.c b/monitor/broadcom.c index fb96609eb..787ff2950 100644 --- a/monitor/broadcom.c +++ b/monitor/broadcom.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include diff --git a/monitor/control.c b/monitor/control.c index 46eed2a96..39a413be1 100644 --- a/monitor/control.c +++ b/monitor/control.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/monitor/display.c b/monitor/display.c index 411af9447..990395425 100644 --- a/monitor/display.c +++ b/monitor/display.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/monitor/ellisys.c b/monitor/ellisys.c index bafbb5d08..e533eeceb 100644 --- a/monitor/ellisys.c +++ b/monitor/ellisys.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/monitor/hcidump.c b/monitor/hcidump.c index bef1338f9..8b6f846d3 100644 --- a/monitor/hcidump.c +++ b/monitor/hcidump.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/monitor/hwdb.c b/monitor/hwdb.c index 6931660f1..f2431fad8 100644 --- a/monitor/hwdb.c +++ b/monitor/hwdb.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include diff --git a/monitor/intel.c b/monitor/intel.c index 4cd1788b7..41e70ba0c 100644 --- a/monitor/intel.c +++ b/monitor/intel.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include diff --git a/monitor/l2cap.c b/monitor/l2cap.c index 05a33b903..1e6ca3492 100644 --- a/monitor/l2cap.c +++ b/monitor/l2cap.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/monitor/ll.c b/monitor/ll.c index c5e110549..3ddbf7a07 100644 --- a/monitor/ll.c +++ b/monitor/ll.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include diff --git a/monitor/lmp.c b/monitor/lmp.c index b87b5496e..3088c5ee2 100644 --- a/monitor/lmp.c +++ b/monitor/lmp.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include diff --git a/monitor/main.c b/monitor/main.c index 8640c023d..acd44a098 100644 --- a/monitor/main.c +++ b/monitor/main.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/monitor/packet.c b/monitor/packet.c index eabd21914..06830fdaa 100644 --- a/monitor/packet.c +++ b/monitor/packet.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/monitor/rfcomm.c b/monitor/rfcomm.c index f3daf95ba..94d28de31 100644 --- a/monitor/rfcomm.c +++ b/monitor/rfcomm.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/monitor/sdp.c b/monitor/sdp.c index 1df26a0ca..575eda536 100644 --- a/monitor/sdp.c +++ b/monitor/sdp.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/monitor/vendor.c b/monitor/vendor.c index 8d3b61496..3dda2ae3b 100644 --- a/monitor/vendor.c +++ b/monitor/vendor.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include "packet.h" #include "vendor.h" diff --git a/obexd/client/driver.c b/obexd/client/driver.c index 27857b571..0dae35601 100644 --- a/obexd/client/driver.c +++ b/obexd/client/driver.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/obexd/client/ftp.c b/obexd/client/ftp.c index d799821b1..5e30654af 100644 --- a/obexd/client/ftp.c +++ b/obexd/client/ftp.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include diff --git a/obexd/client/map.c b/obexd/client/map.c index 3e581c8ee..550c5afb4 100644 --- a/obexd/client/map.c +++ b/obexd/client/map.c @@ -24,6 +24,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/obexd/client/mns.c b/obexd/client/mns.c index 14b184811..4912cb90f 100644 --- a/obexd/client/mns.c +++ b/obexd/client/mns.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/obexd/client/pbap.c b/obexd/client/pbap.c index 1ab34a7db..3f5665fcd 100644 --- a/obexd/client/pbap.c +++ b/obexd/client/pbap.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/obexd/client/transport.c b/obexd/client/transport.c index aae6780a2..4cd770672 100644 --- a/obexd/client/transport.c +++ b/obexd/client/transport.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/obexd/plugins/filesystem.c b/obexd/plugins/filesystem.c index 0e6cd49c3..48239a8bc 100644 --- a/obexd/plugins/filesystem.c +++ b/obexd/plugins/filesystem.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/obexd/plugins/irmc.c b/obexd/plugins/irmc.c index a3bbd60da..fcf5340e7 100644 --- a/obexd/plugins/irmc.c +++ b/obexd/plugins/irmc.c @@ -24,6 +24,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/obexd/plugins/mas.c b/obexd/plugins/mas.c index ef67ec59c..f73c3e9d8 100644 --- a/obexd/plugins/mas.c +++ b/obexd/plugins/mas.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/obexd/plugins/phonebook-dummy.c b/obexd/plugins/phonebook-dummy.c index b9e3a0d23..9279ef29a 100644 --- a/obexd/plugins/phonebook-dummy.c +++ b/obexd/plugins/phonebook-dummy.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/obexd/plugins/phonebook-tracker.c b/obexd/plugins/phonebook-tracker.c index 0743629cb..c1d14078b 100644 --- a/obexd/plugins/phonebook-tracker.c +++ b/obexd/plugins/phonebook-tracker.c @@ -21,7 +21,7 @@ */ #ifdef HAVE_CONFIG_H -#include "config.h" +#include #endif #include diff --git a/obexd/src/log.c b/obexd/src/log.c index f259728fc..8e2ebaab2 100644 --- a/obexd/src/log.c +++ b/obexd/src/log.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/obexd/src/main.c b/obexd/src/main.c index c774cda50..139f1412c 100644 --- a/obexd/src/main.c +++ b/obexd/src/main.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/obexd/src/mimetype.c b/obexd/src/mimetype.c index 833ddc721..c8b040a43 100644 --- a/obexd/src/mimetype.c +++ b/obexd/src/mimetype.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/peripheral/attach.c b/peripheral/attach.c index a70ca55c7..1de02ac04 100644 --- a/peripheral/attach.c +++ b/peripheral/attach.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/peripheral/efivars.c b/peripheral/efivars.c index a86031fbd..3cc213c0c 100644 --- a/peripheral/efivars.c +++ b/peripheral/efivars.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/peripheral/log.c b/peripheral/log.c index 7aaeb4d8c..d5834eb72 100644 --- a/peripheral/log.c +++ b/peripheral/log.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/peripheral/main.c b/peripheral/main.c index 93abe2042..75427ab3a 100644 --- a/peripheral/main.c +++ b/peripheral/main.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/plugins/neard.c b/plugins/neard.c index cabcf3408..6ffcd6e10 100644 --- a/plugins/neard.c +++ b/plugins/neard.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include diff --git a/plugins/sixaxis.c b/plugins/sixaxis.c index 9290dbe74..fed68d2d8 100644 --- a/plugins/sixaxis.c +++ b/plugins/sixaxis.c @@ -27,6 +27,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/profiles/audio/avrcp.c b/profiles/audio/avrcp.c index d5eba3964..6b3f685d2 100644 --- a/profiles/audio/avrcp.c +++ b/profiles/audio/avrcp.c @@ -27,6 +27,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/profiles/audio/media.c b/profiles/audio/media.c index 23d15611b..e2a447e56 100644 --- a/profiles/audio/media.c +++ b/profiles/audio/media.c @@ -27,6 +27,7 @@ #include #endif +#define _GNU_SOURCE #include #include diff --git a/profiles/audio/player.c b/profiles/audio/player.c index 048f98f96..f47f626d4 100644 --- a/profiles/audio/player.c +++ b/profiles/audio/player.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/profiles/audio/transport.c b/profiles/audio/transport.c index b9d357ec2..98f4e1ffd 100644 --- a/profiles/audio/transport.c +++ b/profiles/audio/transport.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include diff --git a/profiles/cups/main.c b/profiles/cups/main.c index aed8d31b8..1fac7267f 100644 --- a/profiles/cups/main.c +++ b/profiles/cups/main.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/profiles/gap/gas.c b/profiles/gap/gas.c index 43b7c3d0e..dffa31314 100644 --- a/profiles/gap/gas.c +++ b/profiles/gap/gas.c @@ -20,6 +20,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/profiles/health/hdp.c b/profiles/health/hdp.c index a6de97f49..541738357 100644 --- a/profiles/health/hdp.c +++ b/profiles/health/hdp.c @@ -21,9 +21,10 @@ */ #ifdef HAVE_CONFIG_H -#include "config.h" +#include #endif +#define _GNU_SOURCE #include #include #include diff --git a/profiles/health/hdp_util.c b/profiles/health/hdp_util.c index b459eaacc..64debfc6b 100644 --- a/profiles/health/hdp_util.c +++ b/profiles/health/hdp_util.c @@ -24,6 +24,7 @@ #include #endif +#define _GNU_SOURCE #include #include diff --git a/profiles/health/mcap.c b/profiles/health/mcap.c index b8522c2ab..249a75326 100644 --- a/profiles/health/mcap.c +++ b/profiles/health/mcap.c @@ -23,13 +23,15 @@ */ #ifdef HAVE_CONFIG_H -#include "config.h" +#include #endif +#define _GNU_SOURCE #include #include #include #include +#include #include diff --git a/profiles/iap/main.c b/profiles/iap/main.c index 53dd9fb9b..2fd34c067 100644 --- a/profiles/iap/main.c +++ b/profiles/iap/main.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/profiles/input/device.c b/profiles/input/device.c index 84614784d..a711ef527 100644 --- a/profiles/input/device.c +++ b/profiles/input/device.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/profiles/network/bnep.c b/profiles/network/bnep.c index 789c18dcf..d0ad9e483 100644 --- a/profiles/network/bnep.c +++ b/profiles/network/bnep.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/profiles/network/connection.c b/profiles/network/connection.c index 5305ace80..97b87d02e 100644 --- a/profiles/network/connection.c +++ b/profiles/network/connection.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/profiles/network/server.c b/profiles/network/server.c index 175e5822d..c462677ed 100644 --- a/profiles/network/server.c +++ b/profiles/network/server.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/adapter.c b/src/adapter.c index c24432125..b8a6bb6e2 100644 --- a/src/adapter.c +++ b/src/adapter.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/advertising.c b/src/advertising.c index 625750c4f..a843dbba3 100644 --- a/src/advertising.c +++ b/src/advertising.c @@ -17,6 +17,11 @@ * */ +#ifdef HAVE_CONFIG_H +#include +#endif + +#define _GNU_SOURCE #include #include #include diff --git a/src/device.c b/src/device.c index 60b991c1b..79ede3729 100644 --- a/src/device.c +++ b/src/device.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/eir.c b/src/eir.c index 25d961dad..fa52a2bd8 100644 --- a/src/eir.c +++ b/src/eir.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/gatt-client.c b/src/gatt-client.c index 45ed3b170..c0cc3cd38 100644 --- a/src/gatt-client.c +++ b/src/gatt-client.c @@ -21,6 +21,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/log.c b/src/log.c index ea639cbd6..11d26d508 100644 --- a/src/log.c +++ b/src/log.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/main.c b/src/main.c index 67eb6ac59..696728320 100644 --- a/src/main.c +++ b/src/main.c @@ -27,6 +27,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/oui.c b/src/oui.c index 5fe2c5ce6..8059c0a89 100644 --- a/src/oui.c +++ b/src/oui.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include "lib/bluetooth.h" #include "oui.h" diff --git a/src/profile.c b/src/profile.c index 1e9c58516..192fd0245 100644 --- a/src/profile.c +++ b/src/profile.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/rfkill.c b/src/rfkill.c index 74eeb6adc..fb2d11306 100644 --- a/src/rfkill.c +++ b/src/rfkill.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/sdp-xml.c b/src/sdp-xml.c index 0a3eb600d..6f831737d 100644 --- a/src/sdp-xml.c +++ b/src/sdp-xml.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/sdpd-server.c b/src/sdpd-server.c index 54de39353..ef35309ce 100644 --- a/src/sdpd-server.c +++ b/src/sdpd-server.c @@ -28,6 +28,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/shared/ad.c b/src/shared/ad.c index 3ceb87632..8d276842e 100644 --- a/src/shared/ad.c +++ b/src/shared/ad.c @@ -21,6 +21,12 @@ * */ +#ifdef HAVE_CONFIG_H +#include +#endif + +#define _GNU_SOURCE + #include "src/shared/ad.h" #include "src/eir.h" @@ -245,7 +251,7 @@ static size_t uuid_data_length(struct queue *uuid_data) static size_t name_length(const char *name, size_t *pos) { size_t len; - + if (!name) return 0; diff --git a/src/shared/btsnoop.c b/src/shared/btsnoop.c index f367aff55..f0d074743 100644 --- a/src/shared/btsnoop.c +++ b/src/shared/btsnoop.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/shared/ecc.c b/src/shared/ecc.c index 8149f1dd5..1b45e0d0a 100644 --- a/src/shared/ecc.c +++ b/src/shared/ecc.c @@ -28,8 +28,10 @@ #include #endif +#define _GNU_SOURCE #include #include +#include #include #include diff --git a/src/shared/hfp.c b/src/shared/hfp.c index d9f7659c4..5bddc9613 100644 --- a/src/shared/hfp.c +++ b/src/shared/hfp.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/shared/log.c b/src/shared/log.c index d42bae713..7c8b71220 100644 --- a/src/shared/log.c +++ b/src/shared/log.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/shared/mainloop-glib.c b/src/shared/mainloop-glib.c index e44197315..2508a1fb2 100644 --- a/src/shared/mainloop-glib.c +++ b/src/shared/mainloop-glib.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/shared/mainloop-notify.c b/src/shared/mainloop-notify.c index 17bf2c027..89a880006 100644 --- a/src/shared/mainloop-notify.c +++ b/src/shared/mainloop-notify.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/shared/mainloop.c b/src/shared/mainloop.c index 6a65fa41d..8a8e2c022 100644 --- a/src/shared/mainloop.c +++ b/src/shared/mainloop.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/shared/pcap.c b/src/shared/pcap.c index bd7675fdc..0d887e24c 100644 --- a/src/shared/pcap.c +++ b/src/shared/pcap.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/shared/ringbuf.c b/src/shared/ringbuf.c index 8e7c50e9a..8cf0b5b19 100644 --- a/src/shared/ringbuf.c +++ b/src/shared/ringbuf.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/shared/shell.c b/src/shared/shell.c index 8ccfe855e..6e6648cfa 100644 --- a/src/shared/shell.c +++ b/src/shared/shell.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/shared/tester.c b/src/shared/tester.c index 3d79e411d..62e5c1aae 100644 --- a/src/shared/tester.c +++ b/src/shared/tester.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/shared/uhid.c b/src/shared/uhid.c index 1c684cd9e..685f90243 100644 --- a/src/shared/uhid.c +++ b/src/shared/uhid.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/shared/util.c b/src/shared/util.c index 43a81afa0..145bb2a3a 100644 --- a/src/shared/util.c +++ b/src/shared/util.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/storage.c b/src/storage.c index 734a9e08e..8cbb5b270 100644 --- a/src/storage.c +++ b/src/storage.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/textfile.c b/src/textfile.c index 7267f3a77..371651bd8 100644 --- a/src/textfile.c +++ b/src/textfile.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/src/uuid-helper.c b/src/uuid-helper.c index d751817b0..2c897d86c 100644 --- a/src/uuid-helper.c +++ b/src/uuid-helper.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/bccmd.c b/tools/bccmd.c index 84f1a4a5b..2c215ace7 100644 --- a/tools/bccmd.c +++ b/tools/bccmd.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/bcmfw.c b/tools/bcmfw.c index ff94c4fe8..80d8e71a2 100644 --- a/tools/bcmfw.c +++ b/tools/bcmfw.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/bluetooth-player.c b/tools/bluetooth-player.c index ccb0b5ee5..c1005c9b7 100644 --- a/tools/bluetooth-player.c +++ b/tools/bluetooth-player.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/bneptest.c b/tools/bneptest.c index a7d5815f8..8bc7596b6 100644 --- a/tools/bneptest.c +++ b/tools/bneptest.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/btattach.c b/tools/btattach.c index 6eb99bac3..56315d050 100644 --- a/tools/btattach.c +++ b/tools/btattach.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/btgatt-client.c b/tools/btgatt-client.c index 31e849aae..7df659747 100644 --- a/tools/btgatt-client.c +++ b/tools/btgatt-client.c @@ -24,6 +24,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/btgatt-server.c b/tools/btgatt-server.c index bc32789d9..d9d96e691 100644 --- a/tools/btgatt-server.c +++ b/tools/btgatt-server.c @@ -20,6 +20,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/btiotest.c b/tools/btiotest.c index 10e78d57e..6c778e3c5 100644 --- a/tools/btiotest.c +++ b/tools/btiotest.c @@ -23,7 +23,7 @@ */ #ifdef HAVE_CONFIG_H -#include "config.h" +#include #endif #include diff --git a/tools/btmgmt.c b/tools/btmgmt.c index 6922f3d87..78b9fda2a 100644 --- a/tools/btmgmt.c +++ b/tools/btmgmt.c @@ -23,6 +23,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/btmon-logger.c b/tools/btmon-logger.c index 65953d261..9c23d3c5e 100644 --- a/tools/btmon-logger.c +++ b/tools/btmon-logger.c @@ -27,6 +27,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/btproxy.c b/tools/btproxy.c index fd53ca264..fb67a5735 100644 --- a/tools/btproxy.c +++ b/tools/btproxy.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/btsnoop.c b/tools/btsnoop.c index 3eb8082dd..9f304377c 100644 --- a/tools/btsnoop.c +++ b/tools/btsnoop.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/check-selftest.c b/tools/check-selftest.c index 6006b80ad..0de6362da 100644 --- a/tools/check-selftest.c +++ b/tools/check-selftest.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/ciptool.c b/tools/ciptool.c index e60493d1b..b898ae8b7 100644 --- a/tools/ciptool.c +++ b/tools/ciptool.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/create-image.c b/tools/create-image.c index d94f99d92..ca9d0112c 100644 --- a/tools/create-image.c +++ b/tools/create-image.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/csr.c b/tools/csr.c index 9408fb669..61bdaa0cf 100644 --- a/tools/csr.c +++ b/tools/csr.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/csr_bcsp.c b/tools/csr_bcsp.c index f7afe537c..e3eea34df 100644 --- a/tools/csr_bcsp.c +++ b/tools/csr_bcsp.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/csr_h4.c b/tools/csr_h4.c index 337177066..2dcaec1e5 100644 --- a/tools/csr_h4.c +++ b/tools/csr_h4.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/csr_usb.c b/tools/csr_usb.c index a1d7324f7..f3ab2ddce 100644 --- a/tools/csr_usb.c +++ b/tools/csr_usb.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/gatt-service.c b/tools/gatt-service.c index 2ce8a1fd8..374a4c9df 100644 --- a/tools/gatt-service.c +++ b/tools/gatt-service.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/hciattach.c b/tools/hciattach.c index fad176c9b..9a02173bf 100644 --- a/tools/hciattach.c +++ b/tools/hciattach.c @@ -27,6 +27,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/hciattach_ath3k.c b/tools/hciattach_ath3k.c index bb0d51e32..d920050f6 100644 --- a/tools/hciattach_ath3k.c +++ b/tools/hciattach_ath3k.c @@ -21,6 +21,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/hciattach_bcm43xx.c b/tools/hciattach_bcm43xx.c index ac1b3c1ed..be82cd011 100644 --- a/tools/hciattach_bcm43xx.c +++ b/tools/hciattach_bcm43xx.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/hciattach_intel.c b/tools/hciattach_intel.c index 2650dcb61..0f0b60f2b 100644 --- a/tools/hciattach_intel.c +++ b/tools/hciattach_intel.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/hciattach_qualcomm.c b/tools/hciattach_qualcomm.c index 22ac62973..29d15a5fe 100644 --- a/tools/hciattach_qualcomm.c +++ b/tools/hciattach_qualcomm.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/hciattach_ti.c b/tools/hciattach_ti.c index 828dd61ba..183839443 100644 --- a/tools/hciattach_ti.c +++ b/tools/hciattach_ti.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/hciattach_tialt.c b/tools/hciattach_tialt.c index f6ef068fd..78498edcf 100644 --- a/tools/hciattach_tialt.c +++ b/tools/hciattach_tialt.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/hciconfig.c b/tools/hciconfig.c index 8a97cc4da..ddc17c4b5 100644 --- a/tools/hciconfig.c +++ b/tools/hciconfig.c @@ -27,6 +27,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/hcidump.c b/tools/hcidump.c index af8f5925a..33d429b6c 100644 --- a/tools/hcidump.c +++ b/tools/hcidump.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/hcitool.c b/tools/hcitool.c index 945f675b0..9250c41f2 100644 --- a/tools/hcitool.c +++ b/tools/hcitool.c @@ -27,6 +27,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/hex2hcd.c b/tools/hex2hcd.c index 943531cdc..1148bbb46 100644 --- a/tools/hex2hcd.c +++ b/tools/hex2hcd.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/hid2hci.c b/tools/hid2hci.c index 8f060f258..1e0f7aa2a 100644 --- a/tools/hid2hci.c +++ b/tools/hid2hci.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/l2ping.c b/tools/l2ping.c index fa97fe30f..db120a550 100644 --- a/tools/l2ping.c +++ b/tools/l2ping.c @@ -27,6 +27,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/l2test.c b/tools/l2test.c index 18194236b..e755ac881 100644 --- a/tools/l2test.c +++ b/tools/l2test.c @@ -27,6 +27,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/mcaptest.c b/tools/mcaptest.c index 30928737f..82663d8de 100644 --- a/tools/mcaptest.c +++ b/tools/mcaptest.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/meshctl.c b/tools/meshctl.c index cbf62ce70..6b6f10882 100644 --- a/tools/meshctl.c +++ b/tools/meshctl.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/mpris-proxy.c b/tools/mpris-proxy.c index bf8148fe5..617f80586 100644 --- a/tools/mpris-proxy.c +++ b/tools/mpris-proxy.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/nokfw.c b/tools/nokfw.c index 20ff846b2..6209642b5 100644 --- a/tools/nokfw.c +++ b/tools/nokfw.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/obex-client-tool.c b/tools/obex-client-tool.c index 1e3e6f088..3d61c00d7 100644 --- a/tools/obex-client-tool.c +++ b/tools/obex-client-tool.c @@ -20,9 +20,10 @@ */ #ifdef HAVE_CONFIG_H -#include "config.h" +#include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/obex-server-tool.c b/tools/obex-server-tool.c index a16c46f89..b20dfaa6b 100644 --- a/tools/obex-server-tool.c +++ b/tools/obex-server-tool.c @@ -20,9 +20,10 @@ */ #ifdef HAVE_CONFIG_H -# include "config.h" +#include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/obexctl.c b/tools/obexctl.c index f839ab0bd..0709f692c 100644 --- a/tools/obexctl.c +++ b/tools/obexctl.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/parser/amp.c b/tools/parser/amp.c index 158ca4a75..7c85fb96c 100644 --- a/tools/parser/amp.c +++ b/tools/parser/amp.c @@ -24,6 +24,7 @@ #include #endif +#define _GNU_SOURCE #include "parser.h" #include "lib/amp.h" diff --git a/tools/parser/att.c b/tools/parser/att.c index 82766c77f..688ed48a2 100644 --- a/tools/parser/att.c +++ b/tools/parser/att.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/parser/avctp.c b/tools/parser/avctp.c index 70c5f6685..5038443a4 100644 --- a/tools/parser/avctp.c +++ b/tools/parser/avctp.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/parser/avdtp.c b/tools/parser/avdtp.c index 5397a42b0..18569c895 100644 --- a/tools/parser/avdtp.c +++ b/tools/parser/avdtp.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/parser/avrcp.c b/tools/parser/avrcp.c index 5f292722c..dfc6d0580 100644 --- a/tools/parser/avrcp.c +++ b/tools/parser/avrcp.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/parser/bnep.c b/tools/parser/bnep.c index 7c549f40b..c3bbae74f 100644 --- a/tools/parser/bnep.c +++ b/tools/parser/bnep.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/parser/bpa.c b/tools/parser/bpa.c index 74a3457e8..aac010b39 100644 --- a/tools/parser/bpa.c +++ b/tools/parser/bpa.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/parser/capi.c b/tools/parser/capi.c index b8d05c256..ef6ac0664 100644 --- a/tools/parser/capi.c +++ b/tools/parser/capi.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/parser/cmtp.c b/tools/parser/cmtp.c index ed5d13b57..e7ac4b55c 100644 --- a/tools/parser/cmtp.c +++ b/tools/parser/cmtp.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/parser/csr.c b/tools/parser/csr.c index a0a4eb5fe..718baab32 100644 --- a/tools/parser/csr.c +++ b/tools/parser/csr.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/parser/ericsson.c b/tools/parser/ericsson.c index 3d52411b1..d148c93f7 100644 --- a/tools/parser/ericsson.c +++ b/tools/parser/ericsson.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include diff --git a/tools/parser/hci.c b/tools/parser/hci.c index 4e6c36040..41f6fe087 100644 --- a/tools/parser/hci.c +++ b/tools/parser/hci.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/parser/hcrp.c b/tools/parser/hcrp.c index 444ec23ee..7c46cb6ea 100644 --- a/tools/parser/hcrp.c +++ b/tools/parser/hcrp.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/parser/hidp.c b/tools/parser/hidp.c index 1adf8ed4e..703049a7a 100644 --- a/tools/parser/hidp.c +++ b/tools/parser/hidp.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/parser/l2cap.c b/tools/parser/l2cap.c index 5daefcbaa..e43761cf7 100644 --- a/tools/parser/l2cap.c +++ b/tools/parser/l2cap.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/parser/lmp.c b/tools/parser/lmp.c index 3d2772c27..a7879fb37 100644 --- a/tools/parser/lmp.c +++ b/tools/parser/lmp.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/parser/obex.c b/tools/parser/obex.c index 0612c30d2..51719aa9c 100644 --- a/tools/parser/obex.c +++ b/tools/parser/obex.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/parser/parser.c b/tools/parser/parser.c index de8dbe870..61c5b1cda 100644 --- a/tools/parser/parser.c +++ b/tools/parser/parser.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/parser/ppp.c b/tools/parser/ppp.c index 3847ff3a6..55aaa60fe 100644 --- a/tools/parser/ppp.c +++ b/tools/parser/ppp.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/parser/rfcomm.c b/tools/parser/rfcomm.c index ea8dfada7..d800b7e6d 100644 --- a/tools/parser/rfcomm.c +++ b/tools/parser/rfcomm.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/parser/sap.c b/tools/parser/sap.c index f51f0cc3d..0a875fc7c 100644 --- a/tools/parser/sap.c +++ b/tools/parser/sap.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/parser/sdp.c b/tools/parser/sdp.c index dba9a3658..7477037b8 100644 --- a/tools/parser/sdp.c +++ b/tools/parser/sdp.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/parser/smp.c b/tools/parser/smp.c index 97f02faa8..817e08e85 100644 --- a/tools/parser/smp.c +++ b/tools/parser/smp.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/parser/tcpip.c b/tools/parser/tcpip.c index 6f2c3cba1..8ccfb007c 100644 --- a/tools/parser/tcpip.c +++ b/tools/parser/tcpip.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/rctest.c b/tools/rctest.c index 6d84e075b..94490f462 100644 --- a/tools/rctest.c +++ b/tools/rctest.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/rfcomm.c b/tools/rfcomm.c index 809c2404c..177d8f828 100644 --- a/tools/rfcomm.c +++ b/tools/rfcomm.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/rtlfw.c b/tools/rtlfw.c index 5e354a3f5..375f07592 100644 --- a/tools/rtlfw.c +++ b/tools/rtlfw.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/scotest.c b/tools/scotest.c index f894c2433..08bc8a8d2 100644 --- a/tools/scotest.c +++ b/tools/scotest.c @@ -26,6 +26,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/sdptool.c b/tools/sdptool.c index b1cbcfdc8..3c5d840d9 100644 --- a/tools/sdptool.c +++ b/tools/sdptool.c @@ -29,6 +29,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/seq2bseq.c b/tools/seq2bseq.c index 23f6c9e89..9268ecd06 100644 --- a/tools/seq2bseq.c +++ b/tools/seq2bseq.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/tools/test-runner.c b/tools/test-runner.c index 7a97111b9..bd3c73001 100644 --- a/tools/test-runner.c +++ b/tools/test-runner.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/unit/test-gobex-apparam.c b/unit/test-gobex-apparam.c index 7541c490c..59393c681 100644 --- a/unit/test-gobex-apparam.c +++ b/unit/test-gobex-apparam.c @@ -21,7 +21,7 @@ */ #ifdef HAVE_CONFIG_H -#include "config.h" +#include #endif #include diff --git a/unit/test-gobex-header.c b/unit/test-gobex-header.c index 8705892cc..3450f8123 100644 --- a/unit/test-gobex-header.c +++ b/unit/test-gobex-header.c @@ -21,7 +21,7 @@ */ #ifdef HAVE_CONFIG_H -#include "config.h" +#include #endif #include diff --git a/unit/test-gobex-packet.c b/unit/test-gobex-packet.c index 0d62460c3..d382ee5b3 100644 --- a/unit/test-gobex-packet.c +++ b/unit/test-gobex-packet.c @@ -21,7 +21,7 @@ */ #ifdef HAVE_CONFIG_H -#include "config.h" +#include #endif #include diff --git a/unit/test-gobex-transfer.c b/unit/test-gobex-transfer.c index 6807c9f73..3f8905c0b 100644 --- a/unit/test-gobex-transfer.c +++ b/unit/test-gobex-transfer.c @@ -21,7 +21,7 @@ */ #ifdef HAVE_CONFIG_H -#include "config.h" +#include #endif #include diff --git a/unit/test-gobex.c b/unit/test-gobex.c index 66531a2fd..1afb7ceff 100644 --- a/unit/test-gobex.c +++ b/unit/test-gobex.c @@ -21,7 +21,7 @@ */ #ifdef HAVE_CONFIG_H -#include "config.h" +#include #endif #include diff --git a/unit/test-hog.c b/unit/test-hog.c index d117968f4..37d3abe3f 100644 --- a/unit/test-hog.c +++ b/unit/test-hog.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/unit/test-lib.c b/unit/test-lib.c index bd4c5eecd..1dd5d92cf 100644 --- a/unit/test-lib.c +++ b/unit/test-lib.c @@ -23,12 +23,13 @@ */ #ifdef HAVE_CONFIG_H -#include "config.h" +#include #endif -#include +#define _GNU_SOURCE #include #include +#include #include "src/shared/util.h" #include "src/shared/tester.h" diff --git a/unit/test-ringbuf.c b/unit/test-ringbuf.c index a97524e44..ef3bf0a50 100644 --- a/unit/test-ringbuf.c +++ b/unit/test-ringbuf.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/unit/test-textfile.c b/unit/test-textfile.c index 5250f983a..4b43898d6 100644 --- a/unit/test-textfile.c +++ b/unit/test-textfile.c @@ -25,6 +25,7 @@ #include #endif +#define _GNU_SOURCE #include #include #include diff --git a/unit/util.c b/unit/util.c index ce4d65add..c8054d2e4 100644 --- a/unit/util.c +++ b/unit/util.c @@ -20,7 +20,7 @@ */ #ifdef HAVE_CONFIG_H -#include "config.h" +#include #endif #include -- 2.47.3