diff options
author | 2021-05-12 16:08:47 -0400 | |
---|---|---|
committer | 2021-05-12 16:08:47 -0400 | |
commit | 68311c8bb2e7f974b5b91ad61f85980f432f2d7f (patch) | |
tree | d4a9ed409ebadc06c878142757ac2fd0fb5456af /system_cmds/gcore.tproj | |
parent | 31cccc89092a6431196810f7fc29a49e51aecfa6 (diff) | |
download | apple_cmds-68311c8bb2e7f974b5b91ad61f85980f432f2d7f.tar.gz apple_cmds-68311c8bb2e7f974b5b91ad61f85980f432f2d7f.tar.zst apple_cmds-68311c8bb2e7f974b5b91ad61f85980f432f2d7f.zip |
system_cmds: shutdown may not work
Diffstat (limited to 'system_cmds/gcore.tproj')
-rw-r--r-- | system_cmds/gcore.tproj/Makefile | 9 | ||||
-rw-r--r-- | system_cmds/gcore.tproj/convert.c | 3 | ||||
-rw-r--r-- | system_cmds/gcore.tproj/vm.c | 1 |
3 files changed, 12 insertions, 1 deletions
diff --git a/system_cmds/gcore.tproj/Makefile b/system_cmds/gcore.tproj/Makefile new file mode 100644 index 0000000..78b3db6 --- /dev/null +++ b/system_cmds/gcore.tproj/Makefile @@ -0,0 +1,9 @@ +PROG= gcore +MAN= gcore-internal.1 gcore.1 +SRCS= convert.c corefile.c dyld_shared_cache.c \ + dyld.c main.c sparse.c threads.c utils.c \ + vanilla.c vm.c + +LDADD+=-lutil -lcompression + +.include <bsd.prog.mk> diff --git a/system_cmds/gcore.tproj/convert.c b/system_cmds/gcore.tproj/convert.c index b945733..a3b41f3 100644 --- a/system_cmds/gcore.tproj/convert.c +++ b/system_cmds/gcore.tproj/convert.c @@ -29,7 +29,8 @@ #include <spawn.h> #include <signal.h> #include <xpc/xpc.h> -#include <xpc/private.h> +/* Declare xpc_create_from_plist manually because xpc/private.h is closed source */ +xpc_object_t xpc_create_from_plist(void *data, size_t size); #include <sys/event.h> #include <sys/time.h> diff --git a/system_cmds/gcore.tproj/vm.c b/system_cmds/gcore.tproj/vm.c index 22b0efe..3c4e7e6 100644 --- a/system_cmds/gcore.tproj/vm.c +++ b/system_cmds/gcore.tproj/vm.c @@ -16,6 +16,7 @@ #include <stdbool.h> #include <assert.h> #include <sys/queue.h> +#include <machine/cpu_capabilities.h> /* * There should be better APIs to describe the shared region |