summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJavier Villavicencio <the_paya@gentoo.org>2009-01-23 22:40:33 +0000
committerJavier Villavicencio <the_paya@gentoo.org>2009-01-23 22:40:33 +0000
commit157a8403c408d6c12a5e72aa9913aa276ad4dd17 (patch)
treeb8bb389fd8f626870a34f1b3fa131a0fd762691c /sys-freebsd
parentamd64/x86 stable, bug #255691 (diff)
downloadgentoo-2-157a8403c408d6c12a5e72aa9913aa276ad4dd17.tar.gz
gentoo-2-157a8403c408d6c12a5e72aa9913aa276ad4dd17.tar.bz2
gentoo-2-157a8403c408d6c12a5e72aa9913aa276ad4dd17.zip
Import from gentoo-bsd overlay of ZFS userland for Gentoo/FreeBSD.
(Portage version: 2.2_rc23/cvs/FreeBSD i386)
Diffstat (limited to 'sys-freebsd')
-rw-r--r--sys-freebsd/freebsd-cddl/ChangeLog12
-rw-r--r--sys-freebsd/freebsd-cddl/files/freebsd-cddl-7.1-libpaths.patch79
-rw-r--r--sys-freebsd/freebsd-cddl/files/freebsd-cddl-7.1-xdr_header.patch16
-rw-r--r--sys-freebsd/freebsd-cddl/freebsd-cddl-7.1.ebuild56
-rw-r--r--sys-freebsd/freebsd-cddl/metadata.xml5
5 files changed, 168 insertions, 0 deletions
diff --git a/sys-freebsd/freebsd-cddl/ChangeLog b/sys-freebsd/freebsd-cddl/ChangeLog
new file mode 100644
index 000000000000..23d60c30c297
--- /dev/null
+++ b/sys-freebsd/freebsd-cddl/ChangeLog
@@ -0,0 +1,12 @@
+# ChangeLog for sys-freebsd/freebsd-cddl
+# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/sys-freebsd/freebsd-cddl/ChangeLog,v 1.1 2009/01/23 22:40:33 the_paya Exp $
+
+*freebsd-cddl-7.1 (23 Jan 2009)
+
+ 23 Jan 2009; Javier Villavicencio <the_paya@gentoo.org>
+ +files/freebsd-cddl-7.1-libpaths.patch,
+ +files/freebsd-cddl-7.1-xdr_header.patch, +metadata.xml,
+ +freebsd-cddl-7.1.ebuild:
+ Initial import from gentoo-bsd overlay. ZFS userland for FreeBSD.
+
diff --git a/sys-freebsd/freebsd-cddl/files/freebsd-cddl-7.1-libpaths.patch b/sys-freebsd/freebsd-cddl/files/freebsd-cddl-7.1-libpaths.patch
new file mode 100644
index 000000000000..0032795eb1e0
--- /dev/null
+++ b/sys-freebsd/freebsd-cddl/files/freebsd-cddl-7.1-libpaths.patch
@@ -0,0 +1,79 @@
+diff -ru cddl.orig/lib/libzfs/Makefile cddl/lib/libzfs/Makefile
+--- cddl.orig/lib/libzfs/Makefile 2008-06-22 10:26:18 -0300
++++ cddl/lib/libzfs/Makefile 2008-06-22 10:26:26 -0300
+@@ -7,7 +7,7 @@
+
+ LIB= zfs
+ DPADD= ${LIBUTIL}
+-LDADD= -lutil
++LDADD= -lutil -lgeom -lm
+
+ SRCS= deviceid.c \
+ mnttab.c \
+diff -ru cddl.orig/lib/libzpool/Makefile cddl/lib/libzpool/Makefile
+--- cddl.orig/lib/libzpool/Makefile 2008-06-22 10:35:15 -0300
++++ cddl/lib/libzpool/Makefile 2008-06-22 10:37:06 -0300
+@@ -42,7 +42,8 @@
+ CFLAGS+= -I${.CURDIR}/../../../contrib/opensolaris/lib/libnvpair
+
+ DPADD= ${LIBPTHREAD} ${LIBZ}
+-LDADD= -lpthread -lz
++LDADD= -lpthread -lz -lavl
++LDFLAGS+= -L${.CURDIR}/../libavl
+
+ # atomic.S doesn't like profiling.
+ NO_PROFILE=
+diff -ru cddl.orig/sbin/zfs/Makefile cddl/sbin/zfs/Makefile
+--- cddl.orig/sbin/zfs/Makefile 2008-06-22 10:02:30 -0300
++++ cddl/sbin/zfs/Makefile 2008-06-22 10:14:23 -0300
+@@ -23,5 +23,7 @@
+ ${LIBM} ${LIBNVPAIR} ${LIBUUTIL} ${LIBUTIL}
+ LDADD= -lzfs -lgeom -lbsdxml -lsbuf \
+ -lm -lnvpair -luutil -lutil
++LDFLAGS+=-L${.CURDIR}/../../lib/libzfs -L${.CURDIR}/../../lib/libnvpair \
++ -L${.CURDIR}/../../lib/libuutil -L/lib -L/usr/lib
+
+ .include <bsd.prog.mk>
+diff -ru cddl.orig/sbin/zpool/Makefile cddl/sbin/zpool/Makefile
+--- cddl.orig/sbin/zpool/Makefile 2008-06-22 10:02:30 -0300
++++ cddl/sbin/zpool/Makefile 2008-06-22 10:14:47 -0300
+@@ -23,5 +23,7 @@
+ ${LIBM} ${LIBNVPAIR} ${LIBUUTIL} ${LIBUTIL}
+ LDADD= -lavl -lzfs -lgeom -lbsdxml -lsbuf \
+ -lm -lnvpair -luutil -lutil
++LDFLAGS+=-L${.CURDIR}/../../lib/libzfs -L${.CURDIR}/../../lib/libavl -L/lib -L/usr/lib \
++ -L${.CURDIR}/../../lib/libnvpair -L${.CURDIR}/../../lib/libuutil
+
+ .include <bsd.prog.mk>
+diff -ru cddl.orig/usr.bin/ztest/Makefile cddl/usr.bin/ztest/Makefile
+--- cddl.orig/usr.bin/ztest/Makefile 2008-06-22 10:02:30 -0300
++++ cddl/usr.bin/ztest/Makefile 2008-06-22 10:12:40 -0300
+@@ -18,5 +18,7 @@
+ DPADD= ${LIBM} ${LIBNVPAIR} ${LIBUMEM} ${LIBZPOOL} \
+ ${LIBPTHREAD} ${LIBZ} ${LIBAVL}
+ LDADD= -lm -lnvpair -lumem -lzpool -lpthread -lz -lavl
++LDFLAGS+=-L${.CURDIR}/../../lib/libnvpair -L${.CURDIR}/../../lib/libumem \
++ -L${.CURDIR}/../../lib/libzpool -L${.CURDIR}/../../lib/libavl -L/lib -L/usr/lib
+
+ .include <bsd.prog.mk>
+diff -ru cddl.orig/usr.sbin/zdb/Makefile cddl/usr.sbin/zdb/Makefile
+--- cddl.orig/usr.sbin/zdb/Makefile 2008-06-22 10:02:30 -0300
++++ cddl/usr.sbin/zdb/Makefile 2008-06-22 10:13:31 -0300
+@@ -19,5 +19,7 @@
+ DPADD= ${LIBM} ${LIBNVPAIR} ${LIBUMEM} ${LIBZPOOL} \
+ ${LIBPTHREAD} ${LIBZ} ${LIBAVL}
+ LDADD= -lm -lnvpair -lumem -lzpool -lpthread -lz -lavl
++LDFLAGS+=-L${.CURDIR}/../../lib/libnvpair -L${.CURDIR}/../../lib/libumem \
++ -L${.CURDIR}/../../lib/libzpool -L${.CURDIR}/../../lib/libavl -L/lib -L/usr/lib
+
+ .include <bsd.prog.mk>
+diff -ru cddl.orig/usr.bin/Makefile.inc cddl/usr.bin/Makefile.inc
+--- cddl.orig/usr.bin/Makefile.inc 2009-01-10 07:21:10 +0000
++++ cddl/usr.bin/Makefile.inc 2009-01-10 07:18:55 +0000
+@@ -1,5 +1,6 @@
+ # $FreeBSD: src/cddl/usr.bin/Makefile.inc,v 1.1.6.1 2008/11/25 02:59:29 kensmith Exp $
+
+ BINDIR?= /usr/bin
++LDFLAGS+= -L${.CURDIR}/../../lib/libctf
+
+ .include "../Makefile.inc"
diff --git a/sys-freebsd/freebsd-cddl/files/freebsd-cddl-7.1-xdr_header.patch b/sys-freebsd/freebsd-cddl/files/freebsd-cddl-7.1-xdr_header.patch
new file mode 100644
index 000000000000..0abc08990e30
--- /dev/null
+++ b/sys-freebsd/freebsd-cddl/files/freebsd-cddl-7.1-xdr_header.patch
@@ -0,0 +1,16 @@
+--- sys/cddl/compat/opensolaris/rpc/xdr.h.orig 2007-04-05 22:09:06 -0300
++++ sys/cddl/compat/opensolaris/rpc/xdr.h 2008-06-22 09:46:28 -0300
+@@ -55,13 +55,6 @@
+
+ #define XDR_GET_BYTES_AVAIL 1
+
+-struct xdr_bytesrec {
+- bool_t xc_is_last_record;
+- size_t xc_num_avail;
+-};
+-
+-typedef struct xdr_bytesrec xdr_bytesrec;
+-
+ /*
+ * These are the request arguments to XDR_CONTROL.
+ *
diff --git a/sys-freebsd/freebsd-cddl/freebsd-cddl-7.1.ebuild b/sys-freebsd/freebsd-cddl/freebsd-cddl-7.1.ebuild
new file mode 100644
index 000000000000..4c21b97fb38b
--- /dev/null
+++ b/sys-freebsd/freebsd-cddl/freebsd-cddl-7.1.ebuild
@@ -0,0 +1,56 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sys-freebsd/freebsd-cddl/freebsd-cddl-7.1.ebuild,v 1.1 2009/01/23 22:40:33 the_paya Exp $
+
+inherit bsdmk freebsd flag-o-matic eutils
+
+DESCRIPTION="FreeBSD CDDL (opensolaris/zfs) extra software"
+SLOT="0"
+KEYWORDS="~x86-fbsd"
+
+IUSE=""
+LICENSE="CDDL"
+
+SRC_URI="mirror://gentoo/${P}.tar.bz2
+ mirror://gentoo/${CONTRIB}.tar.bz2
+ mirror://gentoo/${UBIN}.tar.bz2
+ mirror://gentoo/${LIB}.tar.bz2
+ mirror://gentoo/${SBIN}.tar.bz2
+ mirror://gentoo/${SYS}.tar.bz2
+ build? ( mirror://gentoo/${SYS}.tar.bz2
+ mirror://gentoo/${INCLUDE}.tar.bz2 )"
+
+# sys is required.
+
+RDEPEND="=sys-freebsd/freebsd-lib-${RV}*
+ =sys-freebsd/freebsd-libexec-${RV}*
+ build? ( sys-apps/baselayout )
+ dev-libs/libedit"
+
+DEPEND="${RDEPEND}
+ =sys-freebsd/freebsd-mk-defs-${RV}*
+ !build? ( =sys-freebsd/freebsd-sources-${RV}* )"
+
+S="${WORKDIR}/cddl"
+
+PATCHES="${FILESDIR}/${PN}-7.1-libpaths.patch"
+
+pkg_setup() {
+ mymakeopts="${mymakeopts} NO_MANCOMPRESS= NO_INFOCOMPRESS= "
+}
+
+src_unpack() {
+ freebsd_src_unpack
+ # Link in include headers.
+ ln -s "/usr/include" "${WORKDIR}/include" || die "Symlinking /usr/include.."
+ # This patch is against sys.
+ cd "${WORKDIR}"
+ epatch "${FILESDIR}/${PN}-7.1-xdr_header.patch"
+}
+
+src_compile() {
+ freebsd_src_compile
+}
+
+#src_install() {
+#}
diff --git a/sys-freebsd/freebsd-cddl/metadata.xml b/sys-freebsd/freebsd-cddl/metadata.xml
new file mode 100644
index 000000000000..ecedda4aa2cc
--- /dev/null
+++ b/sys-freebsd/freebsd-cddl/metadata.xml
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<herd>bsd</herd>
+</pkgmetadata>