mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-02-01 03:53:33 +00:00
cf93ecbbb2
The whole repository is now buildable with GNU Make Landlock sandboxing. This proves that no Makefile targets exist which touch files other than their declared prerequisites. In order to do this, we had to: 1. Stop code morphing GCC output in package.com and instead run a newly introduced FIXUPOBJ.COM command after GCC invocations. 2. Disable all the crumby Python unit tests that do things like create files in the current directory, or rename() files between folders. This ended up being a lot of tests, but most of them are still ok. 3. Introduce an .UNSANDBOXED variable to GNU Make to disable Landlock. We currently only do this for things like `make tags`. 4. This change deletes some GNU Make code that was preventing the execve() optimization from working. This means it should no longer be necessary in most cases for command invocations to be indirected through the cocmd interpreter. 5. Missing dependencies had to be declared in certain places, in cases where they couldn't be automatically determined by MKDEPS.COM 6. The libcxx header situation has finally been tamed. One of the things that makes this difficult is MKDEPS.COM only wants to consider the first 64kb of a file, in order to go fast. But libcxx likes to have #include lines buried after huge documentation. 7. An .UNVEIL variable has been introduced to GNU Make just in case we ever wish to explicitly specify additional things that need to be whitelisted which aren't strictly prerequisites. This works in a manner similar to the recently introduced .EXTRA_PREREQS feature. There's now a new build/bootstrap/make.com prebuilt binary available. It should no longer be possible to write invalid Makefile code.
22 lines
807 B
C
22 lines
807 B
C
#ifndef COSMOPOLITAN_LIBC_SOCK_STRUCT_MSGHDR_H_
|
|
#define COSMOPOLITAN_LIBC_SOCK_STRUCT_MSGHDR_H_
|
|
#include "libc/calls/struct/iovec.h"
|
|
#if !(__ASSEMBLER__ + __LINKER__ + 0)
|
|
COSMOPOLITAN_C_START_
|
|
|
|
struct msghdr { /* Linux+NT ABI */
|
|
void *msg_name; /* optional address */
|
|
uint32_t msg_namelen; /* size of msg_name */
|
|
struct iovec *msg_iov; /* scatter/gather array */
|
|
uint64_t msg_iovlen; /* iovec count */
|
|
void *msg_control; /* credentials and stuff */
|
|
uint64_t msg_controllen; /* size of msg_control */
|
|
uint32_t msg_flags; /* MSG_XXX */
|
|
};
|
|
|
|
ssize_t recvmsg(int, struct msghdr *, int);
|
|
ssize_t sendmsg(int, const struct msghdr *, int);
|
|
|
|
COSMOPOLITAN_C_END_
|
|
#endif /* !(__ASSEMBLER__ + __LINKER__ + 0) */
|
|
#endif /* COSMOPOLITAN_LIBC_SOCK_STRUCT_MSGHDR_H_ */
|