Welcome to SparkyLinux forums
Zapraszamy również na polsko-języczne Forum https://forum.linuxiarze.pl

nVidia module =>gcc 5.4 and Sparky kernel 4.9(4.8) =>gcc 6.3

Started by leoDZ, April 23, 2017, 12:36:02 PM

Previous topic - Next topic

leoDZ

Hello.
I can't install nVidia driver bcz it was built with gcc 5.4  but linux kernel was built with gcc 6.3.
My last video driver version was released 2014. And my video drivers has no itself in repos.
I think I should download sparky  with kernel built with gcc 5.4. Am I right ?
Thanks.

paxmark1

More info please. 
What exact type is your actual video card?

"inxi" if installed is one way to send info to forums in a short complete reproducible way. 

Or  https://wiki.debian.org/HowToIdentifyADevice/PCI
https://wiki.debian.org/NvidiaGraphicsDrivers

example of "inxi -v 2" 

inxi -v 2
System:    Host: raunes Kernel: 4.9.0-2-amd64 x86_64 (64 bit) Desktop: LXQt Distro: Debian GNU/Linux 9 (stretch)
Machine:   Device: desktop Mobo: Gigabyte model: H81M-S2H GSM v: x.x UEFI: American Megatrends v: F2 date: 08/11/2015
CPU:       Dual core Intel Core i3-4170 (-HT-MCP-) speed/max: 2912/3700 MHz
Graphics:  Card: Intel 4th Generation Core Processor Family Integrated Graphics Controller
           Display Server: X.Org 1.19.2 driver: intel Resolution: 1920x1080@60.00hz
           GLX Renderer: Mesa DRI Intel Haswell GLX Version: 3.0 Mesa 13.0.6
Network:   Card: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller driver: r8169
Drives:    HDD Total Size: 2008.4GB (17.4% used)
           ID-1: model: ST2000DM001
           ID-2: model: USB_Flash_Drive


Note: above is not my Sparky machine, but a Debian testing one presently running, minus the Sparky add ons. 
Search forum for "More info easier via inxi"    If requested -  no inxi, no help for you by  me.

leoDZ

Thanks for ur tying to help me  ::)
apt-get install inxi
says there is no that app in repos

root@bonfire:/home/leo# lspci | grep VGA
01:00.0 VGA compatible controller: NVIDIA Corporation G73M [Quadro NVS 300M] (rev a1)


I read recently if linux kernel built with higher gcc I have to install gcc I need and make simlinks.
I can recall there was talking about gcc and g++.
How can I install gcc 5.4 and g++ (I don't know whether I must ?) and make symlinks to gcc 6.3 and g++ ?

leoDZ

I found really  interesting page "how to use different versions of gcc (g++)"
Quote

You need to let update-alternatives to know that you have 2 C/C++ compilers, create a record for each one, and then configure which one you want to use. This is done with the following:

sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.7 60 --slave /usr/bin/g++ g++ /usr/bin/g++-4.7
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.8 40 --slave /usr/bin/g++ g++ /usr/bin/g++-4.8
sudo update-alternatives --config gcc

From this point forward, the only thing required when switching compilers is this command:

sudo update-alternatives --config gcc

Source: http://charette.no-ip.com:81/programming/2011-12-24_GCCv47/.
but I add repos from here https://launchpad.net/~ubuntu-toolchain-r/+archive/ubuntu/test
and then
apt-get says there is no gcc 5.4 and g++ 5.4  >:(

So how should I install gcc 5.4 and g++ 5.4 ?

btw nvidia installer said me that in my SL installed gcc 6.3 , but it's lie
root@bonfire:/home/leo# which gcc g++
/usr/bin/gcc
/usr/bin/g++


root@bonfire:/home/leo# gcc --version
gcc (Debian 6.2.1-5) 6.2.1 20161124
Copyright (C) 2016 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.

root@bonfire:/home/leo# g++ --version
g++ (Debian 6.2.1-5) 6.2.1 20161124
Copyright (C) 2016 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 hope nvidia installer didn't lie about gcc it need (5.4)

paxmark1

You are doing things I can't - don't want to do.  You will have fairly new and stable C libraries all set up in Debian testing, which is what Sparky is based on, Sparky just automatically adds in the availability of non-free binaries and outside of Debian sources - PPA's of wine, etc. and some small tweaks. 

https://wiki.debian.org/GCC5      ## Note, when this hit unstable in April 2015, it was a very rough time there.  It has settled down.
https://wiki.debian.org/GCC6

What are you using now - Ubuntu?  inxi is available for Debian and therefore also for Sparky.  the lspci and discover sections in the  https://wiki.debian.org/HowToIdentifyADevice/PCI I posted earlier should have been used to let us know what you have.  We do not know your OS or your card.

For the things you are appear to be interested in doing, you will have the exact same tools in Debian Testing and any Sparky flavor you choose.  gcc-6-base is  (NOTE: automatically installed)
paxmark@raunes:~$ aptitude show gcc-6-base
Package: gcc-6-base                     
Version: 6.3.0-14
New: yes
State: installed
Automatically installed: yes


and gcc-5-base There is some things happening due to the freeze.  What I have is 5.4.1.4 - but at this time maybe only gcc-6-base is available.

Information for all packages in Debian is available online at    https://packages.debian.org/testing/    or just use search engines "debian package "blah" testing to find. 

If all you really want is to get your newer nvidia card to work - Sparky or testing are a good start. 
Package: nvidia-driver-bin               
Version: 375.39-1
State: not installed
Priority: optional
  which is now in testing is from late February 2017 - it is the Debian non-free binary all set to go.  Just have non-free sources available (which happens in Sparky) and "apt-get install nvidia-driver-bin"  It will work or it won't.  You will not have to mess with comiling stuff.

If you really want to get into compiling and gcc and libraries, you will have a much better knowledge base and irc support areas if you go with Debian testing. 

So what is it that you really want to do, find a good distro to support a new nvidia card or learn the basis at a deep level of linux.  Sparky and Debian testing are both quite good for the first - I would go with Sparky. Debian testing and a whole lot of reading and possibly some classes for the second. 

But please, please, please, do not add ubuntu ppa's to Sparky or Debian, it usually results in a FrankenDebian and no one will help you with it, for more info read "Don't Break Debian"


Search forum for "More info easier via inxi"    If requested -  no inxi, no help for you by  me.

leoDZ

QuoteWe do not know your OS or your card.
Sparky
don't you noticed  ?
root@bonfire:/home/leo# lspci | grep VGA
01:00.0 VGA compatible controller: NVIDIA Corporation G73M [Quadro NVS 300M] (rev a1)


Quoteinxi is available for Debian and therefore also for Sparky.
no. Out of box my apt-get can't install inxi

QuoteNote, when this hit unstable in April 2015
I don't wanna use gcc5 instead of gcc6.
I just wanna switch from gcc6 to gcc5 , install my driver nvidia-xxx... .run and switch gcc back.
As far as I told my driver don't wanna install because of it was built with gcc 5.

pavroo

     inxi is available for Debian and therefore also for Sparky.

no. Out of box my apt-get can't install inxi

There is inxi available in Debian's stable, testing and unstable repos.
Did you refresh package list before trying to install it?
Nothing is easy as it looks. Danielle Steel
Join #sparkylinux.org at [url="//irc.libera.chat"]irc.libera.chat[/url]

leoDZ

why do you wanna know about my hardware via  inxi  ?
I can generate full list of my hardware with Everest under Windows.
And lspci works perfect.

leoDZ


View the most recent posts on the forum