aboutsummaryrefslogtreecommitdiff
path: root/cddl/lib/libspl/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'cddl/lib/libspl/Makefile')
-rw-r--r--cddl/lib/libspl/Makefile56
1 files changed, 56 insertions, 0 deletions
diff --git a/cddl/lib/libspl/Makefile b/cddl/lib/libspl/Makefile
new file mode 100644
index 000000000000..64317c41b730
--- /dev/null
+++ b/cddl/lib/libspl/Makefile
@@ -0,0 +1,56 @@
+# $FreeBSD$
+
+.PATH: ${SRCTOP}/sys/contrib/openzfs/lib/libspl
+.PATH: ${SRCTOP}/sys/contrib/openzfs/lib/libspl/os/freebsd
+.PATH: ${SRCTOP}/sys/contrib/openzfs/include
+
+
+LIB= spl
+LIBADD=
+PACKAGE= runtime
+
+SRCS = \
+ assert.c \
+ list.c \
+ mkdirp.c \
+ page.c \
+ strlcat.c \
+ strlcpy.c \
+ timestamp.c \
+ zone.c \
+ include/sys/list.h \
+ include/sys/list_impl.h
+
+SRCS += \
+ getexecname.c \
+ gethostid.c \
+ getmntany.c \
+ mnttab.c
+
+
+.if ${MACHINE_ARCH} == "amd64"
+.PATH: ${SRCTOP}/sys/contrib/openzfs/lib/libspl/asm-x86_64
+SRCS += atomic.S
+.elif ${MACHINE_ARCH} == "i386"
+.PATH: ${SRCTOP}/sys/contrib/openzfs/lib/libspl/asm-i386
+SRCS += atomic.S
+.else
+.PATH: ${SRCTOP}/sys/contrib/openzfs/lib/libspl/asm-generic
+SRCS += atomic.c
+.endif
+
+
+WARNS?= 2
+CSTD= c99
+CFLAGS+= -DIN_BASE
+CFLAGS+= -I${SRCTOP}/sys/contrib/openzfs/include
+CFLAGS+= -I${SRCTOP}/sys/contrib/openzfs/lib/libspl/include/
+CFLAGS+= -I${SRCTOP}/sys/contrib/openzfs/lib/libspl/include/os/freebsd
+CFLAGS+= -I${SRCTOP}/cddl/compat/opensolaris/include
+CFLAGS+= -I${SRCTOP}/sys/contrib/openzfs/module/icp/include
+CFLAGS+= -include ${SRCTOP}/sys/contrib/openzfs/include/os/freebsd/spl/sys/ccompile.h
+CFLAGS+= -DHAVE_ISSETUGID
+CFLAGS+= -include ${SRCTOP}/sys/modules/zfs/zfs_config.h
+CFLAGS.atomic.S+= -DLOCORE
+
+.include <bsd.lib.mk>