From 0a5199a7373310c183dcdda9f060615b48115c66 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Romain=20Tarti=C3=A8re?= Date: Mon, 20 May 2013 17:02:24 +0200 Subject: [PATCH] Avoid clash with system's htole32 if it exists. Fix build on FreeBSD. Reported by: Ganael Laplanche --- libnfc/drivers/acr122_usb.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/libnfc/drivers/acr122_usb.c b/libnfc/drivers/acr122_usb.c index 09e9945..1e044af 100644 --- a/libnfc/drivers/acr122_usb.c +++ b/libnfc/drivers/acr122_usb.c @@ -515,6 +515,8 @@ acr122_usb_close(nfc_device *pnd) nfc_device_free(pnd); } +#if !defined(htole32) + uint32_t htole32(uint32_t u32); uint32_t @@ -529,6 +531,8 @@ htole32(uint32_t u32) return *pu32; } +#endif /* !defined(htole32) */ + static int acr122_build_frame_from_apdu(nfc_device *pnd, const uint8_t ins, const uint8_t p1, const uint8_t p2, const uint8_t *data, const size_t data_len, const uint8_t le) {