Makefile 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. #
  2. # Asterisk -- An open source telephony toolkit.
  3. #
  4. # Makefile for channel drivers
  5. #
  6. # Copyright (C) 1999-2006, Digium, Inc.
  7. #
  8. # This program is free software, distributed under the terms of
  9. # the GNU General Public License
  10. #
  11. -include $(ASTTOPDIR)/menuselect.makeopts $(ASTTOPDIR)/menuselect.makedeps
  12. MODULE_PREFIX=chan
  13. MENUSELECT_CATEGORY=CHANNELS
  14. MENUSELECT_DESCRIPTION=Channel Drivers
  15. all: _all
  16. include $(ASTTOPDIR)/Makefile.moddir_rules
  17. ifneq ($(findstring $(OSARCH), mingw32 cygwin ),)
  18. LIBS+= -lres_monitor.so -lres_features.so
  19. endif
  20. clean::
  21. $(MAKE) -C misdn clean
  22. rm -f dahdi/*.o dahdi/*.i
  23. rm -f sip/*.o sip/*.i
  24. rm -f iax2/*.o iax2/*.i
  25. rm -f pjsip/*.o pjsip/*.i
  26. $(if $(filter chan_iax2,$(EMBEDDED_MODS)),modules.link,chan_iax2.so): $(subst .c,.o,$(wildcard iax2/*.c))
  27. $(subst .c,.o,$(wildcard iax2/*.c)): _ASTCFLAGS+=$(call MOD_ASTCFLAGS,chan_iax2)
  28. $(if $(filter chan_sip,$(EMBEDDED_MODS)),modules.link,chan_sip.so): $(subst .c,.o,$(wildcard sip/*.c))
  29. $(subst .c,.o,$(wildcard sip/*.c)): _ASTCFLAGS+=$(call MOD_ASTCFLAGS,chan_sip)
  30. $(if $(filter chan_pjsip,$(EMBEDDED_MODS)),modules.link,chan_pjsip.so): $(subst .c,.o,$(wildcard pjsip/*.c))
  31. $(subst .c,.o,$(wildcard pjsip/*.c)): _ASTCFLAGS+=$(call MOD_ASTCFLAGS,chan_pjsip)
  32. # Additional objects to combine with chan_dahdi.so
  33. CHAN_DAHDI_OBJS= \
  34. $(subst .c,.o,$(wildcard dahdi/*.c)) \
  35. sig_analog.o \
  36. sig_pri.o \
  37. sig_ss7.o \
  38. $(if $(filter chan_dahdi,$(EMBEDDED_MODS)),modules.link,chan_dahdi.so): $(CHAN_DAHDI_OBJS)
  39. $(CHAN_DAHDI_OBJS): _ASTCFLAGS+=$(call MOD_ASTCFLAGS,chan_dahdi)
  40. chan_misdn.o: _ASTCFLAGS+=-Imisdn
  41. misdn_config.o: _ASTCFLAGS+=-Imisdn
  42. misdn/isdn_lib.o: _ASTCFLAGS+=-Wno-strict-aliasing
  43. $(if $(filter chan_misdn,$(EMBEDDED_MODS)),modules.link,chan_misdn.so): misdn_config.o misdn/isdn_lib.o misdn/isdn_msg_parser.o
  44. misdn_config.o misdn/isdn_lib.o misdn/isdn_msg_parser.o: _ASTCFLAGS+=$(call MOD_ASTCFLAGS,chan_misdn)
  45. $(if $(filter chan_oss,$(EMBEDDED_MODS)),modules.link,chan_oss.so): console_video.o vgrabbers.o console_board.o
  46. console_video.o vgrabbers.o console_board.o: _ASTCFLAGS+=$(call MOD_ASTCFLAGS,chan_oss)
  47. chan_usbradio.o: ./xpmr/xpmr.c ./xpmr/xpmr.h ./xpmr/xpmr_coef.h
  48. chan_usbradio.so: LIBS+=-lusb -lasound
  49. chan_usbradio.so: _ASTCFLAGS+=-DNDEBUG