kamailio3: simplify build procedure and enhance build variables
Signed-off-by: Jiri Slachta <slachta@cesnet.cz>
This commit is contained in:
parent
f98aca94ca
commit
39500cc8a6
1 changed files with 14 additions and 20 deletions
|
@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=kamailio3
|
PKG_NAME:=kamailio3
|
||||||
PKG_VERSION:=3.3.5
|
PKG_VERSION:=3.3.5
|
||||||
PKG_RELEASE:=1
|
PKG_RELEASE:=2
|
||||||
|
|
||||||
PKG_SOURCE_URL:=http://www.kamailio.org/pub/kamailio/$(PKG_VERSION)/src/
|
PKG_SOURCE_URL:=http://www.kamailio.org/pub/kamailio/$(PKG_VERSION)/src/
|
||||||
PKG_SOURCE:=kamailio-$(PKG_VERSION)$(PKG_VARIANT)_src.tar.gz
|
PKG_SOURCE:=kamailio-$(PKG_VERSION)$(PKG_VARIANT)_src.tar.gz
|
||||||
|
@ -129,8 +129,7 @@ define BuildPlugin
|
||||||
|
|
||||||
define Package/kamailio3-mod-$(1)/install
|
define Package/kamailio3-mod-$(1)/install
|
||||||
[ -z "$(2)" ] || $(INSTALL_DIR) $$(1)/usr/lib/kamailio/$(6)
|
[ -z "$(2)" ] || $(INSTALL_DIR) $$(1)/usr/lib/kamailio/$(6)
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/kamailio/$(6)/$(2).so \
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/kamailio/$(6)/$(2).so $$(1)/usr/lib/kamailio/$(6)/
|
||||||
$$(1)/usr/lib/kamailio/$(6)/ ;
|
|
||||||
endef
|
endef
|
||||||
|
|
||||||
INCL_MODULES+=$(2)
|
INCL_MODULES+=$(2)
|
||||||
|
@ -246,8 +245,8 @@ PKG_MAKE_ARGS:= \
|
||||||
lib-dir="/usr/lib/kamailio/" \
|
lib-dir="/usr/lib/kamailio/" \
|
||||||
modules-dir="/usr/lib/kamailio/modules/" \
|
modules-dir="/usr/lib/kamailio/modules/" \
|
||||||
include_modules="$(INCL_MODULES)" \
|
include_modules="$(INCL_MODULES)" \
|
||||||
$(KAM3_EXTRA_ARGS) \
|
TLS_HOOKS=1 \
|
||||||
TLS_HOOKS=1 extra_defs="-DUSE_PTHREAD_MUTEX " \
|
extra_defs="-DUSE_PTHREAD_MUTEX " \
|
||||||
CFLAGS="$(TARGET_CFLAGS)" \
|
CFLAGS="$(TARGET_CFLAGS)" \
|
||||||
ISSMP="no" \
|
ISSMP="no" \
|
||||||
LOCALBASE="$(STAGING_DIR)/usr" \
|
LOCALBASE="$(STAGING_DIR)/usr" \
|
||||||
|
@ -256,26 +255,21 @@ PKG_MAKE_ARGS:= \
|
||||||
PCRELIBS:="$(TARGET_LDFLAGS)" \
|
PCRELIBS:="$(TARGET_LDFLAGS)" \
|
||||||
cfg_target:=/etc/kamailio/ \
|
cfg_target:=/etc/kamailio/ \
|
||||||
PREFIX:=/usr \
|
PREFIX:=/usr \
|
||||||
prefix:=/usr quiet=verbose
|
CROSS_COMPILE=$(TARGET_CROSS) \
|
||||||
|
CC="$(TARGET_CC)" \
|
||||||
|
ARCH="$(ARCH)" \
|
||||||
|
DESTDIR=$(PKG_INSTALL_DIR) \
|
||||||
|
quiet=verbose
|
||||||
|
|
||||||
define Build/Compile
|
define Build/Compile
|
||||||
if ! [ -f $(PREBUILT_STAMP) ]; then echo $(MAKE) -C $(PKG_BUILD_DIR) $(PKG_MAKE_ARGS) \
|
if ! [ -f $(PREBUILT_STAMP) ]; then \
|
||||||
CC="$(TARGET_CC)" \
|
echo $(MAKE) -C $(PKG_BUILD_DIR) $(PKG_MAKE_ARGS) \
|
||||||
ARCH="$(ARCH)" \
|
EXTRA_LIBS=-L$(STAGING_DIR)/usr/lib/ prefix:=/usr \
|
||||||
EXTRA_LIBS=-L$(STAGING_DIR)/usr/lib/ \
|
|
||||||
all && touch $(PREBUILT_STAMP); \
|
all && touch $(PREBUILT_STAMP); \
|
||||||
fi
|
fi
|
||||||
$(MAKE) -C $(PKG_BUILD_DIR) $(PKG_MAKE_ARGS) \
|
$(MAKE) -C $(PKG_BUILD_DIR) $(PKG_MAKE_ARGS) prefix=/ \
|
||||||
CC="$(TARGET_CC)" \
|
|
||||||
ARCH="$(ARCH)" \
|
|
||||||
DESTDIR=$(PKG_INSTALL_DIR) \
|
|
||||||
prefix=/ \
|
|
||||||
install-cfg
|
install-cfg
|
||||||
$(MAKE) -C $(PKG_BUILD_DIR) $(PKG_MAKE_ARGS) \
|
$(MAKE) -C $(PKG_BUILD_DIR) $(PKG_MAKE_ARGS) prefix=/usr \
|
||||||
CC="$(TARGET_CC)" \
|
|
||||||
ARCH="$(ARCH)" \
|
|
||||||
DESTDIR=$(PKG_INSTALL_DIR) \
|
|
||||||
prefix=/usr \
|
|
||||||
install-bin install-modules-all install-utils
|
install-bin install-modules-all install-utils
|
||||||
endef
|
endef
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue