Date: Thu, 22 Apr 2021 11:08:12 GMT From: Alex Richardson <arichardson@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org Subject: git: 4ee7ac8dc525 - stable/13 - Fix build with read-only source dir after 83c20b8a2da0 Message-ID: <202104221108.13MB8CFs088296@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch stable/13 has been updated by arichardson: URL: https://cgit.FreeBSD.org/src/commit/?id=4ee7ac8dc525d0253d90fef8b1882eb4cdef801c commit 4ee7ac8dc525d0253d90fef8b1882eb4cdef801c Author: Alex Richardson <arichardson@FreeBSD.org> AuthorDate: 2021-02-03 09:29:08 +0000 Commit: Alex Richardson <arichardson@FreeBSD.org> CommitDate: 2021-04-22 09:41:20 +0000 Fix build with read-only source dir after 83c20b8a2da0 I changed the Makefile to use SRCS instead of LDADD, but since there is still and absolute path to the source the .o file was created inside the source directory instead of the build directory. It would be nice if this was an error/warning by default, but for now just fix this issue by using .PATH and the base name of the file. Reported by: cy, peterj (cherry picked from commit 8b820df156e065f48857dca89a89462074659e14) --- tests/sys/kern/Makefile | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tests/sys/kern/Makefile b/tests/sys/kern/Makefile index f350b740b7ea..6746812d9b4a 100644 --- a/tests/sys/kern/Makefile +++ b/tests/sys/kern/Makefile @@ -62,9 +62,11 @@ SRCS.libkern_crc32+= libkern_crc32.c SRCS.libkern_crc32+= gsb_crc32.c CFLAGS.libkern_crc32+= -DTESTING .if ${MACHINE_ARCH} == "amd64" || ${MACHINE_ARCH} == "i386" -SRCS.libkern_crc32+= ${SRCTOP}/sys/libkern/x86/crc32_sse42.c +.PATH: ${SRCTOP}/sys/libkern/x86 +SRCS.libkern_crc32+= crc32_sse42.c .elif ${MACHINE_CPUARCH} == "aarch64" -SRCS.libkern_crc32+= ${SRCTOP}/sys/libkern/arm64/crc32c_armv8.S +.PATH: ${SRCTOP}/sys/libkern/arm64 +SRCS.libkern_crc32+= crc32c_armv8.S .endif # subr_unit.c contains functions whose prototypes lie in headers that cannot be
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202104221108.13MB8CFs088296>