Remove IMAGE_BASE_VIRTUAL

This commit is contained in:
Justine Tunney 2023-09-12 01:21:36 -07:00
parent 8a0008d985
commit 20c77338e6
No known key found for this signature in database
GPG key ID: BE714B4575D6E328
65 changed files with 10 additions and 286 deletions

View file

@ -25,7 +25,6 @@ THIS SOFTWARE.
%{
#include "libc/calls/calls.h"
#include "libc/fmt/fmt.h"
#include "libc/stdio/lock.internal.h"
#include "libc/stdio/stdio.h"
#include "libc/temp.h"
#include "libc/mem/alg.h"

View file

@ -668,7 +668,6 @@ static void run_linker(StringArray *inputs, char *output) {
strarray_push(&arr, "--gc-sections");
strarray_push(&arr, "--build-id=none");
strarray_push(&arr, "--no-dynamic-linker");
strarray_push(&arr, xasprintf("-Ttext-segment=%#x", IMAGE_BASE_VIRTUAL));
/* strarray_push(&arr, "-T"); */
/* strarray_push(&arr, LDS); */
/* strarray_push(&arr, APE); */

View file

@ -16,7 +16,6 @@ CHIBICC = o/$(MODE)/third_party/chibicc/chibicc.com
CHIBICC_FLAGS = \
-fno-common \
-include libc/integral/normalize.inc \
-DIMAGE_BASE_VIRTUAL=$(IMAGE_BASE_VIRTUAL) \
-DMODE='"$(MODE)"'
o/$(MODE)/%.chibicc.o: private .UNSANDBOXED = true

View file

@ -30,7 +30,6 @@
#include "libc/calls/calls.h"
#include "libc/calls/weirdtypes.h"
#include "libc/errno.h"
#include "libc/stdio/lock.internal.h"
#include "libc/stdio/stdio.h"
#include "libc/temp.h"
#include "libc/str/str.h"

View file

@ -1,6 +1,5 @@
#ifndef COSMOPOLITAN_THIRD_PARTY_LUA_LREPL_H_
#define COSMOPOLITAN_THIRD_PARTY_LUA_LREPL_H_
#include "libc/intrin/nopl.internal.h"
#include "third_party/linenoise/linenoise.h"
#include "third_party/lua/lauxlib.h"
#if !(__ASSEMBLER__ + __LINKER__ + 0)
@ -25,11 +24,6 @@ void lua_l_message(const char *, const char *);
char *lua_readline_hint(const char *, const char **, const char **);
void lua_readline_completions(const char *, linenoiseCompletions *);
#ifdef _NOPL0
#define lua_repl_lock() _NOPL0("__threadcalls", lua_repl_lock)
#define lua_repl_unlock() _NOPL0("__threadcalls", lua_repl_unlock)
#endif
COSMOPOLITAN_C_END_
#endif /* !(__ASSEMBLER__ + __LINKER__ + 0) */
#endif /* COSMOPOLITAN_THIRD_PARTY_LUA_LREPL_H_ */

View file

@ -7,7 +7,6 @@
#define PY_SSIZE_T_CLEAN
#include "libc/calls/calls.h"
#include "libc/errno.h"
#include "libc/stdio/lock.internal.h"
#include "third_party/python/Include/abstract.h"
#include "third_party/python/Include/boolobject.h"
#include "third_party/python/Include/bytesobject.h"

View file

@ -67,7 +67,6 @@ This module exposes low-level utilities from the Cosmopolitan library.\n\
Static objects:\n\
\n\
MODE -- make build mode, e.g. \"\", \"tiny\", \"opt\", \"rel\", etc.\n\
IMAGE_BASE_VIRTUAL -- base address of actually portable executable image\n\
kernel -- o/s platform, e.g. \"linux\", \"xnu\", \"metal\", \"nt\", etc.\n\
kStartTsc -- the rdtsc() value at process creation.");
@ -402,7 +401,6 @@ PyInit_cosmo(void)
if (PyType_Ready(&FtracerType) < 0) return 0;
if (!(m = PyModule_Create(&cosmomodule))) return 0;
PyModule_AddStringConstant(m, "MODE", MODE);
PyModule_AddIntConstant(m, "IMAGE_BASE_VIRTUAL", IMAGE_BASE_VIRTUAL);
PyModule_AddStringConstant(m, "kernel", GetKernelName());
PyModule_AddIntConstant(m, "kStartTsc", kStartTsc);

View file

@ -63,7 +63,6 @@
#include "third_party/regex/regex.h"
#include "libc/calls/calls.h"
#include "libc/fmt/fmt.h"
#include "libc/stdio/lock.internal.h"
#include "libc/stdio/stdio.h"
#include "libc/temp.h"
#include "libc/mem/alg.h"

View file

@ -8,7 +8,6 @@
*/
#include "libc/calls/calls.h"
#include "libc/fmt/fmt.h"
#include "libc/stdio/lock.internal.h"
#include "libc/stdio/stdio.h"
#include "libc/temp.h"
#include "libc/str/str.h"