LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Fedora
User Name
Password
Fedora This forum is for the discussion of the Fedora Project.

Notices


Reply
  Search this Thread
Old 05-21-2004, 08:58 PM   #1
short101
Member
 
Registered: May 2004
Location: Aust.
Distribution: Debian
Posts: 424

Rep: Reputation: 30
Agere srpm and kernal headers


Hi all. I recently installe d fedora core 1 on my R40 thinkpad. My modem wasnt detected so I ran scanmodem from linmodems. I was then directed to the agere web site and downloaded the driver. They had a few rpms, but none for core 1, so I got the srpm. Then I installed the kernal source from my cd. In the reports from scanmodem, there is one that tells you how to compile drivers, and I followed that and then tried to install the driver, but I'm getting errors, Below is the instuctions I followed and the output fromm the terminal. If anyone can tell me where I went wrong or if there is an easier way to do it, then I'll be forever gratefull.


Configuration of the kernel-source is where almost all the Mistakes occur!!!
Here is a way to do it correctly (but read through EXCEPTIONAL CASES below).
1)Within kernel-source/ folder, browse the README file for general guidance.
It will relate that the command:
# make mrproper
cleans up leftovers from any previous usage .dot-files and the include/linux/ folder.
Additionally you may need to do an edit within Makefile, but ONLY that 4th line.
2) If necessary to edit, FIRST make a backup:
cp Makefile Makefile.backup
then edit ONLY the 4th line of Makefile to match the EXTRAVERSION of 2.4.22-1.2115.nptl
EXTRAVERSION = -
NEVER change anything else within the Makefile.

3) Set the dependencies of the current kernel.
For SuSE 9.0 and later, there is a command which does the following steps
# make cloneconfig && make dep
Also browse the excellent README.SuSE in the kernel-source/ folder
For other Distros, the following steps are necessary, within the kernel-source/ folder
copy the kernel-config file to .config
and DO SPECIFY that " . "
But where is it? For many Distros, it will be the file like
/boot/config-2.4.22-1.2115.nptl
matching the output of:
uname -r
Or it may be the target of a symbolic link: /boot/config -->
So
cp /boot/config-2.4.22-1.2115.nptl .config
For SuSE 8.0 and earlier versions it is:
cp /boot/vmlinuz.config .config
PLEASE do not omit that "." in .config as it is crucially necessary.
View .config with a text browser.
It is simply a listing of the code components used in the kernel and its modules:
#
# Automatically generated make config: don't edit
#
CONFIG_X86=y
# CONFIG_SBUS is not set
CONFIG_UID16=y
etc.

4) The .config file will be read during
# make oldconfig
which feeds its specifications through a process specifying
the SAME inter-dependencies previously used in compiling your kernel,
and generating fresh .dot-config files . They can be displayed with:
# ls -al

5) Though it may be redundant after "make mrproper", it will do no harm to:
make clean
5a) For the SuSe Linux versions 8.0 and previous , there will exist files:
/boot/vmlinuz.autoconf.h
/boot/vmlinuz.version.h
They MUST be copied as:
cp /boot/vmlinuz.autoconf.h /usr/src/linux/include/linux/autoconf.h
cp /boot/vmlinuz.version.h /usr/src/linux/include/linux/version.h

6) Now build kernel-headers with:
make dep
during which you can walk your dog, take a shower, have tea, etc.
7) Check for resultant FileNames.h with:
ls include/linux/
and
cat include/linux/version.h
to verify the version.







