[build] Move to python build scripts per module
This change moves Bonnibel from a separate project into the jsix tree, and alters the project configuration to be jsix-specific. (I stopped using bonnibel for any other projects, so it's far easier to make it a custom generator for jsix.) The build system now also uses actual python code in `*.module` files to configure modules instead of TOML files. Target configs (boot, kernel-mode, user-mode) now moved to separate TOML files under `configs/` and can inherit from one another.
This commit is contained in:
176
src/libraries/libc/libc.module
Normal file
176
src/libraries/libc/libc.module
Normal file
@@ -0,0 +1,176 @@
|
||||
# vim: ft=python
|
||||
|
||||
libc = module("libc",
|
||||
kind = "lib",
|
||||
output = "libc.a",
|
||||
includes = [ "include" ],
|
||||
deps = [ "j6" ],
|
||||
sources = [
|
||||
"arch/x86_64/_Exit.s",
|
||||
"arch/x86_64/crt0.s",
|
||||
"ctype/isalnum.c",
|
||||
"ctype/isalpha.c",
|
||||
"ctype/isblank.c",
|
||||
"ctype/iscntrl.c",
|
||||
"ctype/isdigit.c",
|
||||
"ctype/isgraph.c",
|
||||
"ctype/islower.c",
|
||||
"ctype/isprint.c",
|
||||
"ctype/ispunct.c",
|
||||
"ctype/isspace.c",
|
||||
"ctype/isupper.c",
|
||||
"ctype/isxdigit.c",
|
||||
"ctype/tolower.c",
|
||||
"ctype/toupper.c",
|
||||
"inttypes/imaxabs.c",
|
||||
"inttypes/imaxdiv.c",
|
||||
"inttypes/strtoimax.c",
|
||||
"inttypes/strtoumax.c",
|
||||
"locale/localeconv.c",
|
||||
"locale/setlocale.c",
|
||||
"j6libc/assert.c",
|
||||
"j6libc/errno.c",
|
||||
"j6libc/allocpages.c",
|
||||
"j6libc/atomax.c",
|
||||
"j6libc/closeall.c",
|
||||
"j6libc/close.c",
|
||||
"j6libc/digits.c",
|
||||
"j6libc/filemode.c",
|
||||
"j6libc/fillbuffer.c",
|
||||
"j6libc/flushbuffer.c",
|
||||
"j6libc/is_leap.c",
|
||||
"j6libc/load_lc_collate.c",
|
||||
"j6libc/load_lc_ctype.c",
|
||||
"j6libc/load_lc_messages.c",
|
||||
"j6libc/load_lc_monetary.c",
|
||||
"j6libc/load_lc_numeric.c",
|
||||
"j6libc/load_lc_time.c",
|
||||
"j6libc/load_lines.c",
|
||||
"j6libc/open.c",
|
||||
"j6libc/prepread.c",
|
||||
"j6libc/prepwrite.c",
|
||||
"j6libc/print.c",
|
||||
"j6libc/rename.c",
|
||||
"j6libc/scan.c",
|
||||
"j6libc/seed.c",
|
||||
"j6libc/seek.c",
|
||||
"j6libc/stdinit.c",
|
||||
"j6libc/strtox_main.c",
|
||||
"j6libc/strtox_prelim.c",
|
||||
"j6libc/sbrk.c",
|
||||
"signal/raise.c",
|
||||
"signal/signal.c",
|
||||
"stdio/clearerr.c",
|
||||
"stdio/fclose.c",
|
||||
"stdio/feof.c",
|
||||
"stdio/ferror.c",
|
||||
"stdio/fflush.c",
|
||||
"stdio/fgetc.c",
|
||||
"stdio/fgetpos.c",
|
||||
"stdio/fgets.c",
|
||||
"stdio/fopen.c",
|
||||
"stdio/fprintf.c",
|
||||
"stdio/fputc.c",
|
||||
"stdio/fputs.c",
|
||||
"stdio/fread.c",
|
||||
"stdio/freopen.c",
|
||||
"stdio/fscanf.c",
|
||||
"stdio/fseek.c",
|
||||
"stdio/fsetpos.c",
|
||||
"stdio/ftell.c",
|
||||
"stdio/fwrite.c",
|
||||
"stdio/getc.c",
|
||||
"stdio/getchar.c",
|
||||
"stdio/perror.c",
|
||||
"stdio/printf.c",
|
||||
"stdio/putc.c",
|
||||
"stdio/putchar.c",
|
||||
"stdio/puts.c",
|
||||
"stdio/remove.c",
|
||||
"stdio/rename.c",
|
||||
"stdio/rewind.c",
|
||||
"stdio/scanf.c",
|
||||
"stdio/setbuf.c",
|
||||
"stdio/setvbuf.c",
|
||||
"stdio/snprintf.c",
|
||||
"stdio/sprintf.c",
|
||||
"stdio/sscanf.c",
|
||||
"stdio/tmpfile.c",
|
||||
"stdio/tmpnam.c",
|
||||
"stdio/ungetc.c",
|
||||
"stdio/vfprintf.c",
|
||||
"stdio/vfscanf.c",
|
||||
"stdio/vprintf.c",
|
||||
"stdio/vscanf.c",
|
||||
"stdio/vsnprintf.c",
|
||||
"stdio/vsprintf.c",
|
||||
"stdio/vsscanf.c",
|
||||
"stdlib/abort.c",
|
||||
"stdlib/abs.c",
|
||||
"stdlib/atexit.c",
|
||||
"stdlib/atoi.c",
|
||||
"stdlib/atol.c",
|
||||
"stdlib/atoll.c",
|
||||
"stdlib/bsearch.c",
|
||||
"stdlib/div.c",
|
||||
"stdlib/exit.c",
|
||||
"stdlib/_Exit.c",
|
||||
"stdlib/getenv.c",
|
||||
"stdlib/labs.c",
|
||||
"stdlib/ldiv.c",
|
||||
"stdlib/llabs.c",
|
||||
"stdlib/lldiv.c",
|
||||
"stdlib/malloc.c",
|
||||
"stdlib/qsort.c",
|
||||
"stdlib/rand.c",
|
||||
"stdlib/srand.c",
|
||||
"stdlib/strtol.c",
|
||||
"stdlib/strtoll.c",
|
||||
"stdlib/strtoul.c",
|
||||
"stdlib/strtoull.c",
|
||||
"stdlib/system.c",
|
||||
"string/memchr.c",
|
||||
"string/memcmp.c",
|
||||
"string/memcpy.c",
|
||||
"string/memmove.c",
|
||||
"string/memset.c",
|
||||
"string/strcat.c",
|
||||
"string/strchr.c",
|
||||
"string/strcmp.c",
|
||||
"string/strcoll.c",
|
||||
"string/strcpy.c",
|
||||
"string/strcspn.c",
|
||||
"string/strerror.c",
|
||||
"string/strlen.c",
|
||||
"string/strncat.c",
|
||||
"string/strncmp.c",
|
||||
"string/strncpy.c",
|
||||
"string/strpbrk.c",
|
||||
"string/strrchr.c",
|
||||
"string/strspn.c",
|
||||
"string/strstr.c",
|
||||
"string/strtok.c",
|
||||
"string/strxfrm.c",
|
||||
"time/asctime.c",
|
||||
"time/clock.c",
|
||||
"time/ctime.c",
|
||||
"time/difftime.c",
|
||||
"time/gmtime.c",
|
||||
"time/localtime.c",
|
||||
"time/mktime.c",
|
||||
"time/strftime.c",
|
||||
"time/time.c",
|
||||
"time/timespec_get.c",
|
||||
])
|
||||
|
||||
libc.variables["ccflags"] = [
|
||||
"${ccflags}",
|
||||
"-DDISABLE_SSE",
|
||||
"-DLACKS_UNISTD_H",
|
||||
"-DLACKS_FCNTL_H",
|
||||
"-DLACKS_SYS_PARAM_H",
|
||||
"-DLACKS_SYS_MMAN_H",
|
||||
"-DLACKS_SCHED_H",
|
||||
"-DLACKS_STRINGS_H",
|
||||
"-DHAVE_MMAP=0",
|
||||
]
|
||||
@@ -1,177 +0,0 @@
|
||||
name = "libc"
|
||||
kind = "lib"
|
||||
output = "libc.a"
|
||||
includes = "src/libraries/libc/include"
|
||||
deps = ["j6"]
|
||||
|
||||
sources = [
|
||||
"arch/x86_64/_Exit.s",
|
||||
"arch/x86_64/crt0.s",
|
||||
"ctype/isalnum.c",
|
||||
"ctype/isalpha.c",
|
||||
"ctype/isblank.c",
|
||||
"ctype/iscntrl.c",
|
||||
"ctype/isdigit.c",
|
||||
"ctype/isgraph.c",
|
||||
"ctype/islower.c",
|
||||
"ctype/isprint.c",
|
||||
"ctype/ispunct.c",
|
||||
"ctype/isspace.c",
|
||||
"ctype/isupper.c",
|
||||
"ctype/isxdigit.c",
|
||||
"ctype/tolower.c",
|
||||
"ctype/toupper.c",
|
||||
"inttypes/imaxabs.c",
|
||||
"inttypes/imaxdiv.c",
|
||||
"inttypes/strtoimax.c",
|
||||
"inttypes/strtoumax.c",
|
||||
"locale/localeconv.c",
|
||||
"locale/setlocale.c",
|
||||
"j6libc/assert.c",
|
||||
"j6libc/errno.c",
|
||||
"j6libc/allocpages.c",
|
||||
"j6libc/atomax.c",
|
||||
"j6libc/closeall.c",
|
||||
"j6libc/close.c",
|
||||
"j6libc/digits.c",
|
||||
"j6libc/filemode.c",
|
||||
"j6libc/fillbuffer.c",
|
||||
"j6libc/flushbuffer.c",
|
||||
"j6libc/is_leap.c",
|
||||
"j6libc/load_lc_collate.c",
|
||||
"j6libc/load_lc_ctype.c",
|
||||
"j6libc/load_lc_messages.c",
|
||||
"j6libc/load_lc_monetary.c",
|
||||
"j6libc/load_lc_numeric.c",
|
||||
"j6libc/load_lc_time.c",
|
||||
"j6libc/load_lines.c",
|
||||
"j6libc/open.c",
|
||||
"j6libc/prepread.c",
|
||||
"j6libc/prepwrite.c",
|
||||
"j6libc/print.c",
|
||||
"j6libc/rename.c",
|
||||
"j6libc/scan.c",
|
||||
"j6libc/seed.c",
|
||||
"j6libc/seek.c",
|
||||
"j6libc/stdinit.c",
|
||||
"j6libc/strtox_main.c",
|
||||
"j6libc/strtox_prelim.c",
|
||||
"j6libc/sbrk.c",
|
||||
"signal/raise.c",
|
||||
"signal/signal.c",
|
||||
"stdio/clearerr.c",
|
||||
"stdio/fclose.c",
|
||||
"stdio/feof.c",
|
||||
"stdio/ferror.c",
|
||||
"stdio/fflush.c",
|
||||
"stdio/fgetc.c",
|
||||
"stdio/fgetpos.c",
|
||||
"stdio/fgets.c",
|
||||
"stdio/fopen.c",
|
||||
"stdio/fprintf.c",
|
||||
"stdio/fputc.c",
|
||||
"stdio/fputs.c",
|
||||
"stdio/fread.c",
|
||||
"stdio/freopen.c",
|
||||
"stdio/fscanf.c",
|
||||
"stdio/fseek.c",
|
||||
"stdio/fsetpos.c",
|
||||
"stdio/ftell.c",
|
||||
"stdio/fwrite.c",
|
||||
"stdio/getc.c",
|
||||
"stdio/getchar.c",
|
||||
"stdio/perror.c",
|
||||
"stdio/printf.c",
|
||||
"stdio/putc.c",
|
||||
"stdio/putchar.c",
|
||||
"stdio/puts.c",
|
||||
"stdio/remove.c",
|
||||
"stdio/rename.c",
|
||||
"stdio/rewind.c",
|
||||
"stdio/scanf.c",
|
||||
"stdio/setbuf.c",
|
||||
"stdio/setvbuf.c",
|
||||
"stdio/snprintf.c",
|
||||
"stdio/sprintf.c",
|
||||
"stdio/sscanf.c",
|
||||
"stdio/tmpfile.c",
|
||||
"stdio/tmpnam.c",
|
||||
"stdio/ungetc.c",
|
||||
"stdio/vfprintf.c",
|
||||
"stdio/vfscanf.c",
|
||||
"stdio/vprintf.c",
|
||||
"stdio/vscanf.c",
|
||||
"stdio/vsnprintf.c",
|
||||
"stdio/vsprintf.c",
|
||||
"stdio/vsscanf.c",
|
||||
"stdlib/abort.c",
|
||||
"stdlib/abs.c",
|
||||
"stdlib/atexit.c",
|
||||
"stdlib/atoi.c",
|
||||
"stdlib/atol.c",
|
||||
"stdlib/atoll.c",
|
||||
"stdlib/bsearch.c",
|
||||
"stdlib/div.c",
|
||||
"stdlib/exit.c",
|
||||
"stdlib/_Exit.c",
|
||||
"stdlib/getenv.c",
|
||||
"stdlib/labs.c",
|
||||
"stdlib/ldiv.c",
|
||||
"stdlib/llabs.c",
|
||||
"stdlib/lldiv.c",
|
||||
"stdlib/malloc.c",
|
||||
"stdlib/qsort.c",
|
||||
"stdlib/rand.c",
|
||||
"stdlib/srand.c",
|
||||
"stdlib/strtol.c",
|
||||
"stdlib/strtoll.c",
|
||||
"stdlib/strtoul.c",
|
||||
"stdlib/strtoull.c",
|
||||
"stdlib/system.c",
|
||||
"string/memchr.c",
|
||||
"string/memcmp.c",
|
||||
"string/memcpy.c",
|
||||
"string/memmove.c",
|
||||
"string/memset.c",
|
||||
"string/strcat.c",
|
||||
"string/strchr.c",
|
||||
"string/strcmp.c",
|
||||
"string/strcoll.c",
|
||||
"string/strcpy.c",
|
||||
"string/strcspn.c",
|
||||
"string/strerror.c",
|
||||
"string/strlen.c",
|
||||
"string/strncat.c",
|
||||
"string/strncmp.c",
|
||||
"string/strncpy.c",
|
||||
"string/strpbrk.c",
|
||||
"string/strrchr.c",
|
||||
"string/strspn.c",
|
||||
"string/strstr.c",
|
||||
"string/strtok.c",
|
||||
"string/strxfrm.c",
|
||||
"time/asctime.c",
|
||||
"time/clock.c",
|
||||
"time/ctime.c",
|
||||
"time/difftime.c",
|
||||
"time/gmtime.c",
|
||||
"time/localtime.c",
|
||||
"time/mktime.c",
|
||||
"time/strftime.c",
|
||||
"time/time.c",
|
||||
"time/timespec_get.c",
|
||||
]
|
||||
|
||||
|
||||
[variables]
|
||||
ccflags = [
|
||||
"${ccflags}",
|
||||
"-DDISABLE_SSE",
|
||||
"-DLACKS_UNISTD_H",
|
||||
"-DLACKS_FCNTL_H",
|
||||
"-DLACKS_SYS_PARAM_H",
|
||||
"-DLACKS_SYS_MMAN_H",
|
||||
"-DLACKS_SCHED_H",
|
||||
"-DLACKS_STRINGS_H",
|
||||
"-DHAVE_MMAP=0",
|
||||
]
|
||||
Reference in New Issue
Block a user