1999-12-05 07:28:29 +00:00
|
|
|
#
|
|
|
|
# Asterisk -- A telephony toolkit for Linux.
|
|
|
|
#
|
2005-06-20 17:26:08 +00:00
|
|
|
# Makefile for PBX modules
|
1999-12-05 07:28:29 +00:00
|
|
|
#
|
2006-02-11 17:48:44 +00:00
|
|
|
# Copyright (C) 1999-2006, Digium, Inc.
|
1999-12-05 07:28:29 +00:00
|
|
|
#
|
2005-06-20 17:26:08 +00:00
|
|
|
# Mark Spencer <markster@digium.com>
|
1999-12-05 07:28:29 +00:00
|
|
|
#
|
|
|
|
# This program is free software, distributed under the terms of
|
|
|
|
# the GNU General Public License
|
|
|
|
#
|
|
|
|
|
2006-04-24 17:11:45 +00:00
|
|
|
MODS:=$(filter-out $(MENUSELECT_PBX),$(patsubst %.c,%.so,$(wildcard pbx_*.c)))
|
1999-12-05 07:28:29 +00:00
|
|
|
|
|
|
|
MOC=$(QTDIR)/bin/moc
|
|
|
|
KDE_FLAGS=-I$(KDEDIR)/include -I$(KDEDIR)/include/kde -I$(QTDIR)/include
|
|
|
|
KDE_LIBS=-L$(KDEDIR)/lib -L$(QTDIR)/lib -lqt -lkdecore -lkdeui
|
2005-11-01 21:53:30 +00:00
|
|
|
|
1999-12-05 07:28:29 +00:00
|
|
|
KDE_CONSOLE_OBJS=pbx_kdeconsole_main.o pbx_kdeconsole.o
|
|
|
|
|
2006-02-11 17:48:44 +00:00
|
|
|
all: depend $(MODS)
|
1999-12-05 07:28:29 +00:00
|
|
|
|
2006-02-12 16:52:42 +00:00
|
|
|
clean-depend:
|
|
|
|
rm -f .depend
|
|
|
|
|
|
|
|
clean: clean-depend
|
|
|
|
rm -f *.so *.o
|
1999-12-05 07:28:29 +00:00
|
|
|
|
|
|
|
pbx_gtkconsole.o: pbx_gtkconsole.c
|
|
|
|
$(CC) $(CFLAGS) $(GTK_FLAGS) -c -o $@ $<
|
|
|
|
|
|
|
|
pbx_gtkconsole.so: pbx_gtkconsole.o
|
2003-10-26 18:50:49 +00:00
|
|
|
$(CC) $(SOLINK) -o $@ $< $(GTK_LIBS)
|
1999-12-05 07:28:29 +00:00
|
|
|
|
|
|
|
pbx_kdeconsole.o: pbx_kdeconsole.cc pbx_kdeconsole.moc
|
|
|
|
$(CXX) $(CFLAGS) $(KDE_FLAGS) -c -o $@ $<
|
|
|
|
|
|
|
|
pbx_kdeconsole_main.o: pbx_kdeconsole_main.cc pbx_kdeconsole.h
|
|
|
|
$(CXX) $(CFLAGS) $(KDE_FLAGS) -c -o $@ $<
|
|
|
|
|
|
|
|
pbx_kdeconsole.so: $(KDE_CONSOLE_OBJS)
|
2003-10-26 18:50:49 +00:00
|
|
|
$(CC) $(SOLINK) -o $@ $(KDE_CONSOLE_OBJS) $(KDE_LIBS)
|
1999-12-05 07:28:29 +00:00
|
|
|
|
2006-04-24 17:11:45 +00:00
|
|
|
pbx_dundi.so: pbx_dundi.o dundi-parser.o
|
|
|
|
$(CC) $(SOLINK) -o $@ $< dundi-parser.o $(Z_LIB)
|
|
|
|
|
|
|
|
pbx_dundi.o: pbx_dundi.c
|
|
|
|
$(CC) -c -o $@ $(CFLAGS) $(Z_INCLUDE) $<
|
2004-10-18 21:45:13 +00:00
|
|
|
|
2006-04-24 17:41:27 +00:00
|
|
|
pbx_ael.o: ael/aelflex.o ael/aelbison.o ../include/asterisk/ael_structs.h
|
|
|
|
|
|
|
|
pbx_ael.so: pbx_ael.o ael/aelbison.o ael/aelflex.o
|
|
|
|
$(CC) $(SOLINK) -o $@ pbx_ael.o ael/aelbison.o ael/aelflex.o
|
|
|
|
|
|
|
|
ael/aelflex.o: ael/ael_lex.c ../include/asterisk/ael_structs.h ael/ael.tab.h
|
|
|
|
$(CC) $(CFLAGS) -c -o ael/aelflex.o ael/ael_lex.c
|
|
|
|
|
|
|
|
ael/aelbison.o: ael/ael.tab.c ael/ael.tab.h ../include/asterisk/ael_structs.h
|
|
|
|
$(CC) $(CFLAGS) -c -o ael/aelbison.o ael/ael.tab.c
|
|
|
|
|
|
|
|
ael/ael_lex.c: ael/ael.flex
|
|
|
|
(cd ael; flex ael.flex)
|
|
|
|
|
|
|
|
ael/ael.tab.c ael/ael.tab.h: ael/ael.y
|
|
|
|
(cd ael; bison -v -d ael.y)
|
|
|
|
|
1999-12-05 07:28:29 +00:00
|
|
|
%.moc : %.h
|
|
|
|
$(MOC) $< -o $@
|
|
|
|
|
|
|
|
%.so : %.o
|
2006-04-24 17:11:45 +00:00
|
|
|
$(CC) $(SOLINK) -o $@ $<
|
1999-12-05 07:28:29 +00:00
|
|
|
|
2003-08-19 16:42:30 +00:00
|
|
|
ifneq ($(wildcard .depend),)
|
2005-08-30 02:54:02 +00:00
|
|
|
include .depend
|
2003-08-19 16:42:30 +00:00
|
|
|
endif
|
2003-05-06 00:00:20 +00:00
|
|
|
|
1999-12-05 07:28:29 +00:00
|
|
|
install: all
|
2006-02-11 17:48:44 +00:00
|
|
|
for x in $(MODS); do $(INSTALL) -m 755 $$x $(DESTDIR)$(MODULES_DIR) ; done
|
2003-05-06 00:00:20 +00:00
|
|
|
|
2006-02-01 18:39:41 +00:00
|
|
|
uninstall:
|
|
|
|
|
2003-05-06 00:00:20 +00:00
|
|
|
depend: .depend
|
|
|
|
|
|
|
|
.depend:
|
2005-06-20 17:26:08 +00:00
|
|
|
../build_tools/mkdep $(CFLAGS) `ls *.c`
|