Results 1 to 1 of 1
This is my makefile structure:
Code:
# Simple make
# Made with geany
CC = gcc
OBJS = funcs.o main.o
OUT = gtk-sample
GTK_PATHS = `pkg-config --cflags --libs gtk+-2.0`
$(OUT) ...
- 11-13-2008 #1
How can I make "make" to place objects in other directory?
This is my makefile structure:
The files are like:Code:# Simple make # Made with geany CC = gcc OBJS = funcs.o main.o OUT = gtk-sample GTK_PATHS = `pkg-config --cflags --libs gtk+-2.0` $(OUT) : $(OBJS) $(CC) -Wall $(OBJS) $(GTK_PATHS) -o $(OUT) funcs.o : funcs.c gcc -Wall -c funcs.c $(GTK_PATHS) main.o : main.c gcc -Wall -c main.c $(GTK_PATHS) clean : rm *.o $(OUT)
~/coder/app/main.c
~/coder/app/main.h
~/coder/app/funcs.c
~/coder/app/makefile
~/coder/app/main.o
~/coder/app/funcs.o
~/coder/app/gtk-sample
What I need is something like this:
~/coder/app/main.c
~/coder/app/main.h
~/coder/app/funcs.c
~/coder/app/makefile
~/coder/app/bin/main.o
~/coder/app/bin/funcs.o
~/coder/app/bin/gtk-sample
Thanks for any tips


Reply With Quote