mirror of
https://git.FreeBSD.org/ports.git
synced 2024-11-24 00:45:52 +00:00
- Add staging support
- Use options sub, @sample for config file - Fix few spelling errors in pkg-message
This commit is contained in:
parent
acdd31a3f3
commit
59168d1ba9
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=363873
@ -16,18 +16,15 @@ LICENSE= BSD2CLAUSE
|
||||
BUILD_DEPENDS= cuse4bsd-kmod>=0.1.24:${PORTSDIR}/multimedia/cuse4bsd-kmod
|
||||
LIB_DEPENDS= libcuse4bsd.so:${PORTSDIR}/multimedia/cuse4bsd-kmod
|
||||
|
||||
OPTIONS_DEFINE= DEVD
|
||||
OPTIONS_DEFAULT= DEVD
|
||||
|
||||
USE_RC_SUBR= uhidd
|
||||
SUB_FILES= pkg-message
|
||||
|
||||
MAN5= uhidd.conf.5
|
||||
MAN8= uhidd.8
|
||||
|
||||
LIBDIR= ${PREFIX}/lib
|
||||
|
||||
NO_STAGE= yes
|
||||
OPTIONS_DEFINE= DEVD
|
||||
OPTIONS_DEFAULT= DEVD
|
||||
OPTIONS_SUB= yes
|
||||
|
||||
.include <bsd.port.pre.mk>
|
||||
|
||||
LIBCUSE= ${LIBDIR}/libcuse4bsd.so
|
||||
@ -42,34 +39,22 @@ IGNORE= does not build with the old USB stack
|
||||
EXTRA_PATCHES+= ${FILESDIR}/extra-patch-uhidd-parser.y
|
||||
.endif
|
||||
|
||||
.if ${PORT_OPTIONS:MDEVD}
|
||||
PLIST_SUB+= PL_DEVD=""
|
||||
.else
|
||||
PLIST_SUB+= PL_DEVD="@comment "
|
||||
.endif
|
||||
|
||||
post-patch: .SILENT
|
||||
${FIND} ${WRKSRC}/uhidd -type f -not -name Makefile \
|
||||
-exec ${REINPLACE_CMD} 's|/usr/local|${PREFIX}|g' {} +
|
||||
|
||||
do-install:
|
||||
${INSTALL_PROGRAM} ${WRKSRC}/uhidd/uhidd ${PREFIX}/sbin/uhidd
|
||||
${INSTALL_MAN} ${WRKSRC}/uhidd/uhidd.8 ${PREFIX}/man/man8/uhidd.8
|
||||
${INSTALL_MAN} ${WRKSRC}/uhidd/uhidd.conf.5 ${PREFIX}/man/man5/uhidd.conf.5
|
||||
${INSTALL_PROGRAM} ${WRKSRC}/uhidd/uhidd ${STAGEDIR}${PREFIX}/sbin
|
||||
${INSTALL_MAN} ${WRKSRC}/uhidd/uhidd.8 ${STAGEDIR}${PREFIX}/man/man8
|
||||
${INSTALL_MAN} ${WRKSRC}/uhidd/uhidd.conf.5 ${STAGEDIR}${PREFIX}/man/man5
|
||||
.if ${PORT_OPTIONS:MDEVD}
|
||||
${MKDIR} ${PREFIX}/etc/devd
|
||||
@${MKDIR} ${STAGEDIR}${PREFIX}/etc/devd
|
||||
${REINPLACE_CMD} -E \
|
||||
-e "s|%%PREFIX%%|${PREFIX}|" \
|
||||
-e "s|%%LIBCUSE%%|${LIBCUSE}|" \
|
||||
${WRKSRC}/uhidd/uhidd-devd.conf.sample
|
||||
${INSTALL_DATA} ${WRKSRC}/uhidd/uhidd-devd.conf.sample ${PREFIX}/etc/devd/
|
||||
@if [ ! -f ${PREFIX}/etc/devd/uhidd-devd.conf ]; then \
|
||||
${CP} -p ${PREFIX}/etc/devd/uhidd-devd.conf.sample \
|
||||
${PREFIX}/etc/devd/uhidd-devd.conf; \
|
||||
fi
|
||||
${INSTALL_DATA} ${WRKSRC}/uhidd/uhidd-devd.conf.sample \
|
||||
${STAGEDIR}${PREFIX}/etc/devd
|
||||
.endif
|
||||
|
||||
post-install:
|
||||
@${ECHO_CMD}; ${CAT} ${PKGMESSAGE}; ${ECHO_CMD}
|
||||
|
||||
.include <bsd.port.post.mk>
|
||||
|
@ -1,7 +1,7 @@
|
||||
==============================================================================
|
||||
|
||||
To use uhidd daemon for USB HID devices, depends on which sub class
|
||||
driver you want to attach, to avoid confilicts between the daemon and
|
||||
driver you want to attach, to avoid conflicts between the daemon and
|
||||
the kernel drivers, you should either use the command line option '-u'
|
||||
to instruct the daemon to detach active kernel drivers attached to
|
||||
a device, or you should remove some of those entries 'device ums',
|
||||
@ -13,7 +13,7 @@ you should also remove the relevant devd(8) rules in /etc/devd/usb.conf
|
||||
config file, so those modules will not be loaded automatically by devd(8)
|
||||
when devices are attached.
|
||||
|
||||
If you want to run uhidd deamon at the startup, add the following lines to
|
||||
If you want to run uhidd daemon at the startup, add the following lines to
|
||||
/etc/rc.conf:
|
||||
|
||||
uhidd_flags="-kmohsu"
|
||||
|
@ -1,4 +1,4 @@
|
||||
%%PL_DEVD%%@unexec if cmp -s %D/etc/devd/uhidd-devd.conf.sample %D/etc/devd/uhidd-devd.conf; then rm -f %D/etc/devd/uhidd-devd.conf; fi
|
||||
%%PL_DEVD%%etc/devd/uhidd-devd.conf.sample
|
||||
%%PL_DEVD%%@exec if [ ! -f %D/etc/devd/uhidd-devd.conf ]; then mkdir -p %B; cp -p %D/%F %B/uhidd-devd.conf; fi
|
||||
%%DEVD%%@sample etc/devd/uhidd-devd.conf.sample
|
||||
man/man5/uhidd.conf.5.gz
|
||||
man/man8/uhidd.8.gz
|
||||
sbin/uhidd
|
||||
|
Loading…
Reference in New Issue
Block a user