Skip to content
Snippets Groups Projects
Commit 88b3f0d6 authored by Grzegorz Sluja's avatar Grzegorz Sluja Committed by Sukru Senli
Browse files

Fix the asterisk sounds url mirror mechanism

Check the asterisk sounds url availability. If it is not available
(sometimes asterisk server is down and we could not build our asterisk
fork) then use the iopsys mirror url instead to build the asterisk sounds.
parent fca3bc91
No related branches found
No related tags found
No related merge requests found
......@@ -22,8 +22,12 @@ MOH_DIR:=$(DESTDIR)$(ASTDATADIR)/moh
CORE_SOUNDS_VERSION:=1.6.1
EXTRA_SOUNDS_VERSION:=1.5.2
MOH_VERSION:=2.03
AST_SERVER_AVAILABLE:=$(shell curl --head --silent --fail http://downloads.asterisk.org/pub/telephony/sounds/releases 2> /dev/null)
ifneq ($(AST_SERVER_AVAILABLE),)
SOUNDS_URL:=http://downloads.asterisk.org/pub/telephony/sounds/releases
SOUNDS_URL_MIRROR:=https://download.iopsys.eu/iopsys/mirror/asterisk/sounds/releases
else
SOUNDS_URL:=https://download.iopsys.eu/iopsys/mirror/asterisk/sounds/releases
endif
MCS:=$(subst -EN-,-en-,$(MENUSELECT_CORE_SOUNDS))
MCS:=$(subst -EN_AU-,-en_AU-,$(MCS))
MCS:=$(subst -EN_GB-,-en_GB-,$(MCS))
......@@ -119,9 +123,6 @@ else
if test ! -f $$@ && test ! -f "$(1)$(if $(3),/$(3),)/.$$(subst .tar.gz,,$$@)"; then \
$$(DOWNLOAD) $$(SOUNDS_URL)/$$@; \
fi
if test ! -f $$@ && test ! -f "$(1)$(if $(3),/$(3),)/.$$(subst .tar.gz,,$$@)"; then \
$$(DOWNLOAD) $$(SOUNDS_URL_MIRROR)/$$@; \
fi
endif
endef # sound_format_lang_rule
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment