LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 07-21-2005, 03:16 PM   #1
blahJake
LQ Newbie
 
Registered: Aug 2003
Location: Atlanta, GA or DeLand, FL
Distribution: Fedora Core 6, various for work
Posts: 16

Rep: Reputation: 0
trouble compiling modules against custom fedora core 4 kernel


///////////////////////////////////
// BACKGROUND //
///////////////////////////////////

ok, i'm trying to install ndiswrapper on my laptop, which is running Fedora Core 4 (via the upgrade feature, from Fedora Core 3) so i can use my linksys WPC54Gv2 wireless card (PCMCIA). i can create the kernel module and userspace utilities for it by using a simple 'make rpm'. however, the fedora core kernels are configured w/ 4K stacks instead of 8K stacks. this is a problem for ndiswrapper (which allows the use of windows wireless card drivers in linux) because many windows drivers won't work w/ 4K stacks. i assume this is my problem, as everything goes well until i load the module w/ the card in (freezes during runtime, kernel panics at boot time).

so, i got the src.rpm for the kernel and recreated the source tree as instructed in the fedora core 4 release notes. used their config and changed the stack size option (which is under Kernel Hacking). briefly:
rpm -Uvh kernel-2.6.12-1.1398_FC4.src.rpm
cd /usr/src/redhat/SPECS
rpmbuild -bp --target $(arch) kernel-2.6.spec
<go to source dir, get i686 config file into .config>
make oldconfig
make menuconfig (changed stack size only)
make rpm

this was all done on my desktop (running Fedora Core 3). moved the kernel rpm over to my laptop and installed. i can now boot this kernel (2.6.12-prep) w/out problems.

