Linux Format forums Forum Index Linux Format forums
Help, discussion, magazine feedback and more
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Missing file in kernel tree

 
Post new topic   Reply to topic    Linux Format forums Forum Index -> Help!
View previous topic :: View next topic  
Author Message
Dutch_Master
LXF regular


Joined: Tue Mar 27, 2007 2:49 am
Posts: 2437

PostPosted: Sat Jan 19, 2013 2:43 pm    Post subject: Missing file in kernel tree Reply with quote

I've been trying to install the nVidia graphic driver installer in Debian Stable, with a freshly compiled 3.7.3 kernel. Unfortunately it complains about a missing file: /lib/modules/3.7.3/build/include/linux/version.h And indeed, it's not there in the tree. The 3.7.3 kernel is up and running, so it's not the issue. Can I copy the version.h file from a 2.6 kernel and what do I need to change for the nVidia installer to recognise the 3.7.3 kernel running.

TIA!
Back to top
View user's profile Send private message
guy
LXF regular


Joined: Thu Apr 07, 2005 1:07 pm
Posts: 1071
Location: Worcestershire

PostPosted: Sat Jan 19, 2013 4:42 pm    Post subject: Reply with quote

Try googling on Linux "version.h"

The version.h from an older kernel will not be good. I suspect that you'll need to create your own, to match your custom-complied kernel - I think that may mean a re-compile, I'm not sure: you'll probably understand more of the online discussions than I do.

Be careful with nvidia drivers. Debian defaults to the free Nouveau driver, but nvidia also offer their own blob. So you'll need to know which you are installing.

Don't know if that helps much.
_________________
Cheers,
Guy
The eternal help vampire
Back to top
View user's profile Send private message
roseway
LXF regular


Joined: Thu Jan 18, 2007 2:27 pm
Posts: 446

PostPosted: Sat Jan 19, 2013 6:32 pm    Post subject: Reply with quote

It sounds as though you haven't got the kernel headers installed.
_________________
Eric
Back to top
View user's profile Send private message
Dutch_Master
LXF regular


Joined: Tue Mar 27, 2007 2:49 am
Posts: 2437

PostPosted: Sun Jan 20, 2013 12:09 am    Post subject: Reply with quote

Thanks guys, much appreciated!

I know using an old version.h file for my new kernel isn't ideal, hence my question on what to change. I'm also aware about the Nouveau vs nVidia driver and I'll use the latter, blacklisting the free, non-3D versions. (I need the binary blob to run Google Earth, it won't work on the nv nor nouveau drivers...)

The kernel headers should be in place: I used a fresh kernel from the Linux.org guys and compiled it with the standard "configure && make && make install" sequence (OK, a little more involved to that, but it's not exactly the first kernel I've build Wink) Key is: it has worked on a 3.1.3 kernel before! (and I never had issues like this on the 2.6 kernels)
Back to top
View user's profile Send private message
nelz
Site admin


Joined: Mon Apr 04, 2005 12:52 pm
Posts: 8466
Location: Warrington, UK

PostPosted: Sun Jan 20, 2013 11:11 am    Post subject: Reply with quote

You don't use configuer && make && make install for a kernel, you use

Code:
make menuconfig
make all && make modules_instal && make install


Although I'm sure you know that.
_________________
"Insanity: doing the same thing over and over again and expecting different results." (Albert Einstein)
Back to top
View user's profile Send private message
Dutch_Master
LXF regular


Joined: Tue Mar 27, 2007 2:49 am
Posts: 2437

PostPosted: Sun Jan 20, 2013 12:44 pm    Post subject: Reply with quote

I do:
Code:
make xconfig
make && make modules && make modules_install && make install && mkinitramfs -o /boot/initrd.img-3.7.3 3.7.3 && update-grub
That's why I said "a little more involved" Razz Took about an hour Wink (AMD quad-core, 32 GB RAM)
Back to top
View user's profile Send private message
nelz
Site admin


Joined: Mon Apr 04, 2005 12:52 pm
Posts: 8466
Location: Warrington, UK

PostPosted: Sun Jan 20, 2013 4:40 pm    Post subject: Reply with quote

I build the initramfs into the kernel, it avoids extra files, extra GRUB configuration lines and the possibility of a mismatch between the kernel and initramfs.
_________________
"Insanity: doing the same thing over and over again and expecting different results." (Albert Einstein)
Back to top
View user's profile Send private message
Dutch_Master
LXF regular


Joined: Tue Mar 27, 2007 2:49 am
Posts: 2437

PostPosted: Mon Jan 21, 2013 3:25 am    Post subject: Reply with quote

