make: set MACHINE_ARCH variable

Also, modify sys.mk so we continue to build with -O
This commit is contained in:
Arun Thomas 2011-11-18 16:12:30 +01:00
parent f379b3eecb
commit 3f9ef4ac46
3 changed files with 5 additions and 6 deletions

View file

@ -21,7 +21,8 @@ MACHINE=${ARCH}
MACHINE_ARCH=${ARCH}
CPPFLAGS+= -DTARGET_MACHINE=\"${MACHINE}\" \
-DTARGET_MACHINE_ARCH=\"${MACHINE_ARCH}\" \
-DMAKE_MACHINE=\"${MACHINE}\"
-DMAKE_MACHINE=\"${MACHINE}\" \
-DMAKE_MACHINE_ARCH=\"${MACHINE_ARCH}\"
.PATH: ${.CURDIR}/lst.lib

View file

@ -13,10 +13,6 @@
#
#
.if ${MACHINE_ARCH} == "unknown"
MACHINE_ARCH:= ${MACHINE}
.endif
#
# There are two options in making libm at fdlibm compile time:
# _IEEE_LIBM --- IEEE libm; smaller, and somewhat faster

View file

@ -36,7 +36,9 @@ CC?= cc
${MACHINE_ARCH} == "powerpc" || \
${MACHINE_ARCH} == "sparc" || \
${MACHINE_ARCH} == "sparc64"
DBG?= -O2
#DBG?= -O2
#MINIX: use -O for now
DBG?= -O
.elif ${MACHINE_ARCH} == "sh3el" || ${MACHINE_ARCH} == "sh3eb"
# -O2 is too -falign-* zealous for low-memory sh3 machines
DBG?= -Os -freorder-blocks