aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorElliott Hughes <enh@google.com>2021-09-17 14:27:44 -0700
committerRob Landley <rob@landley.net>2021-09-17 22:54:25 -0500
commitd62ee37816b3de528a19059bcf9911709fd55f0b (patch)
treea4fa5775852acd16b3000a5270081ffdb7e0d7b1 /lib
parentddfc5ac65584c9177f0429ca8386d1e1297bea77 (diff)
downloadtoybox-d62ee37816b3de528a19059bcf9911709fd55f0b.tar.gz
strace: initial commit.
This is most notably lacking -p and -f, and only covers a small subset of system calls, but it's "useful" in the sense that you can strace something like toybox date, say, and see everything. There's a fundamental assumption here that we don't need to worry about multiple personalities. (This is what makes "real" strace's build so complex, and why Android has _never_ actually shipped a fully correct strace build.) Given that the desktop's already been 64-bit only for a while, microcontrollers are likely to stay 32-bit only for a while, and the odd one out -- mobile -- is moving to be 64-bit only (https://www.arm.com/blogs/blueprint/64-bit), so by the time this is ready to graduate from pending, I'm assuming no-one will care!
Diffstat (limited to 'lib')
-rw-r--r--lib/portability.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/portability.h b/lib/portability.h
index bb792f10..22e82ad6 100644
--- a/lib/portability.h
+++ b/lib/portability.h
@@ -371,3 +371,5 @@ int dev_makedev(int major, int minor);
char *fs_type_name(struct statfs *statfs);
int get_block_device_size(int fd, unsigned long long *size);
+
+#include <sys/user.h>