pkgsrc-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
pkg/53310: [patch] Import devel/tslib and add as an optional dependency to x11/qt5-qtbase
>Number: 53310
>Category: pkg
>Synopsis: [patch] Import devel/tslib and add as an optional dependency to x11/qt5-qtbase
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: pkg-manager
>State: open
>Class: change-request
>Submitter-Id: net
>Arrival-Date: Thu May 24 10:10:00 +0000 2018
>Originator: nia
>Release: current
>Organization:
>Environment:
>Description:
tslib is a library for touchscreen support.
I noticed that qt5-qbase was picking up my system's version of the
library and the build was failing as a result (because it adds new
things to PLIST), so I thought I'd make a package for it.
tslib builds successfully on NetBSD, but due to limited driver
support it's probably most useful on FreeBSD and Linux, so currently
only enable the qt5 dependency on those platforms.
This is because it relies on evdev (/dev/input/*) for devices that
aren't RS232-based.
>How-To-Repeat:
>Fix:
Index: devel/Makefile
===================================================================
RCS file: /cvsroot/pkgsrc/devel/Makefile,v
retrieving revision 1.2682
diff -u -r1.2682 Makefile
--- devel/Makefile 23 May 2018 09:28:30 -0000 1.2682
+++ devel/Makefile 23 May 2018 12:42:48 -0000
@@ -2617,6 +2617,7 @@
SUBDIR+= tre
SUBDIR+= treecc
SUBDIR+= trio
+SUBDIR+= tslib
SUBDIR+= tvision
SUBDIR+= ucl
SUBDIR+= ucommon
Index: devel/tslib/DESCR
===================================================================
RCS file: devel/tslib/DESCR
diff -N devel/tslib/DESCR
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ devel/tslib/DESCR 23 May 2018 12:42:48 -0000
@@ -0,0 +1,10 @@
+tslib is a cross-platform library that provides access to touchscreen
+devices and the ability to apply filters to their input events.
+
+tslib is used to access touch screen devices, in case the operating
+system doesn't provide driver support. It may instead also only be used
+to optimize the touch user experience by applying mathematical filters
+in any number or order. The libts library is highly configurable
+and portable. tslib includes tools to calibrate, test and use the
+library. It is well suited for embedded devices and used in many
+commercial products. tslib includes documentation on how to use it.
Index: devel/tslib/Makefile
===================================================================
RCS file: devel/tslib/Makefile
diff -N devel/tslib/Makefile
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ devel/tslib/Makefile 23 May 2018 12:42:48 -0000
@@ -0,0 +1,40 @@
+# $NetBSD$
+
+DISTNAME= tslib-1.16
+CATEGORIES= devel
+MASTER_SITES= ${MASTER_SITE_GITHUB:=kergoth/}
+
+MAINTAINER= pkgsrc-users%NetBSD.org@localhost
+HOMEPAGE= http://www.tslib.org/
+COMMENT= Touchscreen access library
+LICENSE= gnu-lgpl-v2.1
+
+GNU_CONFIGURE= yes
+USE_TOOLS+= autoconf automake
+USE_LIBTOOL= yes
+
+EGDIR= ${PREFIX}/share/examples/tslib
+CONFIGURE_ARGS+= --sysconfdir=${EGDIR}
+CONF_FILES+= ${EGDIR}/ts.conf ${PKG_SYSCONFDIR}/ts.conf
+
+pre-configure:
+ (cd ${WRKSRC}; ./autogen.sh)
+
+.include "../../mk/bsd.prefs.mk"
+
+PLIST_VARS+= input waveshare
+
+.if ${OPSYS} != "Linux" && ${OPSYS} != "FreeBSD"
+# Disable /dev/input/eventN support
+CONFIGURE_ARGS+= --disable-input
+.else
+PLIST.input= yes
+.endif
+
+.if ${OPSYS} != "Linux"
+CONFIGURE_ARGS+= --disable-waveshare
+.else
+PLIST.waveshare= yes
+.endif
+
+.include "../../mk/bsd.pkg.mk"
Index: devel/tslib/PLIST
===================================================================
RCS file: devel/tslib/PLIST
diff -N devel/tslib/PLIST
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ devel/tslib/PLIST 23 May 2018 12:42:48 -0000
@@ -0,0 +1,43 @@
+@comment $NetBSD$
+include/tslib.h
+lib/libts.la
+lib/pkgconfig/tslib.pc
+lib/ts/debounce.la
+lib/ts/dejitter.la
+lib/ts/iir.la
+${PLIST.input}lib/ts/input.la
+lib/ts/invert.la
+lib/ts/linear.la
+lib/ts/lowpass.la
+lib/ts/median.la
+lib/ts/pthres.la
+lib/ts/skip.la
+lib/ts/touchkit.la
+lib/ts/variance.la
+${PLIST.waveshare}lib/ts/waveshare.la
+man/man1/ts_calibrate.1
+man/man1/ts_finddev.1
+man/man1/ts_harvest.1
+man/man1/ts_print.1
+man/man1/ts_print_mt.1
+man/man1/ts_print_raw.1
+man/man1/ts_test.1
+man/man1/ts_test_mt.1
+man/man1/ts_uinput.1
+man/man1/ts_verify.1
+man/man3/ts_close.3
+man/man3/ts_close_restricted.3
+man/man3/ts_config.3
+man/man3/ts_error_fn.3
+man/man3/ts_fd.3
+man/man3/ts_get_eventpath.3
+man/man3/ts_libversion.3
+man/man3/ts_open.3
+man/man3/ts_open_restricted.3
+man/man3/ts_read.3
+man/man3/ts_read_mt.3
+man/man3/ts_read_raw.3
+man/man3/ts_read_raw_mt.3
+man/man3/ts_setup.3
+man/man5/ts.conf.5
+share/examples/tslib/ts.conf
Index: devel/tslib/PLIST.FreeBSD
===================================================================
RCS file: devel/tslib/PLIST.FreeBSD
diff -N devel/tslib/PLIST.FreeBSD
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ devel/tslib/PLIST.FreeBSD 23 May 2018 12:42:48 -0000
@@ -0,0 +1,11 @@
+@comment $NetBSD$
+bin/ts_calibrate
+bin/ts_finddev
+bin/ts_harvest
+bin/ts_print
+bin/ts_print_mt
+bin/ts_print_raw
+bin/ts_test
+bin/ts_test_mt
+bin/ts_uinput
+bin/ts_verify
Index: devel/tslib/PLIST.Linux
===================================================================
RCS file: devel/tslib/PLIST.Linux
diff -N devel/tslib/PLIST.Linux
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ devel/tslib/PLIST.Linux 23 May 2018 12:42:48 -0000
@@ -0,0 +1,11 @@
+@comment $NetBSD$
+bin/ts_calibrate
+bin/ts_finddev
+bin/ts_harvest
+bin/ts_print
+bin/ts_print_mt
+bin/ts_print_raw
+bin/ts_test
+bin/ts_test_mt
+bin/ts_uinput
+bin/ts_verify
Index: devel/tslib/buildlink3.mk
===================================================================
RCS file: devel/tslib/buildlink3.mk
diff -N devel/tslib/buildlink3.mk
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ devel/tslib/buildlink3.mk 23 May 2018 12:42:48 -0000
@@ -0,0 +1,12 @@
+# $NetBSD$
+
+BUILDLINK_TREE+= tslib
+
+.if !defined(TSLIB_BUILDLINK3_MK)
+TSLIB_BUILDLINK3_MK:=
+
+BUILDLINK_API_DEPENDS.tslib+= tslib>=1.16
+BUILDLINK_PKGSRCDIR.tslib?= ../../devel/tslib
+.endif # TSLIB_BUILDLINK3_MK
+
+BUILDLINK_TREE+= -tslib
Index: devel/tslib/distinfo
===================================================================
RCS file: devel/tslib/distinfo
diff -N devel/tslib/distinfo
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ devel/tslib/distinfo 23 May 2018 12:42:48 -0000
@@ -0,0 +1,7 @@
+$NetBSD$
+
+SHA1 (tslib-1.16.tar.gz) = 25aa5fb807ccd9bdff44f1e71b7491783ccecebd
+RMD160 (tslib-1.16.tar.gz) = 8d057bde6f49553f84d89f7a85f6e67ad860b2f5
+SHA512 (tslib-1.16.tar.gz) = a236395c38db400217c154e8ec4f08dca4a85855866d17b6ae9f77f58fb410298fd324a112433c4280f6b8e626d68ed20d186c985845cd85cf460dc284917f8d
+Size (tslib-1.16.tar.gz) = 209234 bytes
+SHA1 (patch-src_ts__open.c) = 99b1577465bab08c1f2c2e7a6b4451911a800671
Index: x11/qt5-qtbase/options.mk
===================================================================
RCS file: /cvsroot/pkgsrc/x11/qt5-qtbase/options.mk,v
retrieving revision 1.10
diff -u -r1.10 options.mk
--- x11/qt5-qtbase/options.mk 17 Jan 2018 19:30:46 -0000 1.10
+++ x11/qt5-qtbase/options.mk 23 May 2018 12:42:48 -0000
@@ -1,12 +1,22 @@
# $NetBSD: options.mk,v 1.10 2018/01/17 19:30:46 markd Exp $
PKG_OPTIONS_VAR= PKG_OPTIONS.qt5
-PKG_SUPPORTED_OPTIONS= cups eglfs gtk3
+PKG_SUPPORTED_OPTIONS= cups eglfs gtk3 tslib
#PKG_SUGGESTED_OPTIONS= cups
+PKG_SUGGESTED_OPTIONS.Linux= tslib
+PKG_SUGGESTED_OPTIONS.FreeBSD= tslib
.include "../../mk/bsd.options.mk"
-PLIST_VARS+= cups gtk3
+PLIST_VARS+= cups gtk3 tslib
+
+.if !empty(PKG_OPTIONS:Mtslib)
+. include "../../devel/tslib/buildlink3.mk"
+CONFIGURE_ARGS+= -tslib
+PLIST.tslib= yes
+.else
+CONFIGURE_ARGS+= -no-tslib
+.endif
.if !empty(PKG_OPTIONS:Mcups)
. include "../../print/cups-base/buildlink3.mk"
Index: x11/qt5-qtbase/PLIST
===================================================================
RCS file: /cvsroot/pkgsrc/x11/qt5-qtbase/PLIST,v
retrieving revision 1.14
diff -u -r1.14 PLIST
--- x11/qt5-qtbase/PLIST 1 Mar 2018 20:09:49 -0000 1.14
+++ x11/qt5-qtbase/PLIST 23 May 2018 12:42:49 -0000
@@ -2503,6 +2503,7 @@
${PLIST.egl}qt5/lib/cmake/Qt5Gui/Qt5Gui_QMinimalEglIntegrationPlugin.cmake
qt5/lib/cmake/Qt5Gui/Qt5Gui_QMinimalIntegrationPlugin.cmake
qt5/lib/cmake/Qt5Gui/Qt5Gui_QOffscreenIntegrationPlugin.cmake
+${PLIST.tslib}qt5/lib/cmake/Qt5Gui/Qt5Gui_QTsLibPlugin.cmake
qt5/lib/cmake/Qt5Gui/Qt5Gui_QTuioTouchPlugin.cmake
${PLIST.unix}qt5/lib/cmake/Qt5Gui/Qt5Gui_QVncIntegrationPlugin.cmake
${PLIST.egl}qt5/lib/cmake/Qt5Gui/Qt5Gui_QXcbEglIntegrationPlugin.cmake
@@ -3150,6 +3151,7 @@
${PLIST.egl}qt5/plugins/egldeviceintegrations/libqeglfs-kms-integration.so
${PLIST.egl}qt5/plugins/egldeviceintegrations/libqeglfs-x11-integration.so
qt5/plugins/generic/libqtuiotouchplugin.so
+${PLIST.tslib}qt5/plugins/generic/libqtslibplugin.so
qt5/plugins/imageformats/libqgif.so
qt5/plugins/imageformats/libqico.so
qt5/plugins/imageformats/libqjpeg.so
Index: mk/defaults/options.description
===================================================================
RCS file: /cvsroot/pkgsrc/mk/defaults/options.description,v
retrieving revision 1.554
diff -u -r1.554 options.description
--- mk/defaults/options.description 16 May 2018 13:30:53 -0000 1.554
+++ mk/defaults/options.description 23 May 2018 12:42:49 -0000
@@ -759,6 +759,7 @@
tremor Enable Tremor fixed point audio decoding library support.
trn-inn Use INN as NNTP client.
trn-nntpclnt Use nntpclnt as NNTP client.
+tslib Use tslib for touchscreen support.
tuning Specify server tuning for large.
twolame Enable MP2 support using twolame.
ucspi-ssl-perl Enable Perl support in ucspi-ssl.
Index: devel/tslib/patches/patch-src_ts__open.c
===================================================================
RCS file: devel/tslib/patches/patch-src_ts__open.c
diff -N devel/tslib/patches/patch-src_ts__open.c
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ devel/tslib/patches/patch-src_ts__open.c 23 May 2018 12:42:49 -0000
@@ -0,0 +1,19 @@
+$NetBSD$
+
+Add support for identifying more operating systems.
+
+--- src/ts_open.c.orig 2018-04-19 13:06:37.000000000 +0000
++++ src/ts_open.c
+@@ -41,8 +41,12 @@ static void print_host_os(void)
+ printf("Host OS: Linux");
+ #elif defined (__FreeBSD__)
+ printf("Host OS: FreeBSD");
++#elif defined (__NetBSD__)
++ printf("Host OS: NetBSD");
+ #elif defined (__OpenBSD__)
+ printf("Host OS: OpenBSD");
++#elif defined (__sun)
++ printf("Host OS: Solaris");
+ #elif defined (__GNU__) && defined (__MACH__)
+ printf("Host OS: Hurd");
+ #elif defined (__HAIKU__)
Home |
Main Index |
Thread Index |
Old Index