Received: by mail.netbsd.org (Postfix, from userid 605) id 031E584E19; Thu, 27 Apr 2023 22:02:39 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by mail.netbsd.org (Postfix) with ESMTP id 31A3884CEB for ; Thu, 27 Apr 2023 22:02:38 +0000 (UTC) X-Virus-Scanned: amavisd-new at netbsd.org Received: from mail.netbsd.org ([127.0.0.1]) by localhost (mail.netbsd.org [127.0.0.1]) (amavisd-new, port 10025) with ESMTP id fFg8QH0zZJOR for ; Thu, 27 Apr 2023 22:02:37 +0000 (UTC) Received: from cvs.NetBSD.org (ivanova.NetBSD.org [IPv6:2001:470:a085:999:28c:faff:fe03:5984]) by mail.netbsd.org (Postfix) with ESMTP id 4E41A84CE3 for ; Thu, 27 Apr 2023 22:02:37 +0000 (UTC) Received: by cvs.NetBSD.org (Postfix, from userid 500) id D730BFA87; Thu, 27 Apr 2023 22:02:33 +0000 (UTC) Content-Transfer-Encoding: 7bit Content-Type: multipart/mixed; boundary="_----------=_1682632953275580" MIME-Version: 1.0 Date: Thu, 27 Apr 2023 22:02:33 +0000 From: "Nikita" Subject: CVS commit: pkgsrc/security To: pkgsrc-changes@NetBSD.org Reply-To: nikita@netbsd.org X-Mailer: log_accum Message-Id: <20230427220233.D730BFA87@cvs.NetBSD.org> Sender: pkgsrc-changes-owner@NetBSD.org List-Id: Precedence: bulk List-Unsubscribe: This is a multi-part message in MIME format. --_----------=_1682632953275580 Content-Disposition: inline Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII" Module Name: pkgsrc Committed By: nikita Date: Thu Apr 27 22:02:33 UTC 2023 Modified Files: pkgsrc/security: Makefile Added Files: pkgsrc/security/libnitrokey: DESCR Makefile PLIST distinfo options.mk pkgsrc/security/libnitrokey/patches: patch-CMakeLists.txt Log Message: libnitrokey: import as security/libnitrokey version 3.8 libnitrokey is a project to communicate with Nitrokey Pro and Storage devices in a clean and easy manner. Written in C++14, testable with py.test and Catch frameworks, with C API, Python access (through CFFI and C API, in future with Pybind11). The development of this project is aimed to make it itself a living documentation of communication protocol between host and the Nitrokey stick devices. To generate a diff of this commit: cvs rdiff -u -r1.897 -r1.898 pkgsrc/security/Makefile cvs rdiff -u -r0 -r1.1 pkgsrc/security/libnitrokey/DESCR \ pkgsrc/security/libnitrokey/Makefile pkgsrc/security/libnitrokey/PLIST \ pkgsrc/security/libnitrokey/distinfo \ pkgsrc/security/libnitrokey/options.mk cvs rdiff -u -r0 -r1.1 \ pkgsrc/security/libnitrokey/patches/patch-CMakeLists.txt Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. --_----------=_1682632953275580 Content-Disposition: inline Content-Length: 6168 Content-Transfer-Encoding: binary Content-Type: text/x-diff; charset=us-ascii Modified files: Index: pkgsrc/security/Makefile diff -u pkgsrc/security/Makefile:1.897 pkgsrc/security/Makefile:1.898 --- pkgsrc/security/Makefile:1.897 Thu Apr 13 13:43:24 2023 +++ pkgsrc/security/Makefile Thu Apr 27 22:02:33 2023 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.897 2023/04/13 13:43:24 wiz Exp $ +# $NetBSD: Makefile,v 1.898 2023/04/27 22:02:33 nikita Exp $ # COMMENT= Security and cryptography tools and libraries @@ -186,6 +186,7 @@ SUBDIR+= libmcrypt SUBDIR+= libmerkletree SUBDIR+= libmultigest SUBDIR+= libnetpgpverify +SUBDIR+= libnitrokey SUBDIR+= liboauth SUBDIR+= libp11 SUBDIR+= libpbc Added files: Index: pkgsrc/security/libnitrokey/DESCR diff -u /dev/null pkgsrc/security/libnitrokey/DESCR:1.1 --- /dev/null Thu Apr 27 22:02:33 2023 +++ pkgsrc/security/libnitrokey/DESCR Thu Apr 27 22:02:33 2023 @@ -0,0 +1,8 @@ +libnitrokey is a project to communicate with Nitrokey Pro and Storage devices +in a clean and easy manner. Written in C++14, testable with py.test and Catch +frameworks, with C API, Python access (through CFFI and C API, in future with +Pybind11). + +The development of this project is aimed to make it itself a living +documentation of communication protocol between host and the Nitrokey stick +devices. Index: pkgsrc/security/libnitrokey/Makefile diff -u /dev/null pkgsrc/security/libnitrokey/Makefile:1.1 --- /dev/null Thu Apr 27 22:02:33 2023 +++ pkgsrc/security/libnitrokey/Makefile Thu Apr 27 22:02:33 2023 @@ -0,0 +1,34 @@ +# $NetBSD: Makefile,v 1.1 2023/04/27 22:02:33 nikita Exp $ + +DISTNAME= libnitrokey-3.8 +CATEGORIES= security +MASTER_SITES= ${MASTER_SITE_GITHUB:=Nitrokey/} +GITHUB_PROJECT= libnitrokey +GITHUB_TAG= v${PKGVERSION_NOREV} + +MAINTAINER= nikita@NetBSD.org +HOMEPAGE= https://github.com/Nitrokey/libnitrokey/ +COMMENT= Library to communicate with Nitrokey devices +LICENSE= gnu-lgpl-v3 + +USE_TOOLS+= pkg-config + +.include "options.mk" +# depends: libudev-devd ? + +# actual hardware tests +# 1. require a connected Nitrokey +# 2. may kill data on your Nitrokey +# hence the main testsuite is disabled +CMAKE_ARGS+= -DCOMPILE_TESTS=OFF + +CMAKE_ARGS+= -DHIDAPI_LIBUSB_INCLUDEDIR=${BUILDLINK_PREFIX.libhidapi}/include/hidapi/ +CMAKE_ARGS+= -DHIDAPI_LIBUSB_LIBDIR=${BUILDLINK_PREFIX.libhidapi}/lib/ + +TEST_TARGET= test +USE_LANGUAGES= c c++14 + +.include "../../devel/libusb1/buildlink3.mk" +.include "../../comms/libhidapi/buildlink3.mk" +.include "../../devel/cmake/build.mk" +.include "../../mk/bsd.pkg.mk" Index: pkgsrc/security/libnitrokey/PLIST diff -u /dev/null pkgsrc/security/libnitrokey/PLIST:1.1 --- /dev/null Thu Apr 27 22:02:33 2023 +++ pkgsrc/security/libnitrokey/PLIST Thu Apr 27 22:02:33 2023 @@ -0,0 +1,25 @@ +@comment $NetBSD: PLIST,v 1.1 2023/04/27 22:02:33 nikita Exp $ +include/libnitrokey/CommandFailedException.h +include/libnitrokey/DeviceCommunicationExceptions.h +include/libnitrokey/LibraryException.h +include/libnitrokey/LongOperationInProgressException.h +include/libnitrokey/NK_C_API.h +include/libnitrokey/NitrokeyManager.h +include/libnitrokey/command.h +include/libnitrokey/command_id.h +include/libnitrokey/cxx_semantics.h +include/libnitrokey/deprecated.h +include/libnitrokey/device.h +include/libnitrokey/device_proto.h +include/libnitrokey/dissect.h +include/libnitrokey/log.h +include/libnitrokey/misc.h +include/libnitrokey/stick10_commands.h +include/libnitrokey/stick10_commands_0.8.h +include/libnitrokey/stick20_commands.h +include/libnitrokey/version.h +lib/libnitrokey.so +lib/libnitrokey.so.3 +lib/libnitrokey.so.3.7.0 +lib/pkgconfig/libnitrokey-1.pc +lib/udev/rules.d/41-nitrokey.rules Index: pkgsrc/security/libnitrokey/distinfo diff -u /dev/null pkgsrc/security/libnitrokey/distinfo:1.1 --- /dev/null Thu Apr 27 22:02:33 2023 +++ pkgsrc/security/libnitrokey/distinfo Thu Apr 27 22:02:33 2023 @@ -0,0 +1,6 @@ +$NetBSD: distinfo,v 1.1 2023/04/27 22:02:33 nikita Exp $ + +BLAKE2s (libnitrokey-3.8.tar.gz) = d7c2b3c779809b63028c7f1f927f4b8c108d6616cdf00a09ab0c5354e5095eae +SHA512 (libnitrokey-3.8.tar.gz) = 30f966eed77aa75057b096d18f8e88d6be28a376dfc1888e44aff80347e031a16755d30acf1bca196acc5b922778d90627ac71cba22f5cb002ba3ec058939c90 +Size (libnitrokey-3.8.tar.gz) = 118197 bytes +SHA1 (patch-CMakeLists.txt) = 4e315dfd8edc47da70739b5910c3f09d087a43c5 Index: pkgsrc/security/libnitrokey/options.mk diff -u /dev/null pkgsrc/security/libnitrokey/options.mk:1.1 --- /dev/null Thu Apr 27 22:02:33 2023 +++ pkgsrc/security/libnitrokey/options.mk Thu Apr 27 22:02:33 2023 @@ -0,0 +1,19 @@ +# $NetBSD: options.mk,v 1.1 2023/04/27 22:02:33 nikita Exp $ + +PKG_OPTIONS_VAR= PKG_OPTIONS.libnitrokey + +PKG_SUPPORTED_OPTIONS+= doc tests + +.include "../../mk/bsd.options.mk" + +.if ${PKG_OPTIONS:Mdoc} +DEPENDS+= doxygen-[0-9]*:../../devel/doxygen +DEPENDS+= graphviz-[0-9]*:../../graphics/graphviz +# else switch this off in cmake +.endif + +.if ${PKG_OPTIONS:Mtests} +# These tests do not require any device to be connected +CMAKE_ARGS+= -DCOMPILE_OFFLINE_TESTS=ON +TEST_DEPENDS+= catch2-[0-9]*:../../devel/catch2 +.endif Index: pkgsrc/security/libnitrokey/patches/patch-CMakeLists.txt diff -u /dev/null pkgsrc/security/libnitrokey/patches/patch-CMakeLists.txt:1.1 --- /dev/null Thu Apr 27 22:02:33 2023 +++ pkgsrc/security/libnitrokey/patches/patch-CMakeLists.txt Thu Apr 27 22:02:33 2023 @@ -0,0 +1,21 @@ +$NetBSD: patch-CMakeLists.txt,v 1.1 2023/04/27 22:02:33 nikita Exp $ + +fix build with pkgsrc hidapi. + +--- CMakeLists.txt.orig 2023-04-27 23:48:15.821869063 +0200 ++++ CMakeLists.txt 2023-04-27 23:49:29.139633117 +0200 +@@ -83,12 +83,8 @@ + ELSEIF(UNIX) + # add_library(hidapi-libusb STATIC hidapi/libusb/hid.c ) + find_package(PkgConfig) +- IF(${CMAKE_SYSTEM_NAME} STREQUAL "FreeBSD") +- pkg_search_module(HIDAPI_LIBUSB REQUIRED hidapi) +- set(HIDAPI_LIBUSB_NAME hidapi) +- ELSE() +- pkg_search_module(HIDAPI_LIBUSB REQUIRED hidapi-libusb) +- ENDIF() ++ pkg_search_module(HIDAPI_LIBUSB REQUIRED hidapi) ++ set(HIDAPI_LIBUSB_NAME hidapi) + target_compile_options(nitrokey PRIVATE ${HIDAPI_LIBUSB_CFLAGS}) + target_link_libraries(nitrokey ${HIDAPI_LIBUSB_LDFLAGS}) + ELSEIF(WIN32) --_----------=_1682632953275580--