20 ## OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF |
20 ## OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF |
21 ## SUCH DAMAGE. |
21 ## SUCH DAMAGE. |
22 ## |
22 ## |
23 |
23 |
24 # package version |
24 # package version |
25 %define V_opkg 1.8.11.0 |
25 %define V_opkg 1.8.15.0 |
26 %define V_asterisk 1.8.11.0 |
26 %define V_asterisk 1.8.15.0 |
27 %define V_asterisk_fax_subdir 1.8.4 |
27 %define V_asterisk_fax_subdir 1.8.4 |
28 %define V_asterisk_fax_digium 1.8.4_1.3.0 |
28 %define V_asterisk_fax_digium 1.8.4_1.3.1 |
29 %define V_asterisk_sounds_core 1.4.22 |
29 %define V_asterisk_sounds_core 1.4.22 |
30 %define V_asterisk_sounds_extra 1.4.11 |
30 %define V_asterisk_sounds_extra 1.4.11 |
31 %define V_asterisk_sounds_amoogab 1.4 |
31 %define V_asterisk_sounds_amoogab 1.4 |
32 %define V_asterisk_sounds_amootts current |
32 %define V_asterisk_sounds_amootts current |
33 %define V_asterisk_sounds_custom 1.0 |
33 %define V_asterisk_sounds_custom 1.0 |
34 %define V_asterisk_sounds_mohop 2.03 |
34 %define V_asterisk_sounds_mohop 2.03 |
|
35 %define V_asterisk_sounds_newpro july_2012 |
35 %define V_asterisk_addons_mp3dec 1 |
36 %define V_asterisk_addons_mp3dec 1 |
36 %define V_fswitch_sounds_en 1.0.16 |
37 %define V_fswitch_sounds_en 1.0.20 |
37 %define V_fswitch_sounds_fr 1.0.14 |
38 %define V_fswitch_sounds_fr 1.0.16 |
38 %define V_fswitch_sounds_ru 1.0.13 |
39 %define V_fswitch_sounds_ru 1.0.13 |
39 %define V_fswitch_music 1.0.8 |
40 %define V_fswitch_music 1.0.8 |
40 %define V_asterisk_codecs_ilbc 20110104 |
41 %define V_asterisk_codecs_ilbc 20110104 |
41 %define V_chan_capi 1.1.5.20120324 |
42 %define V_chan_capi 1.1.5.20120615 |
42 |
43 |
43 # package information |
44 # package information |
44 Name: asterisk |
45 Name: asterisk |
45 Summary: Private Branch Exchange (PBX) |
46 Summary: Private Branch Exchange (PBX) |
46 URL: http://www.asterisk.org/ |
47 URL: http://www.asterisk.org/ |
78 |
79 |
79 # list of sources |
80 # list of sources |
80 Source0: http://downloads.asterisk.org/pub/telephony/asterisk/releases/asterisk-%{V_asterisk}.tar.gz |
81 Source0: http://downloads.asterisk.org/pub/telephony/asterisk/releases/asterisk-%{V_asterisk}.tar.gz |
81 Source1: ftp://ftp.chan-capi.org/chan-capi/chan_capi-%{V_chan_capi}.tar.gz |
82 Source1: ftp://ftp.chan-capi.org/chan-capi/chan_capi-%{V_chan_capi}.tar.gz |
82 Source2: ftp://ftp.europalab.com/pub/sfw/machsnds/asterisk-moh-freeplay-sln16.tar.gz |
83 Source2: ftp://ftp.europalab.com/pub/sfw/machsnds/asterisk-moh-freeplay-sln16.tar.gz |
83 |
|
84 Source3: http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-moh-opsound-sln16-%{V_asterisk_sounds_mohop}.tar.gz |
84 Source3: http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-moh-opsound-sln16-%{V_asterisk_sounds_mohop}.tar.gz |
85 Source4: http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-core-sounds-en-sln16-%{V_asterisk_sounds_core}.tar.gz |
85 Source4: http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-core-sounds-en-sln16-%{V_asterisk_sounds_core}.tar.gz |
86 Source5: http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-core-sounds-es-sln16-%{V_asterisk_sounds_core}.tar.gz |
86 Source5: http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-core-sounds-es-sln16-%{V_asterisk_sounds_core}.tar.gz |
87 Source6: http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-core-sounds-en_AU-sln16-%{V_asterisk_sounds_core}.tar.gz |
87 Source6: http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-core-sounds-en_AU-sln16-%{V_asterisk_sounds_core}.tar.gz |
88 Source7: http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-core-sounds-fr-sln16-%{V_asterisk_sounds_core}.tar.gz |
88 Source7: http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-core-sounds-fr-sln16-%{V_asterisk_sounds_core}.tar.gz |
89 Source8: http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-core-sounds-ru-sln16-%{V_asterisk_sounds_core}.tar.gz |
89 Source8: http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-core-sounds-ru-sln16-%{V_asterisk_sounds_core}.tar.gz |
90 Source9: http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-extra-sounds-en-sln16-%{V_asterisk_sounds_extra}.tar.gz |
90 Source9: http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-extra-sounds-en-sln16-%{V_asterisk_sounds_extra}.tar.gz |
91 Source10: http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-extra-sounds-fr-sln16-%{V_asterisk_sounds_extra}.tar.gz |
91 Source10: http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-extra-sounds-fr-sln16-%{V_asterisk_sounds_extra}.tar.gz |
92 Source11: http://www.amooma.de/asterisk/sprachbausteine/asterisk-%{V_asterisk_sounds_amoogab}-de-prompts.tar.gz |
92 Source11: http://www.asterisk.org/files/new_prompts_%{V_asterisk_sounds_newpro}.zip |
93 Source12: http://www.amooma.de/asterisk/sprachbausteine/asterisk-core-sounds-de-gsm-current.tar.gz |
93 Source12: http://www.amooma.de/asterisk/sprachbausteine/asterisk-%{V_asterisk_sounds_amoogab}-de-prompts.tar.gz |
94 Source13: ftp://ftp.europalab.com/pub/sfw/machsnds/de-digits/de-digits-%{V_asterisk_sounds_custom}.tar.bz2 |
94 Source13: http://www.amooma.de/asterisk/sprachbausteine/asterisk-core-sounds-de-gsm-current.tar.gz |
95 Source14: ftp://ftp.europalab.com/pub/sfw/machsnds/de-sounds/astmultisnds-de-sln16-%{V_asterisk_sounds_custom}.tar.bz2 |
95 Source14: ftp://ftp.europalab.com/pub/sfw/machsnds/de-digits/de-digits-%{V_asterisk_sounds_custom}.tar.bz2 |
96 Source15: ftp://ftp.europalab.com/pub/sfw/machsnds/msvbsnds-sln16-%{V_asterisk_sounds_custom}.tar.bz2 |
96 Source15: ftp://ftp.europalab.com/pub/sfw/machsnds/de-sounds/astmultisnds-de-sln16-%{V_asterisk_sounds_custom}.tar.bz2 |
97 Source16: http://files.freeswitch.org/freeswitch-sounds-en-us-callie-48000-%{V_fswitch_sounds_en}.tar.gz |
97 Source16: ftp://ftp.europalab.com/pub/sfw/machsnds/msvbsnds-sln16-%{V_asterisk_sounds_custom}.tar.bz2 |
98 Source17: http://files.freeswitch.org/freeswitch-sounds-es-mx-maria-44100.tar.gz |
98 Source17: http://files.freeswitch.org/freeswitch-sounds-en-us-callie-48000-%{V_fswitch_sounds_en}.tar.gz |
99 Source18: http://files.freeswitch.org/freeswitch-sounds-fr-ca-june-48000-%{V_fswitch_sounds_fr}.tar.gz |
99 Source18: http://files.freeswitch.org/freeswitch-sounds-es-mx-maria-44100.tar.gz |
100 Source19: http://files.freeswitch.org/freeswitch-sounds-ru-RU-elena-48000-%{V_fswitch_sounds_ru}.tar.gz |
100 Source19: http://files.freeswitch.org/freeswitch-sounds-fr-ca-june-48000-%{V_fswitch_sounds_fr}.tar.gz |
101 Source20: http://files.freeswitch.org/freeswitch-sounds-music-48000-%{V_fswitch_music}.tar.gz |
101 Source20: http://files.freeswitch.org/freeswitch-sounds-ru-RU-elena-48000-%{V_fswitch_sounds_ru}.tar.gz |
102 Source21: http://svn.digium.com/svn/thirdparty/mp3/trunk/addons/mp3-%{V_asterisk_addons_mp3dec}.tar.gz |
102 Source21: http://files.freeswitch.org/freeswitch-sounds-music-48000-%{V_fswitch_music}.tar.gz |
103 Source22: http://downloads.digium.com/pub/telephony/fax/res_fax_digium/asterisk-%{V_asterisk_fax_subdir}/x86-64/res_fax_digium-%{V_asterisk_fax_digium}-generic_64.tar.gz |
103 Source22: http://svn.digium.com/svn/thirdparty/mp3/trunk/addons/mp3-%{V_asterisk_addons_mp3dec}.tar.gz |
104 Source23: http://downloads.digium.com/pub/telephony/fax/res_fax_digium/asterisk-%{V_asterisk_fax_subdir}/x86-32/res_fax_digium-%{V_asterisk_fax_digium}-generic_32.tar.gz |
104 Source23: http://downloads.digium.com/pub/telephony/fax/res_fax_digium/asterisk-%{V_asterisk_fax_subdir}/x86-64/res_fax_digium-%{V_asterisk_fax_digium}-generic_64.tar.gz |
105 Source24: ilbc-20110104.tar.gz |
105 Source24: http://downloads.digium.com/pub/telephony/fax/res_fax_digium/asterisk-%{V_asterisk_fax_subdir}/x86-32/res_fax_digium-%{V_asterisk_fax_digium}-generic_32.tar.gz |
106 Source25: asterisk.txt |
106 Source25: ilbc-%{V_asterisk_codecs_ilbc}.tar.gz |
107 Source26: rc.asterisk |
107 Source26: asterisk.txt |
108 Source27: wakeup.agi |
108 Source27: rc.asterisk |
|
109 Source28: wakeup.agi |
109 Patch0: asterisk.patch |
110 Patch0: asterisk.patch |
110 Patch1: asterisk.patch.xfersips |
111 Patch1: asterisk.patch.xfersips |
111 Patch2: asterisk.patch.proxymwi |
112 Patch2: asterisk.patch.proxymwi |
112 |
113 |
113 # build information |
114 # build information |
114 Prefix: %{l_prefix} |
115 BuildPreReq: OpenPKG, openpkg >= 20100101, bison, gcc, make, grep, pkgconfig |
115 BuildRoot: %{l_buildroot} |
116 PreReq: OpenPKG, openpkg >= 20100101, MTA |
116 BuildPreReq: OpenPKG, openpkg >= 20060823, bison, gcc, make, grep, pkgconfig |
|
117 PreReq: OpenPKG, openpkg >= 20060823, MTA |
|
118 BuildPreReq: zlib, curl, openssl, ncurses, speex, sox, popt, gmime, libxml |
117 BuildPreReq: zlib, curl, openssl, ncurses, speex, sox, popt, gmime, libxml |
119 PreReq: zlib, curl, openssl, ncurses, speex, sox, popt, gmime, libxml |
118 PreReq: zlib, curl, openssl, ncurses, speex, sox, popt, gmime, libxml |
120 %if "%{with_ogg}" == "yes" |
119 %if "%{with_ogg}" == "yes" |
121 BuildPreReq: vorbis-libs |
120 BuildPreReq: vorbis-libs |
122 PreReq: vorbis-libs |
121 PreReq: vorbis-libs |
639 ;; |
642 ;; |
640 esac |
643 esac |
641 %endif |
644 %endif |
642 |
645 |
643 ( echo 'Start of sound installation block (OpenPKG)' |
646 ( echo 'Start of sound installation block (OpenPKG)' |
|
647 # create main sound directory hierarchy |
|
648 ( cd $RPM_BUILD_ROOT%{l_prefix}/share/asterisk/sounds |
|
649 %{l_shtool} mkdir -f -p -m 755 en es fr en_AU |
|
650 ) || exit $? |
644 %if "%{with_esounds}" == "yes" |
651 %if "%{with_esounds}" == "yes" |
645 # create sound directory hierarchy |
652 # create extra sound directory hierarchy |
646 for sndir in en es fr ru en_AU moh; do |
653 %{l_shtool} mkdir -f -p -m 755 \ |
647 %{l_shtool} mkdir -f -p -m 755 \ |
654 $RPM_BUILD_ROOT%{l_prefix}/share/asterisk/sounds/ru |
648 $RPM_BUILD_ROOT%{l_prefix}/share/asterisk/sounds/$sndir |
655 $RPM_BUILD_ROOT%{l_prefix}/share/asterisk/sounds/moh |
649 done |
656 |
|
657 # install humorous 'new' prompts |
|
658 cd $RPM_BUILD_ROOT%{l_prefix}/share/asterisk/sounds/en |
|
659 %{l_prefix}/bin/unzip %{_sourcedir}/new_prompts_%{V_asterisk_sounds_newpro}.zip |
|
660 |
650 # install freeswitch sound prompt files, expecting |
661 # install freeswitch sound prompt files, expecting |
651 # identical sound filenames to be overwritten later |
662 # identical sound filenames to be overwritten later |
652 cd $RPM_BUILD_ROOT%{l_prefix}/share/asterisk/sounds/en |
663 cd $RPM_BUILD_ROOT%{l_prefix}/share/asterisk/sounds/en |
653 %{l_tar} zxf %{_sourcedir}/freeswitch-sounds-en-us-callie-48000-%{V_fswitch_sounds_en}.tar.gz |
664 %{l_tar} zxf %{_sourcedir}/freeswitch-sounds-en-us-callie-48000-%{V_fswitch_sounds_en}.tar.gz |
654 subs=`( cd en/us/callie && find * -type d -prune )` |
665 subs=`( cd en/us/callie && find * -type d -prune )` |