/[gentoo-x86]/sys-kernel/spl/spl-0.6.0_rc10.ebuild
Gentoo

Contents of /sys-kernel/spl/spl-0.6.0_rc10.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.13 - (show annotations) (download)
Sun Jun 8 17:11:38 2014 UTC (2 months, 3 weeks ago) by ryao
Branch: MAIN
CVS Tags: HEAD
Changes since 1.12: +1 -1 lines
FILE REMOVED
Remove ancient SPL versions

(Portage version: 2.2.10/cvs/Linux x86_64, signed Manifest commit with key 0xBEE84C64)

1 # Copyright 1999-2013 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/sys-kernel/spl/spl-0.6.0_rc10.ebuild,v 1.12 2013/04/17 13:26:26 ryao Exp $
4
5 EAPI="4"
6 AUTOTOOLS_AUTORECONF="1"
7
8 inherit flag-o-matic linux-info linux-mod autotools-utils
9
10 if [[ ${PV} == "9999" ]] ; then
11 inherit git-2
12 EGIT_REPO_URI="git://github.com/zfsonlinux/${PN}.git"
13 else
14 inherit eutils versionator
15 MY_PV=$(replace_version_separator 3 '-')
16 SRC_URI="mirror://github/zfsonlinux/${PN}/${PN}-${MY_PV}.tar.gz"
17 S="${WORKDIR}/${PN}-${MY_PV}"
18 KEYWORDS="~amd64"
19 fi
20
21 DESCRIPTION="The Solaris Porting Layer is a Linux kernel module which provides many of the Solaris kernel APIs"
22 HOMEPAGE="http://zfsonlinux.org/"
23
24 LICENSE="GPL-2"
25 SLOT="0"
26 IUSE="custom-cflags debug debug-log"
27 RESTRICT="test"
28
29 COMMON_DEPEND="dev-lang/perl
30 virtual/awk"
31
32 DEPEND="${COMMON_DEPEND}"
33
34 RDEPEND="${COMMON_DEPEND}
35 !sys-devel/spl"
36
37 AT_M4DIR="config"
38 AUTOTOOLS_IN_SOURCE_BUILD="1"
39
40 pkg_setup() {
41 linux-info_pkg_setup
42 CONFIG_CHECK="
43 !DEBUG_LOCK_ALLOC
44 !GRKERNSEC_HIDESYM
45 !PREEMPT
46 MODULES
47 KALLSYMS
48 ZLIB_DEFLATE
49 ZLIB_INFLATE
50 "
51
52 kernel_is ge 2 6 26 || die "Linux 2.6.26 or newer required"
53
54 [ ${PV} != "9999" ] && \
55 { kernel_is le 3 6 || die "Linux 3.6 is the latest supported version."; }
56
57 check_extra_config
58 }
59
60 src_prepare() {
61 # Workaround for hard coded path
62 sed -i "s|/sbin/lsmod|/bin/lsmod|" scripts/check.sh || die
63
64 if [ ${PV} != "9999" ]
65 then
66 # Fix potential deadlocks when ZFS is used on swap
67 epatch "${FILESDIR}/${PN}-0.6.0_rc9-alias-km-sleep-with-km-pushpage.patch"
68
69 # Linux 3.6 Support
70 epatch "${FILESDIR}/${PN}-0.6.0_rc11-linux-3.6-compat.patch"
71 epatch "${FILESDIR}/${PN}-0.6.0_rc12-fix-3.6-compat-regression.patch"
72
73 # Fix x86 build failures on Linux 3.4 and later, bug #450646
74 epatch "${FILESDIR}/${PN}-0.6.0_rc14-fix-atomic64-checks.patch"
75
76 # Fix autotools check that fails on ~ppc64
77 epatch "${FILESDIR}/${PN}-0.6.0_rc14-fix-mutex-owner-check.patch"
78 fi
79
80 autotools-utils_src_prepare
81 }
82
83 src_configure() {
84 use custom-cflags || strip-flags
85 set_arch_to_kernel
86 local myeconfargs=(
87 --bindir="${EPREFIX}/bin"
88 --sbindir="${EPREFIX}/sbin"
89 --with-config=all
90 --with-linux="${KV_DIR}"
91 --with-linux-obj="${KV_OUT_DIR}"
92 $(use_enable debug)
93 $(use_enable debug-log)
94 )
95 autotools-utils_src_configure
96 }
97
98 src_test() {
99 if [[ ! -e /proc/modules ]]
100 then
101 die "Missing /proc/modules"
102 elif [[ $UID -ne 0 ]]
103 then
104 ewarn "Cannot run make check tests with FEATURES=userpriv."
105 ewarn "Skipping make check tests."
106 elif grep -q '^spl ' /proc/modules
107 then
108 ewarn "Cannot run make check tests with module spl loaded."
109 ewarn "Skipping make check tests."
110 else
111 autotools-utils_src_test
112 fi
113 }

  ViewVC Help
Powered by ViewVC 1.1.20