[root@localhost SRPMS]# rpmbuild --rebuild ageresoftmodembeta-2.1.0-2.src.rpm
Installing ageresoftmodembeta-2.1.0-2.src.rpm
Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.84896
+ umask 022
+ cd /usr/src/redhat/BUILD
+ LANG=C
+ export LANG
+ unset DISPLAY
+ cd /usr/src/redhat/BUILD
+ rm -rf AgereSoftModemBeta-2.1.0
+ /usr/bin/gzip -dc /usr/src/redhat/SOURCES/AgereSoftModemBeta-2.1.0.tar.gz
+ tar -xf -
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ cd AgereSoftModemBeta-2.1.0
++ /usr/bin/id -u
+ '[' 0 = 0 ']'
+ /bin/chown -Rhf root .
++ /usr/bin/id -u
+ '[' 0 = 0 ']'
+ /bin/chgrp -Rhf root .
+ /bin/chmod -Rf a+rX,g-w,o-w .
+ exit 0
Executing(%build): /bin/sh -e /var/tmp/rpm-tmp.65722
+ umask 022
+ cd /usr/src/redhat/BUILD
+ cd AgereSoftModemBeta-2.1.0
+ LANG=C
+ export LANG
+ unset DISPLAY
+ make all
Building Modem Controller Module for Agere Soft modem
In file included from /usr/src/linux-2.4.22-1.2115.nptl/include/asm/semaphore.h:39,
from /usr/src/linux-2.4.22-1.2115.nptl/include/linux/fs.h:202,
from /usr/src/linux-2.4.22-1.2115.nptl/include/linux/capability.h:17,
from /usr/src/linux-2.4.22-1.2115.nptl/include/linux/binfmts.h:4,
from /usr/src/linux-2.4.22-1.2115.nptl/include/linux/sched.h:10,
from agrmodem.c:30:
/usr/src/linux-2.4.22-1.2115.nptl/include/asm/system.h: In function `__set_64bit_var':
/usr/src/linux-2.4.22-1.2115.nptl/include/asm/system.h:189: warning: dereferencing type-punned pointer will break strict-aliasing rules
/usr/src/linux-2.4.22-1.2115.nptl/include/asm/system.h:189: warning: dereferencing type-punned pointer will break strict-aliasing rules
agrmodem.c: In function `x_do_gettimeofday':
agrmodem.c:198: warning: control reaches end of non-void function
agrmodem.c: In function `x_atomic_read':
agrmodem.c:311: warning: dereferencing type-punned pointer will break strict-aliasing rules
agrmodem.c: In function `x_atomic_set':
agrmodem.c:312: warning: dereferencing type-punned pointer will break strict-aliasing rules
agrmodem.c: In function `x_atomic_inc':
agrmodem.c:313: warning: dereferencing type-punned pointer will break strict-aliasing rules
agrmodem.c: In function `x_atomic_dec':
agrmodem.c:314: warning: dereferencing type-punned pointer will break strict-aliasing rules
agrmodem.c: In function `x_atomic_dec_and_test':
agrmodem.c:315: warning: dereferencing type-punned pointer will break strict-aliasing rules
In file included from /usr/src/linux-2.4.22-1.2115.nptl/include/linux/tqueue.h:19,
from /usr/src/linux-2.4.22-1.2115.nptl/include/linux/serialP.h:24,
from serial24.c:217:
/usr/src/linux-2.4.22-1.2115.nptl/include/asm/system.h: In function `__set_64bit_var':
/usr/src/linux-2.4.22-1.2115.nptl/include/asm/system.h:189: warning: dereferencing type-punned pointer will break strict-aliasing rules
/usr/src/linux-2.4.22-1.2115.nptl/include/asm/system.h:189: warning: dereferencing type-punned pointer will break strict-aliasing rules
serial24.c: In function `rs_close':
serial24.c:3061: error: invalid operands to binary ==
make: *** [serial24.a] Error 1
error: Bad exit status from /var/tmp/rpm-tmp.65722 (%build)


RPM build errors:
Bad exit status from /var/tmp/rpm-tmp.65722 (%build)
[root@localhost SRPMS]#

Sorry for the long post.

I've got a feeling that its the kernel headers that are making the errors and was hoping I could get away without having to compile the kernal as I am just blindly following what is in the text without really knowing what I'm doing. Please give detailed instructions if you have any ideas.
Cheers.
 
  


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
kernal source and c headers don't match shelbydz Linux - Software 2 10-04-2006 06:45 PM
kernal sources and headers BACTRATE Mandriva 2 04-18-2005 03:20 PM
Kernal modules on a Newly Compiled Kernal sethgeekx86 Slackware 4 05-04-2004 12:08 AM
How do you configure the kernal, overwriting the old version of the same kernal? sabaka Linux - Newbie 13 10-04-2003 11:00 AM
Help! Configuring Kernal failed, GRUB can't boot new kernal, help! sabaka Linux - Newbie 4 09-16-2003 10:12 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Fedora

All times are GMT -5. The time now is 03:58 PM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration