Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 33124 Details for
Bug 32737
Compiling external kernel modules with 2.6 kernels
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
vmware-config-4.5.2.8848-koutput.patch
vmw-cfg.patch (text/plain), 9.80 KB, created by
Georgi Georgiev
on 2004-06-12 00:55:27 UTC
(
hide
)
Description:
vmware-config-4.5.2.8848-koutput.patch
Filename:
MIME Type:
Creator:
Georgi Georgiev
Created:
2004-06-12 00:55:27 UTC
Size:
9.80 KB
patch
obsolete
>--- bin/vmware-config.pl.orig 2004-06-11 10:32:54.000000000 +0900 >+++ bin/vmware-config.pl 2004-06-12 16:33:19.441468915 +0900 >@@ -1725,150 +1725,9 @@ > sub check_answer_headerdir { > my $answer = shift; > my $source = shift; >- my $pattern = '@@VMWARE@@'; >- my $header_version_uts; >- my $header_smp; >- my $header_page_offset; >- >- $answer = dir_remove_trailing_slashes($answer); >- >- if (not (-d $answer)) { >- if ($source eq 'user') { >- print wrap('The path "' . $answer . '" is not an existing directory.' >- . "\n\n", 0); >- } >- return ''; >- } >- >- if ($answer =~ m|^/usr/include(/.*)?$|) { #/# Broken colorizer. >- if ($source eq 'user') { >- if (get_answer('The header files in /usr/include are generally for C ' >- . 'libraries, not for the running kernel. If you do not ' >- . 'have kernel header files in your /usr/src directory, ' >- . 'you probably do not have the kernel-source package ' >- . 'installed. Are you sure that /usr/include contains ' >- . 'the header files associated with your running kernel?', >- 'yesno', 'no') eq 'no') { >- return ''; >- } >- } >- } >- >- if ( (not (-d $answer . '/linux')) >- || (not (-d $answer . '/asm')) >- || (not (-d $answer . '/net'))) { >- if ($source eq 'user') { >- print wrap('The path "' . $answer . '" is an existing directory, but it ' >- . 'does not contain at least one of these directories ' >- . '"linux", "asm", "net" as expected.' . "\n\n", 0); >- } >- return ''; >- } >- >- # >- # Check that the running kernel matches the set of header files >- # >- >- if (not (-r $answer . '/linux/version.h')) { >- if ($source eq 'user') { >- print wrap('The path "' . $answer . '" is a kernel header file ' >- . 'directory, but it does not contain the file ' >- . '"linux/version.h" as expected. This can happen if the ' >- . 'kernel has never been built, or if you have invoked the ' >- . '"make mrproper" command in your kernel directory. In any ' >- . 'case, you may want to rebuild your kernel.' . "\n\n", 0); >- } >- return ''; >- } >- $header_version_uts = direct_command( >- shell_string($gHelper{'echo'}) . ' ' >- . shell_string('#include <linux/version.h>' . "\n" . $pattern >- . ' UTS_RELEASE') . ' | ' . shell_string($gHelper{'gcc'}) >- . ' ' . shell_string('-I' . $answer) . ' -E - | ' >- . shell_string($gHelper{'grep'}) . ' ' . shell_string($pattern)); >- chomp($header_version_uts); >- $header_version_uts =~ s/^$pattern \"([^\"]*)\".*$/$1/; >- if (not ($header_version_uts eq $gSystem{'uts_release'})) { >- if ($source eq 'user') { >- print wrap('The directory of kernel headers (version ' >- . $header_version_uts . ') does not match your running ' >- . 'kernel (version ' . $gSystem{'uts_release'} . '). Even ' >- . 'if the module were to compile successfully, it would not ' >- . 'load into the running kernel.' . "\n\n", 0); >- } >- return ''; >- } >- >- if (not (-r $answer . '/linux/autoconf.h')) { >- if ($source eq 'user') { >- print wrap('The path "' . $answer . '" is a kernel header file ' >- . 'directory, but it does not contain the file ' >- . '"linux/autoconf.h" as expected. This can happen if the ' >- . 'kernel has never been built, or if you have invoked the ' >- . '"make mrproper" command in your kernel directory. In any ' >- . 'case, you may want to rebuild your kernel.' . "\n\n", 0); >- } >- return ''; >- } >- $header_smp = direct_command(shell_string($gHelper{'grep'}) . ' CONFIG_SMP ' >- . shell_string($answer . '/linux/autoconf.h')); >- if (not ($header_smp eq '')) { >- # linux/autoconf.h contains the up/smp information >- $header_smp = direct_command( >- shell_string($gHelper{'echo'}) . ' ' >- . shell_string('#include <linux/autoconf.h>' . "\n" . $pattern >- . ' CONFIG_SMP') . ' | ' . shell_string($gHelper{'gcc'}) >- . ' ' . shell_string('-I' . $answer) . ' -E - | ' >- . shell_string($gHelper{'grep'}) . ' ' . shell_string($pattern)); >- chomp($header_smp); >- $header_smp =~ s/^$pattern (\S+).*$/$1/; >- $header_smp = ($header_smp eq '1') ? 'yes' : 'no'; >- if (not (lc($header_smp) eq lc($gSystem{'smp'}))) { >- if ($source eq 'user') { >- print wrap('The kernel defined by this directory of header files is ' >- . (($header_smp eq 'yes') ? 'multiprocessor' >- : 'uniprocessor') . ', while ' >- . 'your running kernel is ' >- . (($gSystem{'smp'} eq 'yes') ? 'multiprocessor' >- : 'uniprocessor') . '.' >- . "\n\n", 0); >- } >- return ''; >- } >- } >- >- if (not (-r $answer . '/asm/page.h')) { >- if ($source eq 'user') { >- print wrap('The path "' . $answer . '" is a kernel header file ' >- . 'directory, but it does not contain the file "asm/page.h" ' >- . 'as expected.' . "\n\n", 0); >- } >- return ''; >- } >- $header_page_offset = direct_command( >- shell_string($gHelper{'echo'}) . ' ' >- . shell_string('#define __KERNEL__' . "\n" . '#include <asm/page.h>' >- . "\n" . $pattern . ' __PAGE_OFFSET') . ' | ' >- . shell_string($gHelper{'gcc'}) . ' ' . shell_string('-I' . $answer) >- . ' -E - | ' . shell_string($gHelper{'grep'}) . ' ' >- . shell_string($pattern)); >- chomp($header_page_offset); >- $header_page_offset =~ s/^$pattern \(?0x([0-9a-fA-F]{8,}).*$/$1/; >- if ($header_page_offset =~ /[0-9a-fA-F]{8,}/) { >- # We found a valid page offset >- if (defined($gSystem{'page_offset'}) and >- not (lc($header_page_offset) eq lc($gSystem{'page_offset'}))) { >- if ($source eq 'user') { >- print wrap('The kernel defined by this directory of header files does ' >- . 'not have the same address space size as your running ' >- . 'kernel.' . "\n\n", 0); >- } >- return ''; >- } >- } >- > return $answer; > } >+ > $gAnswerSize{'headerdir'} = 20; > $gCheckAnswerFct{'headerdir'} = \&check_answer_headerdir; > >@@ -2722,35 +2581,8 @@ > $gcc_version = direct_command(shell_string($gHelper{'gcc'}) > . ' -dumpversion'); > chomp($gcc_version); >- if ($gcc_version =~ /^(egcs-)?(\d+(\.\d+)*)/) { >- $gSystem{'gcc_version'} = $2; >- } else { >- print wrap('Your compiler "' . $gHelper{'gcc'} . '" version "' . >- $gcc_version . '" is not supported ' . >- 'by this version of ' . vmware_product_name() . '.' . >- "\n\n", 0); >- return 'no'; >- } >- >- if (check_gcc_version($gSystem{'gcc_version'}) eq 'no') { >- return 'no'; >- } >- >- # When installing the modules, kernels 2.4+ setup a symlink to the kernel >- # source directory >- $headerdir = $cKernelModuleDir . '/preferred/build/include'; >- if (check_answer_headerdir($headerdir, 'default') eq '') { >- $headerdir = $cKernelModuleDir . '/' . $gSystem{'uts_release'} >- . '/build/include'; >- if (check_answer_headerdir($headerdir, 'default') eq '') { >- # Use a default usual location >- $headerdir = '/usr/src/linux/include'; >- } >- } >- get_persistent_answer('What is the location of the directory of C header ' >- . 'files that match your running kernel?', >- 'HEADER_DIR', 'headerdir', $headerdir); > >+ $headerdir = '/usr/src/linux/include'; > $gFirstModuleBuild = 0; > } > >@@ -2882,52 +2714,6 @@ > > if ($gOption{'compile'} == 1) { > db_add_answer('BUILDR_' . $name, 'yes'); >- } else { >- my @mod_list; >- >- print wrap('Trying to find a suitable ' . $name >- . ' module for your running kernel.' . "\n\n", 0); >- @mod_list = get_suitable_modules($mod_dir . '/binary'); >- while ($#mod_list > -1) { >- my $candidate = shift(@mod_list); >- my $modversion = shift(@mod_list); >- >- # Note: When using the force flag, >- # Non-versioned modules can load into a versioned kernel. >- # Versioned modules can load into a non-versioned kernel. >- # >- # Consequently, it is only safe to use the force flag if _both_ the >- # kernel and the module are versioned. >- # This is not always the case as demonstrated by bug 18371. >- >- if (try_module($name, >- $mod_dir . '/binary/' . $candidate . '/objects/' >- . $name . '.o', >- ($gSystem{'versioned'} eq 'yes') >- && ($modversion eq 'yes'), 1)) { >- print wrap('The module ' . $candidate . ' loads perfectly in the ' >- . 'running kernel.' . "\n\n", 0); >- return 'yes'; >- } >- } >- >- if ($gOption{'prebuilt'} == 1) { >- db_add_answer('BUILDR_' . $name, 'no'); >- print wrap('None of the pre-built ' . $name . ' modules for ' >- . vmware_product_name() . ' is suitable for your ' >- . 'running kernel.' . "\n\n", 0); >- return 'no'; >- } >- >- if (get_persistent_answer('None of the pre-built ' . $name . ' modules for ' >- . vmware_product_name() . ' is suitable ' >- . 'for your running kernel. Do you want this ' >- . 'program to try to build the ' . $name >- . ' module for your system (you need to have a ' >- . 'C compiler installed on your system)?', >- 'BUILDR_' . $name, 'yesno', 'yes') eq 'no') { >- return 'no'; >- } > } > > if (build_module($name, $mod_dir . '/source') eq 'no') {
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 32737
:
23927
|
24094
|
24095
|
24096
|
24131
|
24646
|
24647
|
24649
|
24650
|
24651
|
25235
|
25237
|
25238
|
25239
|
25279
|
25280
|
25281
|
25282
|
25283
|
25363
|
25453
|
25454
|
25497
|
26588
|
26635
|
26643
|
27538
|
30030
|
31314
|
31315
|
31317
|
31345
|
31346
|
31347
|
32935
|
33123
| 33124 |
33125
|
33356
|
36615