summaryrefslogtreecommitdiff
path: root/devel
diff options
context:
space:
mode:
authormanu <manu>2016-12-16 08:11:55 +0000
committermanu <manu>2016-12-16 08:11:55 +0000
commit69e56fc60944824a4a71e32a706853ed0075e2d4 (patch)
treeddbb45d47053af15eedc81eedb3ef2152b83f51e /devel
parent21dea1feacb2931f44e3a3acb0a585d86e1e1d58 (diff)
downloadpkgsrc-69e56fc60944824a4a71e32a706853ed0075e2d4.tar.gz
Add libnfc-1.7.1
libnfc is the first libre low level NFC SDK and Programmers API released under the GNU Lesser General Public License. It provides complete transparency and royalty-free use for everyone. The library currently supports modulations for ISO/IEC 14443 A and B, FeliCa, Jewel/Topaz tags and Data Exchange Protocol (P2P) as target and as initiator.
Diffstat (limited to 'devel')
-rw-r--r--devel/libnfc/DESCR7
-rw-r--r--devel/libnfc/Makefile26
-rw-r--r--devel/libnfc/PLIST46
-rw-r--r--devel/libnfc/buildlink3.mk17
-rw-r--r--devel/libnfc/distinfo9
-rw-r--r--devel/libnfc/patches/patch-configure17
-rw-r--r--devel/libnfc/patches/patch-libnfc_buses_uart.c17
-rw-r--r--devel/libnfc/patches/patch-libnfc_drivers_acr122_pcsc.c17
8 files changed, 156 insertions, 0 deletions
diff --git a/devel/libnfc/DESCR b/devel/libnfc/DESCR
new file mode 100644
index 00000000000..a179793b1f8
--- /dev/null
+++ b/devel/libnfc/DESCR
@@ -0,0 +1,7 @@
+libnfc is the first libre low level NFC SDK and Programmers API
+released under the GNU Lesser General Public License. It provides
+complete transparency and royalty-free use for everyone.
+
+The library currently supports modulations for ISO/IEC 14443 A and
+B, FeliCa, Jewel/Topaz tags and Data Exchange Protocol (P2P) as
+target and as initiator.
diff --git a/devel/libnfc/Makefile b/devel/libnfc/Makefile
new file mode 100644
index 00000000000..1321195fbfc
--- /dev/null
+++ b/devel/libnfc/Makefile
@@ -0,0 +1,26 @@
+# $NetBSD: Makefile,v 1.1 2016/12/16 08:11:55 manu Exp $
+
+DISTNAME= libnfc-1.7.1
+CATEGORIES= net
+MASTER_SITES= https://dl.bintray.com/nfc-tools/sources/
+EXTRACT_SUFX= .tar.bz2
+
+MAINTAINER= pkgsrc-users@NetBSD.org
+HOMEPAGE= http://nfc-tools.org/index.php?title=Libnfc
+COMMENT= Low level NFC SDK and Programmers API
+LICENSE= gnu-lgpl-v3
+
+GNU_CONFIGURE= yes
+USE_LIBTOOL= yes
+USE_TOOLS+= pkg-config
+
+CONFIGURE_ARGS+=--with-drivers=all
+CONFIGURE_ARGS+=--enable-doc
+
+BUILD_DEPENDS+= doxygen>=1.8.11:../../devel/doxygen
+
+.include "../../devel/libusb/buildlink3.mk"
+.include "../../devel/readline/buildlink3.mk"
+.include "../../security/pcsc-lite/buildlink3.mk"
+
+.include "../../mk/bsd.pkg.mk"
diff --git a/devel/libnfc/PLIST b/devel/libnfc/PLIST
new file mode 100644
index 00000000000..ff04c3b4a6a
--- /dev/null
+++ b/devel/libnfc/PLIST
@@ -0,0 +1,46 @@
+@comment $NetBSD: PLIST,v 1.1 2016/12/16 08:11:55 manu Exp $
+bin/nfc-anticol
+bin/nfc-dep-initiator
+bin/nfc-dep-target
+bin/nfc-emulate-forum-tag2
+bin/nfc-emulate-forum-tag4
+bin/nfc-emulate-tag
+bin/nfc-emulate-uid
+bin/nfc-jewel
+bin/nfc-list
+bin/nfc-mfclassic
+bin/nfc-mfsetuid
+bin/nfc-mfultralight
+bin/nfc-poll
+bin/nfc-read-forum-tag3
+bin/nfc-relay
+bin/nfc-relay-picc
+bin/nfc-scan-device
+bin/pn53x-diagnose
+bin/pn53x-sam
+bin/pn53x-tamashell
+include/nfc/nfc-emulation.h
+include/nfc/nfc-types.h
+include/nfc/nfc.h
+lib/libnfc.la
+lib/pkgconfig/libnfc.pc
+man/man1/nfc-anticol.1
+man/man1/nfc-dep-initiator.1
+man/man1/nfc-dep-target.1
+man/man1/nfc-emulate-forum-tag2.1
+man/man1/nfc-emulate-forum-tag4.1
+man/man1/nfc-emulate-tag.1
+man/man1/nfc-emulate-uid.1
+man/man1/nfc-jewel.1
+man/man1/nfc-list.1
+man/man1/nfc-mfclassic.1
+man/man1/nfc-mfsetuid.1
+man/man1/nfc-mfultralight.1
+man/man1/nfc-poll.1
+man/man1/nfc-read-forum-tag3.1
+man/man1/nfc-relay-picc.1
+man/man1/nfc-relay.1
+man/man1/nfc-scan-device.1
+man/man1/pn53x-diagnose.1
+man/man1/pn53x-sam.1
+man/man1/pn53x-tamashell.1
diff --git a/devel/libnfc/buildlink3.mk b/devel/libnfc/buildlink3.mk
new file mode 100644
index 00000000000..681c3035eda
--- /dev/null
+++ b/devel/libnfc/buildlink3.mk
@@ -0,0 +1,17 @@
+# $NetBSD: buildlink3.mk,v 1.1 2016/12/16 08:11:55 manu Exp $
+
+BUILDLINK_TREE+= libnfc
+
+.if !defined(LIBNFC_BUILDLINK3_MK)
+LIBNFC_BUILDLINK3_MK:=
+
+BUILDLINK_API_DEPENDS.libnfc+= libnfc>=1.7.1
+BUILDLINK_ABI_DEPENDS.libnfc+= libnfc>=1.7.1
+BUILDLINK_PKGSRCDIR.libnfc?= ../../devel/libnfc
+
+.include "../../devel/libusb/buildlink3.mk"
+.include "../../devel/readline/buildlink3.mk"
+.include "../../security/pcsc-lite/buildlink3.mk"
+.endif # LIBNFC_BUILDLINK3_MK
+
+BUILDLINK_TREE+= -libnfc
diff --git a/devel/libnfc/distinfo b/devel/libnfc/distinfo
new file mode 100644
index 00000000000..52b294df681
--- /dev/null
+++ b/devel/libnfc/distinfo
@@ -0,0 +1,9 @@
+$NetBSD: distinfo,v 1.1 2016/12/16 08:11:55 manu Exp $
+
+SHA1 (libnfc-1.7.1.tar.bz2) = d77c1408f5e38f24d69778b2ff82f68b2d7bc111
+RMD160 (libnfc-1.7.1.tar.bz2) = e0d7a3ce57fd57281145d3c78042b9fbccf85009
+SHA512 (libnfc-1.7.1.tar.bz2) = 6a03d197c450c0ab8f2d16ae8c1f80e206fa909ece84a32dbb962acd0f7ef693a419608cdaa4c2207a1d2593599e44479520d7413eace7fca19d3230442e506c
+Size (libnfc-1.7.1.tar.bz2) = 484309 bytes
+SHA1 (patch-configure) = d0860d7617260826dc66895f0da202950bf12afc
+SHA1 (patch-libnfc_buses_uart.c) = 05b50592b0609c6c1c435466d840fee8cedf6fcb
+SHA1 (patch-libnfc_drivers_acr122_pcsc.c) = 448bbf340b0961ba7ffb0bd5f18c343bff7c4329
diff --git a/devel/libnfc/patches/patch-configure b/devel/libnfc/patches/patch-configure
new file mode 100644
index 00000000000..45b13a81800
--- /dev/null
+++ b/devel/libnfc/patches/patch-configure
@@ -0,0 +1,17 @@
+$NetBSD: patch-configure,v 1.1 2016/12/16 08:11:55 manu Exp $
+
+POSIXly correct test(1) for equality.
+
+--- configure.orig 2016-12-14 11:06:15.000000000 +0100
++++ configure 2016-12-14 11:07:56.000000000 +0100
+@@ -13966,9 +13966,9 @@
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for readline.h" >&5
+ $as_echo_n "checking for readline.h... " >&6; }
+
+- if test "x$cross_compiling" == "xyes"; then
++ if test "x$cross_compiling" = "xyes"; then
+ without_readline=yes
+ fi
+
+ if test "x$without_readline" != "xyes"; then
diff --git a/devel/libnfc/patches/patch-libnfc_buses_uart.c b/devel/libnfc/patches/patch-libnfc_buses_uart.c
new file mode 100644
index 00000000000..62799e4ae89
--- /dev/null
+++ b/devel/libnfc/patches/patch-libnfc_buses_uart.c
@@ -0,0 +1,17 @@
+$NetBSD: patch-libnfc_buses_uart.c,v 1.1 2016/12/16 08:11:55 manu Exp $
+
+NetBSD serial ports
+
+--- libnfc/buses/uart.c.orig 2016-12-14 10:59:45.000000000 +0100
++++ libnfc/buses/uart.c 2016-12-14 11:00:35.000000000 +0100
+@@ -76,8 +76,10 @@
+ # if defined(__APPLE__)
+ const char *serial_ports_device_radix[] = { "tty.SLAB_USBtoUART", "tty.usbserial-", NULL };
+ # elif defined (__FreeBSD__) || defined (__OpenBSD__) || defined(__FreeBSD_kernel__)
+ const char *serial_ports_device_radix[] = { "cuaU", "cuau", NULL };
++# elif defined (__NetBSD__)
++const char *serial_ports_device_radix[] = { "tty0", "ttyC", "ttyS", "ttyU", "ttyY" , NULL };
+ # elif defined (__linux__)
+ const char *serial_ports_device_radix[] = { "ttyUSB", "ttyS", "ttyACM", "ttyAMA", "ttyO", NULL };
+ # else
+ # error "Can't determine serial string for your system"
diff --git a/devel/libnfc/patches/patch-libnfc_drivers_acr122_pcsc.c b/devel/libnfc/patches/patch-libnfc_drivers_acr122_pcsc.c
new file mode 100644
index 00000000000..2af72edde9e
--- /dev/null
+++ b/devel/libnfc/patches/patch-libnfc_drivers_acr122_pcsc.c
@@ -0,0 +1,17 @@
+$NetBSD: patch-libnfc_drivers_acr122_pcsc.c,v 1.1 2016/12/16 08:11:55 manu Exp $
+
+NetBSD definition for CCID ioctl
+
+--- libnfc/drivers/acr122_pcsc.c.orig 2016-12-14 15:03:27.000000000 +0100
++++ libnfc/drivers/acr122_pcsc.c 2016-12-14 15:04:21.000000000 +0100
+@@ -58,9 +58,9 @@
+ #if defined (_WIN32)
+ # define IOCTL_CCID_ESCAPE_SCARD_CTL_CODE SCARD_CTL_CODE(3500)
+ #elif defined(__APPLE__)
+ # define IOCTL_CCID_ESCAPE_SCARD_CTL_CODE (((0x31) << 16) | ((3500) << 2))
+-#elif defined (__FreeBSD__) || defined (__OpenBSD__)
++#elif defined (__FreeBSD__) || defined (__OpenBSD__) || defined (__NetBSD__)
+ # define IOCTL_CCID_ESCAPE_SCARD_CTL_CODE (((0x31) << 16) | ((3500) << 2))
+ #elif defined (__linux__)
+ # include <reader.h>
+ // Escape IOCTL tested successfully: