Author: bonefish Date: 2010-01-11 21:36:24 +0100 (Mon, 11 Jan 2010) New Revision: 35015 Changeset: http://dev.haiku-os.org/changeset/35015/haiku Modified: haiku/trunk/build/jam/BuildSetup Log: Removed useless assigning of the default values and use a switch for the architectures. Modified: haiku/trunk/build/jam/BuildSetup =================================================================== --- haiku/trunk/build/jam/BuildSetup 2010-01-11 20:23:34 UTC (rev 35014) +++ haiku/trunk/build/jam/BuildSetup 2010-01-11 20:36:24 UTC (rev 35015) @@ -304,29 +304,25 @@ HAIKU_KERNEL_PIC_CCFLAGS = -fno-pic ; HAIKU_KERNEL_PIC_LINKFLAGS = ; -if $(HAIKU_ARCH) = ppc { - # Build a position independent PPC kernel. We need to be able to relocate - # the kernel, since the virtual address space layout at boot time is not - # fixed. - HAIKU_KERNEL_PIC_CCFLAGS = -fPIE ; - HAIKU_KERNEL_PIC_LINKFLAGS = -shared -fPIE ; + +switch $(HAIKU_ARCH) { + case ppc : + { + # Build a position independent PPC kernel. We need to be able to + # relocate the kernel, since the virtual address space layout at boot + # time is not fixed. + HAIKU_KERNEL_PIC_CCFLAGS = -fPIE ; + HAIKU_KERNEL_PIC_LINKFLAGS = -shared -fPIE ; + } + + case m68k : + { + # We don't want to have to handle emulating missing FPU opcodes for 040 + # and 060 in the kernel. + HAIKU_KERNEL_CCFLAGS += -m68020-60 ; + HAIKU_KERNEL_C++FLAGS += -m68020-60 ; + } } -if $(HAIKU_ARCH) = m68k { - # We don't need a PIC kernel as it's always at the same place. - # it's actually needed to not use pic, else linking fails due to too large - # pc refs. - HAIKU_KERNEL_PIC_CCFLAGS = -fno-pic ; - HAIKU_KERNEL_PIC_LINKFLAGS = ; - # we don't want to have to handle emulating missing FPU opcodes for 040 and - # 060 in the kernel - HAIKU_KERNEL_CCFLAGS += -m68020-60 ; - HAIKU_KERNEL_C++FLAGS += -m68020-60 ; -} -if $(HAIKU_ARCH) = mipsel { - # TODO: verify correctness of this - HAIKU_KERNEL_PIC_CCFLAGS = -fno-pic ; - HAIKU_KERNEL_PIC_LINKFLAGS = ; -} # If the environment variable HAIKU_INCLUDE_PATENTED_CODE is defined, we # define an equally named macro to the variable value. Some components use the