Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 79657 | Differences between
and this patch

Collapse All | Expand All

(-)chan_bluetooth/Makefile.orig (-11 / +26 lines)
Lines 1-17 Link Here
1
BLT_DIR  = $(shell dirname $(word $(words $(MAKEFILE_LIST)),$(MAKEFILE_LIST)))
1
BLT_OBJS = .tmp/chan_bluetooth.o
2
BLT_OBJS = $(BLT_DIR)/.tmp/chan_bluetooth.o
3
2
4
ifeq ($(strip ${MAKEFILE_LIST}), Makefile)
5
thisshouldnotberun:
6
	@echo " --- Please read the README and INSTALL file!"
7
endif
8
3
9
$(BLT_DIR)/.tmp/chan_bluetooth.o: $(BLT_DIR)/chan_bluetooth.c
4
CC=gcc
10
	$(CC) -c -I$(BLT_DIR) $(CFLAGS) -o $@ $<
5
SOLINK=$(shell /usr/bin/asterisk-config --solink)
6
CFLAGS=$(shell /usr/bin/asterisk-config --cflags) -fPIC -DPIC
11
7
12
chan_bluetooth.so: $(BLT_DIR)/.tmp $(BLT_OBJS)
8
ASTETCDIR=$(shell /usr/bin/asterisk-config --configdir)
9
ASTMODDIR=$(shell /usr/bin/asterisk-config --modulesdir)
10
11
all: .depend chan_bluetooth.so
12
13
.tmp/chan_bluetooth.o: chan_bluetooth.c
14
	$(CC) -c -I. $(CFLAGS) -o $@ $<
15
16
chan_bluetooth.so: .tmp $(BLT_OBJS)
13
	$(CC) $(SOLINK) -o $@ $(BLT_OBJS) -lbluetooth
17
	$(CC) $(SOLINK) -o $@ $(BLT_OBJS) -lbluetooth
14
18
15
$(BLT_DIR)/.tmp:
19
.tmp:
16
	mkdir -p $(BLT_DIR)/.tmp
20
	mkdir -p .tmp
21
22
.depend:
23
	@if [ ! -x /usr/bin/asterisk-config ]; then \
24
		echo "/usr/bin/asterisk-config not found!"; \
25
		exit 255; \
26
	fi
17
27
28
install:
29
	if [ ! -d $(DESTDIR)$(ASTETCDIR) ]; then mkdir -p $(DESTDIR)$(ASTETCDIR); fi
30
	install -m600 conf/bluetooth.conf $(DESTDIR)$(ASTETCDIR)
31
	if [ ! -d $(DESTDIR)$(ASTMODDIR) ]; then mkdir -p $(DESTDIR)$(ASTMODDIR); fi
32
	install -m755 chan_bluetooth.so $(DESTDIR)$(ASTMODDIR)

Return to bug 79657