| 1 | # Copyright 1999-2004 Gentoo Foundation |
1 | # Copyright 1999-2004 Gentoo Foundation |
| 2 | # Distributed under the terms of the GNU General Public License v2 |
2 | # Distributed under the terms of the GNU General Public License v2 |
| 3 | # $Header: /var/cvsroot/gentoo-x86/eclass/linux-mod.eclass,v 1.61 2006/03/25 16:43:09 betelgeuse Exp $ |
3 | # $Header: /var/cvsroot/gentoo-x86/eclass/linux-mod.eclass,v 1.62 2006/03/26 17:47:19 blubb Exp $ |
| 4 | |
4 | |
| 5 | # Description: This eclass is used to interface with linux-info in such a way |
5 | # Description: This eclass is used to interface with linux-info in such a way |
| 6 | # to provide the functionality required and initial functions |
6 | # to provide the functionality required and initial functions |
| 7 | # required to install external modules against a kernel source |
7 | # required to install external modules against a kernel source |
| 8 | # tree. |
8 | # tree. |
| … | |
… | |
| 81 | # The order of these is important as both of linux-info and eutils contain |
81 | # The order of these is important as both of linux-info and eutils contain |
| 82 | # set_arch_to_kernel and set_arch_to_portage functions and the ones in eutils |
82 | # set_arch_to_kernel and set_arch_to_portage functions and the ones in eutils |
| 83 | # are deprecated in favor of the ones in linux-info. |
83 | # are deprecated in favor of the ones in linux-info. |
| 84 | # See http://bugs.gentoo.org/show_bug.cgi?id=127506 |
84 | # See http://bugs.gentoo.org/show_bug.cgi?id=127506 |
| 85 | |
85 | |
| 86 | inherit eutils linux-info |
86 | inherit eutils linux-info multilib |
| 87 | EXPORT_FUNCTIONS pkg_setup pkg_postinst src_install src_compile pkg_postrm |
87 | EXPORT_FUNCTIONS pkg_setup pkg_postinst src_install src_compile pkg_postrm |
| 88 | |
88 | |
| 89 | IUSE="" # don't put pcmcia here, rather in the ebuilds that actually support pcmcia |
89 | IUSE="" # don't put pcmcia here, rather in the ebuilds that actually support pcmcia |
| 90 | SLOT="0" |
90 | SLOT="0" |
| 91 | DESCRIPTION="Based on the $ECLASS eclass" |
91 | DESCRIPTION="Based on the $ECLASS eclass" |
| … | |
… | |
| 471 | # introduced - Jason Wever <weeve@gentoo.org>, 23 Oct 2005 |
471 | # introduced - Jason Wever <weeve@gentoo.org>, 23 Oct 2005 |
| 472 | #check_vermagic; |
472 | #check_vermagic; |
| 473 | } |
473 | } |
| 474 | |
474 | |
| 475 | linux-mod_src_compile() { |
475 | linux-mod_src_compile() { |
| 476 | local modulename libdir srcdir objdir i n myARCH="${ARCH}" |
476 | local modulename libdir srcdir objdir i n myARCH="${ARCH}" myABI="${ABI}" |
| 477 | ARCH="$(tc-arch-kernel)" |
477 | ARCH="$(tc-arch-kernel)" |
|
|
478 | ABI="${KERNEL_ABI}" |
| 478 | |
479 | |
| 479 | BUILD_TARGETS=${BUILD_TARGETS:-clean module} |
480 | BUILD_TARGETS=${BUILD_TARGETS:-clean module} |
| 480 | |
481 | |
| 481 | for i in ${MODULE_IGNORE} |
482 | for i in ${MODULE_IGNORE} |
| 482 | do |
483 | do |
| … | |
… | |
| 511 | cd ${OLDPWD} |
512 | cd ${OLDPWD} |
| 512 | fi |
513 | fi |
| 513 | done |
514 | done |
| 514 | |
515 | |
| 515 | ARCH="${myARCH}" |
516 | ARCH="${myARCH}" |
|
|
517 | ABI="${myABI}" |
| 516 | } |
518 | } |
| 517 | |
519 | |
| 518 | linux-mod_src_install() { |
520 | linux-mod_src_install() { |
| 519 | local modulename libdir srcdir objdir i n |
521 | local modulename libdir srcdir objdir i n |
| 520 | |
522 | |