X-Git-Url: http://git.openwrt.org/?p=openwrt%2Fsvn-archive%2Farchive.git;a=blobdiff_plain;f=net%2Fasterisk-addons-1.4.x%2FMakefile;h=1824fac12e8e9aa05b8f6f69332626a35469a8d0;hp=96ec271a30cb3389e47371899c1c8907f325e975;hb=e7aab96765be1c497ddd8495a6c189ebc8a5d17f;hpb=69cf15396fc5d11862148b1961da5ad1821141e0 diff --git a/net/asterisk-addons-1.4.x/Makefile b/net/asterisk-addons-1.4.x/Makefile index 96ec271a30..1824fac12e 100644 --- a/net/asterisk-addons-1.4.x/Makefile +++ b/net/asterisk-addons-1.4.x/Makefile @@ -71,7 +71,6 @@ endef define Package/asterisk14-mysql $(call Package/asterisk-addons/Default) DEPENDS:= +asterisk14 +libmysqlclient - DEFAULT:=n TITLE+= MySQL support endef @@ -80,45 +79,54 @@ $(call Package/asterisk-addons/Default/description) This package contains MySQL support modules for Asterisk. endef - +EXTRA_CFLAGS:=$(TARGET_CFLAGS) $(TARGET_CPPFLAGS) +EXTRA_LDFLAGS:=$(TARGET_LDFLAGS) ifneq ($(SDK)$(CONFIG_PACKAGE_asterisk14-mysql),) EXTRA_CFLAGS+= -I$(STAGING_DIR)/usr/include/mysql EXTRA_LDFLAGS+= -L$(STAGING_DIR)/usr/lib/mysql endif +CONFIGURE_ARGS += \ + --with-bluetooth="$(STAGING_DIR)/usr" \ + --with-ncurses="$(STAGING_DIR)/usr" \ + --with-mysqlclient="$(STAGING_DIR)/usr" \ + +CONFIGURE_VARS += \ + ac_cv_file__usr_include_asterisk_channel_h="yes" \ define Build/Configure ( cd $(PKG_BUILD_DIR); ./bootstrap.sh ) - $(call Build/Configure/Default) - cd $(PKG_BUILD_DIR)/asterisk-ooh323c && \ - CPPFLAGS="-I$(STAGING_DIR)/host/include $(EXTRA_CFLAGS)" \ - LDFLAGS="-L$(STAGING_DIR)/host/lib" \ - ./configure \ - --target=$(GNU_TARGET_NAME) \ - --host=$(GNU_TARGET_NAME) \ - -build=$(GNU_HOST_NAME) \ - --prefix=/usr \ - --exec-prefix=/usr \ - --bindir=/usr/bin \ - --sbindir=/usr/sbin \ - --libexecdir=/usr/lib \ - --sysconfdir=/etc \ - --datadir=/usr/share \ - --localstatedir=/var \ - --mandir=/usr/man \ - --infodir=/usr/info \ - $(DISABLE_NLS) \ - ac_cv_file__usr_include_asterisk_channel_h="yes" + $(call Build/Configure/Default,,,) + $(call Build/Configure/Default,,,asterisk-ooh323c) + $(call libtool_disable_rpath) endef +# XXX: explanations +# - use AM_CFLAGS for asterisk-ooh323c +# - use OPTIMIZE & OPTIONS for format_mp3 + +MAKE_ARGS:= \ + AM_CFLAGS="$(TARGET_CFLAGS)" \ + OPTIMIZE="$(TARGET_CFLAGS)" \ + OPTIONS="" \ + BLUETOOTH_LIB="$(TARGET_LDFLAGS) -lbluetooth" \ + +MAKE_VARS:= \ + CFLAGS="$(EXTRA_CFLAGS) -DLOW_MEMORY" \ + LDFLAGS="$(EXTRA_LDFLAGS)" \ + define Build/Compile mkdir -p $(PKG_INSTALL_DIR)/usr/lib/asterisk/modules - CFLAGS="-DLOW_MEMORY $(EXTRA_CFLAGS)" \ - LDFLAGS="$(EXTRA_LDFLAGS)" \ + $(MAKE_VARS) \ + $(MAKE) -C "$(PKG_BUILD_DIR)" \ + $(MAKE_ARGS) \ + all + $(call libtool_fixup_libdir,$(PKG_INSTALL_DIR)) + $(MAKE_VARS) \ $(MAKE) -C "$(PKG_BUILD_DIR)" \ - BLUETOOTH_LIB="$(TARGET_LDFLAGS) -lbluetooth" \ + $(MAKE_ARGS) \ DESTDIR="$(PKG_INSTALL_DIR)" \ - all install samples + install samples endef