pkgsrc-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[pkgsrc/trunk]: pkgsrc/net/freerdp2 freerdp2: Fix epoll-shim usage, wayland s...
details: https://anonhg.NetBSD.org/pkgsrc/rev/e79056865b96
branches: trunk
changeset: 382816:e79056865b96
user: nia <nia%pkgsrc.org@localhost>
date: Sat Aug 06 08:02:27 2022 +0000
description:
freerdp2: Fix epoll-shim usage, wayland support, and man page installation
diffstat:
net/freerdp2/Makefile | 24 ++--------
net/freerdp2/PLIST | 15 ++++++-
net/freerdp2/distinfo | 6 ++-
net/freerdp2/options.mk | 19 +++++++-
net/freerdp2/patches/patch-CMakeLists.txt | 35 ++++++++++++++++
net/freerdp2/patches/patch-client_Wayland_wlf__input.c | 24 ++++++++++
net/freerdp2/patches/patch-client_Wayland_wlfreerdp.c | 16 +++++++
net/freerdp2/patches/patch-cmake_InstallFreeRDPMan.cmake | 19 ++++++++
8 files changed, 135 insertions(+), 23 deletions(-)
diffs (281 lines):
diff -r 77915aa8f3db -r e79056865b96 net/freerdp2/Makefile
--- a/net/freerdp2/Makefile Sat Aug 06 07:50:05 2022 +0000
+++ b/net/freerdp2/Makefile Sat Aug 06 08:02:27 2022 +0000
@@ -1,8 +1,8 @@
-# $NetBSD: Makefile,v 1.26 2022/07/02 16:53:32 ryoon Exp $
+# $NetBSD: Makefile,v 1.27 2022/08/06 08:02:27 nia Exp $
DISTNAME= freerdp-2.3.2
PKGNAME= ${DISTNAME:S/freerdp-/freerdp2-/1}
-PKGREVISION= 4
+PKGREVISION= 5
CATEGORIES= net
MASTER_SITES= https://pub.freerdp.com/releases/
@@ -21,7 +21,6 @@
CMAKE_ARGS+= -DWITH_SERVER=ON
CMAKE_ARGS+= -DWITH_CHANNELS=ON
CMAKE_ARGS+= -DWITH_JPEG=ON
-CMAKE_ARGS+= -DWITH_WAYLAND=OFF # XXX needs epoll
CMAKE_ARGS+= -DWITH_GSTREAMER_1_0=OFF
CMAKE_ARGS+= -DAVCODEC_LIBRARY=${PREFIX}/lib/ffmpeg4/libavcodec.so
@@ -39,28 +38,14 @@
.include "../../mk/bsd.prefs.mk"
-.if ${OPSYS} == "NetBSD"
# backtrace(3)
-LDFLAGS.${OPSYS}+= -lexecinfo
-.endif
-.if ${OPSYS} == "FreeBSD" || ${OPSYS} == "NetBSD" || ${OPSYS} == "OpenBSD"
-NEED_EPOLLSHIM= # defined
-LDFLAGS.${OPSYS}+= -lepoll-shim
-.endif
+LDFLAGS.NetBSD+= -lexecinfo
PKGCONFIG_OVERRIDE+= freerdp.pc.in
INSTALLATION_DIRS+= ${PKGMANDIR}/man1 ${PKGMANDIR}/man7
post-install:
-.for page in freerdp-shadow-cli.1 winpr-hash.1 winpr-makecert.1 xfreerdp.1
- ${MV} ${DESTDIR}${PREFIX}/share/man/man1/${page} \
- ${DESTDIR}${PREFIX}/${PKGMANDIR}/man1/${page} || ${TRUE}
-.endfor
- ${MV} ${DESTDIR}${PREFIX}/share/man/man7/wlog.7 \
- ${DESTDIR}${PREFIX}/${PKGMANDIR}/man7/wlog.7 || ${TRUE}
- ${MV} ${DESTDIR}${PREFIX}/share/man/man1/xfreerdp.1 \
- ${DESTDIR}${PREFIX}/${PKGMANDIR}/man1/xfreerdp2.1 || ${TRUE}
${MV} ${DESTDIR}${PREFIX}/bin/xfreerdp \
${DESTDIR}${PREFIX}/bin/xfreerdp2 || ${TRUE}
@@ -70,7 +55,8 @@
.include "../../multimedia/ffmpeg4/buildlink3.mk"
.include "../../security/openssl/buildlink3.mk"
.include "../../mk/jpeg.buildlink3.mk"
-.ifdef NEED_EPOLLSHIM
+.if defined(OPSYS_HAS_KQUEUE)
+CFLAGS+= -I${BUILDLINK_DIR}/include/libepoll-shim
.include "../../devel/libepoll-shim/buildlink3.mk"
.endif
.include "../../mk/bsd.pkg.mk"
diff -r 77915aa8f3db -r e79056865b96 net/freerdp2/PLIST
--- a/net/freerdp2/PLIST Sat Aug 06 07:50:05 2022 +0000
+++ b/net/freerdp2/PLIST Sat Aug 06 08:02:27 2022 +0000
@@ -1,8 +1,9 @@
-@comment $NetBSD: PLIST,v 1.3 2021/05/03 18:35:07 jdolecek Exp $
+@comment $NetBSD: PLIST,v 1.4 2022/08/06 08:02:27 nia Exp $
bin/freerdp-proxy
bin/freerdp-shadow-cli
bin/winpr-hash
bin/winpr-makecert
+${PLIST.wayland}bin/wlfreerdp
${PLIST.x11}bin/xfreerdp2
include/freerdp2/freerdp/addin.h
include/freerdp2/freerdp/altsec.h
@@ -142,6 +143,8 @@
include/freerdp2/freerdp/utils/stopwatch.h
include/freerdp2/freerdp/version.h
include/freerdp2/freerdp/window.h
+${PLIST.wayland}include/uwac0/uwac/uwac-tools.h
+${PLIST.wayland}include/uwac0/uwac/uwac.h
include/winpr2/winpr/asn1.h
include/winpr2/winpr/bcrypt.h
include/winpr2/winpr/bitstream.h
@@ -230,6 +233,10 @@
lib/cmake/WinPR2/WinPRConfigVersion.cmake
lib/cmake/WinPR2/WinPRTargets-release.cmake
lib/cmake/WinPR2/WinPRTargets.cmake
+${PLIST.wayland}lib/cmake/uwac0/uwac-release.cmake
+${PLIST.wayland}lib/cmake/uwac0/uwac.cmake
+${PLIST.wayland}lib/cmake/uwac0/uwacConfig.cmake
+${PLIST.wayland}lib/cmake/uwac0/uwacConfigVersion.cmake
lib/libfreerdp-client2.so
lib/libfreerdp-client2.so.2
lib/libfreerdp-client2.so.${PKGVERSION}
@@ -245,6 +252,9 @@
lib/libfreerdp2.so
lib/libfreerdp2.so.2
lib/libfreerdp2.so.${PKGVERSION}
+${PLIST.wayland}lib/libuwac0.so
+${PLIST.wayland}lib/libuwac0.so.0
+${PLIST.wayland}lib/libuwac0.so.0.1.1
lib/libwinpr-tools2.so
lib/libwinpr-tools2.so.2
lib/libwinpr-tools2.so.${PKGVERSION}
@@ -255,10 +265,13 @@
lib/pkgconfig/freerdp-server2.pc
lib/pkgconfig/freerdp-shadow2.pc
lib/pkgconfig/freerdp2.pc
+${PLIST.wayland}lib/pkgconfig/uwac0.pc
lib/pkgconfig/winpr-tools2.pc
lib/pkgconfig/winpr2.pc
man/man1/freerdp-shadow-cli.1
man/man1/winpr-hash.1
man/man1/winpr-makecert.1
+${PLIST.wayland}man/man1/wlfreerdp.1
${PLIST.x11}man/man1/xfreerdp.1
man/man7/wlog.7
+@pkgdir share/man/man7
diff -r 77915aa8f3db -r e79056865b96 net/freerdp2/distinfo
--- a/net/freerdp2/distinfo Sat Aug 06 07:50:05 2022 +0000
+++ b/net/freerdp2/distinfo Sat Aug 06 08:02:27 2022 +0000
@@ -1,7 +1,11 @@
-$NetBSD: distinfo,v 1.9 2021/10/26 11:05:37 nia Exp $
+$NetBSD: distinfo,v 1.10 2022/08/06 08:02:27 nia Exp $
BLAKE2s (freerdp-2.3.2.tar.gz) = b17b6a3127b36e4c8837f7542cf91e26c7828d55975dc7aab420f532e4e1fe93
SHA512 (freerdp-2.3.2.tar.gz) = b8502d34c73113a42bf2dc240431967829064d68f507cc42ff06432a784213eee4a2c001b174f1b970545aec75b3caf21ba5f4ee1ca8c07c7ef834131413204b
Size (freerdp-2.3.2.tar.gz) = 7284490 bytes
+SHA1 (patch-CMakeLists.txt) = b836a6f13ca3ae654fd9c96aec43c01df237ad53
SHA1 (patch-channels_rdpdr_client_rdpdr__main.c) = 4358d4cd4b9293a27f3edafb94e7759e133ecd5f
+SHA1 (patch-client_Wayland_wlf__input.c) = c79c7359ce538021e09ffbec9e61a9acc63d24af
+SHA1 (patch-client_Wayland_wlfreerdp.c) = c20ac99842d3ae0fda2a1b43807e65efd5121487
+SHA1 (patch-cmake_InstallFreeRDPMan.cmake) = b2008b0e17acdbb352919f3bc45c81fc93dcf3cf
SHA1 (patch-winpr_libwinpr_sysinfo_sysinfo.c) = b0fc583b02c3f416eb9d0f7cb140c4c69b3bdaef
diff -r 77915aa8f3db -r e79056865b96 net/freerdp2/options.mk
--- a/net/freerdp2/options.mk Sat Aug 06 07:50:05 2022 +0000
+++ b/net/freerdp2/options.mk Sat Aug 06 08:02:27 2022 +0000
@@ -1,10 +1,15 @@
-# $NetBSD: options.mk,v 1.3 2021/05/03 18:24:38 jdolecek Exp $
+# $NetBSD: options.mk,v 1.4 2022/08/06 08:02:27 nia Exp $
PKG_OPTIONS_VAR= PKG_OPTIONS.freerdp2
-PKG_SUPPORTED_OPTIONS= alsa pulseaudio cups x11 pcsc
+PKG_SUPPORTED_OPTIONS= alsa pcsc pulseaudio cups wayland x11
PKG_SUGGESTED_OPTIONS= x11 pcsc
PKG_SUGGESTED_OPTIONS.Linux= alsa
+.include "../../devel/wayland/platform.mk"
+.if ${PLATFORM_SUPPORTS_WAYLAND} == "yes"
+PKG_SUGGESTED_OPTIONS+= wayland
+.endif
+
.include "../../mk/bsd.options.mk"
.if !empty(PKG_OPTIONS:Malsa)
@@ -55,3 +60,13 @@
.else
CMAKE_ARGS+= -DWITH_PCSC=OFF
.endif
+
+PLIST_VARS+= wayland
+.if !empty(PKG_OPTIONS:Mwayland)
+. include "../../devel/wayland/buildlink3.mk"
+. include "../../x11/libxkbcommon/buildlink3.mk"
+PLIST.wayland= yes
+CMAKE_ARGS+= -DWITH_WAYLAND=ON
+.else
+CMAKE_ARGS+= -DWITH_WAYLAND=OFF
+.endif
diff -r 77915aa8f3db -r e79056865b96 net/freerdp2/patches/patch-CMakeLists.txt
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/net/freerdp2/patches/patch-CMakeLists.txt Sat Aug 06 08:02:27 2022 +0000
@@ -0,0 +1,35 @@
+$NetBSD: patch-CMakeLists.txt,v 1.1 2022/08/06 08:02:27 nia Exp $
+
+Find epoll-shim using pkg-config on all BSDs.
+
+--- CMakeLists.txt.orig 2021-03-15 12:29:35.000000000 +0000
++++ CMakeLists.txt
+@@ -39,7 +39,7 @@ set(CMAKE_COLOR_MAKEFILE ON)
+ set(CMAKE_POSITION_INDEPENDENT_CODE ON)
+
+ # Include our extra modules
+-set(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake/)
++set (CMAKE_MODULE_PATH "/encrypt/src/pkgsrc/net/freerdp2/work/.buildlink/cmake-Modules" ${CMAKE_SOURCE_DIR}/cmake/)
+
+ if((CMAKE_SYSTEM_NAME MATCHES "WindowsStore") AND (CMAKE_SYSTEM_VERSION MATCHES "10.0"))
+ set(UWP 1)
+@@ -205,6 +205,7 @@ if(${CMAKE_SYSTEM_NAME} MATCHES "BSD")
+ if(${CMAKE_SYSTEM_NAME} MATCHES "OpenBSD")
+ set(OPENBSD TRUE)
+ endif()
++ pkg_check_modules (EPOLL_SHIM REQUIRED epoll-shim)
+ endif()
+
+ if(${CMAKE_SYSTEM_NAME} MATCHES "DragonFly")
+@@ -212,11 +213,6 @@ if(${CMAKE_SYSTEM_NAME} MATCHES "DragonF
+ set(FREEBSD TRUE)
+ endif()
+
+-if(FREEBSD)
+- find_path(EPOLLSHIM_INCLUDE_DIR NAMES sys/epoll.h sys/timerfd.h HINTS /usr/local/include/libepoll-shim)
+- find_library(EPOLLSHIM_LIBS NAMES epoll-shim libepoll-shim HINTS /usr/local/lib)
+-endif()
+-
+ # Configure MSVC Runtime
+ if(MSVC)
+ include(MSVCRuntime)
diff -r 77915aa8f3db -r e79056865b96 net/freerdp2/patches/patch-client_Wayland_wlf__input.c
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/net/freerdp2/patches/patch-client_Wayland_wlf__input.c Sat Aug 06 08:02:27 2022 +0000
@@ -0,0 +1,24 @@
+$NetBSD: patch-client_Wayland_wlf__input.c,v 1.1 2022/08/06 08:02:27 nia Exp $
+
+Support building Wayland components on non-Linux.
+
+--- client/Wayland/wlf_input.c.orig 2021-03-15 12:29:35.000000000 +0000
++++ client/Wayland/wlf_input.c
+@@ -19,7 +19,17 @@
+ */
+
+ #include <stdlib.h>
++#ifdef __linux
+ #include <linux/input.h>
++#else
++#ifndef BTN_LEFT
++#define BTN_LEFT (0x110)
++#define BTN_RIGHT (0x111)
++#define BTN_MIDDLE (0x112)
++#define BTN_SIDE (0x113)
++#define BTN_EXTRA (0x114)
++#endif
++#endif
+
+ #include <freerdp/locale/keyboard.h>
+ #include <freerdp/client/rdpei.h>
diff -r 77915aa8f3db -r e79056865b96 net/freerdp2/patches/patch-client_Wayland_wlfreerdp.c
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/net/freerdp2/patches/patch-client_Wayland_wlfreerdp.c Sat Aug 06 08:02:27 2022 +0000
@@ -0,0 +1,16 @@
+$NetBSD: patch-client_Wayland_wlfreerdp.c,v 1.1 2022/08/06 08:02:27 nia Exp $
+
+Support building Wayland components on non-Linux.
+
+--- client/Wayland/wlfreerdp.c.orig 2021-03-15 12:29:35.000000000 +0000
++++ client/Wayland/wlfreerdp.c
+@@ -31,7 +31,9 @@
+ #include <freerdp/utils/signal.h>
+ #include <freerdp/locale/keyboard.h>
+
++#ifdef __linux
+ #include <linux/input.h>
++#endif
+
+ #include <uwac/uwac.h>
+
diff -r 77915aa8f3db -r e79056865b96 net/freerdp2/patches/patch-cmake_InstallFreeRDPMan.cmake
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/net/freerdp2/patches/patch-cmake_InstallFreeRDPMan.cmake Sat Aug 06 08:02:27 2022 +0000
@@ -0,0 +1,19 @@
+$NetBSD: patch-cmake_InstallFreeRDPMan.cmake,v 1.1 2022/08/06 08:02:27 nia Exp $
+
+Install man pages to CMAKE_INSTALL_MANDIR on all OSes, per pkgsrc policy.
+
+--- cmake/InstallFreeRDPMan.cmake.orig 2021-03-15 12:29:35.000000000 +0000
++++ cmake/InstallFreeRDPMan.cmake
+@@ -1,9 +1,7 @@
++include(GNUInstallDirs)
++
+ function(install_freerdp_man manpage section)
+ if(WITH_MANPAGES)
+- if(OPENBSD OR FREEBSD)
+- install(FILES ${manpage} DESTINATION man/man${section})
+- else()
+- install(FILES ${manpage} DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/man/man${section})
+- endif()
++ install(FILES ${manpage} DESTINATION ${CMAKE_INSTALL_MANDIR}/man${section})
+ endif()
+ endfunction()
Home |
Main Index |
Thread Index |
Old Index