Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

FL-534: kmod revbump

  • Loading branch information...
commit c95cdbc83604daaa0e4a16261a2e90ba5908a9b9 1 parent 66dee8e
Jean-Francis Roy jeanfrancisroy authored
104 sys-apps/kmod/kmod-13-r1.ebuild
... ... @@ -0,0 +1,104 @@
  1 +# Distributed under the terms of the GNU General Public License v2
  2 +
  3 +EAPI=5
  4 +
  5 +VIRTUAL_MODUTILS=1
  6 +
  7 +inherit autotools eutils libtool multilib linux-mod
  8 +
  9 +if [[ ${PV} == 9999 ]]; then
  10 + EGIT_REPO_URI="git://git.kernel.org/pub/scm/utils/kernel/${PN}/${PN}.git"
  11 + inherit git-2
  12 +else
  13 + SRC_URI="mirror://kernel/linux/utils/kernel/kmod/${P}.tar.xz"
  14 + KEYWORDS="*"
  15 +fi
  16 +
  17 +DESCRIPTION="library and tools for managing linux kernel modules"
  18 +HOMEPAGE="http://git.kernel.org/?p=utils/kernel/kmod/kmod.git"
  19 +
  20 +LICENSE="LGPL-2"
  21 +SLOT="0"
  22 +IUSE="debug doc lzma static-libs +tools zlib"
  23 +
  24 +# Upstream does not support running the test suite with custom configure flags.
  25 +# I was also told that the test suite is intended for kmod developers.
  26 +# So we have to restrict it.
  27 +# See bug #408915.
  28 +RESTRICT="test"
  29 +
  30 +RDEPEND="!sys-apps/module-init-tools
  31 + !sys-apps/modutils
  32 + lzma? ( >=app-arch/xz-utils-5.0.4-r1 )
  33 + zlib? ( >=sys-libs/zlib-1.2.6 )" #427130
  34 +DEPEND="${RDEPEND}
  35 + dev-libs/libxslt
  36 + doc? ( dev-util/gtk-doc )
  37 + lzma? ( virtual/pkgconfig )
  38 + zlib? ( virtual/pkgconfig )"
  39 +
  40 +pkg_setup() {
  41 + CONFIG_CHECK="~MODULES ~MODULE_UNLOAD"
  42 +
  43 + linux-info_pkg_setup
  44 +}
  45 +
  46 +src_prepare()
  47 +{
  48 + epatch ${FILESDIR}/${P}-dont-call-syscall.patch
  49 +
  50 + if [ ! -e configure ]; then
  51 + if use doc; then
  52 + gtkdocize --copy --docdir libkmod/docs || die
  53 + else
  54 + touch libkmod/docs/gtk-doc.make
  55 + fi
  56 + eautoreconf
  57 + else
  58 + elibtoolize
  59 + fi
  60 +}
  61 +
  62 +src_configure()
  63 +{
  64 + econf \
  65 + --bindir=/sbin \
  66 + --with-rootlibdir=/$(get_libdir) \
  67 + $(use_enable static-libs static) \
  68 + $(use_enable tools) \
  69 + $(use_enable debug) \
  70 + $(use_enable doc gtk-doc) \
  71 + $(use_with lzma xz) \
  72 + $(use_with zlib)
  73 +}
  74 +
  75 +src_install()
  76 +{
  77 + default
  78 + prune_libtool_files
  79 +
  80 + if use tools; then
  81 + local sbincmd
  82 + for sbincmd in depmod insmod lsmod modinfo modprobe rmmod; do
  83 + dosym /sbin/kmod /sbin/${sbincmd}
  84 + done
  85 +
  86 + fi
  87 +
  88 + cat <<-EOF > "${T}"/usb-load-ehci-first.conf
  89 + softdep uhci_hcd pre: ehci_hcd
  90 + softdep ohci_hcd pre: ehci_hcd
  91 + EOF
  92 +
  93 + insinto /lib/modprobe.d
  94 + doins "${T}"/usb-load-ehci-first.conf #260139
  95 +}
  96 +
  97 +pkg_postinst() {
  98 + # Upgrade path from sys-apps/module-init-tools
  99 + if [[ -d ${ROOT}/lib/modules/${KV_FULL} ]]; then
  100 + if [[ -z ${REPLACING_VERSIONS} ]]; then
  101 + update_depmod
  102 + fi
  103 + fi
  104 +}
2  sys-apps/kmod/kmod-13.ebuild
@@ -45,8 +45,6 @@ pkg_setup() {
45 45
46 46 src_prepare()
47 47 {
48   - epatch ${FILESDIR}/${P}-dont-call-syscall.patch
49   -
50 48 if [ ! -e configure ]; then
51 49 if use doc; then
52 50 gtkdocize --copy --docdir libkmod/docs || die

0 comments on commit c95cdbc

Please sign in to comment.
Something went wrong with that request. Please try again.