mirror of
https://git.FreeBSD.org/ports.git
synced 2025-02-02 11:09:29 +00:00
Update the rtc device to use dynamic numbering on -current. In order to
accomdate this change, stop using device nodes in /usr/compat/linux/dev and instead rely on the linuxalator passing through requests to the real /dev. (This second change also applies to 4.x).
This commit is contained in:
parent
6ac3ed82f1
commit
2d30e526ba
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=103901
@ -7,7 +7,7 @@
|
||||
|
||||
PORTNAME= rtc
|
||||
PORTVERSION= 2004.02.24.1
|
||||
PORTREVISION= 3
|
||||
PORTREVISION= 4
|
||||
CATEGORIES= emulators linux
|
||||
MASTER_SITES= # none
|
||||
DISTFILES= # none
|
||||
@ -51,11 +51,10 @@ do-extract:
|
||||
|
||||
pre-install:
|
||||
${MKDIR} ${KMODDIR}
|
||||
${MKDIR} ${DEVDIR}
|
||||
|
||||
post-install:
|
||||
${RM} -f ${DEVDIR}/rtc
|
||||
mknod ${DEVDIR}/rtc c ${CDEV_MAJOR} 0
|
||||
-mknod /dev/rtc c ${CDEV_MAJOR} 0
|
||||
${INSTALL_DATA} ${WRKSRC}/rtc.h ${PREFIX}/include/
|
||||
${MKDIR} ${PREFIX}/share/examples/rtc
|
||||
${INSTALL_DATA} ${WRKSRC}/test.c ${PREFIX}/share/examples/rtc/
|
||||
|
@ -96,6 +96,8 @@ static struct cdevsw rtc_cdevsw = {
|
||||
#if __FreeBSD_version >= 502103
|
||||
.d_version = D_VERSION,
|
||||
.d_flags = D_NEEDGIANT,
|
||||
#else
|
||||
.d_maj = CDEV_MAJOR,
|
||||
#endif
|
||||
.d_open = rtc_open,
|
||||
.d_close = rtc_close,
|
||||
@ -103,7 +105,6 @@ static struct cdevsw rtc_cdevsw = {
|
||||
.d_poll = rtc_poll,
|
||||
.d_read = rtc_read,
|
||||
.d_name = DEVICE_NAME,
|
||||
.d_maj = CDEV_MAJOR,
|
||||
#else
|
||||
/* open */ rtc_open,
|
||||
/* close */ rtc_close,
|
||||
|
@ -4,7 +4,4 @@ modules/rtc.ko
|
||||
share/examples/rtc/test.c
|
||||
@dirrm share/examples/rtc
|
||||
@unexec rmdir %D/modules 2>/dev/null || true
|
||||
@exec rm -f %%DEVDIR%%/rtc
|
||||
@exec mkdir -p %%DEVDIR%%
|
||||
@exec mknod %%DEVDIR%%/rtc c %%CDEV_MAJOR%% 0
|
||||
@unexec rm -f %%DEVDIR%%/rtc
|
||||
@unexec rm -f /dev/rtc
|
||||
|
Loading…
x
Reference in New Issue
Block a user