Use ${MACHINE} for the kernel modeule ldscript

For consistancy with the kernel linker script also use ${MACHINE} for
finding the kernel module linker script. As we currently only use this
for amd64 and i386 this is a no-op, but I'm planning on using this with
arm64 where ${MACHINE} != ${MACHINE_ARCH}.

Reviewed by:	markj, kib, imp
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D33841
This commit is contained in:
Andrew Turner 2022-01-11 11:55:32 +00:00
parent 5da9b3b011
commit 2754373f9a

View File

@ -234,8 +234,8 @@ EXPORT_SYMS?= NO
CLEANFILES+= export_syms
.endif
.if exists(${SYSDIR}/conf/ldscript.kmod.${MACHINE_ARCH})
LDSCRIPT_FLAGS?= -T ${SYSDIR}/conf/ldscript.kmod.${MACHINE_ARCH}
.if exists(${SYSDIR}/conf/ldscript.kmod.${MACHINE})
LDSCRIPT_FLAGS?= -T ${SYSDIR}/conf/ldscript.kmod.${MACHINE}
.endif
.if ${__KLD_SHARED} == yes