summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app-emulation/vmware-workstation/files/3.2.1.2242/vmware-config.pl-gcc-generalized.patch')
-rw-r--r--app-emulation/vmware-workstation/files/3.2.1.2242/vmware-config.pl-gcc-generalized.patch60
1 files changed, 60 insertions, 0 deletions
diff --git a/app-emulation/vmware-workstation/files/3.2.1.2242/vmware-config.pl-gcc-generalized.patch b/app-emulation/vmware-workstation/files/3.2.1.2242/vmware-config.pl-gcc-generalized.patch
new file mode 100644
index 000000000000..f2a0239f4c7b
--- /dev/null
+++ b/app-emulation/vmware-workstation/files/3.2.1.2242/vmware-config.pl-gcc-generalized.patch
@@ -0,0 +1,60 @@
+--- bin/vmware-config.pl.orig 2002-12-16 12:15:35.000000000 -0500
++++ bin/vmware-config.pl 2002-12-16 13:30:29.000000000 -0500
+@@ -1487,21 +1487,21 @@
+ }
+
+ $gcc_version = direct_command(shell_string($gHelper{'gcc'})
+- . ' --version');
++ . ' -dumpversion');
+ chomp($gcc_version);
+ @gcc_version_num = split(/\./, $gcc_version);
+- if ($gcc_version_num[0] >= 3) {
+- if (get_answer('As of April 2002, gcc version 3 and later is not yet a '
+- . 'supported compiler by the Linux kernel development '
+- . 'team. Have a look at Documentation/Changes in your '
+- . 'kernel source directory to get the correct compiler '
+- . 'installed. Do you want to go with compiler "'
+- . $gHelper{'gcc'} . '" version ' . $gcc_version . '?',
+- 'yesno', 'no') eq 'no') {
+- print wrap('Unable to continue.' . "\n\n", 0);
+- module_error();
+- }
+- }
++# if ($gcc_version_num[0] >= 3) {
++# if (get_answer('As of April 2002, gcc version 3 and later is not yet a '
++# . 'supported compiler by the Linux kernel development '
++# . 'team. Have a look at Documentation/Changes in your '
++# . 'kernel source directory to get the correct compiler '
++# . 'installed. Do you want to go with compiler "'
++# . $gHelper{'gcc'} . '" version ' . $gcc_version . '?',
++# 'yesno', 'no') eq 'no') {
++# print wrap('Unable to continue.' . "\n\n", 0);
++# module_error();
++# }
++# }
+
+ # When installing the modules, kernels 2.4+ setup a symlink to the kernel
+ # source directory
+@@ -1526,6 +1526,22 @@
+ module_error();
+ }
+
++ my $makefile="$build_dir/$name-only/Makefile";
++ my $gcc_replace="";
++ $gcc_version = direct_command(shell_string($gHelper{'gcc'})
++ . ' -dumpversion');
++ chomp($gcc_version);
++ @gcc_version_num = split(/\./, $gcc_version);
++ if ($gcc_version_num[0] >= 3) {
++ $gcc_replace="-e 's:-malign-:-falign-:g'";
++ }
++ system("/usr/bin/cp $makefile $makefile.old");
++ system("/usr/bin/sed" .
++ " -e 's:CC) --version:CC) -dumpversion:'" .
++ " -e 's:-m486:-march=i486:'" .
++ " -e 's:-Wall -Wstrict-prototypes::'" .
++ " $gcc_replace" .
++ " $makefile.old > $makefile");
+ print wrap('Building the ' . $name . ' module.' . "\n\n", 0);
+ if (system(shell_string($gHelper{'make'}) . ' -C ' . shell_string($build_dir . '/' . $name . '-only') . ' auto-build ' . (($gSystem{'smp'} eq 'yes') ? 'SUPPORT_SMP=1 ' : '') . shell_string('HEADER_DIR=' . db_get_answer('HEADER_DIR')) . ' ' . shell_string('CC=' . $gHelper{'gcc'}) . ' ' . shell_string('GREP=' . $gHelper{'grep'}))) {
+ print wrap('Unable to build the ' . $name . ' module.' . "\n\n", 0);