diff options
author | silby <silby@FreeBSD.org> | 2004-03-14 05:20:03 +0800 |
---|---|---|
committer | silby <silby@FreeBSD.org> | 2004-03-14 05:20:03 +0800 |
commit | e5f161de4f2c35f433657a73445488a22a44fa55 (patch) | |
tree | 716b0c2a87ffbb088a17349854be87d87ffe088d /emulators | |
parent | 03ed4486da30dc8c6966ff02ebfe66ae61c2a590 (diff) | |
download | freebsd-ports-gnome-e5f161de4f2c35f433657a73445488a22a44fa55.tar.gz freebsd-ports-gnome-e5f161de4f2c35f433657a73445488a22a44fa55.tar.zst freebsd-ports-gnome-e5f161de4f2c35f433657a73445488a22a44fa55.zip |
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).
Diffstat (limited to 'emulators')
-rw-r--r-- | emulators/rtc/Makefile | 5 | ||||
-rw-r--r-- | emulators/rtc/files/rtc.c | 3 | ||||
-rw-r--r-- | emulators/rtc/pkg-plist | 5 |
3 files changed, 5 insertions, 8 deletions
diff --git a/emulators/rtc/Makefile b/emulators/rtc/Makefile index 2eb2ba6f0005..fddb23c83e76 100644 --- a/emulators/rtc/Makefile +++ b/emulators/rtc/Makefile @@ -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/ diff --git a/emulators/rtc/files/rtc.c b/emulators/rtc/files/rtc.c index 8f0407f1f319..3311cd7ccab0 100644 --- a/emulators/rtc/files/rtc.c +++ b/emulators/rtc/files/rtc.c @@ -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, diff --git a/emulators/rtc/pkg-plist b/emulators/rtc/pkg-plist index 1e7a517f1f3b..b142ef15f620 100644 --- a/emulators/rtc/pkg-plist +++ b/emulators/rtc/pkg-plist @@ -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 |