nV News Forums

 
 

nV News Forums (http://www.nvnews.net/vbulletin/index.php)
-   NVIDIA Linux (http://www.nvnews.net/vbulletin/forumdisplay.php?f=14)
-   -   Could not compile 'gcc-version-check.c' in my Debian box. (http://www.nvnews.net/vbulletin/showthread.php?t=163770)

ant 06-23-11 06:47 AM

Could not compile 'gcc-version-check.c' in my Debian box.
 
Hi!

I just upgraded a bunch of Debian packages for the day that seems to including X.org's libraries. I decided to recompile my NVIDIA driver after exiting X to console (use startx command to run my X) because of segfaults in my dmesg. Here is what I saw and did on (forum rejected my post with "The message you have entered is too short. Please lengthen your message to at least 1 characters." error -- HUH?): http://pastebin.com/MSqsD2Qz ...

It seems my X is OK when I continued in of aborting. Do I need to worry about that compilation error with GCC?

Thank you in advance. :)

ant 06-23-11 06:50 AM

Re: Could not compile 'gcc-version-check.c' in my Debian box.
 
1 Attachment(s)
Or see attached logs.txt if easier.

ant 07-01-11 12:35 PM

Re: Could not compile 'gcc-version-check.c' in my Debian box.
 
And again with today's updates:

# apt-get upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages have been kept back:
k3b k3b-data kamera kcalc kcharselect kdebase-bin kdebase-data
kdemultimedia-kio-plugins kfind kfloppy kget klipper kmix konqueror
konqueror-nsplugins konsole kppp kruler ksnapshot kwin
The following packages will be upgraded:
libfltk1.1 libgl1-mesa-dri libgl1-mesa-glx libglu1-mesa libsensors4
libthai-data libthai0 lm-sensors lynx lynx-cur xserver-common
xserver-xorg-core xserver-xorg-dev
13 upgraded, 0 newly installed, 0 to remove and 20 not upgraded.
Need to get 24.0 MB of archives.
After this operation, 254 kB of additional disk space will be used.
Do you want to continue [Y/n]?
Get:1 http://ftp.debian.org/debian/ testing/main xserver-common all 2:1.10.2-2 [1,203 kB]
Get:2 http://ftp.debian.org/debian/ testing/main libgl1-mesa-glx i386 7.10.3-3 [167 kB]
Get:3 http://ftp.debian.org/debian/ testing/main xserver-xorg-core i386 2:1.10.2-2 [1,677 kB]
Get:4 http://ftp.debian.org/debian/ testing/main libgl1-mesa-dri i386 7.10.3-3 [17.1 MB]
Get:5 http://ftp.debian.org/debian/ testing/main libfltk1.1 i386 1.1.10-6 [461 kB]
Get:6 http://ftp.debian.org/debian/ testing/main libglu1-mesa i386 7.10.3-3 [222 kB]
Get:7 http://ftp.debian.org/debian/ testing/main libsensors4 i386 1:3.3.0-4 [52.4 kB]
Get:8 http://ftp.debian.org/debian/ testing/main libthai-data all 0.1.15-2 [201 kB]
Get:9 http://ftp.debian.org/debian/ testing/main libthai0 i386 0.1.15-2 [43.3 kB]
Get:10 http://ftp.debian.org/debian/ testing/main xserver-xorg-dev i386 2:1.10.2-2 [305 kB]
Get:11 http://ftp.debian.org/debian/ testing/main lm-sensors i386 1:3.3.0-4 [123 kB]
Get:12 http://ftp.debian.org/debian/ testing/main lynx-cur i386 2.8.8dev.9-2 [2,195 kB]
Get:13 http://ftp.debian.org/debian/ testing/main lynx all 2.8.8dev.9-2 [221 kB]
Fetched 24.0 MB in 14s (1,641 kB/s)
Reading package fields... Done
Reading package status... Done
Retrieving bug reports... Done
Parsing Found/Fixed information... Done
Reading changelogs... Done
(Reading database ... 125217 files and directories currently installed.)
Preparing to replace xserver-common 2:1.10.2-1+wheezy1 (using .../xserver-common_2%3a1.10.2-2_all.deb) ...
Unpacking replacement xserver-common ...
Preparing to replace libgl1-mesa-glx 7.10.2-3 (using .../libgl1-mesa-glx_7.10.3-3_i386.deb) ...
Unpacking replacement libgl1-mesa-glx ...
dpkg: considering deconfiguration of libgl1-mesa-dri, which would be broken by installation of xserver-xorg-core ...
dpkg: yes, will deconfigure libgl1-mesa-dri (broken by xserver-xorg-core).
Preparing to replace xserver-xorg-core 2:1.10.2-1+wheezy1 (using .../xserver-xorg-core_2%3a1.10.2-2_i386.deb) ...
De-configuring libgl1-mesa-dri ...
Unpacking replacement xserver-xorg-core ...
Preparing to replace libgl1-mesa-dri 7.10.2-3 (using .../libgl1-mesa-dri_7.10.3-3_i386.deb) ...
Unpacking replacement libgl1-mesa-dri ...
Preparing to replace libfltk1.1 1.1.10-4 (using .../libfltk1.1_1.1.10-6_i386.deb) ...
Unpacking replacement libfltk1.1 ...
Preparing to replace libglu1-mesa 7.10.2-3 (using .../libglu1-mesa_7.10.3-3_i386.deb) ...
Unpacking replacement libglu1-mesa ...
Preparing to replace libsensors4 1:3.3.0-3 (using .../libsensors4_1%3a3.3.0-4_i386.deb) ...
Unpacking replacement libsensors4 ...
Preparing to replace libthai-data 0.1.15-1 (using .../libthai-data_0.1.15-2_all.deb) ...
Unpacking replacement libthai-data ...
Preparing to replace libthai0 0.1.15-1 (using .../libthai0_0.1.15-2_i386.deb) ...
Unpacking replacement libthai0 ...
Preparing to replace xserver-xorg-dev 2:1.10.2-1+wheezy1 (using .../xserver-xorg-dev_2%3a1.10.2-2_i386.deb) ...
Unpacking replacement xserver-xorg-dev ...
Preparing to replace lm-sensors 1:3.3.0-3 (using .../lm-sensors_1%3a3.3.0-4_i386.deb) ...
Unpacking replacement lm-sensors ...
Preparing to replace lynx-cur 2.8.8dev.8-1 (using .../lynx-cur_2.8.8dev.9-2_i386.deb) ...
update-alternatives: using /usr/bin/elinks to provide /usr/bin/www-browser (www-browser) in auto mode.
Unpacking replacement lynx-cur ...
Preparing to replace lynx 2.8.8dev.8-1 (using .../lynx_2.8.8dev.9-2_all.deb) ...
Unpacking replacement lynx ...
Processing triggers for man-db ...
Processing triggers for menu ...
Setting up xserver-common (2:1.10.2-2) ...
Setting up libgl1-mesa-glx (7.10.3-3) ...
Setting up xserver-xorg-core (2:1.10.2-2) ...
Setting up libgl1-mesa-dri (7.10.3-3) ...
Setting up libfltk1.1 (1.1.10-6) ...
Setting up libglu1-mesa (7.10.3-3) ...
Setting up libsensors4 (1:3.3.0-4) ...
Setting up libthai-data (0.1.15-2) ...
Setting up libthai0 (0.1.15-2) ...
Setting up xserver-xorg-dev (2:1.10.2-2) ...
Setting up lm-sensors (1:3.3.0-4) ...
Setting up lynx-cur (2.8.8dev.9-2) ...
Installing new version of config file /etc/lynx-cur/lynx.cfg ...
update-alternatives: using /usr/bin/lynx to provide /usr/bin/www-browser (www-browser) in auto mode.
Setting up lynx (2.8.8dev.9-2) ...
Processing triggers for menu ...
localepurge: Disk space freed in /usr/share/locale: 2480 KiB
localepurge: Disk space freed in /usr/share/man: 0 KiB
localepurge: Disk space freed in /usr/share/gnome/help: 0 KiB
localepurge: Disk space freed in /usr/share/omf: 0 KiB
localepurge: Disk space freed in /usr/share/doc/kde/HTML: 0 KiB

Total disk space freed by localepurge: 2480 KiB

ant 07-10-11 12:16 PM

Re: Could not compile 'gcc-version-check.c' in my Debian box.
 
I tried installing: libc-dev-bin libc6-dev libklibc-dev linux-libc-dev gcc-4.3-source gcc-4.3 gcc-4.3-base packages through apt-get, but they did not help (same results).

I also tried gcc-4.3-multilib package (is this required too?), but got dependency errors:
# apt-get install gcc-4.3-multilib
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
gcc-4.3-multilib : Depends: gcc-4.3-base (= 4.3.5-4) but 4.3.5-5 is to be installed
Depends: gcc-4.3 (= 4.3.5-4) but 4.3.5-5 is to be installed

:(

dk75 07-17-11 03:13 AM

Re: Could not compile 'gcc-version-check.c' in my Debian box.
 
1 Attachment(s)
Same thing there.
LinuxMint DebianEdition, testing repository.
It was good 2 month ago but now I must ignore "gcc-version-check.c" error in order to compile/install new driver.

PS: I've done system update yesterday and that changed glx symlinks so I've done new driver installation moment ago and it was no "gcc-version-check.c" compilation error - so debian thing.
And I've worked with driver compiled with that error for a month, so if You are sure that your GCC install is good then it is not an real issue.

ant 07-17-11 08:18 AM

Re: Could not compile 'gcc-version-check.c' in my Debian box.
 
Quote:

Originally Posted by dk75 (Post 2456625)
Same thing there.
LinuxMint DebianEdition, unstable repository.
It was good 2 month ago but now I must ignore "gcc-version-check.c" error in order to compile/install new driver.

PS: I've done system update yesterday and that changed glx symlinks so I've done new driver installation moment ago and it was no "gcc-version-check.c" compilation error - so debian thing.
And I've worked with driver compiled with that error for a month, so if You are sure that your GCC install is good then it is not an real issue.

Finally, someone else has the same problem. Whew.

As for my GCC installation, it should be good. How can I check?

dk75 07-17-11 03:23 PM

Re: Could not compile 'gcc-version-check.c' in my Debian box.
 
Didn't it compiled driver without error?
Did system update removed some GCC component?
Didn't compiler worked before system update?

If your system update didn't changed you default compiler (like from gcc 4.4 to gcc 4.6) then it should be ok.

You could search for gcc, g++, gcov, cpp and whatever they are same release and revision:
Code:

:~$ gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/lib/x86_64-linux-gnu/gcc/x86_64-linux-gnu/4.6.1/lto-wrapper
Target: x86_64-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Debian 4.6.1-1' --with-bugurl=file:///usr/share/doc/gcc-4.6/README.Bugs --enable-languages=c,c++,fortran,objc,obj-c++,go --prefix=/usr --program-suffix=-4.6 --enable-shared --enable-multiarch --with-multiarch-defaults=x86_64-linux-gnu --enable-linker-build-id --with-system-zlib --libexecdir=/usr/lib/x86_64-linux-gnu --without-included-gettext --enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.6 --libdir=/usr/lib/x86_64-linux-gnu --enable-nls --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --enable-plugin --enable-objc-gc --with-arch-32=i586 --with-tune=generic --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu
Thread model: posix
gcc version 4.6.1 (Debian 4.6.1-1)
:~$
:~$ g++ -v
Using built-in specs.
COLLECT_GCC=g++
COLLECT_LTO_WRAPPER=/usr/lib/x86_64-linux-gnu/gcc/x86_64-linux-gnu/4.6.1/lto-wrapper
Target: x86_64-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Debian 4.6.1-1' --with-bugurl=file:///usr/share/doc/gcc-4.6/README.Bugs --enable-languages=c,c++,fortran,objc,obj-c++,go --prefix=/usr --program-suffix=-4.6 --enable-shared --enable-multiarch --with-multiarch-defaults=x86_64-linux-gnu --enable-linker-build-id --with-system-zlib --libexecdir=/usr/lib/x86_64-linux-gnu --without-included-gettext --enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.6 --libdir=/usr/lib/x86_64-linux-gnu --enable-nls --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --enable-plugin --enable-objc-gc --with-arch-32=i586 --with-tune=generic --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu
Thread model: posix
gcc version 4.6.1 (Debian 4.6.1-1)
:~$
:~$ gcov -v
gcov (Debian 4.6.1-1) 4.6.1
Copyright (C) 2011 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE.

:~$
:~$ cpp --version
cpp (Debian 4.6.1-1) 4.6.1
Copyright (C) 2011 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

:~$

As you can see everything is from one release.

ant 07-17-11 03:39 PM

Re: Could not compile 'gcc-version-check.c' in my Debian box.
 
Quote:

Originally Posted by dk75 (Post 2456793)
Didn't it compiled driver without error?
Did system update removed some GCC component?
Didn't compiler worked before system update?

If your system update didn't changed you default compiler (like from gcc 4.4 to gcc 4.6) then it should be ok.

You could search for gcc, g++, gcov, cpp and whatever they are same release and revision:

...

As you can see everything is from one release.

Here's mine:
Code:

$ gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/lib/i386-linux-gnu/gcc/i486-linux-gnu/4.6.1/lto-wrapper
Target: i486-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Debian 4.6.1-1' --with-bugurl=file:///usr/share/doc/gcc-4.6/README.Bugs --enable-languages=c,c++,fortran,objc,obj-c++,go --prefix=/usr --program-suffix=-4.6 --enable-shared --enable-multiarch --with-multiarch-defaults=i386-linux-gnu --enable-linker-build-id --with-system-zlib --libexecdir=/usr/lib/i386-linux-gnu --without-included-gettext --enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.6 --libdir=/usr/lib/i386-linux-gnu --enable-nls --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --enable-plugin --enable-objc-gc --enable-targets=all --with-arch-32=i586 --with-tune=generic --enable-checking=release --build=i486-linux-gnu --host=i486-linux-gnu --target=i486-linux-gnu
Thread model: posix
gcc version 4.6.1 (Debian 4.6.1-1)

$ g++ -v
Using built-in specs.
COLLECT_GCC=g++
COLLECT_LTO_WRAPPER=/usr/lib/i386-linux-gnu/gcc/i486-linux-gnu/4.6.1/lto-wrapper
Target: i486-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Debian 4.6.1-1' --with-bugurl=file:///usr/share/doc/gcc-4.6/README.Bugs --enable-languages=c,c++,fortran,objc,obj-c++,go --prefix=/usr --program-suffix=-4.6 --enable-shared --enable-multiarch --with-multiarch-defaults=i386-linux-gnu --enable-linker-build-id --with-system-zlib --libexecdir=/usr/lib/i386-linux-gnu --without-included-gettext --enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.6 --libdir=/usr/lib/i386-linux-gnu --enable-nls --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --enable-plugin --enable-objc-gc --enable-targets=all --with-arch-32=i586 --with-tune=generic --enable-checking=release --build=i486-linux-gnu --host=i486-linux-gnu --target=i486-linux-gnu
Thread model: posix
gcc version 4.6.1 (Debian 4.6.1-1)

$ gcov -v
gcov (Debian 4.6.1-1) 4.6.1
Copyright (C) 2011 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE.

$ cpp --version
cpp (Debian 4.6.1-1) 4.6.1
Copyright (C) 2011 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

I was able to compile without any errors in the past before I started this forum thread. I don't know if system update removed some GCC component. Compiler worked before whatever system update. The problem is I rarely update/recompile my NVIDIA binary driver and I do apt-get update and upgrade daily, so who knows when exactly happened. :(

dk75 07-17-11 04:03 PM

Re: Could not compile 'gcc-version-check.c' in my Debian box.
 
whaa, you compile your own kernel or it is unstable repository kernel compiled with gcc 4.6?
Because nVidia driver as a kernel module needs to be compiled with this same version of compiler as a kernel.

That's my kernel and I need to change GCC to 4.4 every time when I compile nVidia driver:
Code:

:~$ cat /proc/version
Linux version 2.6.39-2-amd64 (Debian 2.6.39-3) (ben@decadent.org.uk) (gcc version 4.4.6 (Debian 4.4.6-6) ) #1 SMP Tue Jul 5 02:51:22 UTC 2011


ant 07-17-11 04:36 PM

Re: Could not compile 'gcc-version-check.c' in my Debian box.
 
Quote:

Originally Posted by dk75 (Post 2456819)
whaa, you compile your own kernel or it is unstable repository kernel compiled with gcc 4.6?
Because nVidia driver as a kernel module needs to be compiled with this same version of compiler as a kernel.

That's my kernel and I need to change GCC to 4.4 every time when I compile nVidia driver:
Code:

:~$ cat /proc/version
Linux version 2.6.39-2-amd64 (Debian 2.6.39-3) (ben@decadent.org.uk) (gcc version 4.4.6 (Debian 4.4.6-6) ) #1 SMP Tue Jul 5 02:51:22 UTC 2011


On my old Debian box, I don't compile Kernels.

dk75 07-18-11 03:32 AM

Re: Could not compile 'gcc-version-check.c' in my Debian box.
 
So, if you have standard kernel then it is probably compiled with gcc 4.4 ( cat /proc/version to check) so it would be wise to change your's gcc from 4.6 to 4.4 before installing nVidia driver.

ant 07-18-11 07:17 AM

Re: Could not compile 'gcc-version-check.c' in my Debian box.
 
Quote:

Originally Posted by dk75 (Post 2457034)
So, if you have standard kernel then it is probably compiled with gcc 4.4 ( cat /proc/version to check) so it would be wise to change your's gcc from 4.6 to 4.4 before installing nVidia driver.

Here you go:
$ cat /proc/version
Linux version 2.6.32-5-686 (Debian 2.6.32-35) (dannf@debian.org) (gcc version 4.3.5 (Debian 4.3.5-4) ) #1 SMP Mon Jun 13 04:13:06 UTC 2011

I used "CC=gcc-4.3 sh /storage/SharedFiles/linux/drivers/NVIDIA-Linux-x86-275.09.07.run" to compile my NVIDIA driver with GCC v4.3.


All times are GMT -5. The time now is 05:45 AM.

Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Copyright 1998 - 2014, nV News.