asterisk/asterisk.spec

changeset 362
7c568c62ffb3
parent 348
062212fbda04
child 398
08f5eb82b58f
     1.1 --- a/asterisk/asterisk.spec	Thu Sep 15 19:34:00 2011 +0200
     1.2 +++ b/asterisk/asterisk.spec	Thu Sep 15 19:40:20 2011 +0200
     1.3 @@ -22,8 +22,8 @@
     1.4  ##
     1.5  
     1.6  #   package version
     1.7 -%define       V_opkg                     1.8.4.2
     1.8 -%define       V_asterisk                 1.8.4.2
     1.9 +%define       V_opkg                     1.8.6.0
    1.10 +%define       V_asterisk                 1.8.6.0
    1.11  %define       V_asterisk_fax_subdir      1.8.4
    1.12  %define       V_asterisk_fax_digium      1.8.4_1.3.0
    1.13  %define       V_asterisk_sounds_core     1.4.21
    1.14 @@ -33,11 +33,11 @@
    1.15  %define       V_asterisk_sounds_custom   1.0
    1.16  %define       V_asterisk_sounds_mohop    2.03
    1.17  %define       V_asterisk_addons_mp3dec   1
    1.18 -%define       V_fswitch_sounds_en        1.0.14
    1.19 -%define       V_fswitch_sounds_ru        1.0.12
    1.20 +%define       V_fswitch_sounds_en        1.0.16
    1.21 +%define       V_fswitch_sounds_ru        1.0.13
    1.22  %define       V_fswitch_music            1.0.8
    1.23  %define       V_asterisk_codecs_ilbc     20110104
    1.24 -%define       V_chan_capi                1.1.5.919
    1.25 +%define       V_chan_capi                1.1.5.20110914
    1.26  
    1.27  #   package information
    1.28  Name:         asterisk
    1.29 @@ -50,7 +50,7 @@
    1.30  Group:        VoIP
    1.31  License:      GPL
    1.32  Version:      %{V_opkg}
    1.33 -Release:      20110604
    1.34 +Release:      20110916
    1.35  
    1.36  #   package options
    1.37  %option       with_dahdi   no
    1.38 @@ -78,29 +78,40 @@
    1.39  Source0:      http://downloads.asterisk.org/pub/telephony/asterisk/releases/asterisk-%{V_asterisk}.tar.gz
    1.40  Source1:      ftp://ftp.chan-capi.org/chan-capi/chan_capi-%{V_chan_capi}.tar.gz
    1.41  Source2:      ftp://ftp.europalab.com/pub/sfw/machsnds/asterisk-moh-freeplay-sln16.tar.gz
    1.42 +
    1.43  Source3:      http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-moh-opsound-sln16-%{V_asterisk_sounds_mohop}.tar.gz
    1.44 -Source4:      http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-core-sounds-en-sln16-%{V_asterisk_sounds_core}.tar.gz
    1.45 -Source5:      http://downloads.asterisk.org/pub/telephony/sounds/asterisk-core-sounds-en_AU-sln16-current.tar.gz
    1.46 -Source6:      http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-core-sounds-es-sln16-%{V_asterisk_sounds_core}.tar.gz
    1.47 -Source7:      http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-core-sounds-fr-sln16-%{V_asterisk_sounds_core}.tar.gz
    1.48 -Source8:      http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-extra-sounds-en-sln16-%{V_asterisk_sounds_extra}.tar.gz
    1.49 -Source9:      http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-extra-sounds-fr-sln16-%{V_asterisk_sounds_extra}.tar.gz
    1.50 -Source10:     http://www.amooma.de/asterisk/sprachbausteine/asterisk-%{V_asterisk_sounds_amoogab}-de-prompts.tar.gz
    1.51 -Source11:     http://www.amooma.de/asterisk/sprachbausteine/asterisk-core-sounds-de-gsm-current.tar.gz
    1.52 -Source12:     ftp://ftp.europalab.com/pub/sfw/machsnds/de-digits/de-digits-%{V_asterisk_sounds_custom}.tar.bz2
    1.53 -Source13:     ftp://ftp.europalab.com/pub/sfw/machsnds/de-sounds/astmultisnds-de-sln16-%{V_asterisk_sounds_custom}.tar.bz2
    1.54 -Source14:     ftp://ftp.europalab.com/pub/sfw/machsnds/msvbsnds-sln16-%{V_asterisk_sounds_custom}.tar.bz2
    1.55 -Source15:     http://files.freeswitch.org/freeswitch-sounds-en-us-callie-48000-%{V_fswitch_sounds_en}.tar.gz
    1.56 -Source16:     http://files.freeswitch.org/freeswitch-sounds-es-mx-maria-44100.tar.gz
    1.57 -Source17:     http://files.freeswitch.org/freeswitch-sounds-ru-RU-elena-48000-%{V_fswitch_sounds_ru}.tar.gz
    1.58 -Source18:     http://files.freeswitch.org/freeswitch-sounds-music-48000-%{V_fswitch_music}.tar.gz
    1.59 -Source19:     http://svn.digium.com/svn/thirdparty/mp3/trunk/addons/mp3-%{V_asterisk_addons_mp3dec}.tar.gz
    1.60 -Source20:     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
    1.61 -Source21:     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
    1.62 -Source22:     ilbc-20110104.tar.gz
    1.63 -Source23:     asterisk.txt
    1.64 -Source24:     rc.asterisk
    1.65 -Source25:     wakeup.agi
    1.66 +Source4:      http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-moh-opsound-sln16-%{V_asterisk_sounds_mohop}.tar.gz.sha1
    1.67 +Source5:      http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-core-sounds-en-sln16-%{V_asterisk_sounds_core}.tar.gz
    1.68 +Source6:      http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-core-sounds-en-sln16-%{V_asterisk_sounds_core}.tar.gz.sha1
    1.69 +Source7:      http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-core-sounds-es-sln16-%{V_asterisk_sounds_core}.tar.gz
    1.70 +Source8:      http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-core-sounds-es-sln16-%{V_asterisk_sounds_core}.tar.gz.sha1
    1.71 +Source9:      http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-core-sounds-en_AU-sln16-%{V_asterisk_sounds_core}.tar.gz
    1.72 +Source10:     http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-core-sounds-en_AU-sln16-%{V_asterisk_sounds_core}.tar.gz.sha1
    1.73 +Source11:     http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-core-sounds-fr-sln16-%{V_asterisk_sounds_core}.tar.gz
    1.74 +Source12:     http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-core-sounds-fr-sln16-%{V_asterisk_sounds_core}.tar.gz.sha1
    1.75 +Source13:     http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-core-sounds-ru-sln16-%{V_asterisk_sounds_core}.tar.gz
    1.76 +Source14:     http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-core-sounds-ru-sln16-%{V_asterisk_sounds_core}.tar.gz.sha1
    1.77 +Source15:     http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-extra-sounds-en-sln16-%{V_asterisk_sounds_extra}.tar.gz
    1.78 +Source16:     http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-extra-sounds-en-sln16-%{V_asterisk_sounds_extra}.tar.gz.sha1
    1.79 +Source16:     http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-extra-sounds-fr-sln16-%{V_asterisk_sounds_extra}.tar.gz
    1.80 +Source17:     http://downloads.asterisk.org/pub/telephony/sounds/releases/asterisk-extra-sounds-fr-sln16-%{V_asterisk_sounds_extra}.tar.gz.sha1
    1.81 +
    1.82 +Source18:     http://www.amooma.de/asterisk/sprachbausteine/asterisk-%{V_asterisk_sounds_amoogab}-de-prompts.tar.gz
    1.83 +Source19:     http://www.amooma.de/asterisk/sprachbausteine/asterisk-core-sounds-de-gsm-current.tar.gz
    1.84 +Source20:     ftp://ftp.europalab.com/pub/sfw/machsnds/de-digits/de-digits-%{V_asterisk_sounds_custom}.tar.bz2
    1.85 +Source21:     ftp://ftp.europalab.com/pub/sfw/machsnds/de-sounds/astmultisnds-de-sln16-%{V_asterisk_sounds_custom}.tar.bz2
    1.86 +Source22:     ftp://ftp.europalab.com/pub/sfw/machsnds/msvbsnds-sln16-%{V_asterisk_sounds_custom}.tar.bz2
    1.87 +Source23:     http://files.freeswitch.org/freeswitch-sounds-en-us-callie-48000-%{V_fswitch_sounds_en}.tar.gz
    1.88 +Source24:     http://files.freeswitch.org/freeswitch-sounds-es-mx-maria-44100.tar.gz
    1.89 +Source25:     http://files.freeswitch.org/freeswitch-sounds-ru-RU-elena-48000-%{V_fswitch_sounds_ru}.tar.gz
    1.90 +Source26:     http://files.freeswitch.org/freeswitch-sounds-music-48000-%{V_fswitch_music}.tar.gz
    1.91 +Source27:     http://svn.digium.com/svn/thirdparty/mp3/trunk/addons/mp3-%{V_asterisk_addons_mp3dec}.tar.gz
    1.92 +Source28:     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
    1.93 +Source29:     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
    1.94 +Source30:     ilbc-20110104.tar.gz
    1.95 +Source31:     asterisk.txt
    1.96 +Source32:     rc.asterisk
    1.97 +Source33:     wakeup.agi
    1.98  Patch0:       asterisk.patch
    1.99  Patch1:       asterisk.patch.xfersips
   1.100  Patch2:       asterisk.patch.proxymwi
   1.101 @@ -253,8 +264,8 @@
   1.102      %setup -q -n asterisk-%{V_asterisk} -D -T -a 1
   1.103      %setup -q -n asterisk-%{V_asterisk} -D -T -a 2
   1.104  %if "%{with_fax}" == "yes"
   1.105 -    %setup -q -n asterisk-%{V_asterisk} -D -T -a 20
   1.106 -    %setup -q -n asterisk-%{V_asterisk} -D -T -a 21
   1.107 +    %setup -q -n asterisk-%{V_asterisk} -D -T -a 28
   1.108 +    %setup -q -n asterisk-%{V_asterisk} -D -T -a 29
   1.109  %endif
   1.110      ( cd addons
   1.111        %{l_tar} zxf %{_sourcedir}/mp3-%{V_asterisk_addons_mp3dec}.tar.gz
   1.112 @@ -291,6 +302,7 @@
   1.113          -e 's;^\(#define DEFAULT_DB .*\${ASTDBDIR}\)/astdb;\1/asterisk.db;' \
   1.114          build_tools/make_defaults_h
   1.115      %{l_shtool} subst \
   1.116 +        -e 's;^\(_all:.* *\)cleantest *;\1;' \
   1.117          -e 's; *-I/usr/local/ssl/include;;g' \
   1.118          -e 's;/opt/ssl/include;%{l_prefix}/include;g' \
   1.119          -e 's;/usr/local;%{l_prefix};g' \
   1.120 @@ -309,17 +321,12 @@
   1.121          main/Makefile
   1.122      %{l_shtool} subst \
   1.123          -e 's;\(<defaultenabled>\)no\(</defaultenabled>\);\1yes\2;g' \
   1.124 -        addons/.*.moduleinfo \
   1.125 -        apps/.app_ivrdemo.moduleinfo \
   1.126 -        apps/.app_saycounted.moduleinfo \
   1.127 -        apps/.app_rpt.moduleinfo \
   1.128 -        codecs/.moduleinfo \
   1.129 +        apps/app_ivrdemo.c \
   1.130 +        apps/app_saycounted.c \
   1.131 +        apps/app_rpt.c \
   1.132          utils/utils.xml \
   1.133          agi/agi.xml
   1.134      %{l_shtool} subst \
   1.135 -        -e 's;check_expr2;check_expr;g' \
   1.136 -        utils/utils.xml
   1.137 -    %{l_shtool} subst \
   1.138          -e 's;\(-DSOLARIS\);\1 -D__EXTENSIONS__=1;g' \
   1.139          main/editline/Makefile.in \
   1.140          main/db1-ast/Makefile
   1.141 @@ -333,10 +340,6 @@
   1.142          -e 's;if \(((tmp = strchr(name\);while \1;g' \
   1.143          main/abstract_jb.c
   1.144      %{l_shtool} subst \
   1.145 -        -e 's;\(CORE_SOUNDS_VERSION\):=.*$;\1:=%{V_asterisk_sounds_core};' \
   1.146 -        -e 's;\(EXTRA_SOUNDS_VERSION\):=.*$;\1:=%{V_asterisk_sounds_extra};' \
   1.147 -        sounds/Makefile
   1.148 -    %{l_shtool} subst \
   1.149          -e 's;\(/etc/radiusclient-ng/radiusclient.conf\);%{l_prefix}\1;g' \
   1.150          -e 's;\(radiusclient\)-ng;\1;g' \
   1.151          cdr/cdr_radius.c \
   1.152 @@ -433,7 +436,7 @@
   1.153          --localstatedir=%{l_prefix}/var \
   1.154          --datarootdir=%{l_prefix}/share/asterisk \
   1.155          --with-crypto=%{l_prefix} \
   1.156 -        --with-curl=%{l_prefix} \
   1.157 +        --with-libcurl=%{l_prefix} \
   1.158          --with-ncurses=%{l_prefix} \
   1.159          --with-gsm="internal" \
   1.160          --with-popt=%{l_prefix} \
   1.161 @@ -502,17 +505,18 @@
   1.162  %else
   1.163          --without-imap \
   1.164  %endif
   1.165 +        --without-iodbc \
   1.166  %if "%{with_odbc}" == "yes"
   1.167 -        --with-odbc=%{l_prefix} \
   1.168 +        --with-unixodbc=%{l_prefix} \
   1.169  %else
   1.170 -        --without-odbc \
   1.171 +        --without-unixodbc \
   1.172  %endif
   1.173  %if "%{with_libpri}" == "yes"
   1.174          --with-pri=%{l_prefix} \
   1.175  %else
   1.176          --without-pri \
   1.177  %endif
   1.178 -        --with-sounds-cache=no \
   1.179 +        --with-sounds-cache=%_sourcedir \
   1.180          --without-netsnmp \
   1.181          --without-isdnnet \
   1.182          --without-misdn \
   1.183 @@ -527,35 +531,31 @@
   1.184          --without-vpb \
   1.185          --without-sdl \
   1.186          --without-x11 \
   1.187 -        --without-gtk \
   1.188          --without-gtk2
   1.189  
   1.190      #   build menuselect
   1.191      %{l_make} %{l_mflags -O} menuselect.makeopts
   1.192 -    %{l_shtool} subst \
   1.193 -        -e 's;\(MENUSELECT_MOH=\).*;\1;' \
   1.194 -        -e 's;\(MENUSELECT_CORE_SOUNDS=\).*;\1;' \
   1.195 -        -e 's;\(MENUSELECT_EXTRA_SOUNDS=\).*;\1;' \
   1.196 +    menuselect/menuselect \
   1.197 +        --enable format_mp3 --enable app_fax --enable codec_ilbc \
   1.198 +        --enable RADIO_RELAX --enable G711_NEW_ALGORITHM \
   1.199 +        --enable G711_REDUCED_BRANCHING --enable CORE-SOUNDS-EN-SLN16 \
   1.200 +        --enable CORE-SOUNDS-ES-SLN16 --enable CORE-SOUNDS-FR-SLN16 \
   1.201 +        --enable CORE-SOUNDS-EN_AU-SLN16 --enable CORE-SOUNDS-RU-SLN16 \
   1.202 +        --enable MOH-OPSOUND-SLN16 --enable EXTRA-SOUNDS-EN-SLN16 \
   1.203 +        --enable EXTRA-SOUNDS-FR-SLN16 \
   1.204 +        menuselect.makeopts
   1.205 +    menuselect/menuselect \
   1.206 +        --disable CORE-SOUNDS-EN-GSM \
   1.207 +        --disable MOH-OPSOUND-WAV \
   1.208          menuselect.makeopts
   1.209  %if "%{with_imap}" == "yes"
   1.210 -    %{l_shtool} subst \
   1.211 -        -e 's;\(MENUSELECT_OPTS_app_voicemail=\).*;\1IMAP_STORAGE;' \
   1.212 -        menuselect.makeopts
   1.213 +    menuselect/menuselect --enable IMAP_STORAGE menuselect.makeopts
   1.214  %endif
   1.215  
   1.216      #   build program
   1.217      %{l_make} %{l_mflags -O} \
   1.218          CC="%{l_cc} $cflags -I../include -I../../include $cppflags" NOISY_BUILD=yes
   1.219  
   1.220 -    #   build addon modules
   1.221 -    ( cd addons
   1.222 -      %{l_make} %{l_mflags -O} \
   1.223 -          CC="%{l_cc} %{l_cflags -O} -I../../include %{l_cppflags ncurses}" NOISY_BUILD=yes ASTTOPDIR=..
   1.224 -    ) || exit $?
   1.225 -
   1.226 -    #   build agi programs
   1.227 -    ( cd agi && %{l_make} %{l_mflags -O}) || exit $?
   1.228 -
   1.229  %if "%{with_capi}" == "yes"
   1.230      #   build capi channel
   1.231      ( cd chan_capi-*
   1.232 @@ -574,14 +574,6 @@
   1.233          DESTDIR=$RPM_BUILD_ROOT \
   1.234          INSTALL_PREFIX=%{l_prefix}
   1.235  
   1.236 -    #   install addon modules
   1.237 -    ( cd addons
   1.238 -      %{l_make} %{l_mflags} install \
   1.239 -          ASTTOPDIR=.. \
   1.240 -          DESTDIR=$RPM_BUILD_ROOT \
   1.241 -          INSTALL_PREFIX=%{l_prefix}
   1.242 -    ) || exit $?
   1.243 -
   1.244  %if "%{with_capi}" == "yes"
   1.245      #   install capi channel
   1.246      ( cd chan_capi-*
   1.247 @@ -726,15 +718,19 @@
   1.248      rm -f $RPM_BUILD_ROOT%{l_prefix}/man/man8/autosupport.8 >/dev/null 2>&1 || true
   1.249      rm -f $RPM_BUILD_ROOT%{l_prefix}/man/man8/safe_asterisk.8 >/dev/null 2>&1 || true
   1.250      rm -rf $RPM_BUILD_ROOT%{l_prefix}/share/asterisk/images >/dev/null 2>&1 || true
   1.251 +    rm -rf $RPM_BUILD_ROOT%{l_prefix}/share/asterisk/moh/.asterisk* >/dev/null 2>&1 || true
   1.252      rm -rf $RPM_BUILD_ROOT%{l_prefix}/share/asterisk/moh/CREDIT* >/dev/null 2>&1 || true
   1.253      rm -rf $RPM_BUILD_ROOT%{l_prefix}/share/asterisk/moh/CHANGES* >/dev/null 2>&1 || true
   1.254 +    rm -rf $RPM_BUILD_ROOT%{l_prefix}/share/asterisk/moh/LICENSE* >/dev/null 2>&1 || true
   1.255      rm -rf $RPM_BUILD_ROOT%{l_prefix}/share/asterisk/sounds/*/CREDIT* >/dev/null 2>&1 || true
   1.256      rm -rf $RPM_BUILD_ROOT%{l_prefix}/share/asterisk/sounds/*/CHANGES* >/dev/null 2>&1 || true
   1.257 +    rm -rf $RPM_BUILD_ROOT%{l_prefix}/share/asterisk/sounds/*/.asterisk* >/dev/null 2>&1 || true
   1.258  
   1.259      #   create additional directories
   1.260      %{l_shtool} mkdir -f -p -m 755 \
   1.261          $RPM_BUILD_ROOT%{l_prefix}/var/asterisk/db \
   1.262 -        $RPM_BUILD_ROOT%{l_prefix}/var/asterisk/spool/facsimile \
   1.263 +        $RPM_BUILD_ROOT%{l_prefix}/var/asterisk/spool/facsimile/rx \
   1.264 +        $RPM_BUILD_ROOT%{l_prefix}/var/asterisk/spool/facsimile/tx \
   1.265          $RPM_BUILD_ROOT%{l_prefix}/var/asterisk/spool/outgoing \
   1.266          $RPM_BUILD_ROOT%{l_prefix}/share/asterisk/licenses
   1.267  
   1.268 @@ -786,8 +782,9 @@
   1.269      #   determine installation files
   1.270      %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT \
   1.271          %{l_files_std} \
   1.272 +        '%config %attr(640,%{l_mgrp},%{l_rgrp}) %{l_prefix}/etc/asterisk/*' \
   1.273          '%config %attr(-,%{l_mgrp},%{l_mgrp}) %{l_prefix}/share/asterisk/licenses' \
   1.274 -        '%config %attr(640,%{l_mgrp},%{l_rgrp}) %{l_prefix}/etc/asterisk/*' \
   1.275 +        '%attr(750,%{l_rgrp},%{l_rgrp}) %{l_prefix}/var/asterisk/spool/facsimile' \
   1.276          '%attr(-,%{l_rusr},%{l_rgrp}) %{l_prefix}/var/asterisk'
   1.277  
   1.278  #        '%attr(-,%{l_rusr},%{l_rgrp}) %{l_prefix}/share/asterisk/sounds/es/vm-Voicemail.sln16' \
   1.279 @@ -838,7 +835,7 @@
   1.280      ( echo "Asterisk has been installed with proprietary Digium fax support."
   1.281        echo "The responsible module is called res_fax_digium and requires a"
   1.282        echo "valid license. The license must be found in the directory"
   1.283 -      echo "'licenses' which in turn must be found in $prefix/share/asterisk"
   1.284 +      echo "'licenses' which in turn must be found in %{l_prefix}/share/asterisk"
   1.285        echo "or wherever astvarlibdir has been configured in 'asterisk.conf'."
   1.286        echo ""
   1.287        echo "Please see http://downloads.digium.com/pub/telephony/fax/ for information."

mercurial