dcsimg
How to get something like uname -r into managed makefile project (CDT) under linux
0 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Johann_Horvat
Posted On:   Friday, April 20, 2007 12:04 PM

Dear Jguru People, I have a C Project, which target is a executable for linux x86 and a kernel module for 2.6. I want to try to get it compile under eclipse/cdt... My existing makefile looks like this: obj-m := rt_process.o KDIR := /lib/modules/$(shell uname -r)/build PWD := $(shell pwd) EXTRA_CFLAGS := -I/usr/realtime/include -I/usr/include/ -ffast-math -mhard-float default: $(MAKE) -C $(KDIR) SUBDIRS=$(PWD) modules gcc -o scope scope.c clean: rm *.o rm *.ko As you can see I use bash specific things like $(shell uname -r) to determine the running kernel. How can I achieve this with the project   More>>

Dear Jguru People,


I have a C Project, which target is a executable for linux x86 and a kernel module for 2.6. I want to try to get it compile under eclipse/cdt...
My existing makefile looks like this:

			
obj-m := rt_process.o

KDIR := /lib/modules/$(shell uname -r)/build
PWD := $(shell pwd)
EXTRA_CFLAGS := -I/usr/realtime/include -I/usr/include/ -ffast-math -mhard-float

default:
$(MAKE) -C $(KDIR) SUBDIRS=$(PWD) modules
gcc -o scope scope.c

clean:
rm *.o
rm *.ko

As you can see I use bash specific things like $(shell uname -r) to determine the running kernel.


How can I achieve this with the project settings dialog of eclipse?


Thank you

Johann

   <<Less
About | Sitemap | Contact