LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
LinkBack Search this Thread
Old 07-16-2003, 09:28 AM   #1
TheOneAndOnlySM
Member
 
Registered: Jul 2003
Location: Dallas, TX
Distribution: Ubuntu 10.04 LTS
Posts: 987

Rep: Reputation: 30
Intel driver will not find kernel


I'm trying to install a driver for my Intel Pro/100 VE ethernet card but when i do a makefile, the terminal outputs a message saying that it cannot find my kernel source. In redhat 9 with kernel 2.4.20-18.9, where is the source and how should i modify the following (called Makefile) to search that path?

(i think this is the only part of the program needed to correct my problem, near the bottom)

# Configuration Section

# debug
# CFLAGS += -g
#extra warnings
#CFLAGS += -W -Wfloat-equal -Wtraditional -Wundef -Wshadow -Wpointer-arith\
# -Wbad-function-cast -Wcast-qual -Wcast-align -Wwrite-strings -Wconversion\
#-Wsign-compare -Waggregate-return -Wmissing-prototypes -Wmissing-declarations\
# -Wpacked -Wpadded -Wredundant-decls -Wnested-externs -Wunreachable-code -Winline

##############################################################################
# Driver files

# core driver files
TARGET := e100.o
CFILES = e100_main.c e100_eeprom.c e100_config.c e100_phy.c e100_kcompat.c e100_test.c
HFILES = e100.h e100_config.h e100_phy.h e100_kcompat.h e100_ucode.h

# Man
MAN_FILE = e100.7

# pick an appropriate MAN path
MAN_CFG := /etc/man.config
MAN_TYPE := man7
MSP := $(shell [ -e $(MAN_CFG) ] && grep -e "^MANPATH[^_]" $(MAN_CFG) | awk '{print $$2}')
ifeq (,$(MSP))
MSP := /usr/share/man \
/usr/man
endif
# prune the list down to only values that exist
test_dir = $(shell [ -e $(dir)/$(MAN_TYPE) ] && echo $(dir))
MSP := $(foreach dir, $(MSP), $(test_dir))
# we will use the first valid entry in the search path
MAN_PATH := $(firstword $(MSP))
ifeq (,$(MAN_PATH))
MAN_PATH := /usr/man
endif
MAN_INSTDIR=$(MAN_PATH)/$(MAN_TYPE)

ifeq ($(ARCH),alpha)
CFLAGS += -ffixed-8 -mno-fp-regs
endif

###########################################################################
# Environment tests

# Kernel Search Path
# All the places we look for kernel source
KSP := /lib/modules/$(shell uname -r)/build \
/usr/src/linux-$(shell uname -r) \
/usr/src/linux-$(shell uname -r | sed 's/-.*//') \
/usr/src/kernel-headers-$(shell uname -r) \
/usr/src/kernel-source-$(shell uname -r) \
/usr/src/linux-$(shell uname -r | sed 's/\([0-9]*\.[0-9]*\)\..*/\1/') \
/usr/src/linux

# prune the list down to only values that exist
# and have an include/linux sub-directory
test_dir = $(shell [ -e $(dir)/include/linux ] && echo $(dir))
KSP := $(foreach dir, $(KSP), $(test_dir))

# we will use this first valid entry in the search path
KSRC := $(firstword $(KSP))

ifeq (,$(KSRC))
$(error Linux kernel source not found)
endif
 
Old 07-16-2003, 09:36 AM   #2
ksgill
Senior Member
 
Registered: Apr 2003
Location: Toronto, Canada
Distribution: Ubuntu Jaunty (9.04)
Posts: 1,044

Rep: Reputation: 45
Well, it cant find your kernel-source which is different from kernel and is usually located in /usr/src. You can find the source for your kernel here:

http://ftp.freshrpms.net/pub/freshrp...kernel-source/

find the correct one, install it and then update your makefile( there should be a line in Makefile like this one:
Kernel-source: /usr/include/whatver..
change it to your: /usr/kernel-source/include ;
note that it should point to include folder of your kernel source.
From then on it should be easy.
 
  


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
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Cant find driver for Intel PRO/Wireless 2100 3A MiniPCI Adapter ankursaxena Red Hat 1 03-02-2005 01:09 PM
Cant find driver for Intel PRO/Wireless 2100 3A MiniPCI Adapter ankursaxena Linux - Wireless Networking 1 02-27-2005 12:00 PM
How to find Intel Ham modem driver Sleepypig Linux - Hardware 1 02-14-2005 05:02 AM
Intel ADI 198x Driver needs kernel-source spage0506 Linux - Hardware 2 01-31-2005 08:26 AM
Intel Ham 5628 Driver for 2.6 Kernel alexan Linux - Hardware 0 10-14-2004 04:22 AM


All times are GMT -5. The time now is 06:52 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