summaryrefslogtreecommitdiffstats
path: root/usr.bin/truss/Makefile
diff options
context:
space:
mode:
authordes <des@FreeBSD.org>2011-10-21 11:08:25 +0000
committerdes <des@FreeBSD.org>2011-10-21 11:08:25 +0000
commit6c6abb3ddc0d7b2572a91949e5eaf448f0a392af (patch)
tree762720b203c8a69ddb88af3b29c52f2a2c9d5302 /usr.bin/truss/Makefile
parent28e8dea25892d12660b01d59590e5a8e70ae3880 (diff)
downloadFreeBSD-src-6c6abb3ddc0d7b2572a91949e5eaf448f0a392af.zip
FreeBSD-src-6c6abb3ddc0d7b2572a91949e5eaf448f0a392af.tar.gz
It turns out that truss also used kdump's mkioctls script, and expected
ioctlname() to return a pointer to the name rather than print it. This did not show up in testing because truss had its own prototype for ioctlname(), so it would build fine and run fine as long as the program being traced did not issue an ioctl. Teach mkioctls to generate different versions of ioctlname() based on its first command-line argument. Pointed out by: Garrett Cooper <yanegomi@gmail.com>
Diffstat (limited to 'usr.bin/truss/Makefile')
-rw-r--r--usr.bin/truss/Makefile3
1 files changed, 2 insertions, 1 deletions
diff --git a/usr.bin/truss/Makefile b/usr.bin/truss/Makefile
index f80ac03..31f08d4 100644
--- a/usr.bin/truss/Makefile
+++ b/usr.bin/truss/Makefile
@@ -23,7 +23,8 @@ syscalls.h: syscalls.master
${.CURDIR}/i386.conf
ioctl.c: ${.CURDIR}/../kdump/mkioctls
- sh ${.CURDIR}/../kdump/mkioctls ${DESTDIR}/usr/include > ${.TARGET}
+ env MACHINE=${MACHINE} \
+ /bin/sh ${.CURDIR}/../kdump/mkioctls return ${DESTDIR}/usr/include > ${.TARGET}
.if ${MACHINE_CPUARCH} == "i386"
SRCS+= i386-linux.c linux_syscalls.h
OpenPOWER on IntegriCloud