File: Makefile

package info (click to toggle)
ussp-push 0.9-2
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k, lenny
  • size: 128 kB
  • ctags: 74
  • sloc: ansic: 877; xml: 101; makefile: 61
file content (43 lines) | stat: -rw-r--r-- 1,163 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
#
# UNrooted.net example code
#
# Minimal Makefile used to build my Bluez OBEX example.  The generated 
# executable 'ussp-push' can be used to push files using OBEX over RFCOMM with
# the Bluez Linux Bluetooth stack.  You should be able to just 'make' directly
# without any setup.
#

#
# These are the default paths the openobex package installs under.  Hack as
# necessary to reflect your setup.
#

OBEXINC=-I/usr/local/include
OBEXLIB=-L/usr/local/lib -lopenobex -lbluetooth

CFLAGS:=${CFLAGS} -Wall

OBEX_INCLUDES=obex_macros.h obex_socket.h obex_main.h obex_sdp.h

#
# The make rules.. basically just two files here plus the openobex and glib
# libraries and we can make the executable.
#

all: ussp-push

ussp-push: obex_main.o obex_socket.o obex_sdp.o
	gcc obex_main.o obex_socket.o obex_sdp.o ${OBEXLIB} -o ussp-push
 
obex_main.o: obex_main.c ${OBEX_INCLUDES}
	gcc ${CFLAGS} ${OBEXINC} -c obex_main.c -o obex_main.o

obex_socket.o: obex_socket.c ${OBEX_INCLUDES}
	gcc ${CFLAGS} ${OBEXINC} -c obex_socket.c -o obex_socket.o

obex_sdp.o: obex_sdp.c ${OBEX_INCLUDES}
	gcc ${CFLAGS} ${OBEXINC} -c obex_sdp.c -o obex_sdp.o

clean:
	@rm -rf ussp-push *.o *~