build fixes for sparc64 and freebsd platforms

This commit is contained in:
BVK Chaitanya 2010-05-26 16:53:43 +05:30
parent 066e9dd87e
commit c53fe8dfbb
2 changed files with 5 additions and 2 deletions

View file

@ -1,6 +1,7 @@
# -*- makefile -*- # -*- makefile -*-
ifeq ($(target_cpu), sparc64) ifeq ($(target_cpu), sparc64)
COMMON_CFLAGS += -mno-app-regs
COMMON_LDFLAGS += -mno-relax COMMON_LDFLAGS += -mno-relax
endif endif
@ -25,10 +26,12 @@ TARGET_NO_STRIP = yes
noinst_MODULES = emu-full.mod noinst_MODULES = emu-full.mod
emu_full_mod_SOURCES = kern/emu/full.c emu_full_mod_SOURCES = kern/emu/full.c
emu_full_mod_CFLAGS = $(COMMON_CFLAGS) emu_full_mod_CFLAGS = $(COMMON_CFLAGS)
emu_full_mod_LDFLAGS = $(COMMON_LDFLAGS)
noinst_MODULES = emu-lite.mod noinst_MODULES = emu-lite.mod
emu_lite_mod_SOURCES = kern/emu/lite.c kern/emu/cache.S symlist.c emu_lite_mod_SOURCES = kern/emu/lite.c kern/emu/cache.S symlist.c
emu_lite_mod_CFLAGS = $(COMMON_CFLAGS) emu_lite_mod_CFLAGS = $(COMMON_CFLAGS)
emu_lite_mod_LDFLAGS = $(COMMON_LDFLAGS)
# For halt.mod. # For halt.mod.
pkglib_MODULES += halt.mod pkglib_MODULES += halt.mod
@ -45,7 +48,7 @@ endif
grub_emu_LDFLAGS = $(LIBCURSES) grub_emu_LDFLAGS = $(LIBCURSES)
ifeq ($(target_cpu), sparc64) ifeq ($(target_cpu), sparc64)
grub_emu_LDFLAGS += -m64 -mno-relax grub_emu_LDFLAGS += -m64 -melf64_sparc -mno-relax
endif endif
ifeq ($(enable_grub_emu_usb), yes) ifeq ($(enable_grub_emu_usb), yes)

View file

@ -155,7 +155,7 @@ esac
machine_CPPFLAGS="$machine_CPPFLAGS -DMACHINE=`echo ${target_cpu}_$platform | sed y,abcdefghijklmnopqrstuvwxyz,ABCDEFGHIJKLMNOPQRSTUVWXYZ,`" machine_CPPFLAGS="$machine_CPPFLAGS -DMACHINE=`echo ${target_cpu}_$platform | sed y,abcdefghijklmnopqrstuvwxyz,ABCDEFGHIJKLMNOPQRSTUVWXYZ,`"
CPPFLAGS="$CPPFLAGS $cpu_CPPFLAGS $machine_CPPFLAGS" CPPFLAGS="$CPPFLAGS $cpu_CPPFLAGS $machine_CPPFLAGS"
TARGET_ASFLAGS="$TARGET_ASFLAGS $machine_CPPFLAGS" TARGET_ASFLAGS="$TARGET_ASFLAGS $cpu_CPPFLAGS $machine_CPPFLAGS"
TARGET_CFLAGS="$TARGET_CFLAGS $cpu_CPPFLAGS $machine_CPPFLAGS" TARGET_CFLAGS="$TARGET_CFLAGS $cpu_CPPFLAGS $machine_CPPFLAGS"
AC_SUBST(host_cpu) AC_SUBST(host_cpu)