git: 3b8c26507f7b - stable/13 - Use ${MACHINE} for the kernel modeule ldscript

From: Andrew Turner <andrew_at_FreeBSD.org>
Date: Mon, 31 Jan 2022 11:32:54 UTC
The branch stable/13 has been updated by andrew:

URL: https://cgit.FreeBSD.org/src/commit/?id=3b8c26507f7b5325df967abfddc23f38cf940ab6

commit 3b8c26507f7b5325df967abfddc23f38cf940ab6
Author:     Andrew Turner <andrew@FreeBSD.org>
AuthorDate: 2022-01-11 11:55:32 +0000
Commit:     Andrew Turner <andrew@FreeBSD.org>
CommitDate: 2022-01-31 10:05:54 +0000

    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
    
    (cherry picked from commit 2754373f9ac8e73f8fdbba9df26ac03e4864576e)
---
 sys/conf/kmod.mk | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/sys/conf/kmod.mk b/sys/conf/kmod.mk
index c0d4441af029..736ce26d406c 100644
--- a/sys/conf/kmod.mk
+++ b/sys/conf/kmod.mk
@@ -236,8 +236,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