now, if i try to 'make rpm' for ndiswrapper, it says it needs /lib/modules/2.6.12-prep/build/Makefile, which doesn't exist. i've tried making this directory a symlink to the expanded source tree, which clearly has the makefile (the tree is present on the laptop, there just wasn't enough disk space to build it there).

when i first installed fedora core 4, i couldn't build against the current kernel due to the same error. this was fixed by installing the corresponding kernel-devel rpm.

i've examined the structure of the existing /lib/modules directories and attempted to mimic them manually (by creating symlinks), but have been unsuccessful.

///////////////////////////
// QUESTION //
///////////////////////////

what do i need to do to be able to compile the module against this new kernel that has no kernel-devel rpm to go with it? can i create this rpm somehow? can the appropriate /lib/modules directory be created from the source tree, src.rpm, or otherwise?

any advice, including pointers to resources, will be greatly appreciated.
 
Old 08-12-2005, 07:26 PM   #2
thewade
LQ Newbie
 
Registered: Aug 2005
Distribution: Fedora Core
Posts: 2

Rep: Reputation: 0
Different but the same

I am also trying to install ndiswrapper, except that I am using Fedora Core 3, the 2.6.13-rc4-RT-V0.7.52-13 kernel, and I am buildding from the ndiswrapper 1.2.1 tar.gz file, not the src rpm.

I try "sudo make rpm" but I get:
Quote:
[wade@transport ndiswrapper-1.2]$ sudo make rpm
mkdir -p ndiswrapper-1.2
for subdir in utils driver debian; do \
if test "$subdir" = .; then :; else \
test -d ndiswrapper-1.2/$subdir \
|| mkdir ndiswrapper-1.2/$subdir \
|| exit 1; \
fi; \
done
make -C driver distdir=../ndiswrapper-1.2/driver dist
make[1]: Entering directory `/home/wade/ndiswrapper-1.2/driver'
make[1]: Leaving directory `/home/wade/ndiswrapper-1.2/driver'
make -C utils distdir=../ndiswrapper-1.2/utils dist
make[1]: Entering directory `/home/wade/ndiswrapper-1.2/utils'
make[1]: Leaving directory `/home/wade/ndiswrapper-1.2/utils'
make -C debian distdir=../ndiswrapper-1.2/debian dist
make[1]: Entering directory `/home/wade/ndiswrapper-1.2/debian'
make[1]: Leaving directory `/home/wade/ndiswrapper-1.2/debian'
# Update version in dist rpm spec file - don't crash if it fails
sed -i "s/\%define\s\+ndiswrapper_version\s\+[^\}]\+\}/%define ndiswrapper_version 1.2\}/" ndiswrapper-1.2/ndiswrapper.spec
tar cfz ndiswrapper-1.2.tar.gz ndiswrapper-1.2
rpmbuild -ta ndiswrapper-1.2.tar.gz --define="ndiswrapper_version 1.2"
error: Failed build dependencies:
/lib/modules/2.6.13-rc4-RT-V0.7.52-13/build/Makefile is needed by ndiswrapper-1.2-1.i386
make: *** [rpm] Error 1
I then try "sudo pmbuild -ta ndiswrapper-1.2.tar.gz --define="ndiswrapper_version 1.2" -vv" and get:
Quote:
sudo rpmbuild -ta ndiswrapper-1.2.tar.gz --define="ndiswrapper_version 1.2" -vv
D: opening db environment /var/lib/rpm/Packages joinenv
D: opening db index /var/lib/rpm/Packages rdonly mode=0x0
D: locked db index /var/lib/rpm/Packages
D: ========== +++ ndiswrapper-1.2-1 i386/linux 0x0
D: opening db index /var/lib/rpm/Depends create mode=0x0
D: opening db index /var/lib/rpm/Basenames rdonly mode=0x0
D: opening db index /var/lib/rpm/Providename rdonly mode=0x0
D: Requires: /lib/modules/2.6.13-rc4-RT-V0.7.52-13/build/Makefile NO
D: package ndiswrapper-1.2-1.i386 has unsatisfied Requires: /lib/modules/2.6.13-rc4-RT-V0.7.52-13/build/Makefile
D: closed db index /var/lib/rpm/Depends
D: closed db index /var/lib/rpm/Providename
D: closed db index /var/lib/rpm/Basenames
D: closed db index /var/lib/rpm/Packages
D: closed db environment /var/lib/rpm/Packages
error: Failed build dependencies:
/lib/modules/2.6.13-rc4-RT-V0.7.52-13/build/Makefile is needed by ndiswrapper-1.2-1.i386
but clearly the Makefile is there:
Quote:
-rw-r--r-- wade wade rootbject_r:src_t /lib/modules/2.6.13-rc4-RT-V0.7.52-13/build/Makefile
so what is up (wo)man?
 
Old 08-13-2005, 10:40 AM   #3
thewade
LQ Newbie
 
Registered: Aug 2005
Distribution: Fedora Core
Posts: 2

Rep: Reputation: 0
New problem

I still have not figured out the "make rpm" problem, so I just did "make;sudo make install".
But now the module wont load due to an unknown symbol "get_current"!
Quote:
sudo modprobe ndiswrapper
FATAL: Error inserting ndiswrapper (/lib/modules/2.6.13-rc4-RT-V0.7.52-13/misc/ndiswrapper.ko): Unknown symbol in module, or unknown parameter (see dmesg)
dmesg gives me:
Quote:
ndiswrapper: Unknown symbol get_current
ndiswrapper: Unknown symbol get_current
ndiswrapper: Unknown symbol get_current
POOP!
 
Old 10-20-2006, 11:36 AM   #4
mmmax3d
LQ Newbie
 
Registered: Oct 2006
Posts: 2

Rep: Reputation: 0
Problem

Hi!

I have a HP Pavilion zd8179ea and have installed Linux Fedora on it. I am trying to make the wireless connection work. It has the Broadcom chipset. I followed the procedure and I have done all the steps right till I have reached the NDISWRAPPER steps. I am trying to enter the ¨make¨ command and the ¨make install¨ command but I get an error message. This is the error:

[root@localhost ndiswrapper-1.26]# make
make -C driver
make[1]: Entering directory `/home/user01/ndiswrapper-1.26/driver'
Can't find kernel build files in /lib/modules/2.6.18-1.2200.fc5smp/build;
give the path to kernel build directory with
KBUILD=<path> argument to make
make[1]: *** [prereq_check] Error 1
make[1]: Leaving directory `/home/user01/ndiswrapper-1.26/driver'
make: *** [all] Error 2
[root@localhost ndiswrapper-1.26]#

What is going wrong? I am doing something wrong? Please help me as soon as possible cause my work depends on that...

Thank you
 
Old 12-15-2006, 07:59 PM   #5
lebabyg
Member
 
Registered: Mar 2006
Location: UK
Distribution: Ubuntu Feisty
Posts: 272

Rep: Reputation: 30
wade, did you manage to find a solution to compiling ndiswrapper on a custom kernel, as i have exactly the same problem although mine is more problematic as i need to use the custom kernel to include the modules for my AMD processor and for my custom DSDT table (goes into thermal overrun otherwise) any help is very much appreciated. Cheers Graham
 
Old 12-15-2006, 10:08 PM   #6
studioj
Member
 
Registered: Oct 2006
Posts: 460

Rep: Reputation: 31
first i don't know one single thing about rpms but i think
repeat the build procedure this time doing it on the laptop so all the build directories are in the right place ??
don't even have to install it just create the build.
 
Old 12-16-2006, 06:54 AM   #7
lebabyg
Member
 
Registered: Mar 2006
Location: UK
Distribution: Ubuntu Feisty
Posts: 272

Rep: Reputation: 30
ndiswrapper compiles and builds fine on my custom kernel, i just can't insert the module as it says its in the wrong format. Any ideas??
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Custom kernel does not load modules Ankardo Linux - Newbie 2 06-10-2005 06:30 AM
Compiling Fedora Core Kernel betamike Fedora 2 03-04-2005 06:47 AM
Compiling 2.6.6 kernel in fedora core 2... SpItoS Linux - Newbie 4 01-17-2005 02:51 PM
custom slackpack kernel-modules sammyb Slackware 0 11-29-2004 03:41 PM
Kernel compiling under Fedora Core 2 midimarcus Linux - Newbie 7 07-08-2004 06:23 AM


All times are GMT -5. The time now is 10:57 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration