git: 119c786f7b5a - main - stand: Compile zfs_zstd.c directly now
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sat, 09 Jul 2022 05:03:31 UTC
The branch main has been updated by imp:
URL: https://cgit.FreeBSD.org/src/commit/?id=119c786f7b5ac05d7ee7b2a01eef392093d6724a
commit 119c786f7b5ac05d7ee7b2a01eef392093d6724a
Author: Warner Losh <imp@FreeBSD.org>
AuthorDate: 2022-07-08 23:34:58 +0000
Commit: Warner Losh <imp@FreeBSD.org>
CommitDate: 2022-07-09 04:49:56 +0000
stand: Compile zfs_zstd.c directly now
Now that we have the ability to work around all the issues that
zstd_stub.c worked around, compile zfs_std.c directly.
Sponsored by: Netflix
Reviewed by: kevans
Differential Revision: https://reviews.freebsd.org/D35750
---
stand/libsa/zfs/Makefile.inc | 11 ++++++-----
1 file changed, 6 insertions(+), 5 deletions(-)
diff --git a/stand/libsa/zfs/Makefile.inc b/stand/libsa/zfs/Makefile.inc
index 411e0e4638d7..3f28c39c69da 100644
--- a/stand/libsa/zfs/Makefile.inc
+++ b/stand/libsa/zfs/Makefile.inc
@@ -3,11 +3,12 @@
.PATH: ${ZFSSRC}
.PATH: ${SYSDIR}/crypto/skein
.PATH: ${ZFSOSSRC}/spl
+.PATH: ${OZFS}/module/zstd
.PATH: ${OZFS}/module/zstd/lib/common
.PATH: ${OZFS}/module/zstd/lib/compress
.PATH: ${OZFS}/module/zstd/lib/decompress
ZFS_SRC= zfs.c nvlist.c skein.c skein_block.c list.c
-ZFS_SRC+= zstd_shim.c
+ZFS_SRC+= zfs_zstd.c
ZSTD_SRC+= entropy_common.c error_private.c
ZSTD_SRC+= fse_compress.c fse_decompress.c hist.c
ZSTD_SRC+= huf_compress.c huf_decompress.c pool.c xxhash.c
@@ -30,12 +31,12 @@ ZFS_EARLY= -I${ZFSSRC}/spl \
-I${ZFSOSINC}/zfs
.for i in ${ZFS_SRC} ${ZSTD_SRC}
-CFLAGS.$i+= -include ${ZFSOSINC}/spl/sys/ccompile.h
-CFLAGS.$i+= -Wformat -Wall
+CFLAGS.$i+= -include ${ZFSOSINC}/spl/sys/ccompile.h -Wformat -Wall -I${OZFS}/include \
+ -DNEED_SOLARIS_BOOLEAN
.endfor
CFLAGS_EARLY.list.c+= ${ZFS_EARLY}
-CFLAGS_EARLY.zstd_shim.c+= ${ZFS_EARLY}
+CFLAGS_EARLY.zfs_zstd.c+= ${ZFS_EARLY}
# Can't use the early flags because there's two conflicting definitions of boolean_t in
# the zfs code that need to be unified.
@@ -53,7 +54,7 @@ CFLAGS.zfs.c+= -I${ZFSOSINC}/spl \
CFLAGS.$i+= -U__BMI__ ${NO_WBITWISE_INSTEAD_OF_LOGICAL}
.endfor
-CFLAGS.zstd_shim.c+= -DIN_BASE -DIN_LIBSA -I${OZFS}/include
+CFLAGS.zfs_zstd.c+= -DIN_BASE -DIN_LIBSA
# Do not unroll skein loops, reduce code size
CFLAGS.skein_block.c+= -DSKEIN_LOOP=111