Date: Mon, 6 Nov 2017 15:21:51 +0000 (UTC) From: Warner Losh <imp@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r325480 - in head/sys/boot: . ficl ficl32 libsa32 zfs zfs32 Message-ID: <201711061521.vA6FLpCp036302@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: imp Date: Mon Nov 6 15:21:51 2017 New Revision: 325480 URL: https://svnweb.freebsd.org/changeset/base/325480 Log: Use DO32 for all the places that we need to flag we're building a 32 bit version of a library. Use a generic name since this may be usefule elsewhere. Sponsored by: Netflix Modified: head/sys/boot/ficl.mk head/sys/boot/ficl/Makefile head/sys/boot/ficl32/Makefile head/sys/boot/libsa32/Makefile head/sys/boot/zfs/Makefile head/sys/boot/zfs32/Makefile Modified: head/sys/boot/ficl.mk ============================================================================== --- head/sys/boot/ficl.mk Mon Nov 6 15:21:45 2017 (r325479) +++ head/sys/boot/ficl.mk Mon Nov 6 15:21:51 2017 (r325480) @@ -4,7 +4,7 @@ .include "defs.mk" -.if ${MACHINE_CPUARCH} == "amd64" && defined(FICL32) +.if ${MACHINE_CPUARCH} == "amd64" && ${DO32:U0} == 1 FICL_CPUARCH= i386 .elif ${MACHINE_ARCH:Mmips64*} != "" FICL_CPUARCH= mips64 @@ -15,7 +15,7 @@ FICL_CPUARCH= ${MACHINE_CPUARCH} .PATH: ${FICLSRC} ${FICLSRC}/${FICL_CPUARCH} .if ${MACHINE_CPUARCH} == "amd64" -.if defined(FICL32) +.if ${DO32:U0} == 1 CFLAGS+= -m32 -I. .else CFLAGS+= -fPIC @@ -30,7 +30,7 @@ CFLAGS+= -I${FICLSRC} -I${FICLSRC}/${FICL_CPUARCH} -I$ CFLAGS+= -DBOOT_FORTH CFLAGS+= -DBF_DICTSIZE=15000 -.if ${MACHINE_CPUARCH} == "amd64" && defined(FICL32) +.if ${MACHINE_CPUARCH} == "amd64" && ${DO32:U0} == 1 .if !exists(machine) ${SRCS:M*.c:R:S/$/.o/g}: machine Modified: head/sys/boot/ficl/Makefile ============================================================================== --- head/sys/boot/ficl/Makefile Mon Nov 6 15:21:45 2017 (r325479) +++ head/sys/boot/ficl/Makefile Mon Nov 6 15:21:51 2017 (r325480) @@ -10,9 +10,13 @@ BASE_SRCS= dict.c ficl.c fileaccess.c float.c loader.c SRCS= ${BASE_SRCS} sysdep.c softcore.c CLEANFILES= softcore.c testmain testmain.o .if ${MACHINE_CPUARCH} == "i386" || \ - (${MACHINE_CPUARCH} == "amd64" && defined(FICL32)) + (${MACHINE_CPUARCH} == "amd64" && defined(DO32)) CFLAGS+= -march=i386 .endif +.if ${MACHINE_CPUARCH} == "amd64" && defined(DO32) +CFLAGS+= -m32 +.endif + .if defined(HAVE_PNP) CFLAGS+= -DHAVE_PNP .endif Modified: head/sys/boot/ficl32/Makefile ============================================================================== --- head/sys/boot/ficl32/Makefile Mon Nov 6 15:21:45 2017 (r325479) +++ head/sys/boot/ficl32/Makefile Mon Nov 6 15:21:51 2017 (r325480) @@ -1,5 +1,5 @@ # $FreeBSD$ -FICL32= +DO32=1 .include "${.CURDIR}/../ficl/Makefile" Modified: head/sys/boot/libsa32/Makefile ============================================================================== --- head/sys/boot/libsa32/Makefile Mon Nov 6 15:21:45 2017 (r325479) +++ head/sys/boot/libsa32/Makefile Mon Nov 6 15:21:51 2017 (r325480) @@ -1,5 +1,7 @@ # $FreeBSD$ +DO32=1 + .include <bsd.init.mk> LIB=sa32 Modified: head/sys/boot/zfs/Makefile ============================================================================== --- head/sys/boot/zfs/Makefile Mon Nov 6 15:21:45 2017 (r325479) +++ head/sys/boot/zfs/Makefile Mon Nov 6 15:21:51 2017 (r325480) @@ -17,16 +17,16 @@ CFLAGS+= -I${SYSDIR}/cddl/boot/zfs CFLAGS+= -I${SYSDIR}/crypto/skein .if ${MACHINE_CPUARCH} == "i386" || \ - (${MACHINE_CPUARCH} == "amd64" && defined(ZFS32)) + (${MACHINE_CPUARCH} == "amd64" && defined(DO32)) CFLAGS+= -march=i386 .endif -.if ${MACHINE_CPUARCH} == "amd64" && defined(ZFS32) +.if ${MACHINE_CPUARCH} == "amd64" && defined(DO32) CFLAGS+= -m32 .endif CFLAGS+= -Wformat -Wall -.if ${MACHINE_CPUARCH} == "amd64" && defined(ZFS32) +.if ${MACHINE_CPUARCH} == "amd64" && defined(DO32) CLEANFILES+= machine machine: .NOMETA ln -sf ${SYSDIR}/i386/include machine @@ -35,7 +35,7 @@ machine: .NOMETA .include <bsd.stand.mk> .include <bsd.lib.mk> -.if ${MACHINE_CPUARCH} == "amd64" && defined(ZFS32) +.if ${MACHINE_CPUARCH} == "amd64" && defined(DO32) .if !exists(machine) beforedepend ${OBJS}: machine .endif Modified: head/sys/boot/zfs32/Makefile ============================================================================== --- head/sys/boot/zfs32/Makefile Mon Nov 6 15:21:45 2017 (r325479) +++ head/sys/boot/zfs32/Makefile Mon Nov 6 15:21:51 2017 (r325480) @@ -1,5 +1,5 @@ # $FreeBSD$ -ZFS32=1 +DO32=1 .include "${.CURDIR}/../zfs/Makefile"
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201711061521.vA6FLpCp036302>