d49e2683be
dmesgfs is another example file system, which displays the device tree information gained from dmesg(8) as a directory hierarchy. The information can be displayed in files, or as targets of symbolic links. % l /mnt/mainbus0 total 320 drwxr-xr-x 2 agc agc 512 May 21 22:21 . drwxr-xr-x 2 root wheel 0 Jan 1 1970 .. drwxr-xr-x 2 agc agc 512 May 21 22:21 acpi0 lrwxr-xr-x 1 agc agc 41 May 21 22:21 cpu0 -> cpu0 at mainbus0 apid 0: (boot processor) lrwxr-xr-x 1 agc agc 40 May 21 22:21 ioapic -> ioapic at mainbus0 apid 1 not configured drwxr-xr-x 2 agc agc 512 May 21 22:21 pci0 % l /mnt/mainbus0/pci0/piixide0/atabus1/atapibus0 total 256 drwxr-xr-x 2 agc agc 512 May 21 22:21 . drwxr-xr-x 2 agc agc 512 May 21 22:21 .. lrwxr-xr-x 1 agc agc 31 May 21 22:21 Description -> atapibus0 at atabus1: 2 targets lrwxr-xr-x 1 agc agc 104 May 21 22:21 cd0 -> cd0 at atapibus0 drive 0: <VMware Virtual IDE CDROM Drive, 1000000000000000000, 0000000> cdrom removable %
14 lines
238 B
Makefile
14 lines
238 B
Makefile
# $NetBSD: Makefile,v 1.1 2007/05/21 21:29:23 agc Exp $
|
|
|
|
PROG=dmesgfs
|
|
SRCS=dmesgfs.c virtdir.c
|
|
LDADD+= -lrefuse
|
|
CPPFLAGS+= -g -I${.CURDIR}/../virtdir
|
|
LDFLAGS+=-g
|
|
MAN=dmesgfs.8
|
|
WARNS=4
|
|
|
|
.PATH: ${.CURDIR}/../virtdir
|
|
|
|
.include <bsd.prog.mk>
|