1.include <bsd.init.mk> 2.include <bsd.compiler.mk> 3 4.PATH: ${SRCTOP}/sys/contrib/openzfs/lib/libspl 5.PATH: ${SRCTOP}/sys/contrib/openzfs/include 6 7LIB= spl 8LIBADD= 9PACKAGE= zfs 10 11SRCS = \ 12 assert.c \ 13 backtrace.c \ 14 list.c \ 15 mkdirp.c \ 16 os/freebsd/zone.c \ 17 page.c \ 18 timestamp.c \ 19 include/sys/list.h \ 20 include/sys/list_impl.h 21 22# These functions are not required when bootstrapping and the atomic code 23# will not compile when building on macOS. 24.if !defined(BOOTSTRAPPING) 25SRCS += \ 26 atomic.c \ 27 getexecname.c \ 28 os/freebsd/getexecname.c \ 29 os/freebsd/gethostid.c \ 30 os/freebsd/getmntany.c \ 31 os/freebsd/mnttab.c 32.endif 33 34WARNS?= 2 35CSTD= c99 36CFLAGS+= -DIN_BASE 37CFLAGS+= -I${SRCTOP}/sys/contrib/openzfs/include 38CFLAGS+= -I${SRCTOP}/sys/contrib/openzfs/lib/libspl/include/ 39CFLAGS+= -I${SRCTOP}/sys/contrib/openzfs/lib/libspl/include/os/freebsd 40CFLAGS+= -I${SRCTOP}/cddl/compat/opensolaris/include 41CFLAGS+= -I${SRCTOP}/sys/contrib/openzfs/module/icp/include 42CFLAGS+= -include ${SRCTOP}/sys/contrib/openzfs/include/os/freebsd/spl/sys/ccompile.h 43CFLAGS+= -DHAVE_ISSETUGID 44CFLAGS+= -include ${SRCTOP}/sys/modules/zfs/zfs_config.h 45.if ${COMPILER_TYPE} == "clang" 46CFLAGS.atomic.c+= -Wno-error=atomic-alignment 47.endif 48 49.include <bsd.lib.mk> 50