Added PIC initialization and keyboard.

This commit is contained in:
2024-01-18 02:24:42 +01:00
parent f03963a485
commit 04d25d498d
11 changed files with 1022 additions and 34 deletions

View File

@@ -27,12 +27,16 @@ crti_o = kernel_env.Object('src/crt/crti.s')
crtn_o = kernel_env.Object('src/crt/crtn.s')
kernel_env['LINKCOM'] = env['LINKCOM'].replace('$_LIBFLAGS', f'{crti_o[0].abspath} {crtbegin_o} $_LIBFLAGS -lgcc {crtend_o} {crtn_o[0].abspath}')
kernel_irs_sources = Split('''
src/kernel/keyboard.cpp
src/kernel/pic.cpp
''')
kernel_sources = env['KERNEL_SOURCES'] + Split('''
src/cstdlib/memory.s
src/kernel/boot.s
src/kernel/startup.cpp
''')
''') + [kernel_env.Object(f, CCFLAGS = kernel_env['CCFLAGS'] + ['-mgeneral-regs-only']) for f in kernel_irs_sources]
kernel_target = kernel_env.File('#kernel.x86_64.bin')
prog_kernel = kernel_env.Program(