]> granicus.if.org Git - strace/blobdiff - README-linux
Merge Harald Böhme's solaris patches
[strace] / README-linux
index b6f37534ba7e04980a228d74f51da32b5111aefe..e2f9779670301c6e6d1784ee1bcf251567038358 100644 (file)
@@ -1,52 +1,32 @@
-========================================================================
-This is the unmodified README from Branko Lankester's release of strace
-for Linux.  Some of the notes and instructions are no longer valid
-however the file has been retained for its historical value. -- jrs
-========================================================================
 
-This is the second release of strace for linux, it requires linux
-version 0.99.10 or newer.  strace was written by Paul Kranenburg for
-SunOS, I have modified it to work with linux.  Read the file README and
-the strace.1 for more info on strace.
+Strace has been ported by Branko Lankester <branko@hacktic.nl>
+to run on Linux systems.  Since then it has been greatly modified
+by various other people.
 
+If you want to compile strace on a Linux system please make sure that
+you use recent kernel headers. Strace needs those to get the proper data
+structures and constatns used by the kernel, since these can be
+different from the structures that the C library uses. Currently you
+will need at least a 2.2.7 or newer kernel. 
 
-Changes for this release are:
-- bugfixes
-- support for new system calls and ioctls
-- symbolic output for: termio ioctls, sysv ipc, fcntl file locking,
-  statfs and ptrace
-- microsecond time stamps
+To complicate things a bit further strace might not compile if you are
+using development kernels. These tend to have headers that conflict with
+the headers from libc which makes it impossible to use them.
 
-A lot of the changes and bugfixes for this version were done by
-Rick Sladkey <jrs@world.std.com>, System V IPC support was added
-by Ulrich Pegelow <pegelow@moorea.uni-muenster.de>.
+There are three ways to compile strace with other kernel headers:
+* Specify the location in CFLAGS when running configure
 
+     CFLAGS=-I/usr/src/linux/include ./configure
 
-FILES:
+* you can tell make where your kernel sources are. For example if you
+  have your kernelsource in /usr/src/linux, you can invoke make like
+  this:
 
-README.first   this file
-README         the original readme file for SunOS strace
-getioctls      script to create the ioctlents.h file for linux.
-Sun/*          files from the original package I didn't use
+     make CFLAGS="\$CFLAGS -I/usr/src/linux/include"
 
+  (the extra \$CFLAGS is there to make sure we don't override any CFLAGS
+  settings that configure has found).
 
-Notes:
+* you can link /usr/include/linux and /usr/include/asm to the
+  corresponding directories in your kernel source-tree.
 
-- With older versions of Linux (before 0.99.10) signals can get lost
-for a traced process.
-
-- strace works best if you have a proc fs mounted on /proc, the
-/proc/##/mem frame buffers are used for reading system call arguments.
-You can use /dev/ram or some other unused block device for mounting
-the proc fs:
-
-       mount -t proc /dev/ram /proc
-
-or in /etc/fstab:
-
-/dev/hda       /proc           proc    defaults
-
-
-
-Branko Lankester                                       Jun 18 1993
-branko@hacktic.nl || lankeste@fwi.uva.nl