mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-07-06 03:08:31 +00:00
Introduce #include <cosmo.h>
to toolchain users
This change improves the way internal APIs are being hidden behind the `COSMO` define. The cosmo.h header will take care of defining that, so that a separate define statement isn't needed. This change also does a lot more to define which APIs are standard, and which belong to Cosmo.
This commit is contained in:
parent
9b55dbe417
commit
4a59210008
115 changed files with 699 additions and 422 deletions
|
@ -16,7 +16,7 @@
|
|||
│ TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR │
|
||||
│ PERFORMANCE OF THIS SOFTWARE. │
|
||||
╚─────────────────────────────────────────────────────────────────────────────*/
|
||||
#include "libc/dos.h"
|
||||
#include "libc/dos.internal.h"
|
||||
#include "libc/fmt/conv.h"
|
||||
#include "libc/limits.h"
|
||||
#include "libc/log/check.h"
|
||||
|
@ -29,7 +29,7 @@
|
|||
#include "libc/time/struct/tm.h"
|
||||
#include "libc/x/x.h"
|
||||
#include "libc/x/xasprintf.h"
|
||||
#include "libc/zip.h"
|
||||
#include "libc/zip.internal.h"
|
||||
#include "net/http/http.h"
|
||||
#include "third_party/zlib/zlib.h"
|
||||
#include "tool/build/lib/elfwriter.h"
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
│ TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR │
|
||||
│ PERFORMANCE OF THIS SOFTWARE. │
|
||||
╚─────────────────────────────────────────────────────────────────────────────*/
|
||||
#include "tool/build/lib/loader.h"
|
||||
#include "libc/calls/calls.h"
|
||||
#include "libc/calls/struct/stat.h"
|
||||
#include "libc/elf/elf.h"
|
||||
|
@ -34,7 +35,6 @@
|
|||
#include "third_party/xed/x86.h"
|
||||
#include "tool/build/lib/argv.h"
|
||||
#include "tool/build/lib/endian.h"
|
||||
#include "tool/build/lib/loader.h"
|
||||
#include "tool/build/lib/machine.h"
|
||||
#include "tool/build/lib/memory.h"
|
||||
|
||||
|
@ -105,7 +105,7 @@ static void LoadBin(struct Machine *m, intptr_t base, const char *prog,
|
|||
.p_vaddr = base,
|
||||
.p_paddr = base,
|
||||
.p_filesz = codesize,
|
||||
.p_memsz = ROUNDUP(codesize + FRAMESIZE, BIGPAGESIZE),
|
||||
.p_memsz = ROUNDUP(codesize + FRAMESIZE, 0x200000),
|
||||
.p_align = PAGESIZE,
|
||||
};
|
||||
LoadElfLoadSegment(m, code, codesize, &phdr);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue