summaryrefslogtreecommitdiff
path: root/formats/Makefile
diff options
context:
space:
mode:
authorKevin P. Fleming <kpfleming@digium.com>2006-04-24 17:11:45 +0000
committerKevin P. Fleming <kpfleming@digium.com>2006-04-24 17:11:45 +0000
commit574e14cbea69b596a9a540b6401f2a087ec1e9ac (patch)
tree170532911902642fdae405ec644509398b0b6ee5 /formats/Makefile
parent746c984500cc209a5140c89eb98ec6aabb2fcd2a (diff)
Thanks to the fine work of Russell Bryant and Dancho Lazarov, we now have autoconf and menuselect tools for Asterisk!
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@22267 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'formats/Makefile')
-rw-r--r--formats/Makefile28
1 files changed, 6 insertions, 22 deletions
diff --git a/formats/Makefile b/formats/Makefile
index 2d3b24aa3..dab3a3922 100644
--- a/formats/Makefile
+++ b/formats/Makefile
@@ -11,26 +11,10 @@
# the GNU General Public License
#
-MODS:=$(patsubst %.c,%.so,$(wildcard format_*.c))
-
-# OGG/Vorbis format
-# (on FreeBSD is in /usr/local/include/...
-
-ifeq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/vorbis/codec.h),)
-ifeq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/local/include/vorbis/codec.h),)
- MODS:=$(filter-out format_ogg_vorbis.so,$(MODS))
-endif
-endif
+MODS:=$(filter-out $(MENUSELECT_FORMATS),$(patsubst %.c,%.so,$(wildcard format_*.c)))
GSMLIB=../codecs/gsm/lib/libgsm.a
-ifeq (${OSARCH},CYGWIN)
- CYGSOLINK=-Wl,--out-implib=lib$@.a -Wl,--export-all-symbols
- CYGSOLIB=-L.. -L. -lasterisk.dll
-else
- CFLAGS+=-fPIC
-endif
-
all: depend $(MODS)
clean-depend:
@@ -40,17 +24,17 @@ clean: clean-depend
rm -f *.so *.o
%.so : %.o
- $(CC) $(SOLINK) -o $@ ${CYGSOLINK} $< ${CYGSOLIB}
+ $(CC) $(SOLINK) -o $@ $<
ifneq ($(wildcard .depend),)
include .depend
endif
-format_mp3.so : format_mp3.o
- $(CC) $(SOLINK) -o $@ ${CYGSOLINK} $< ${CYGSOLIB} -lm
-
format_ogg_vorbis.so : format_ogg_vorbis.o
- $(CC) $(SOLINK) -o $@ ${CYGSOLINK} $< ${CYGSOLIB} -logg -lvorbis -lvorbisenc -lm
+ $(CC) $(SOLINK) -o $@ $< $(OGG_LIB) $(VORBIS_LIB)
+
+format_ogg_vorbis.o: format_ogg_vorbis.c
+ $(CC) -c -o $@ $(CFLAGS) $(OGG_INCLUDE) $(VORBIS_INCLUDE) $<
install: all
for x in $(MODS); do $(INSTALL) -m 755 $$x $(DESTDIR)$(MODULES_DIR) ; done