From mboxrd@z Thu Jan 1 00:00:00 1970 From: kristofer.hallin@gmail.com (Kristofer Hallin) Date: Sat, 13 Sep 2014 16:36:54 +0200 Subject: Makefile for a single source file In-Reply-To: References: Message-ID: To: kernelnewbies@lists.kernelnewbies.org List-Id: kernelnewbies.lists.kernelnewbies.org Is this part of the Eudyptula Challenge? On 13 Sep 2014 16:35, "Kevin Wilson" wrote: > Hi, > I have a single source file which I wrote, implementing a kernel > module: helloworld.c > > In order to built it, I prepared the following Makefile: > > obj-m += helloworld.o > > all: > make -C /lib/modules/$(shell uname -r)/build M=$(PWD) modules > > clean: > make -C /lib/modules/$(shell uname -r)/build M=$(PWD) clean > > > > Is it ok ? or should the obj-m parameter be *different* than the the > source file (without the *.o suffix) > (something like obj-m += hello.o ?) > > Regards, > Kevin > > _______________________________________________ > Kernelnewbies mailing list > Kernelnewbies at kernelnewbies.org > http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20140913/b798db79/attachment.html