deskflow: add new package
authorTobias Nygren <tnn@NetBSD.org>
Mon, 10 Mar 2025 11:19:11 +0000 (12:19 +0100)
committerTobias Nygren <tnn@NetBSD.org>
Mon, 10 Mar 2025 11:20:55 +0000 (12:20 +0100)
This is the spiritual successor to net/synergy and it aims to be
protocol compatible with it.

Makefile
deskflow/DESCR [new file with mode: 0644]
deskflow/Makefile [new file with mode: 0644]
deskflow/PLIST [new file with mode: 0644]
deskflow/distinfo [new file with mode: 0644]
deskflow/patches/patch-src_lib_deskflow_CMakeLists.txt [new file with mode: 0644]

index d64596c8b7f354f804bb1e8a807af21a0d4a32f9..9f36d3027c362e63faebd4558f3495fa3af29ef1 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -688,6 +688,7 @@ SUBDIR+=    denise
 SUBDIR+=       depsolver
 SUBDIR+=       descent3
 SUBDIR+=       deskcribe
+SUBDIR+=       deskflow
 SUBDIR+=       desktop-data-model
 SUBDIR+=       desktop-installer
 SUBDIR+=       desmume
diff --git a/deskflow/DESCR b/deskflow/DESCR
new file mode 100644 (file)
index 0000000..f11e675
--- /dev/null
@@ -0,0 +1,5 @@
+Deskflow is a free and open source keyboard and mouse sharing app.
+Use the keyboard, mouse, or trackpad of one computer to control nearby
+computers, and work seamlessly between them. It's like a software KVM
+(but without the video). TLS encryption is enabled by default.
+Wayland is supported. Clipboard sharing is supported.
diff --git a/deskflow/Makefile b/deskflow/Makefile
new file mode 100644 (file)
index 0000000..32e368b
--- /dev/null
@@ -0,0 +1,65 @@
+# $NetBSD$
+
+DISTNAME=      deskflow-1.20.1
+CATEGORIES=    net x11
+MASTER_SITES=  ${MASTER_SITE_GITHUB:=deskflow/}
+GITHUB_TAG=    v${PKGVERSION_NOREV}
+
+MAINTAINER=    pkgsrc-users@NetBSD.org
+HOMEPAGE=      https://github.com/deskflow/deskflow/
+COMMENT=       Let a user share a mouse and keyboard among computers
+LICENSE=       gnu-gpl-v2
+
+USE_LANGUAGES=         c c++
+USE_CXX_FEATURES=      c++20
+USE_TOOLS+=            pkg-config
+
+DISTFILES=             ${DEFAULT_DISTFILES}
+
+CLI11_VERSION=         2.4.2
+DISTFILES+=            CLI11-${CLI11_VERSION}.hpp
+SITES.CLI11-${CLI11_VERSION}.hpp=      \
+                       -https://github.com/CLIUtils/CLI11/releases/download/v${CLI11_VERSION}/CLI11.hpp
+
+TOMLPP_VERSION=                3.4.0
+DISTFILES+=            toml-${TOMLPP_VERSION}.hpp
+SITES.toml-${TOMLPP_VERSION}.hpp=      \
+                       -https://raw.githubusercontent.com/marzer/tomlplusplus/refs/tags/v${TOMLPP_VERSION}/toml.hpp
+
+SUBST_CLASSES+=                paths
+SUBST_STAGE.paths=     pre-configure
+SUBST_FILES.paths=     src/lib/arch/unix/ArchFileUnix.cpp
+SUBST_SED.paths=       -e 's,"/etc","${PKG_SYSCONFDIR}",g'
+SUBST_SED.paths+=      -e 's,"/usr/bin","${PREFIX}/bin",g'
+
+post-extract:
+       ${MKDIR} -p ${WRKSRC}/${CMAKE_BUILD_DIR}/include/CLI
+       ${MV} ${WRKDIR}/CLI11-${CLI11_VERSION}.hpp ${WRKSRC}/${CMAKE_BUILD_DIR}/include/CLI/CLI.hpp
+       ${MKDIR} -p ${WRKSRC}/${CMAKE_BUILD_DIR}/include/toml++
+       ${MV} ${WRKDIR}/toml-${TOMLPP_VERSION}.hpp ${WRKSRC}/${CMAKE_BUILD_DIR}/include/toml++/toml.h
+
+
+
+.include "../../mk/bsd.prefs.mk"
+
+.include "../../devel/cmake/build.mk"
+.include "../../devel/glib2/buildlink3.mk"
+.include "../../devel/googletest/buildlink3.mk"
+.include "../../graphics/gdk-pixbuf2/buildlink3.mk"
+.include "../../graphics/hicolor-icon-theme/buildlink3.mk"
+.include "../../security/openssl/buildlink3.mk"
+.include "../../sysutils/libnotify/buildlink3.mk"
+.include "../../textproc/pugixml/buildlink3.mk"
+.include "../../wip/libei/buildlink3.mk"
+.include "../../wip/libportal/buildlink3.mk"
+.include "../../x11/libSM/buildlink3.mk"
+.include "../../x11/libXext/buildlink3.mk"
+.include "../../x11/libXinerama/buildlink3.mk"
+.include "../../x11/libXtst/buildlink3.mk"
+.include "../../x11/libXrandr/buildlink3.mk"
+.include "../../x11/libxkbfile/buildlink3.mk"
+.include "../../x11/libxkbcommon/buildlink3.mk"
+.if ${OPSYS} != "Darwin"
+.include "../../x11/qt6-qtbase/buildlink3.mk"
+.endif
+.include "../../mk/bsd.pkg.mk"
diff --git a/deskflow/PLIST b/deskflow/PLIST
new file mode 100644 (file)
index 0000000..79f29a0
--- /dev/null
@@ -0,0 +1,9 @@
+@comment $NetBSD$
+bin/deskflow
+bin/deskflow-client
+bin/deskflow-server
+share/applications/org.deskflow.deskflow.desktop
+share/icons/hicolor/512x512/apps/org.deskflow.deskflow.png
+share/licenses/deskflow/LICENSE
+share/licenses/deskflow/LICENSE_EXCEPTION
+share/metainfo/org.deskflow.deskflow.metainfo.xml
diff --git a/deskflow/distinfo b/deskflow/distinfo
new file mode 100644 (file)
index 0000000..09ad212
--- /dev/null
@@ -0,0 +1,12 @@
+$NetBSD$
+
+BLAKE2s (CLI11-2.4.2.hpp) = 13fba654ef1c7f536402ba64cbc412ea457a55fda7e56bee0344f80175210206
+SHA512 (CLI11-2.4.2.hpp) = bc98c9075bc6c60053d40f969f81435d6d6d426e49f10ff21152976073f536608a7f28b685bb7cc207586c651ec0f82f8adf8c1be90a8a8a7974c2076360b8ef
+Size (CLI11-2.4.2.hpp) = 420699 bytes
+BLAKE2s (deskflow-1.20.1.tar.gz) = 192aedfe4fb28f2976865fe3573ddef4517e18cd844e42fc80baebc915e1bfc9
+SHA512 (deskflow-1.20.1.tar.gz) = 1b1c2855d9ab62bbe1a7f758d33001fb54ce7fb9e70a95898376da393ea8035d31a65f0180d939e9f999973e8337eae67c6e0c98981e4f6b1cbbc194a829b46f
+Size (deskflow-1.20.1.tar.gz) = 1901842 bytes
+BLAKE2s (toml-3.4.0.hpp) = 8d715a2b4fd6648d5a40ff0f8e2462d9488608da8efe052c5df0516a86b29799
+SHA512 (toml-3.4.0.hpp) = b434408b483f3ce308c63d48922f2dacfaac95be9031056118486b230123a3bdc8303e191c0dc787dc22bcc3a1777fe94057638b6c10da9620163665481c4d0d
+Size (toml-3.4.0.hpp) = 485931 bytes
+SHA1 (patch-src_lib_deskflow_CMakeLists.txt) = fd6b5a4aa018fbbf28530da41144eebf9e743435
diff --git a/deskflow/patches/patch-src_lib_deskflow_CMakeLists.txt b/deskflow/patches/patch-src_lib_deskflow_CMakeLists.txt
new file mode 100644 (file)
index 0000000..b63cfeb
--- /dev/null
@@ -0,0 +1,31 @@
+$NetBSD$
+
+Prevent download during configure phase.
+
+--- src/lib/deskflow/CMakeLists.txt.orig       2025-03-10 10:04:06.434024162 +0000
++++ src/lib/deskflow/CMakeLists.txt
+@@ -11,11 +11,6 @@ else()
+   #Be sure to update the version and MD5 together
+   set(CLI11_VERSION 2.4.2)
+   set(CLI11_MD5 d7923d1ca06d03e2299e55cad532d126)
+-  file(
+-    DOWNLOAD "https://github.com/CLIUtils/CLI11/releases/download/v${CLI11_VERSION}/CLI11.hpp"
+-    "${CMAKE_BINARY_DIR}/include/CLI/CLI.hpp"
+-    EXPECTED_MD5 ${CLI11_MD5}
+-  )
+   set(cli11_inc_dir "${CMAKE_BINARY_DIR}/include")
+   message(STATUS "CLI11 [Downloaded] Version: ${CLI11_VERSION}")
+   message(STATUS "CLI11 INC_DIR: ${cli11_inc_dir}")
+@@ -30,12 +25,6 @@ else()
+   # Save our copy with .h not .hpp for compatibliy with system version < 3.4
+   set(TOMLPP_VERSION 3.4.0)
+   set(TOMLPP_MD5 caefb3b60119731fb4b4d24b6339e7fb)
+-  file(
+-    DOWNLOAD "https://raw.githubusercontent.com/marzer/tomlplusplus/refs/tags/v${TOMLPP_VERSION}/toml.hpp"
+-    "${CMAKE_BINARY_DIR}/include/toml++/toml.h"
+-    SHOW_PROGRESS
+-    EXPECTED_MD5 ${TOMLPP_MD5}
+-  )
+   set(tomlPP_inc_dir "${CMAKE_BINARY_DIR}/include")
+   message(STATUS "tomlplusplus [Downloaded] Version: 3.4.0")
+   message(STATUS "tomlplusplus INC DIR: ${tomlPP_inc_dir}")