pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

udev: add version 228



Module Name:	pkgsrc-wip
Committed By:	Denys Nykula <nykula%ukr.net@localhost>
Pushed By:	nykula
Date:		Sat Oct 26 19:32:07 2019 +0300
Changeset:	141176310f28610aa4480243a1e46b1e1044e95e

Modified Files:
	Makefile
	libudev/Makefile
	weston/DESCR
	weston/Makefile
Added Files:
	libudev/Makefile.common
	udev/DESCR
	udev/Makefile
	udev/PLIST
	udev/files/libudev.am
	udev/files/rules.am

Log Message:
udev: add version 228

Writes index of device paths to /var/run/udev/ that libudev reads at
runtime. I cut out the invasive parts that force systemd naming systemwide
or change device owners. Left just the index for libinput. Run it once for
weston to find a seat, that is a video card, keyboard and mouse combo. Can
then backup the above dir and delete the package. TODO code a libudev shim
finding the seat by watching /dev which could eliminate this daemon.

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=141176310f28610aa4480243a1e46b1e1044e95e

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 Makefile                |  1 +
 libudev/Makefile        | 17 ++---------------
 libudev/Makefile.common | 21 +++++++++++++++++++++
 udev/DESCR              |  9 +++++++++
 udev/Makefile           | 16 ++++++++++++++++
 udev/PLIST              |  9 +++++++++
 udev/files/libudev.am   | 11 +++++++++++
 udev/files/rules.am     |  2 ++
 weston/DESCR            |  2 ++
 weston/Makefile         |  2 +-
 10 files changed, 74 insertions(+), 16 deletions(-)

diffs:
diff --git a/Makefile b/Makefile
index 36e600d941..22fc274e25 100644
--- a/Makefile
+++ b/Makefile
@@ -4831,6 +4831,7 @@ SUBDIR+=	uade
 SUBDIR+=	ubit
 SUBDIR+=	uchime
 SUBDIR+=	uclibc
+SUBDIR+=	udev
 SUBDIR+=	udhcp
 SUBDIR+=	udp-ping
 SUBDIR+=	udunits2
diff --git a/libudev/Makefile b/libudev/Makefile
index db8acb4137..4aaa7e59bb 100644
--- a/libudev/Makefile
+++ b/libudev/Makefile
@@ -1,22 +1,9 @@
 # $NetBSD$
 
-DISTNAME=	libudev-228
-CATEGORIES=	sysutils
-MASTER_SITES=	${MASTER_SITE_GITHUB:=gentoo/}
-GITHUB_PROJECT=	eudev
-GITHUB_TAG=	v3.2.8 # udev version 228 according to configure.ac
-
-MAINTAINER=	nykula%ukr.net@localhost
-HOMEPAGE=	https://wiki.gentoo.org/wiki/Project:Eudev
 COMMENT=	Device enumeration and database of constants
-LICENSE=	gnu-gpl-v2
-
-ONLY_FOR_PLATFORM=	Linux-*-*
-USE_TOOLS+=	autoconf automake gmake
-GNU_CONFIGURE=	yes
-CONFIGURE_ARGS+=	--disable-programs --with-rootrundir=${VARBASE}/run
+CONFIGURE_ARGS+=	--disable-programs
 
 pre-configure:
 	cd ${WRKSRC} &&autoreconf -fiv
 
