| 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.75 2007/10/03 12:53:10 phreak Exp $ |
3 | # $Header: /var/cvsroot/gentoo-x86/eclass/linux-mod.eclass,v 1.77 2007/11/16 06:12:01 zmedico 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. |
| … | |
… | |
| 489 | ARCH="$(tc-arch-kernel)" |
489 | ARCH="$(tc-arch-kernel)" |
| 490 | ABI="${KERNEL_ABI}" |
490 | ABI="${KERNEL_ABI}" |
| 491 | |
491 | |
| 492 | BUILD_TARGETS=${BUILD_TARGETS:-clean module} |
492 | BUILD_TARGETS=${BUILD_TARGETS:-clean module} |
| 493 | strip_modulenames; |
493 | strip_modulenames; |
|
|
494 | cd "${S}" |
| 494 | for i in ${MODULE_NAMES} |
495 | for i in ${MODULE_NAMES} |
| 495 | do |
496 | do |
| 496 | unset libdir srcdir objdir |
497 | unset libdir srcdir objdir |
| 497 | for n in $(find_module_params ${i}) |
498 | for n in $(find_module_params ${i}) |
| 498 | do |
499 | do |
| … | |
… | |
| 552 | } |
553 | } |
| 553 | |
554 | |
| 554 | linux-mod_pkg_preinst() { |
555 | linux-mod_pkg_preinst() { |
| 555 | debug-print-function ${FUNCNAME} $* |
556 | debug-print-function ${FUNCNAME} $* |
| 556 | |
557 | |
| 557 | [ -d ${IMAGE}/lib/modules ] && UPDATE_DEPMOD=true || UPDATE_DEPMOD=false |
558 | [ -d "${D}lib/modules" ] && UPDATE_DEPMOD=true || UPDATE_DEPMOD=false |
| 558 | [ -d ${IMAGE}/etc/modules.d ] && UPDATE_MODULES=true || UPDATE_MODULES=false |
559 | [ -d "${D}etc/modules.d" ] && UPDATE_MODULES=true || UPDATE_MODULES=false |
| 559 | [ -d ${IMAGE}/lib/modules ] && UPDATE_MODULEDB=true || UPDATE_MODULEDB=false |
560 | [ -d "${D}lib/modules" ] && UPDATE_MODULEDB=true || UPDATE_MODULEDB=false |
| 560 | } |
561 | } |
| 561 | |
562 | |
| 562 | linux-mod_pkg_postinst() { |
563 | linux-mod_pkg_postinst() { |
| 563 | debug-print-function ${FUNCNAME} $* |
564 | debug-print-function ${FUNCNAME} $* |
| 564 | |
565 | |