freeswitch-stable: move source file copying to Build/Compile

Some source files need to be copied into PKG_BUILD_DIR. This is
currently done in Build/Prepare.

When PKG_CONFIG_DEPENDS causes a reconfiguration, Build/Prepare is not
triggered again, meaning needed source files would not be copied.

Move these lines to Build/Compile to address this.

Signed-off-by: Sebastian Kemper <sebastian_ml@gmx.net>
This commit is contained in:
Sebastian Kemper 2018-03-04 18:09:29 +01:00
parent e0c576c18b
commit ab7d46ec35

View file

@ -957,24 +957,6 @@ define Build/Prepare
$(SED) 's|$(FS_STABLE_ANCHOR)|APR_SETVAR(LDFLAGS,$(FS_STABLE_APR_LIBS) $(TARGET_LDFLAGS))|' \ $(SED) 's|$(FS_STABLE_ANCHOR)|APR_SETVAR(LDFLAGS,$(FS_STABLE_APR_LIBS) $(TARGET_LDFLAGS))|' \
$(PKG_BUILD_DIR)/libs/unimrcp/build/acmacros/apr.m4 $(PKG_BUILD_DIR)/libs/unimrcp/build/acmacros/apr.m4
ifneq ($(CONFIG_PACKAGE_$(PKG_NAME)-mod-event_zmq),)
$(CP) $(DL_DIR)/$(FS_STABLE_ZEROMQ_FILE) $(PKG_BUILD_DIR)/libs
endif
ifneq ($(CONFIG_PACKAGE_$(PKG_NAME)-mod-pocketsphinx)$(CONFIG_PACKAGE_$(PKG_NAME)-misc-grammar),)
$(CP) $(DL_DIR)/$(FS_STABLE_POCKETSPHINX_FILE) $(PKG_BUILD_DIR)/libs
$(CP) $(DL_DIR)/$(FS_STABLE_SPHINXBASE_FILE) $(PKG_BUILD_DIR)/libs
$(CP) $(DL_DIR)/$(FS_STABLE_SPHINXMODEL_FILE) $(PKG_BUILD_DIR)/libs
endif
ifneq ($(CONFIG_PACKAGE_$(PKG_NAME)-mod-radius_cdr),)
$(CP) $(DL_DIR)/$(FS_STABLE_FREERADIUS_CLIENT_FILE) $(PKG_BUILD_DIR)/libs
endif
ifneq ($(CONFIG_PACKAGE_$(PKG_NAME)-mod-v8),)
$(CP) $(DL_DIR)/$(FS_STABLE_V8_FILE) $(PKG_BUILD_DIR)/libs
endif
# Hack for misc-grammar - needs mod_pocketsphinx to provide grammar files # Hack for misc-grammar - needs mod_pocketsphinx to provide grammar files
ifneq ($(CONFIG_PACKAGE_$(PKG_NAME)-misc-grammar),) ifneq ($(CONFIG_PACKAGE_$(PKG_NAME)-misc-grammar),)
ifeq ($(CONFIG_PACKAGE_$(PKG_NAME)-mod-pocketsphinx),) ifeq ($(CONFIG_PACKAGE_$(PKG_NAME)-mod-pocketsphinx),)
@ -998,6 +980,25 @@ endif
endef endef
define Build/Compile define Build/Compile
# Copy some source files if certain modules are selected
ifneq ($(CONFIG_PACKAGE_$(PKG_NAME)-mod-event_zmq),)
$(CP) $(DL_DIR)/$(FS_STABLE_ZEROMQ_FILE) $(PKG_BUILD_DIR)/libs
endif
ifneq ($(CONFIG_PACKAGE_$(PKG_NAME)-mod-pocketsphinx)$(CONFIG_PACKAGE_$(PKG_NAME)-misc-grammar),)
$(CP) $(DL_DIR)/$(FS_STABLE_POCKETSPHINX_FILE) $(PKG_BUILD_DIR)/libs
$(CP) $(DL_DIR)/$(FS_STABLE_SPHINXBASE_FILE) $(PKG_BUILD_DIR)/libs
$(CP) $(DL_DIR)/$(FS_STABLE_SPHINXMODEL_FILE) $(PKG_BUILD_DIR)/libs
endif
ifneq ($(CONFIG_PACKAGE_$(PKG_NAME)-mod-radius_cdr),)
$(CP) $(DL_DIR)/$(FS_STABLE_FREERADIUS_CLIENT_FILE) $(PKG_BUILD_DIR)/libs
endif
ifneq ($(CONFIG_PACKAGE_$(PKG_NAME)-mod-v8),)
$(CP) $(DL_DIR)/$(FS_STABLE_V8_FILE) $(PKG_BUILD_DIR)/libs
endif
# Compile FreeTDM first # Compile FreeTDM first
ifneq ($(CONFIG_PACKAGE_$(PKG_LIBFTDM)),) ifneq ($(CONFIG_PACKAGE_$(PKG_LIBFTDM)),)
$(call Build/Compile/Default,-C $(PKG_BUILD_DIR)/libs/$(FTDM)) $(call Build/Compile/Default,-C $(PKG_BUILD_DIR)/libs/$(FTDM))