-.include "../../mk/bsd.pkg.mk"
+.include "../../wip/libudev/Makefile.common"
diff --git a/libudev/Makefile.common b/libudev/Makefile.common
new file mode 100644
index 0000000000..b6d4a98f9a
--- /dev/null
+++ b/libudev/Makefile.common
@@ -0,0 +1,21 @@
+# $NetBSD$
+# used by wip/libudev/Makefile
+# used by wip/udev/Makefile
+
+DISTNAME=	libudev-228
+CATEGORIES=	sysutils
+MASTER_SITES=	${MASTER_SITE_GITHUB:=gentoo/}
+GITHUB_PROJECT=	eudev
+GITHUB_TAG=	v3.2.8 # udev version 228 according to configure.ac
+DISTINFO_FILE=	${.CURDIR}/../../wip/libudev/distinfo
+
+MAINTAINER=	nykula%ukr.net@localhost
+HOMEPAGE=	https://wiki.gentoo.org/wiki/Project:Eudev
+LICENSE=	gnu-gpl-v2
+
+ONLY_FOR_PLATFORM=	Linux-*-*
+USE_TOOLS+=	autoconf automake gmake
+GNU_CONFIGURE=	yes
+CONFIGURE_ARGS+=	--with-rootrundir=${VARBASE}/run
+
+.include "../../mk/bsd.pkg.mk"
diff --git a/udev/DESCR b/udev/DESCR
new file mode 100644
index 0000000000..5c5607ac28
--- /dev/null
+++ b/udev/DESCR
@@ -0,0 +1,9 @@
+Monitors devices and executes rules for each insert or removal. Creates an
+index of paths in /var/run/udev/ that libudev uses at runtime. Need to
+trigger it once for weston to find a seat, that is a video card, keyboard
+and mouse combo. Run `udevd -d` and `udevadm trigger`.
+
+You can then backup the above dir and delete the package if your embedded
+device set never changes. Somebody should code a libudev API clone finding
+the seat using sysfs and watching /dev, which would eliminate the daemon
+on desktops and ease porting wayland to BSD counterparts.
diff --git a/udev/Makefile b/udev/Makefile
new file mode 100644
index 0000000000..daf036af15
--- /dev/null
+++ b/udev/Makefile
@@ -0,0 +1,16 @@
+# $NetBSD$
+
+PKGNAME=	udev-228
+COMMENT=	Hotplug daemon
+CONFIGURE_ARGS+=	--disable-hwdb
+
+pre-configure:
+	cp ${FILESDIR}/rules.am ${WRKSRC}/rules/Makefile.am
+	sed -i 's/.(PROGRAMS_SUBDIRS)/udev/' ${WRKSRC}/src/Makefile.am
+	cp ${FILESDIR}/libudev.am ${WRKSRC}/src/libudev/Makefile.am
+	sed -i 's/.(LN.*;/true;/' ${WRKSRC}/src/udev/Makefile.am
+	sed -i 's,/run,"UDEV_ROOT_RUN",' ${WRKSRC}/src/udev/*.c
+	cd ${WRKSRC} &&autoreconf -fiv
+
+.include "../../wip/libudev/buildlink3.mk"
+.include "../../wip/libudev/Makefile.common"
diff --git a/udev/PLIST b/udev/PLIST
new file mode 100644
index 0000000000..234968c84e
--- /dev/null
+++ b/udev/PLIST
@@ -0,0 +1,9 @@
+@comment $NetBSD$
+bin/udevadm
+etc/udev/udev.conf
+include/udev.h
+lib/udev/rules.d/60-drm.rules
+lib/udev/rules.d/60-evdev.rules
+lib/udev/rules.d/60-input-id.rules
+sbin/udevd
+share/pkgconfig/udev.pc
diff --git a/udev/files/libudev.am b/udev/files/libudev.am
new file mode 100644
index 0000000000..c58093ac36
--- /dev/null
+++ b/udev/files/libudev.am
@@ -0,0 +1,11 @@
+# Limit to libudev-private.la, wip/libudev does the public lib.
+AM_CPPFLAGS=-include $(top_builddir)/config.h \
+	-DUDEV_ROOT_RUN=\"$(rootrundir)\" \
+	-DUDEV_CONF_FILE=\"$(udevconffile)\" \
+	-DUDEV_HWDB_BIN=\"$(udevhwdbbin)\" -I $(top_srcdir)/src/shared
+libudev_private_la_SOURCES=libudev.sym libudev-private.h libudev.c \
+	libudev-list.c libudev-util.c libudev-device.c \
+	libudev-enumerate.c libudev-monitor.c libudev-queue.c \
+	libudev-hwdb-def.h libudev-hwdb.c libudev-device-private.c
+libudev_private_la_CFLAGS=$(AM_CFLAGS) -fvisibility=default
+noinst_LTLIBRARIES=libudev-private.la
diff --git a/udev/files/rules.am b/udev/files/rules.am
new file mode 100644
index 0000000000..eb4145081d
--- /dev/null
+++ b/udev/files/rules.am
@@ -0,0 +1,2 @@
+# Don't apply systemd naming or change owners, just index for libinput.
+dist_udevrules_DATA=60-drm.rules 60-evdev.rules 60-input-id.rules
diff --git a/weston/DESCR b/weston/DESCR
index ed3e7289b1..14ae6168fe 100644
--- a/weston/DESCR
+++ b/weston/DESCR
@@ -3,3 +3,5 @@ compositor. Shows a wallpaper under its semi-transparent launcher panel
 with a clock. Takes over a text console, or starts a nested window
 instance inside an existing session. Renders to a framebuffer device or an
 EGL direct rendering context. Has a screenshooter and a terminal emulator.
+
+Needs wip/udev once at runtime, see its DESCR for details.
diff --git a/weston/Makefile b/weston/Makefile
index 1e9491d518..c424267e7f 100644
--- a/weston/Makefile
+++ b/weston/Makefile
@@ -1,7 +1,7 @@
 # $NetBSD$
 
 DISTNAME=	weston-7.0.0
-CATEGORIES=	local
+CATEGORIES=	wm
 MASTER_SITES=	https://wayland.freedesktop.org/releases/
 EXTRACT_SUFX=	.tar.xz
 


Home | Main Index | Thread Index | Old Index