2013-04-04 16:08:57 +00:00
|
|
|
#
|
2017-09-12 12:10:43 +00:00
|
|
|
# Copyright (C) 2010-2017 OpenWrt.org
|
2013-04-04 16:08:57 +00:00
|
|
|
# Copyright (C) 2010 Alfred E. Heggestad
|
|
|
|
#
|
|
|
|
# This is free software, licensed under the GNU General Public License v2.
|
|
|
|
# See /LICENSE for more information.
|
|
|
|
#
|
|
|
|
|
|
|
|
include $(TOPDIR)/rules.mk
|
|
|
|
|
|
|
|
PKG_NAME:=baresip
|
2017-11-07 19:48:49 +00:00
|
|
|
PKG_VERSION:=0.5.6
|
2017-11-28 21:43:10 +00:00
|
|
|
PKG_RELEASE:=3
|
2013-04-04 16:08:57 +00:00
|
|
|
|
|
|
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
2017-11-26 21:45:24 +00:00
|
|
|
PKG_SOURCE_URL:=http://www.creytiv.com/pub
|
2017-11-07 19:48:49 +00:00
|
|
|
PKG_HASH:=148defef160842e0247af92c84bb0c8de4b36ffa68cf3a87c4cd7e510cddd00c
|
2013-04-04 16:08:57 +00:00
|
|
|
|
2014-11-04 16:00:24 +00:00
|
|
|
PKG_LICENSE:=BSD-3-Clause
|
|
|
|
PKG_LICENSE_FILES:=docs/COPYING
|
2016-05-31 18:12:51 +00:00
|
|
|
PKG_MAINTAINER:=Jiri Slachta <jiri@slachta.eu>
|
2014-11-04 16:00:24 +00:00
|
|
|
|
2017-11-26 21:42:05 +00:00
|
|
|
PKG_INSTALL:=1
|
|
|
|
|
2013-04-04 16:08:57 +00:00
|
|
|
baresip-mods:= \
|
|
|
|
alsa \
|
|
|
|
avcodec \
|
|
|
|
avformat \
|
|
|
|
cons \
|
|
|
|
evdev \
|
|
|
|
g711 \
|
|
|
|
g722 \
|
2015-07-22 13:16:46 +00:00
|
|
|
g726 \
|
2017-01-05 00:13:57 +00:00
|
|
|
opus \
|
2013-04-04 16:08:57 +00:00
|
|
|
oss \
|
2017-11-26 22:01:25 +00:00
|
|
|
plc \
|
|
|
|
portaudio \
|
|
|
|
pulse \
|
|
|
|
sndfile \
|
|
|
|
speex \
|
|
|
|
speex_aec \
|
|
|
|
speex_pp \
|
|
|
|
srtp \
|
2013-04-04 16:08:57 +00:00
|
|
|
stdio \
|
|
|
|
v4l \
|
2016-04-05 07:05:46 +00:00
|
|
|
v4l2
|
2013-04-04 16:08:57 +00:00
|
|
|
|
|
|
|
PKG_CONFIG_DEPENDS:= \
|
|
|
|
$(patsubst %,CONFIG_PACKAGE_baresip-mod-%,$(baresip-mods)) \
|
|
|
|
|
|
|
|
include $(INCLUDE_DIR)/package.mk
|
|
|
|
|
|
|
|
define Package/baresip/Default
|
|
|
|
SECTION:=net
|
|
|
|
CATEGORY:=Network
|
|
|
|
SUBMENU:=Telephony
|
2017-11-26 21:45:24 +00:00
|
|
|
URL:=http://www.creytiv.com
|
2013-04-04 16:08:57 +00:00
|
|
|
endef
|
|
|
|
|
|
|
|
define Package/baresip
|
|
|
|
$(call Package/baresip/Default)
|
|
|
|
TITLE:=Portable and modular SIP User-Agent with A/V support
|
2017-11-26 21:45:24 +00:00
|
|
|
DEPENDS:=+libre +librem
|
2014-10-28 20:43:11 +00:00
|
|
|
MENU:=1
|
2013-04-04 16:08:57 +00:00
|
|
|
endef
|
|
|
|
|
|
|
|
baresip-mod-alsa := USE_ALSA
|
2015-01-04 13:11:30 +00:00
|
|
|
baresip-mod-avcodec := USE_AVCODEC
|
|
|
|
baresip-mod-avformat := USE_AVFORMAT
|
2013-04-04 16:08:57 +00:00
|
|
|
baresip-mod-cons := USE_CONS
|
|
|
|
baresip-mod-evdev := USE_EVDEV
|
|
|
|
baresip-mod-g711 := USE_G711
|
|
|
|
baresip-mod-g722 := USE_G722
|
2015-07-22 13:16:46 +00:00
|
|
|
baresip-mod-g726 := USE_G726
|
2017-01-05 00:13:57 +00:00
|
|
|
baresip-mod-opus := USE_OPUS
|
2013-04-04 16:08:57 +00:00
|
|
|
baresip-mod-oss := USE_OSS
|
2017-11-26 22:01:25 +00:00
|
|
|
baresip-mod-plc := USE_PLC
|
|
|
|
baresip-mod-portaudio := USE_PORTAUDIO
|
|
|
|
baresip-mod-pulse := USE_PULSE
|
|
|
|
baresip-mod-sndfile := USE_SNDFILE
|
|
|
|
baresip-mod-speex := USE_SPEEX
|
|
|
|
baresip-mod-speex_aec := USE_SPEEX_AEC
|
|
|
|
baresip-mod-speex_pp := USE_SPEEX_PP
|
|
|
|
baresip-mod-srtp := USE_SRTP
|
2013-04-04 16:08:57 +00:00
|
|
|
baresip-mod-stdio := USE_STDIO
|
|
|
|
baresip-mod-v4l := USE_V4L
|
|
|
|
baresip-mod-v4l2 := USE_V4L2
|
|
|
|
|
|
|
|
BARESIP_MOD_OPTIONS:= \
|
|
|
|
MOD_AUTODETECT= \
|
2015-08-12 11:56:44 +00:00
|
|
|
EXTRA_MODULES="dtmfio" \
|
2013-04-04 16:08:57 +00:00
|
|
|
$(foreach m,$(baresip-mods),$(baresip-mod-$(m))=$(if $(CONFIG_PACKAGE_baresip-mod-$(m)),1))
|
|
|
|
|
2017-11-26 21:42:05 +00:00
|
|
|
MAKE_FLAGS+= \
|
|
|
|
EXTRA_LFLAGS="$(TARGET_LDFLAGS)" \
|
|
|
|
LIBRE_MK="$(STAGING_DIR)/usr/share/re/re.mk" \
|
|
|
|
LIBRE_INC="$(STAGING_DIR)/usr/include/re" \
|
|
|
|
LIBRE_SO="$(STAGING_DIR)/usr/lib" \
|
|
|
|
LIBREM_PATH="$(STAGING_DIR)/usr" \
|
|
|
|
SYSROOT="$(shell $(FIND) $(TOOLCHAIN_DIR) -path '*/include/pthread.h' | sed -ne '1s|/include/pthread.h||p')" \
|
|
|
|
SYSROOT_ALT="$(STAGING_DIR)/usr" \
|
|
|
|
RELEASE=1 \
|
|
|
|
$(BARESIP_MOD_OPTIONS)
|
2013-04-04 16:08:57 +00:00
|
|
|
|
2017-11-26 21:45:24 +00:00
|
|
|
TARGET_CFLAGS+=-D_GNU_SOURCE
|
|
|
|
|
2013-04-04 16:08:57 +00:00
|
|
|
define Package/baresip/install
|
|
|
|
$(INSTALL_DIR) $(1)/usr/bin
|
2017-11-26 21:45:24 +00:00
|
|
|
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/baresip $(1)/usr/bin
|
2013-04-04 16:08:57 +00:00
|
|
|
$(INSTALL_DIR) $(1)/usr/lib/baresip/modules
|
2017-11-07 19:48:49 +00:00
|
|
|
$(INSTALL_BIN) \
|
2014-03-26 12:04:16 +00:00
|
|
|
$(PKG_INSTALL_DIR)/usr/lib/baresip/modules/{account,auloop,contact,ice,menu,stun,turn}.so \
|
2017-11-26 21:45:24 +00:00
|
|
|
$(1)/usr/lib/baresip/modules
|
2013-04-04 16:08:57 +00:00
|
|
|
$(INSTALL_DIR) $(1)/usr/share/baresip
|
2017-11-26 21:45:24 +00:00
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/share/baresip/* $(1)/usr/share/baresip
|
2013-04-04 16:08:57 +00:00
|
|
|
$(INSTALL_DIR) $(1)/etc/init.d
|
|
|
|
$(INSTALL_BIN) ./files/baresip.init $(1)/etc/init.d/baresip
|
|
|
|
endef
|
|
|
|
|
2014-12-28 16:03:36 +00:00
|
|
|
##################
|
2017-11-26 21:56:38 +00:00
|
|
|
# bareSIP modules
|
2013-04-04 16:08:57 +00:00
|
|
|
# 1. Name
|
|
|
|
# 2. Title
|
|
|
|
# 3. Files
|
2014-12-28 16:03:36 +00:00
|
|
|
# 4. Dependencies
|
|
|
|
##################
|
|
|
|
|
2013-04-04 16:08:57 +00:00
|
|
|
define BuildPlugin
|
|
|
|
|
|
|
|
define Package/baresip-mod-$(1)
|
|
|
|
$$(call Package/baresip/Default)
|
2017-11-26 21:56:38 +00:00
|
|
|
TITLE:=$(2)
|
|
|
|
DEPENDS:=baresip $(patsubst +%,+PACKAGE_$(PKG_NAME)-mod-$(1):%,$(4))
|
2013-04-04 16:08:57 +00:00
|
|
|
endef
|
|
|
|
|
|
|
|
define Package/baresip-mod-$(1)/install
|
|
|
|
[ -z "$(3)" ] || $(INSTALL_DIR) $$(1)/usr/lib/baresip/modules
|
|
|
|
for f in $(3); do \
|
2017-11-26 21:45:24 +00:00
|
|
|
$(INSTALL_DATA) \
|
2013-04-04 16:08:57 +00:00
|
|
|
$(PKG_INSTALL_DIR)/usr/lib/baresip/modules/$$$$$$$${f}.so \
|
2017-11-26 21:45:24 +00:00
|
|
|
$$(1)/usr/lib/baresip/modules; \
|
2013-04-04 16:08:57 +00:00
|
|
|
done
|
|
|
|
endef
|
|
|
|
|
|
|
|
$$(eval $$(call BuildPackage,baresip-mod-$(1)))
|
|
|
|
endef
|
|
|
|
|
|
|
|
$(eval $(call BuildPackage,baresip))
|
|
|
|
|
2017-11-26 21:56:38 +00:00
|
|
|
$(eval $(call BuildPlugin,alsa,ALSA audio driver,alsa,+alsa-lib))
|
2017-11-26 22:01:25 +00:00
|
|
|
$(eval $(call BuildPlugin,aubridge,Audio bridge module,aubridge,))
|
|
|
|
$(eval $(call BuildPlugin,aufile,Audio module for using a WAV-file as audio input,aufile,))
|
2017-11-28 21:43:10 +00:00
|
|
|
$(eval $(call BuildPlugin,avcodec,Video codec using FFmpeg,avcodec,+libffmpeg-full +libx264))
|
2017-11-26 21:56:38 +00:00
|
|
|
$(eval $(call BuildPlugin,avformat,Video source using FFmpeg,avformat,+libffmpeg-full))
|
|
|
|
$(eval $(call BuildPlugin,cons,UDP/TCP console UI driver,cons,))
|
2017-11-26 22:01:25 +00:00
|
|
|
$(eval $(call BuildPlugin,debug_cmd,Debug commands,debug_cmd,))
|
|
|
|
$(eval $(call BuildPlugin,dtls_srtp,DTLS-SRTP end-to-end encryption,dtls_srtp,))
|
2016-04-05 08:06:43 +00:00
|
|
|
$(eval $(call BuildPlugin,dtmfio,DTMF input/output,dtmfio,))
|
2017-11-26 21:56:38 +00:00
|
|
|
$(eval $(call BuildPlugin,evdev,Linux input driver,evdev,))
|
2017-11-26 22:01:25 +00:00
|
|
|
$(eval $(call BuildPlugin,fakevideo,Fake video input/output driver,fakevideo,))
|
2013-04-04 16:08:57 +00:00
|
|
|
$(eval $(call BuildPlugin,g711,G.711 audio codec,g711,))
|
2017-11-26 21:56:38 +00:00
|
|
|
$(eval $(call BuildPlugin,g722,G.722 audio codec,g722,+libspandsp))
|
|
|
|
$(eval $(call BuildPlugin,g726,G.726 audio codec,g726,+libspandsp))
|
|
|
|
$(eval $(call BuildPlugin,httpd,HTTP webserver UI-module,httpd,))
|
2017-11-26 22:01:25 +00:00
|
|
|
$(eval $(call BuildPlugin,mwi,Message Waiting Indication,mwi,))
|
|
|
|
$(eval $(call BuildPlugin,natbd,NAT Behavior Discovery Module,natbd,))
|
|
|
|
$(eval $(call BuildPlugin,natpmp,NAT Port Mapping Protocol module,natpmp,))
|
2017-11-26 21:56:38 +00:00
|
|
|
$(eval $(call BuildPlugin,opus,OPUS Interactive audio codec,opus,+libopus))
|
2013-04-04 16:08:57 +00:00
|
|
|
$(eval $(call BuildPlugin,oss,OSS audio driver,oss,))
|
2017-11-26 22:01:25 +00:00
|
|
|
$(eval $(call BuildPlugin,plc,Packet Loss Concealment,plc,+libspandsp))
|
|
|
|
$(eval $(call BuildPlugin,portaudio,Portaudio audio driver,portaudio,+portaudio))
|
|
|
|
$(eval $(call BuildPlugin,presence,Presence module,presence,))
|
|
|
|
$(eval $(call BuildPlugin,pulse,Pulseaudio audio driver,pulse,+pulseaudio-daemon))
|
|
|
|
$(eval $(call BuildPlugin,selfview,Video selfview module,selfview,))
|
|
|
|
$(eval $(call BuildPlugin,sndfile,Audio dumper using libsndfile,sndfile,+libsndfile))
|
|
|
|
$(eval $(call BuildPlugin,speex,Speex audio codec,speex,+libspeex))
|
|
|
|
$(eval $(call BuildPlugin,speex_aec,Speex Acoustic Echo Canceller,speex_aec,+libspeex +libspeexdsp))
|
|
|
|
$(eval $(call BuildPlugin,speex_pp,Speex preprocessor,speex_pp,+libspeex +libspeexdsp))
|
|
|
|
$(eval $(call BuildPlugin,srtp,Secure RTP module using libre,srtp,))
|
2017-11-26 21:56:38 +00:00
|
|
|
$(eval $(call BuildPlugin,stdio,Standard input/output UI driver,stdio,))
|
2017-11-26 22:01:25 +00:00
|
|
|
$(eval $(call BuildPlugin,uuid,UUID generator and loader,uuid,))
|
2017-11-26 21:56:38 +00:00
|
|
|
$(eval $(call BuildPlugin,v4l,Video4Linux video source,v4l,+libv4l))
|
|
|
|
$(eval $(call BuildPlugin,v4l2,Video4Linux2 video source,v4l2,+libv4l))
|
2017-11-26 22:01:25 +00:00
|
|
|
$(eval $(call BuildPlugin,v4l2_codec,Video4Linux2 video codec module,v4l2_codec,))
|
|
|
|
$(eval $(call BuildPlugin,vidbridge,Video bridge module,vidbridge,))
|
|
|
|
$(eval $(call BuildPlugin,vidloop,Video-loop test module,vidloop,))
|
|
|
|
$(eval $(call BuildPlugin,vumeter,Display audio levels in console,vumeter,))
|