]> git.pld-linux.org Git - packages/asterisk.git/blobdiff - asterisk.spec
- use external libedit
[packages/asterisk.git] / asterisk.spec
index 53652574c6ba2c35ea8b7d412514c946ca47a0a6..668abb3bdd4f9b4f8895db92b7214e74ef6e3566 100644 (file)
@@ -9,6 +9,8 @@
 # Conditional build:
 %bcond_with    rxfax           # without rx (also tx :-D) fax
 %bcond_with    bluetooth       # without bluetooth support (NFT)
+%bcond_without h323            # With H.323 support
+%bcond_with    zaptel          # zaptel instead of dahdi
 %bcond_with    zhone           # zhone hack
 %bcond_with    zhone_hack      # huge hack workarounding broken zhone channel banks which start randomly
                                # issuing pulse-dialled calls to weird numbers
 Summary:       Asterisk PBX
 Summary(pl.UTF-8):     Centralka (PBX) Asterisk
 Name:          asterisk
-Version:       1.4.22
+Version:       1.4.44
 Release:       1%{?with_bristuff:.bristuff}
 License:       GPL v2
 Group:         Applications/System
-Source0:       http://ftp.digium.com/pub/asterisk/releases/%{name}-%{version}.tar.gz
-# Source0-md5: 7626febc4a01e16e012dfccb9e4ab9d2
+Source0:       http://downloads.digium.com/pub/asterisk/releases/%{name}-%{version}.tar.gz
+# Source0-md5: 31daa6d5702f58bea1448e9ef45c9c8e
 Source1:       %{name}.init
 Source2:       %{name}.sysconfig
-Source3:       http://ftp.digium.com/pub/telephony/sounds/releases/asterisk-core-sounds-en-gsm-1.4.6.tar.gz
+Source3:       http://downloads.digium.com/pub/telephony/sounds/releases/asterisk-core-sounds-en-gsm-1.4.6.tar.gz
 # Source3-md5: 02e582b6c7de58e5eaba220229c0a71a
-Source4:       http://ftp.digium.com/pub/telephony/sounds/asterisk-moh-freeplay-wav.tar.gz
+Source4:       http://downloads.digium.com/pub/telephony/sounds/asterisk-moh-freeplay-wav.tar.gz
 # Source4-md5: e523fc2b4ac524f45da7815e97780540
 Source5:       %{name}.logrotate
 Patch0:                %{name}-m4.patch
 Patch1:                %{name}-configure.patch
 Patch2:                %{name}-no_k6_on_sparc.patch
 Patch3:                %{name}-lib.patch
+Patch4:                %{name}-external-libedit.patch
 Source10:      http://soft-switch.org/downloads/spandsp/spandsp-%{_spandsp_version}/asterisk-1.2.x/app_txfax.c
 # Source10-md5:        8c8fcb263b76897022b4c28052a7b439
 Source11:      http://soft-switch.org/downloads/spandsp/spandsp-%{_spandsp_version}/asterisk-1.2.x/app_rxfax.c
@@ -56,11 +59,17 @@ BuildRequires:      autoconf
 BuildRequires: automake
 BuildRequires: bison
 %{?with_bluetooth:BuildRequires: bluez-devel}
+%if %{with zaptel}
+BuildRequires: zaptel-devel >= 1.2.10
+%else
+BuildRequires: dahdi-linux-devel
+%endif
 BuildRequires: freetds >= 0.63
 BuildRequires: gawk
 BuildRequires: gcc >= 5:3.4
 BuildRequires: iksemel-devel
 BuildRequires: imap-static
+BuildRequires: libedit-devel
 BuildRequires: mysql-devel
 BuildRequires: ncurses-devel
 BuildRequires: openssl-devel >= 0.9.7d
@@ -69,10 +78,11 @@ BuildRequires:      sed >= 4.0
 %{?with_rxfax:BuildRequires:   spandsp-devel-%{_spandsp_version}}
 BuildRequires: speex-devel
 BuildRequires: unixODBC-devel
-BuildRequires: zaptel-devel >= 1.2.10
 BuildRequires: zlib-devel
+%if %{with h323}
 BuildRequires: openh323-devel
 BuildRequires: pwlib-devel
