From f5e48e94a2f4d4bbd6e5628c7f2afafc6dbcc459 Mon Sep 17 00:00:00 2001 From: Ian Moffett Date: Thu, 7 Mar 2024 17:28:52 -0500 Subject: build: Build mlibc + add distclean target Signed-off-by: Ian Moffett --- .../options/linux/generic/sys-ptrace-stubs.cpp | 36 ---------------------- 1 file changed, 36 deletions(-) delete mode 100644 lib/mlibc/options/linux/generic/sys-ptrace-stubs.cpp (limited to 'lib/mlibc/options/linux/generic/sys-ptrace-stubs.cpp') diff --git a/lib/mlibc/options/linux/generic/sys-ptrace-stubs.cpp b/lib/mlibc/options/linux/generic/sys-ptrace-stubs.cpp deleted file mode 100644 index 8c836c5..0000000 --- a/lib/mlibc/options/linux/generic/sys-ptrace-stubs.cpp +++ /dev/null @@ -1,36 +0,0 @@ - -#include -#include -#include - -#include -#include -#include - -long ptrace(int req, ...) { - va_list ap; - - va_start(ap, req); - auto pid = va_arg(ap, pid_t); - auto addr = va_arg(ap, void *); - auto data = va_arg(ap, void *); - va_end(ap); - - long ret; - if(req > 0 && req < 4) { - data = &ret; - } - - MLIBC_CHECK_OR_ENOSYS(mlibc::sys_ptrace, -1); - long out; - if(int e = mlibc::sys_ptrace(req, pid, addr, data, &out); e) { - errno = e; - return -1; - } else if(req > 0 && req < 4) { - errno = 0; - return ret; - } - - return out; -} - -- cgit v1.2.3