Review your favorite Linux distribution.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
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!


  Search this Thread
Old 03-16-2009, 12:24 AM   #1
LQ Newbie
Registered: Mar 2009
Location: Michigan / United States
Distribution: Debian, MacOSX
Posts: 2

Rep: Reputation: 0
Question Need help understanding Makefile(s)

Hello to all, I'm trying to make several thing but I'm having issues I think because the files the Makefile references are in different locations. I'm running Debian 2.6.26-1-686. Here is a Makefile I'm having trouble with:

obj-m := fpi2002.o

KDIR := /lib/modules/$(shell uname -r)/build
PWD := $(shell pwd)
$(MAKE) -C $(KDIR) SUBDIRS=$(PWD) modules

install: fpi2002.ko
cp fpi2002.ko /lib/modules/$(shell uname -r)/kernel/drivers/serial/fpi2002.ko
depmod -a


This is the original file, I've tried editing KDIR to the path of kernel headers "/lib/modules/$(shell uname -r)/build/include" but then I get a message that there is no rule to make target modules. This may have been the wrong path to take that's why I've kept a backup of the original.(see above) Anyways I'm at a loss as I don't really understand the syntax of a makefile, my programming experience has been in the .Net environment.
Old 03-16-2009, 01:50 AM   #2
Senior Member
Registered: Jan 2008
Location: Urbana IL
Distribution: Slackware, Slacko,
Posts: 3,716
Blog Entries: 3

Rep: Reputation: 483Reputation: 483Reputation: 483Reputation: 483Reputation: 483
think you could just post a question how to get my pen to work on my tablet pc.and

Last edited by Drakeo; 03-16-2009 at 02:04 AM.


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
Is it mandatory to have the name of the makefile as 'Makefile' for kernal module comp narender.d Linux - Kernel 3 05-29-2009 06:26 AM
what is the meaning of Makefile,, cynthia_thomas Linux - General 3 12-08-2005 05:00 AM
Help in understanding Makefile rules cranium2004 Programming 2 03-11-2005 06:06 AM
how to get (makefile -f makefile )output into the textview widget in Pygtk sailu_mvn Programming 3 02-28-2005 03:57 AM
generate Makefile from without calling ./configure ? chris78 Programming 2 05-02-2004 12:23 PM > Forums > Linux Forums > Linux - Newbie

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

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