+%endif
 %if %{with bristuff}
 BuildRequires: libgsmat-devel
 BuildRequires: libpri-bristuff-devel >= 1.2.4
@@ -81,8 +91,10 @@ BuildRequires:  libpri-devel >= 1.2.4
 %endif
 Requires(post,preun):  /sbin/chkconfig
 Requires:      rc-scripts
+%if %{with h323}
 %requires_eq   openh323
 %requires_eq   pwlib
+%endif
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %description
@@ -138,7 +150,7 @@ Pliki przykładowe dla centralki Asterisk.
 
 %{?with_zhone:sed -i -e 's|.*#define.*ZHONE_HACK.*|#define ZHONE_HACK 1|g' channels/chan_dahdi.c}
 
-%patch0 -p0
+#%patch0 -p0
 #%patch1 -p1
 #%patch2 -p1
 #%patch3 -p1
@@ -146,6 +158,7 @@ Pliki przykładowe dla centralki Asterisk.
 #%patch6 -p1
 #%patch7 -p1
 #%patch9 -p1
+%patch4 -p1
 
 %if %{with rxfax}
 cd apps
@@ -154,7 +167,7 @@ cp %{SOURCE10} .
 cp %{SOURCE11} .
 %endif
 
-%patch11 -p1
+#%patch11 -p1
 
 %{?with_bluetooth:%patch12 -p1}
 %{?with_zhonehack:%patch13 -p1}
@@ -163,7 +176,7 @@ cp %{SOURCE11} .
 %patch15 -p1
 %patch16 -p1
 %endif
-%patch17 -p2
+#%patch17 -p2
 
 sed -i -e "s#/usr/lib/#/usr/%{_lib}/#g#" Makefile
 
@@ -175,15 +188,28 @@ echo '-lssl -lpam' > imap/c-client/LDFLAGS
 %build
 rm -f pbx/.depend
 
-%{__aclocal}
+%{__aclocal} -I autoconf
 %{__autoheader}
 %{__autoconf}
 
-CPPFLAGS="-I/usr/include/openh323"; export CPPFLAGS
+CPPFLAGS="%{rpmcppflags} -I/usr/include/imap"; export CPPFLAGS
+%if %{with h323}
+CPPFLAGS="$CPPFLAGS -I/usr/include/openh323"; export CPPFLAGS
+%endif
 %configure \
+%if %{with zaptel}
+       --with-zaptel=%{_prefix} \
+       --without-dahdi \
+%else
+       --with-dahdi=%{_prefix} \
+       --without-zaptel \
+%endif
+       --without-osptk \
+       %{!?with_h323:--without-h323} \
        %{?with_bristuff:--with-gsmat=%{_prefix}} \
        --with-imap="`pwd`"/imap
 
+
 # safe checks
 %{?with_bristuff:grep '^#define HAVE_GSMAT 1' include/asterisk/autoconfig.h || exit 1}
 
@@ -262,9 +288,11 @@ fi
 %dir /var/lib/asterisk/images
 %dir /var/lib/asterisk/keys
 %dir /var/lib/asterisk/moh
-/var/lib/asterisk/moh/fpm-calm-river.wav
-/var/lib/asterisk/moh/fpm-sunshine.wav
-/var/lib/asterisk/moh/fpm-world-mix.wav
+/var/lib/asterisk/moh/macroform-cold_day.wav
+/var/lib/asterisk/moh/macroform-robot_dity.wav
+/var/lib/asterisk/moh/macroform-the_simplicity.wav
+/var/lib/asterisk/moh/manolo_camp-morning_coffee.wav
+/var/lib/asterisk/moh/reno_project-system.wav
 %dir /var/lib/asterisk/sounds
 %dir /var/lib/asterisk/sounds/digits
 %dir /var/lib/asterisk/sounds/dictate
@@ -295,7 +323,7 @@ fi
 %{_mandir}/man8/safe_asterisk.8*
 %dir /var/lib/asterisk/firmware
 %dir /var/lib/asterisk/firmware/iax
-/var/lib/asterisk/firmware/iax/iaxy.bin
+#/var/lib/asterisk/firmware/iax/iaxy.bin
 
 %files examples
 %defattr(644,root,root,755)
This page took 0.049235 seconds and 4 git commands to generate.