I'd prefer to keep the initrd image outside the kernel, it's more flexible that way (and takes about the same space, I'd reckon). Anyway, any thoughts on the missing version.h file (and the contents thereof, for a 3.7.3 kernel) or should I report this as a bug?
Back to top
View user's profile Send private message
nelz
Site admin


Joined: Mon Apr 04, 2005 12:52 pm
Posts: 8466
Location: Warrington, UK

PostPosted: Mon Jan 21, 2013 9:49 am    Post subject: Reply with quote

I want reliability, not flexibility. If the initramfs was optional, I wouldn't be using it in the first place.

As for the file, that file does not exist on any of my systems, so it appears to no longer be used. However, I don't use the nvidia drivers so I've never had cause ot worry about it. Could a later release of the nvidia drivers help?
_________________
"Insanity: doing the same thing over and over again and expecting different results." (Albert Einstein)
Back to top
View user's profile Send private message
Ram
LXF regular


Joined: Thu Apr 07, 2005 10:44 pm
Posts: 1674
Location: Guisborough

PostPosted: Mon Jan 21, 2013 12:08 pm    Post subject: Reply with quote

Got loads in mine, 3 newest are

Code:

/usr/src/linux-headers-2.6.32-45-generic/include/linux
and
/usr/include/linux
both with these 2 lines
#define LINUX_VERSION_CODE 132640
#define KERNEL_VERSION(a,b,c) (((a) << 16) + ((b) << 8) + (c))


The other one is in
Code:

/usr/include/linux/dvb

with this in it.
/*
 * version.h
 *
 * Copyright (C) 2000 Holger Waechtler <holger@convergence.de>
 *                    for convergence integrated media GmbH
 *
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public License
 * as published by the Free Software Foundation; either version 2.1
 * of the License, or (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
 *
 */

#ifndef _DVBVERSION_H_
#define _DVBVERSION_H_

#define DVB_API_VERSION 5
#define DVB_API_VERSION_MINOR 1

#endif /*_DVBVERSION_H_*/

_________________

lubuntu LXDE 13.10 running on AMD Phenom II*4; ASUS Crosshair III Formula MB; 4 GB Ram.....
Back to top
View user's profile Send private message MSN Messenger
Dutch_Master
LXF regular


Joined: Tue Mar 27, 2007 2:49 am
Posts: 2437

PostPosted: Mon Jan 21, 2013 12:45 pm    Post subject: Reply with quote

@Nelz, the nVidia drivers I tried are the latest releases (late 2012)

@Ram: I too have a 2.6.32 kernel, but its contents is obviously incorrect for a 3.7.3 kernel. The dvb file is irrelevant, as it's not a kernel but an application. Thanks anyway!
Back to top
View user's profile Send private message
Ram
LXF regular


Joined: Thu Apr 07, 2005 10:44 pm
Posts: 1674
Location: Guisborough

PostPosted: Mon Jan 21, 2013 1:50 pm    Post subject: Reply with quote

Which driver are you using.

Similar issue but for Ubuntu here With 313.09 driver. 1 reply say use 313.18 driver.
_________________

lubuntu LXDE 13.10 running on AMD Phenom II*4; ASUS Crosshair III Formula MB; 4 GB Ram.....
Back to top
View user's profile Send private message MSN Messenger
Dutch_Master
LXF regular


Joined: Tue Mar 27, 2007 2:49 am
Posts: 2437

PostPosted: Mon Jan 21, 2013 2:48 pm    Post subject: Reply with quote

The 310 and 313 series aren't applicable for my GPU (GeForce 7 series) so it's the 304 and 173 series.
Back to top
View user's profile Send private message
cmcevoy



Joined: Wed Nov 30, 2005 4:06 pm
Posts: 70
Location: Ripon, UK

PostPosted: Sat Jan 26, 2013 4:11 pm    Post subject: Reply with quote

You need this snippet - obviously replace the kernel module with the version you have:
Code:
cd /lib/modules/3.7.1-17-desktop/build/include/
ln -s generated/uapi/linux
Back to top
View user's profile Send private message
Dutch_Master
LXF regular


Joined: Tue Mar 27, 2007 2:49 am
Posts: 2437

PostPosted: Sat Jan 26, 2013 5:36 pm    Post subject: Reply with quote

Many thanks, I'll give it a try later on Very Happy
Back to top
View user's profile Send private message
View previous topic :: View next topic  
Display posts from previous:   
Post new topic   Reply to topic    Linux Format forums Forum Index -> Help! All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Linux Format forums topic RSS feed 


Powered by phpBB © 2001, 2005 phpBB Group


Copyright 2011 Future Publishing, all rights reserved.


Web hosting by UKFast