Changeset 2fff3c4 in mainline
- Timestamp:
- 2019-08-17T12:49:43Z (5 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- c4e5d40
- Parents:
- ecf56f80
- git-author:
- Jiří Zárevúcky <zarevucky.jiri@…> (2019-06-16 13:32:05)
- git-committer:
- Jiří Zárevúcky <zarevucky.jiri@…> (2019-08-17 12:49:43)
- Files:
-
- 4 added
- 12 deleted
- 4 edited
- 6 moved
Legend:
- Unmodified
- Added
- Removed
-
Makefile
recf56f80 r2fff3c4 61 61 CROSS_PATH = $(shell dirname "$(CC)") 62 62 63 .PHONY: all precheck cscope cscope_parts autotool config_ auto config_default config distclean clean check releasefile release common boot kernel uspaceexport-posix space63 .PHONY: all precheck cscope cscope_parts autotool config_default config distclean clean check releasefile release common export-posix space 64 64 65 all: kernel uspaceexport-cross test-xcw65 all: common export-cross test-xcw 66 66 $(MAKE) -r -C boot PRECHECK=$(PRECHECK) 67 67 … … 70 70 71 71 common: $(COMMON_MAKEFILE) $(CONFIG_MAKEFILE) $(CONFIG_HEADER) $(ERRNO_HEADER) build/build.ninja 72 73 kernel: common74 $(MAKE) -r -C kernel PRECHECK=$(PRECHECK)75 76 uspace: common77 72 PATH="$(CROSS_PATH):$$PATH" ninja -C build 78 73 PATH="$(CROSS_PATH):$$PATH" DESTDIR="$$PWD/dist" meson install --no-rebuild --only-changed -C build > build/install.log 79 74 80 test-xcw: uspaceexport-cross75 test-xcw: common export-cross 81 76 ifeq ($(CONFIG_DEVEL_FILES),y) 82 77 export PATH=$$PATH:$(abspath tools/xcw/bin) && $(MAKE) -r -C tools/xcw/demo -
boot/Makefile.common
recf56f80 r2fff3c4 43 43 -include $(CONFIG_MAKEFILE) 44 44 45 KERNEL_PATH = $(ROOT_PATH)/kernel46 45 USPACE_PATH = $(ROOT_PATH)/uspace 47 46 DIST_PATH = $(ROOT_PATH)/dist … … 225 224 226 225 COMPONENTS = \ 227 $( KERNEL_PATH)/kernel.elf \226 $(DIST_PATH)/boot/kernel.elf \ 228 227 $(addprefix $(DIST_PATH)/,$(INIT_TASKS)) \ 229 228 $(INITRD).img -
kernel/arch/amd64/meson.build
recf56f80 r2fff3c4 1 1 # 2 2 # Copyright (c) 2005 Martin Decky 3 # Copyright (c) 2019 Jiří Zárevúcky 3 4 # All rights reserved. 4 5 # … … 27 28 # 28 29 29 30 FPU_NO_CFLAGS = -mno-sse -mno-sse231 32 30 # TODO: Red Zone is only a problem if we allow interrupts to land on an active 33 31 # stack. Using separate stack for interrupts and ensuring that we never … … 35 33 # the argument. 36 34 37 COMMON_CFLAGS += -mcmodel=$(MEMORY_MODEL) -mno-red-zone -fno-unwind-tables -fno-omit-frame-pointer 35 kernel_c_args += [ '-mno-sse', '-mno-sse2', '-mcmodel=' + MEMORY_MODEL, '-mno-red-zone', '-fno-unwind-tables', '-fno-omit-frame-pointer' ] 38 36 39 BITS = 64 40 ENDIANESS = LE 37 # TODO: fix this 38 kernel_link_args += [ '-Wl,--no-gc-sections' ] 41 39 42 ## Accepted CPUs 43 # 44 45 ifeq ($(PROCESSOR),opteron) 46 COMMON_CFLAGS += -march=opteron 40 if PROCESSOR == 'opteron' 41 kernel_c_args += '-march=opteron' 47 42 endif 48 43 49 ARCH_SOURCES = \ 50 arch/$(KARCH)/src/fpu_context.c \ 51 arch/$(KARCH)/src/boot/multiboot.S \ 52 arch/$(KARCH)/src/boot/multiboot2.S \ 53 arch/$(KARCH)/src/boot/memmap.c \ 54 arch/$(KARCH)/src/debug/stacktrace.c \ 55 arch/$(KARCH)/src/debug/stacktrace_asm.S \ 56 arch/$(KARCH)/src/pm.c \ 57 arch/$(KARCH)/src/vreg.c \ 58 arch/$(KARCH)/src/kseg.c \ 59 arch/$(KARCH)/src/context.S \ 60 arch/$(KARCH)/src/ddi/ddi.c \ 61 arch/$(KARCH)/src/drivers/i8254.c \ 62 arch/$(KARCH)/src/delay.S \ 63 arch/$(KARCH)/src/amd64.c \ 64 arch/$(KARCH)/src/bios/bios.c \ 65 arch/$(KARCH)/src/interrupt.c \ 66 arch/$(KARCH)/src/mm/km.c \ 67 arch/$(KARCH)/src/mm/as.c \ 68 arch/$(KARCH)/src/mm/frame.c \ 69 arch/$(KARCH)/src/mm/page.c \ 70 arch/$(KARCH)/src/mm/tlb.c \ 71 arch/$(KARCH)/src/asm.S \ 72 arch/$(KARCH)/src/cpu/cpu.c \ 73 arch/$(KARCH)/src/proc/scheduler.c \ 74 arch/$(KARCH)/src/proc/task.c \ 75 arch/$(KARCH)/src/proc/thread.c \ 76 arch/$(KARCH)/src/userspace.c \ 77 arch/$(KARCH)/src/smc.c \ 78 arch/$(KARCH)/src/syscall.c 44 arch_src += files( 45 'src/amd64.c', 46 'src/asm.S', 47 'src/bios/bios.c', 48 'src/boot/memmap.c', 49 'src/boot/multiboot2.S', 50 'src/boot/multiboot.S', 51 'src/context.S', 52 'src/cpu/cpu.c', 53 'src/ddi/ddi.c', 54 'src/debug/stacktrace_asm.S', 55 'src/debug/stacktrace.c', 56 'src/delay.S', 57 'src/drivers/i8254.c', 58 'src/fpu_context.c', 59 'src/interrupt.c', 60 'src/kseg.c', 61 'src/mm/as.c', 62 'src/mm/frame.c', 63 'src/mm/km.c', 64 'src/mm/page.c', 65 'src/mm/tlb.c', 66 'src/pm.c', 67 'src/proc/scheduler.c', 68 'src/proc/task.c', 69 'src/proc/thread.c', 70 'src/smc.c', 71 'src/syscall.c', 72 'src/userspace.c', 73 'src/vreg.c', 74 ) 79 75 80 ifeq ($(CONFIG_SMP),y) 81 ARCH_SOURCES += \ 82 arch/$(KARCH)/src/smp/ap.S \ 83 arch/$(KARCH)/src/smp/apic.c \ 84 arch/$(KARCH)/src/smp/ipi.c \ 85 arch/$(KARCH)/src/smp/mps.c \ 86 arch/$(KARCH)/src/smp/smp.c 76 if CONFIG_SMP 77 arch_src += files( 78 'src/smp/apic.c', 79 'src/smp/ap.S', 80 'src/smp/ipi.c', 81 'src/smp/mps.c', 82 'src/smp/smp.c', 83 ) 87 84 endif 88 85 89 ARCH_AUTOCHECK_HEADERS = \ 90 arch/$(KARCH)/include/arch/istate_struct.h \ 91 arch/$(KARCH)/include/arch/context_struct.h \ 92 arch/$(KARCH)/include/arch/kseg_struct.h \ 93 arch/$(KARCH)/include/arch/boot/memmap_struct.h 86 _check_headers = [ 87 'include/arch/boot/memmap_struct.h', 88 'include/arch/context_struct.h', 89 'include/arch/istate_struct.h', 90 'include/arch/kseg_struct.h', 91 ] 92 93 foreach h : _check_headers 94 arch_src += [ autocheck.process(h) ] 95 endforeach -
kernel/arch/arm32/meson.build
recf56f80 r2fff3c4 1 1 # 2 # Copyright (c) 200 5 Martin Decky2 # Copyright (c) 2007 Jakub Jermar, Michal Kebrt 3 3 # All rights reserved. 4 4 # … … 28 28 29 29 30 COMMON_CFLAGS += -mconstant-gp -fno-unwind-tables -mfixed-range=f32-f127 30 atsign = '%' 31 31 32 LDFLAGS += -Wl,-EL 32 kernel_c_args += [ '-fno-omit-frame-pointer', '-mapcs-frame', '-mno-unaligned-access', '-mfpu=vfpv3' ] 33 33 34 BITS = 64 35 ENDIANESS = LE 36 37 ARCH_SOURCES = \ 38 arch/$(KARCH)/src/start.S \ 39 arch/$(KARCH)/src/asm.S \ 40 arch/$(KARCH)/src/dummy.S \ 41 arch/$(KARCH)/src/ia64.c \ 42 arch/$(KARCH)/src/fpu_context.c \ 43 arch/$(KARCH)/src/context.S \ 44 arch/$(KARCH)/src/cpu/cpu.c \ 45 arch/$(KARCH)/src/debug/stacktrace.c \ 46 arch/$(KARCH)/src/debug/stacktrace_asm.S \ 47 arch/$(KARCH)/src/ivt.S \ 48 arch/$(KARCH)/src/interrupt.c \ 49 arch/$(KARCH)/src/mm/km.c \ 50 arch/$(KARCH)/src/mm/as.c \ 51 arch/$(KARCH)/src/mm/frame.c \ 52 arch/$(KARCH)/src/mm/page.c \ 53 arch/$(KARCH)/src/mm/tlb.c \ 54 arch/$(KARCH)/src/mm/vhpt.c \ 55 arch/$(KARCH)/src/proc/scheduler.c \ 56 arch/$(KARCH)/src/ddi/ddi.c \ 57 arch/$(KARCH)/src/smc.c \ 58 arch/$(KARCH)/src/smp/smp.c \ 59 arch/$(KARCH)/src/drivers/it.c 60 61 ifeq ($(MACHINE),ski) 62 ARCH_SOURCES += arch/$(KARCH)/src/drivers/ski.c 34 if CONFIG_FPU 35 # This is necessary to allow vmsr insn and fpexc manipulation 36 # Use vfp32 to allow context save/restore of d16-d31 regs. 37 kernel_c_args += [ '-mfloat-abi=hard', '-mfpu=vfp3' ] 63 38 endif 64 39 65 ifeq ($(MACHINE),i460GX) 66 DEFS += -DI460GX 40 arch_src += files( 41 'src/start.S', 42 'src/asm.S', 43 'src/eabi.S', 44 'src/exc_handler.S', 45 'src/arm32.c', 46 'src/machine_func.c', 47 'src/context.S', 48 'src/dummy.S', 49 'src/cpu/cpu.c', 50 'src/interrupt.c', 51 'src/exception.c', 52 'src/userspace.c', 53 'src/smc.c', 54 'src/debug/stacktrace.c', 55 'src/debug/stacktrace_asm.S', 56 'src/mm/km.c', 57 'src/mm/as.c', 58 'src/mm/frame.c', 59 'src/mm/page.c', 60 'src/mm/tlb.c', 61 'src/mm/page_fault.c', 62 'src/atomic.c', 63 'src/ras.c', 64 ) 65 66 if CONFIG_FPU 67 arch_src += files('src/fpu_context.c', 'src/fpu.S') 67 68 endif 68 69 69 ARCH_AUTOCHECK_HEADERS = \ 70 arch/$(KARCH)/include/arch/istate_struct.h \ 71 arch/$(KARCH)/include/arch/context_struct.h 70 if MACHINE == 'gta02' 71 arch_src += files('src/mach/gta02/gta02.c') 72 72 73 elif MACHINE == 'integratorcp' 74 arch_src += files('src/mach/integratorcp/integratorcp.c') 75 76 elif MACHINE == 'beagleboardxm' 77 arch_src += files('src/mach/beagleboardxm/beagleboardxm.c') 78 79 elif MACHINE == 'beaglebone' 80 arch_src += files('src/mach/beaglebone/beaglebone.c') 81 82 elif MACHINE == 'raspberrypi' 83 arch_src += files('src/mach/raspberrypi/raspberrypi.c') 84 85 endif -
kernel/arch/arm64/meson.build
recf56f80 r2fff3c4 27 27 # 28 28 29 COMMON_CFLAGS += -fno-omit-frame-pointer 29 kernel_c_args += [ '-fno-omit-frame-pointer', '-march=armv8-a+nofp+nosimd', '-mgeneral-regs-only' ] 30 30 31 LDFLAGS += -Wl,--gc-sections 31 arch_src += files( 32 'src/arm64.c', 33 'src/asm.S', 34 'src/context.S', 35 'src/cpu/cpu.c', 36 'src/debug/stacktrace.c', 37 'src/debug/stacktrace_asm.S', 38 'src/exception.c', 39 'src/fpu.S', 40 'src/fpu_context.c', 41 'src/interrupt.c', 42 'src/machine_func.c', 43 'src/mm/as.c', 44 'src/mm/frame.c', 45 'src/mm/km.c', 46 'src/mm/page.c', 47 'src/mm/tlb.c', 48 'src/smc.c', 49 'src/smp/ipi.c', 50 'src/smp/smp.c', 51 'src/start.S', 52 ) 32 53 54 if MACHINE == 'virt' 55 arch_src += files('src/mach/virt/virt.c') 56 endif 33 57 58 _check_headers = [ 59 'include/arch/context_struct.h', 60 'include/arch/fpu_context_struct.h', 61 'include/arch/istate_struct.h', 62 ] 63 64 foreach h : _check_headers 65 arch_src += [ autocheck.process(h) ] 66 endforeach -
kernel/arch/ia32/meson.build
recf56f80 r2fff3c4 27 27 # 28 28 29 COMMON_CFLAGS += -fno-unwind-tables 30 LDFLAGS += -Wl,--gc-sections 29 kernel_c_args += [ '-mno-mmx', '-mno-sse', '-mno-sse2', '-mno-sse3', '-mno-3dnow' ] 31 30 31 # TODO: fix this 32 kernel_link_args += [ '-Wl,--no-gc-sections' ] 32 33 34 arch_src += files( 35 'src/context.S', 36 'src/debug/stacktrace.c', 37 'src/debug/stacktrace_asm.S', 38 'src/delay.S', 39 'src/asm.S', 40 'src/proc/scheduler.c', 41 'src/proc/task.c', 42 'src/proc/thread.c', 43 'src/bios/bios.c', 44 'src/smp/ap.S', 45 'src/smp/apic.c', 46 'src/smp/mps.c', 47 'src/smp/smp.c', 48 'src/atomic.S', 49 'src/smp/ipi.c', 50 'src/ia32.c', 51 'src/vreg.c', 52 'src/interrupt.c', 53 'src/pm.c', 54 'src/userspace.c', 55 'src/smc.c', 56 'src/cpu/cpu.c', 57 'src/mm/km.c', 58 'src/mm/as.c', 59 'src/mm/frame.c', 60 'src/mm/page.c', 61 'src/mm/tlb.c', 62 'src/ddi/ddi.c', 63 'src/drivers/i8254.c', 64 'src/boot/multiboot.S', 65 'src/boot/multiboot2.S', 66 'src/boot/memmap.c', 67 'src/fpu_context.c', 68 'src/syscall.c', 69 ) 70 71 _check_headers = [ 72 'include/arch/istate_struct.h', 73 'include/arch/context_struct.h', 74 'include/arch/boot/memmap_struct.h', 75 ] 76 77 foreach h : _check_headers 78 arch_src += [ autocheck.process(h) ] 79 endforeach -
kernel/arch/ia64/meson.build
recf56f80 r2fff3c4 1 1 # 2 2 # Copyright (c) 2005 Martin Decky 3 # Copyright (c) 2019 Jiří Zárevúcky 3 4 # All rights reserved. 4 5 # … … 27 28 # 28 29 29 COMMON_CFLAGS += -msoft-float -mabi=32 30 AS_PROLOG = .module softfloat;.abicalls; 31 LDFLAGS += -Wl,--gc-sections 30 kernel_c_args += [ '-mconstant-gp', '-fno-unwind-tables', '-mfixed-range=f32-f127' ] 31 kernel_link_args += [ '-Wl,-EL' ] 32 32 33 ifeq ($(MACHINE),msim) 34 COMMON_CFLAGS += -march=r4000 33 arch_src += files( 34 'src/start.S', 35 'src/asm.S', 36 'src/dummy.S', 37 'src/ia64.c', 38 'src/fpu_context.c', 39 'src/context.S', 40 'src/cpu/cpu.c', 41 'src/debug/stacktrace.c', 42 'src/debug/stacktrace_asm.S', 43 'src/ivt.S', 44 'src/interrupt.c', 45 'src/mm/km.c', 46 'src/mm/as.c', 47 'src/mm/frame.c', 48 'src/mm/page.c', 49 'src/mm/tlb.c', 50 'src/mm/vhpt.c', 51 'src/proc/scheduler.c', 52 'src/ddi/ddi.c', 53 'src/smc.c', 54 'src/smp/smp.c', 55 'src/drivers/it.c', 56 ) 57 58 if MACHINE == 'ski' 59 arch_src += files('src/drivers/ski.c') 35 60 endif 36 61 37 if eq ($(MACHINE),lmalta)38 COMMON_CFLAGS += -march=4kc62 if MACHINE == 'i460GX' 63 kernel_c_args += [ '-DI460GX' ] 39 64 endif 40 65 41 ifeq ($(MACHINE),bmalta) 42 COMMON_CFLAGS += -march=4kc 43 endif 66 _check_headers = [ 67 'include/arch/istate_struct.h', 68 'include/arch/context_struct.h', 69 ] 70 71 foreach h : _check_headers 72 arch_src += [ autocheck.process(h) ] 73 endforeach -
kernel/arch/mips32/meson.build
recf56f80 r2fff3c4 27 27 # 28 28 29 # TODO: We need to implement DWARF unwinding and get rid of this flag. 30 COMMON_CFLAGS += -fno-omit-frame-pointer -Wl,-z,max-page-size=0x1000 29 kernel_c_args += [ 30 '-msoft-float', 31 '-mno-abicalls', 32 '-G', '0', 33 '-fno-zero-initialized-in-bss', 34 '-mabi=32', 35 ] 31 36 32 # XXX: This architecture requires unoptimized TLS pointer access, 33 # as with the GCC option `-mno-tls-direct-seg-refs`. 34 # The `amd64-helenos` target defaults to this behavior. 37 as_prolog = '.module softfloat;' 35 38 36 LDFLAGS += -Wl,--gc-sections 39 arch_src += files( 40 'src/start.S', 41 'src/context.S', 42 'src/mips32.c', 43 'src/asm.S', 44 'src/exception.c', 45 'src/interrupt.c', 46 'src/cache.c', 47 'src/debugger.c', 48 'src/cpu/cpu.c', 49 'src/debug/stacktrace.c', 50 'src/debug/stacktrace_asm.S', 51 'src/mm/km.c', 52 'src/mm/frame.c', 53 'src/mm/page.c', 54 'src/mm/tlb.c', 55 'src/mm/as.c', 56 'src/fpu_context.c', 57 'src/smc.c', 58 'src/smp/smp.c', 59 'src/machine_func.c', 60 ) 37 61 62 if MACHINE == 'lmalta' or MACHINE == 'bmalta' 63 arch_src += files('src/mach/malta/malta.c') 38 64 65 elif MACHINE == 'msim' 66 arch_src += files( 67 'src/mach/msim/msim.c', 68 'src/mach/msim/dorder.c', 69 ) 70 71 endif 72 73 _check_headers = [ 74 'include/arch/istate_struct.h', 75 'include/arch/context_struct.h', 76 'include/arch/fpu_context_struct.h', 77 ] 78 79 foreach h : _check_headers 80 arch_src += [ autocheck.process(h) ] 81 endforeach -
meson.build
recf56f80 r2fff3c4 310 310 endforeach 311 311 312 #subdir('kernel')312 subdir('kernel') 313 313 subdir('uspace') 314 314 -
uspace/lib/c/arch/ia64/meson.build
recf56f80 r2fff3c4 10 10 'src/stacktrace.c', 11 11 'src/stacktrace_asm.S', 12 'src/rtld/dynamic.c', 13 'src/rtld/reloc.c', 12 14 ) 13 15
Note:
See TracChangeset
for help on using the changeset viewer.