debian: remove support for building sounds and music

The various sounds and music have their own source packages now as
they have their own conventions and version numbers which fortunately
update less frequently than FreeSWITCH itself.
This commit is contained in:
Travis Cross 2012-05-24 15:13:11 +00:00
parent 343bdec239
commit 7b5a9193aa
3 changed files with 4 additions and 130 deletions

View File

@ -48,10 +48,8 @@ The format of debian/modules.conf is:
To build this package, I recommend running the following from the root To build this package, I recommend running the following from the root
directory of your FS git working tree: directory of your FS git working tree:
mkdir ../sounds
export FS_SOUNDS_DIR=$(pwd)/../sounds
git clean -fdx && git reset --hard HEAD git clean -fdx && git reset --hard HEAD
(cd debian && ./bootstrap.sh) (cd debian && ./bootstrap.sh)
schedtool -B -e git-buildpackage --git-verbose -us -uc schedtool -B -e git-buildpackage --git-verbose -us -uc
-- Travis Cross <tc@traviscross.com>, Sat, 5 May 2012 23:32:53 +0000 -- Travis Cross <tc@traviscross.com>, Thu, 24 May 2012 16:28:46 +0000

117
debian/bootstrap.sh vendored
View File

@ -408,27 +408,13 @@ Description: FreeSWITCH systemd configuration
Package: freeswitch-music Package: freeswitch-music
Architecture: all Architecture: all
Depends: \${misc:Depends}, Depends: \${misc:Depends},
freeswitch-music-default (= \${binary:Version}) freeswitch-music-default (>= 1.0.8)
Description: Music on hold audio for FreeSWITCH Description: Music on hold audio for FreeSWITCH
$(debian_wrap "${fs_description}") $(debian_wrap "${fs_description}")
. .
This is a metapackage which depends on the default music on hold This is a metapackage which depends on the default music on hold
packages for FreeSWITCH. packages for FreeSWITCH.
Package: freeswitch-music-default
Architecture: all
Depends: \${misc:Depends},
freeswitch-music-default-8k (= \${binary:Version})
Recommends:
freeswitch-music-default-16k (= \${binary:Version}),
freeswitch-music-default-32k (= \${binary:Version}),
freeswitch-music-default-48k (= \${binary:Version})
Description: Music on hold audio for FreeSWITCH
$(debian_wrap "${fs_description}")
.
This is a metapackage which depends on the default music on hold
packages for FreeSWITCH at various sampling rates.
Package: freeswitch-sounds Package: freeswitch-sounds
Architecture: all Architecture: all
Depends: \${misc:Depends}, Depends: \${misc:Depends},
@ -452,27 +438,13 @@ Description: English sounds for FreeSWITCH
Package: freeswitch-sounds-en-us Package: freeswitch-sounds-en-us
Architecture: all Architecture: all
Depends: \${misc:Depends}, Depends: \${misc:Depends},
freeswitch-sounds-en-us-callie (= \${binary:Version}) freeswitch-sounds-en-us-callie (>= 1.0.18)
Description: US English sounds for FreeSWITCH Description: US English sounds for FreeSWITCH
$(debian_wrap "${fs_description}") $(debian_wrap "${fs_description}")
. .
This is a metapackage which depends on the default US/English sound This is a metapackage which depends on the default US/English sound
packages for FreeSWITCH. packages for FreeSWITCH.
Package: freeswitch-sounds-en-us-callie
Architecture: all
Depends: \${misc:Depends},
freeswitch-sounds-en-us-callie-8k (= \${binary:Version})
Recommends:
freeswitch-sounds-en-us-callie-16k (= \${binary:Version}),
freeswitch-sounds-en-us-callie-32k (= \${binary:Version}),
freeswitch-sounds-en-us-callie-48k (= \${binary:Version})
Description: US English sounds for FreeSWITCH
$(debian_wrap "${fs_description}")
.
This is a metapackage which depends on the US/English Callie sound
packages for FreeSWITCH at various sampling rates.
EOF EOF
} }
@ -557,14 +529,6 @@ print_conf_overrides () {
print_common_overrides "$1" print_common_overrides "$1"
} }
print_sound_overrides () {
print_common_overrides "$1"
}
print_music_overrides () {
print_common_overrides "$1"
}
print_conf_control () { print_conf_control () {
cat <<EOF cat <<EOF
Package: freeswitch-conf-${conf//_/-} Package: freeswitch-conf-${conf//_/-}
@ -584,46 +548,6 @@ conf/${conf} /usr/share/freeswitch/conf
EOF EOF
} }
print_music_control () {
cat <<EOF
Package: freeswitch-music-default-${rate_k}
Architecture: all
Depends: \${misc:Depends}
Description: Music on hold audio for FreeSWITCH
$(debian_wrap "${fs_description}")
.
This package contains the default music on hold audio for FreeSWITCH
at a sampling rate of ${rate}Hz.
EOF
}
print_music_install () {
cat <<EOF
/usr/share/freeswitch/sounds/music/${rate}
EOF
}
print_sound_control () {
cat <<EOF
Package: freeswitch-sounds-${sound//\//-}-${rate_k}
Architecture: all
Depends: \${misc:Depends}
Description: ${sound} sounds for FreeSWITCH
$(debian_wrap "${fs_description}")
.
This package contains the ${sound} sounds for FreeSWITCH at a
sampling rate of ${rate}Hz.
EOF
}
print_sound_install () {
cat <<EOF
/usr/share/freeswitch/sounds/${sound_path}/*/${rate}
EOF
}
print_edit_warning () { print_edit_warning () {
echo "#### Do not edit! This file is auto-generated from debian/bootstrap.sh."; echo echo "#### Do not edit! This file is auto-generated from debian/bootstrap.sh."; echo
} }
@ -667,35 +591,6 @@ genconf () {
test -f $f.tmpl && cat $f.tmpl >> $f test -f $f.tmpl && cat $f.tmpl >> $f
} }
genmusic () {
rate="$1" rate_k="${rate%%000}k"
print_music_control >> control
local p=freeswitch-music-default-${rate_k}
local f=$p.install
(print_edit_warning; print_music_install) > $f
test -f $f.tmpl && cat $f.tmpl >> $f
local f=$p.lintian-overrides
(print_edit_warning; print_music_overrides "$p") > $f
test -f $f.tmpl && cat $f.tmpl >> $f
unset rate rate_k
}
gensound () {
rate="$1" rate_k="${rate%%000}k" sound_path="$2" sound="${2,,}"
language=$(echo $sound | cut -d/ -f1)
country=$(echo $sound | cut -d/ -f2)
speaker=$(echo $sound | cut -d/ -f3)
print_sound_control >> control
local p=freeswitch-sounds-${sound//\//-}-${rate_k}
local f=$p.install
(print_edit_warning; print_sound_install) > $f
test -f $f.tmpl && cat $f.tmpl >> $f
local f=$p.lintian-overrides
(print_edit_warning; print_sound_overrides "$p") > $f
test -f $f.tmpl && cat $f.tmpl >> $f
unset rate rate_k sound sound_path language country speaker
}
accumulate_build_depends () { accumulate_build_depends () {
local x="" local x=""
if [ -n "$(eval echo \$build_depends_$codename)" ]; then if [ -n "$(eval echo \$build_depends_$codename)" ]; then
@ -865,14 +760,6 @@ map_modules 'mod_filter' '' 'accumulate_build_depends'
echo "Generating debian/..." >&2 echo "Generating debian/..." >&2
> control > control
(print_edit_warning; print_source_control; print_core_control) >> control (print_edit_warning; print_source_control; print_core_control) >> control
echo "Generating debian/ (music)..." >&2
for r in 8000 16000 32000 48000; do genmusic $r; done
echo "Generating debian/ (sounds)..." >&2
for x in 'en/us/callie'; do
for r in 8000 16000 32000 48000; do
gensound $r $x
done
done
echo "Generating debian/ (conf)..." >&2 echo "Generating debian/ (conf)..." >&2
(echo "### conf"; echo) >> control (echo "### conf"; echo) >> control
map_confs 'genconf' map_confs 'genconf'

13
debian/rules vendored
View File

@ -7,7 +7,6 @@
FS_CFLAGS?=-ggdb3 -O2 FS_CFLAGS?=-ggdb3 -O2
FS_CPPFLAGS?= FS_CPPFLAGS?=
FS_CXXFLAGS?=$(FS_CFLAGS) FS_CXXFLAGS?=$(FS_CFLAGS)
FS_INSTALL_SOUNDS?=true
export PATH?=/usr/lib/ccache:/usr/sbin:/usr/bin:/sbin:/bin export PATH?=/usr/lib/ccache:/usr/sbin:/usr/bin:/sbin:/bin
export CFLAGS=$(FS_CFLAGS) export CFLAGS=$(FS_CFLAGS)
export CPPFLAGS=$(FS_CPPFLAGS) export CPPFLAGS=$(FS_CPPFLAGS)
@ -20,7 +19,6 @@ show_vars= \
echo "CFLAGS='$(CFLAGS)'"; \ echo "CFLAGS='$(CFLAGS)'"; \
echo "CXXFLAGS='$(CXXFLAGS)'"; \ echo "CXXFLAGS='$(CXXFLAGS)'"; \
echo "CCACHE_DIR='$(CCACHE_DIR)'"; \ echo "CCACHE_DIR='$(CCACHE_DIR)'"; \
echo "FS_INSTALL_SOUNDS='$(FS_INSTALL_SOUNDS)'"; \
echo; echo;
binary: binary:
@ -90,7 +88,6 @@ override_dh_strip:
override_dh_auto_install: override_dh_auto_install:
dh_auto_install dh_auto_install
-$(FS_INSTALL_SOUNDS) && DESTDIR=debian/tmp make cd-sounds-install cd-moh-install
mkdir -p debian/tmp/lib/systemd/system mkdir -p debian/tmp/lib/systemd/system
install -m0644 debian/freeswitch-systemd.freeswitch.service debian/tmp/lib/systemd/system/freeswitch.service install -m0644 debian/freeswitch-systemd.freeswitch.service debian/tmp/lib/systemd/system/freeswitch.service
rm -f debian/tmp/usr/share/freeswitch/grammar/model/communicator/COPYING rm -f debian/tmp/usr/share/freeswitch/grammar/model/communicator/COPYING
@ -118,13 +115,5 @@ binary-quicktest:
@$(call show_vars) @$(call show_vars)
echo "applications/mod_commands" > debian/modules.conf echo "applications/mod_commands" > debian/modules.conf
(cd debian && ./bootstrap.sh) (cd debian && ./bootstrap.sh)
env FS_INSTALL_SOUNDS=false dh binary \ dh binary
-Nfreeswitch-sounds-music-8k \
-Nfreeswitch-sounds-music-16k \
-Nfreeswitch-sounds-music-32k \
-Nfreeswitch-sounds-music-48k \
-Nfreeswitch-sounds-en-us-callie-8k \
-Nfreeswitch-sounds-en-us-callie-16k \
-Nfreeswitch-sounds-en-us-callie-32k \
-Nfreeswitch-sounds-en-us-callie-48k