wanpipe/rpmspec/wanpipe.spec

498 lines
16 KiB
RPMSpec
Raw Normal View History

2021-12-29 16:59:00 +00:00
%define KERNEL_VERSION %{?kern_ver}
2021-12-29 16:56:27 +00:00
%define WANPIPE_VER wanpipe
%define name %{WANPIPE_VER}
2021-12-29 17:19:24 +00:00
%define version 3.3.4
2021-12-29 17:02:04 +00:00
%define release 0
2021-12-29 16:56:27 +00:00
%define serial 1
%define UTILS_DIR /usr/sbin
2021-12-29 17:14:12 +00:00
%define ETC_DIR /etc
%define USR_DIR /usr
2021-12-29 16:56:27 +00:00
%define PROD_HOME /etc/wanpipe
%define WANCFG_LIBS_DIR /etc/wanpipe/lib
%define API_DIR /etc/wanpipe/api
%define DOCS_DIR /usr/share/doc/wanpipe
2021-12-29 16:59:00 +00:00
%define USR_INCLUDE_DIR /usr/include
%define LIBSANGOMA_CONF /etc/ld.so.conf.d/libsangoma.so.conf
2021-12-29 16:56:27 +00:00
%define PROD wanrouter
%define MODULES_DIR /lib/modules
%define META_CONF %{PROD_HOME}/%{PROD}.rc
%define WAN_INTR_DIR %{PROD_HOME}/interfaces
%define WAN_CONF_DIR %{PROD_HOME}
%define PROD_CONF %{WAN_CONF_DIR}/wanpipe1.conf
2021-12-29 16:59:00 +00:00
%define START_SCRIPT S07%{PROD}
%define OLD_START S07router
%define STOP_SCRIPT K90%{PROD}
%define OLD_STOP K900router
2021-12-29 16:56:27 +00:00
%define ROUTER_RC %{META_CONF}
%define WANROUTER_STARTUP_SMPL %{PROD_HOME}/samples/wanrouter
%define WANROUTER_STARTUP /usr/sbin/wanrouter
%define NEW_IF_TYPE NO
%define PROD_INIT /usr/sbin/
2021-12-29 16:59:00 +00:00
%define KVERSION %{?kern_ver}
2021-12-29 16:56:27 +00:00
Summary: Sangoma WANPIPE package for Linux. It contains the WANPIPE kernel drivers and configuration/startup/debugging utilities for Linux.
2021-12-29 16:59:00 +00:00
Name: %{name}-%{?kern_ver}
2021-12-29 16:56:27 +00:00
Version: %{version}
2021-12-29 16:59:00 +00:00
Release: %{release}
License: GPL
Group: Applications/Communications
2021-12-29 16:56:27 +00:00
Vendor: Sangoma Technologies Inc.
Url: www.sangoma.com
Group: Networking/WAN
%description
2021-12-29 16:59:00 +00:00
Linux Drivers for Sangoma AFT Series of cards and S Series of Cards. Wanpipe supports the following protocols, TDM Voice, Frame Relay, X25(API), PPP, Multi-link PPP, CHDLC and custom API development for WAN and Voice.
2021-12-29 16:56:27 +00:00
%prep
%build
%install
%clean
%postun
echo "Uninstalling WANPIPE..."
# ----------------------------------------------------------------------------
# Remove initialization scripts.
# ----------------------------------------------------------------------------
remove_init()
2021-12-29 16:59:00 +00:00
{
chkconfig --del wanrouter
rm /etc/init.d/wanrouter
}
remove_init_old()
2021-12-29 16:56:27 +00:00
{
# Examine system bootstrap files.
if [ -d /etc/rc0.d ]
then RC_DIR=/etc
elif [ -d /etc/rc.d/rc0.d ]
then RC_DIR=/etc/rc.d
else return 0
fi
echo "Removing start-up scripts..."
rm -f $RC_DIR/rc2.d/%{START_SCRIPT}
rm -f $RC_DIR/rc3.d/%{START_SCRIPT}
rm -f $RC_DIR/rc4.d/%{START_SCRIPT}
rm -f $RC_DIR/rc5.d/%{START_SCRIPT}
rm -f $RC_DIR/rc0.d/%{STOP_SCRIPT}
rm -f $RC_DIR/rc1.d/%{STOP_SCRIPT}
rm -f $RC_DIR/rc6.d/%{STOP_SCRIPT}
rm -f $RC_DIR/init.d/%{PROD}
return 0
}
#remove start-on-boot scripts
remove_init;
%post
# ----------------------------------------------------------------------------
# Create meta-configuration file.
# ----------------------------------------------------------------------------
create_metaconf()
{
local response
# Select directory for the log file.
if [ -d /var/log ]; then
LOG_FILE=/var/log/%{PROD}
elif [ -d /var/adm wanpipe1]; then
LOG_FILE=/var/adm/%{PROD}
else
LOG_FILE=%{PROD_HOME}/%{PROD}.log
fi
# Select directory for the lock file.
if [ -d /var/lock/subsys ]; then
LOCK_FILE=/var/lock/subsys/%{PROD}
elif [ -d /var/lock ]; then
LOCK_FILE=/var/lock/%{PROD}
else
LOCK_FILE=$PROD_HOME/%{PROD}.lck
fi
cat > %{META_CONF} << ENDOFTEXT
#!/bin/sh
2021-12-29 16:59:00 +00:00
# wanrouter.rc WAN router meta-configuration file.
2021-12-29 16:56:27 +00:00
#
2021-12-29 16:59:00 +00:00
# This file defines variables used by the router shell scripts
# and should be located in /etc/wanpipe directory. These are:
2021-12-29 16:56:27 +00:00
#
2021-12-29 16:59:00 +00:00
# ROUTER_BOOT = Boot flag (YES/NO).
# WAN_CONF_DIR = Where to put wanpipe config files.
# WAN_INTR_DIR = Where to put wanpipe interface files.
# WAN_LOG = Where to put start-up log file.
# WAN_LOCK = File used as a lock.
# WAN_LOCK_DIR =
# WAN_IP_FORWARD = Enable IP Forwarding on startup.
# WAN_DEVICES = Name of the wanpipe devices to be
2021-12-29 16:56:27 +00:00
# loaded on 'wanrouter start'
# (ex: "wanpipe1 wanpipe2 wanpipe3...")
#
# Note: Name of wanpipe devices correspond
# to the configuration files in
# WANPIPE_CONF_DIR directory:
2021-12-29 16:59:00 +00:00
# (ex. /etc/wanpipe/wanpipe1.conf )
2021-12-29 16:56:27 +00:00
#
# Note: This file is 'executed' by the shell script, so
2021-12-29 16:59:00 +00:00
# the usual shell syntax must be observed.
2021-12-29 16:56:27 +00:00
ENDOFTEXT
2021-12-29 16:59:00 +00:00
echo "ROUTER_BOOT=YES" >> %{META_CONF}
echo "WAN_CONF_DIR=%{WAN_CONF_DIR}" >> %{META_CONF}
echo "WAN_INTR_DIR=%{WAN_INTR_DIR}" >> %{META_CONF}
echo "WAN_LOG=$LOG_FILE" >> %{META_CONF}
echo "WAN_LOCK=$LOCK_FILE" >> %{META_CONF}
echo "WAN_LOCK_DIR=/var/lock/subsys" >> %{META_CONF}
echo "WAN_IP_FORWARD=NO" >> %{META_CONF}
echo "NEW_IF_TYPE=NO" >> %{META_CONF}
echo "WAN_LIB_DIR=/etc/wanpipe/lib" >> %{META_CONF}
echo "WAN_ADSL_LIST=/etc/wanpipe/wan_adsl.list" >> %{META_CONF}
echo "WAN_ANNEXG_LOAD=NO" >> %{META_CONF}
echo "WAN_LIP_LOAD=YES" >> %{META_CONF}
echo "WAN_DYN_WANCONFIG=NO" >> %{META_CONF}
echo "WAN_SCRIPTS_DIR=/etc/wanpipe/scripts" >> %{META_CONF}
echo "WAN_FIRMWARE_DIR=/etc/wanpipe/firmware" >> %{META_CONF}
echo "WAN_DEVICES_REV_STOP_ORDER=YES" >> %{META_CONF}
echo "WAN_DEVICES=\"wanpipe1\"" >> %{META_CONF}
2021-12-29 16:56:27 +00:00
return 0
}
# ----------------------------------------------------------------------------
# Install initialization scripts.
# ----------------------------------------------------------------------------
2021-12-29 17:12:33 +00:00
install_init()
2021-12-29 16:59:00 +00:00
{
ln -s /usr/sbin/wanrouter /etc/init.d/wanrouter
chkconfig wanrouter on
}
install_init_old()
2021-12-29 16:56:27 +00:00
{
#Examine system bootstrap files.
if [ -d /etc/rc0.d ]
then RC_DIR=/etc
elif [ -d /etc/rc.d/rc0.d ]
then RC_DIR=/etc/rc.d
else return 0
fi
PROD_INIT=%{PROD_INIT}%{PROD}
# Install start scripts.
[ -d $RC_DIR/rc2.d ] && ln -sf $PROD_INIT $RC_DIR/rc2.d/%{START_SCRIPT}
[ -d $RC_DIR/rc3.d ] && ln -sf $PROD_INIT $RC_DIR/rc3.d/%{START_SCRIPT}
[ -d $RC_DIR/rc5.d ] && ln -sf $PROD_INIT $RC_DIR/rc4.d/%{START_SCRIPT}
[ -d $RC_DIR/rc5.d ] && ln -sf $PROD_INIT $RC_DIR/rc5.d/%{START_SCRIPT}
# Install stop scripts.
[ -d $RC_DIR/rc0.d ] && ln -sf $PROD_INIT $RC_DIR/rc0.d/%{STOP_SCRIPT}
[ -d $RC_DIR/rc1.d ] && ln -sf $PROD_INIT $RC_DIR/rc1.d/%{STOP_SCRIPT}
[ -d $RC_DIR/rc6.d ] && ln -sf $PROD_INIT $RC_DIR/rc6.d/%{STOP_SCRIPT}
[ -d $RC_DIR/init.d ] && ln -sf $PROD_INIT $RC_DIR/init.d/%{PROD}
return 0
}
if [ -d "/usr/local/wanrouter" ]; then
cat <<EOM
*** Previous installation of Wanpipe detected.
Please use /usr/sbin/wancfg instead of /usr/local/wanrouter/wancfg
for Wanpipe configuration.
The new configuration files will be saved in /etc/wanpipe
and /etc/wanpipe/interfaces directories.
EOM
else
echo 'no old wanpipe detected' > /dev/null
fi
cat <<EOM
*** Sangoma Wanpipe was successfully installed.
Run wancfg command to configure wanpipe.
Refer to %{DOCS_DIR} for documentation.
Docs: README-2.config
README-3.operation
README-4.debugging
Hardware Probe: /usr/sbin/wanrouter hwprobe
Wanpipe Config: /usr/sbin/wancfg
Wanpipe Start : /usr/sbin/wanrouter start
EOM
#check dependancies for the new modules
2021-12-29 16:59:00 +00:00
depmod -ae -F /boot/System.map-%{KVERSION} %{KVERSION}
echo "Wanpipe Modules located in %{MODULES_DIR}/%{KVERSION}"
2021-12-29 16:56:27 +00:00
#install start-on-boot scripts
install_init;
#create wanrouter.rc in /etc/wanpipe
#create_metaconf;
%files
2021-12-29 16:59:00 +00:00
%{UTILS_DIR}
2021-12-29 17:14:12 +00:00
%{ETC_DIR}
%{USR_DIR}
2021-12-29 16:56:27 +00:00
%{PROD_HOME}
%{DOCS_DIR}
%{MODULES_DIR}
2021-12-29 16:59:00 +00:00
%{USR_INCLUDE_DIR}
2021-12-29 16:56:27 +00:00
%changelog
2021-12-29 17:16:45 +00:00
2021-12-29 17:19:24 +00:00
* Wed Mar 26 2008 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.4
======================================================================
- BRI TE auto clocking feature - Bug fix
This feature failed on on some machines with multiple TE BRI modules.
This bug would cause modules to loose sync. Bug introduced in 3.3.3
release.
2021-12-29 17:19:00 +00:00
* Tue Mar 25 2008 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.3
======================================================================
- BRI TE auto clocking feature.
Where a connected TE port is elected
as the telco clock recovery port for the whole card. If that TE
port goes down, another connected TE port is found to provide
telco recovery clock to the card. If no connected TE ports are found
then internal oscillator is used.
-> This option is fully automatic no configuration options needed.
- BRI Zaptel Clock Source
Since BRI does not interface to zaptel, it acts as ZT DUMMY to
provide zaptel reliable timing. One has to configure
TDMV_DUMMY=YES in [wanpipe1] section of wanpipe1.conf
2021-12-29 17:19:24 +00:00
- A200/A400 Remora Relax CFG
2021-12-29 17:19:00 +00:00
If one module fails during operation the wanpipe driver by default
fails to load. With this option wanpipe driver
will allow the card to come up with a broken module so that
customer will be able to continue working until the module is replaced.
RM_RELAX_CFG=YES in [wanpipe1] section of wanpipe1.conf
* Fri Feb 14 2008 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.2.1
======================================================================
- Added DTR API for Serial S514X Card
Ability to read and set the DTR/RTS on serial cards throught the API.
Sample code in wanpipe-3.3.2.1/api/chdlc/chdlc_modem_cmd.c
2021-12-29 17:18:25 +00:00
* Wed Feb 12 2008 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.2
======================================================================
2021-12-29 17:16:45 +00:00
2021-12-29 17:18:25 +00:00
- Support for A500 hardware support with NetBricks BRI Stack
- Major A500 driver updates and fixes
- Serial A142/A144 hardware support
- AFT A056 56K hardware support
2021-12-29 17:16:45 +00:00
2021-12-29 17:18:25 +00:00
- Support for HW DTMF
2021-12-29 17:16:45 +00:00
2021-12-29 17:18:25 +00:00
- Updates for AFT PMC and MAXIM framers
PMC - lowered LOS sensitivity
Fixes fake up/down state changes on
started inactive lines.
2021-12-29 17:16:17 +00:00
2021-12-29 17:18:25 +00:00
MAXIM - lowered sensistivy
Fixes cable cross talk on 8 port cards.
- Enabled Unframed E1
- Enabled Tri-State Mode
- Fixed loopback commands
2021-12-29 17:16:17 +00:00
2021-12-29 17:18:25 +00:00
- Updated loopback commands for AFT Maxim cards
2021-12-29 17:16:17 +00:00
2021-12-29 17:18:25 +00:00
- Updated for AstLinux
The make file can now build all WAN and Voice Protocols
- Updated legacy protocols for new front end architecture
2021-12-29 17:16:17 +00:00
2021-12-29 17:18:25 +00:00
-
2021-12-29 17:16:17 +00:00
2021-12-29 17:18:25 +00:00
* Fri Feb 01 2008 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.2.p8
======================================================================
2021-12-29 17:16:17 +00:00
2021-12-29 17:18:25 +00:00
- wancfg_zaptel now asks for the default_tei value for
- BRI cards in TE mode
2021-12-29 17:16:17 +00:00
2021-12-29 17:18:25 +00:00
- Fix for HWEC not being enabled when non-consecutive modules are using
- in BRI cards
2021-12-29 17:16:17 +00:00
2021-12-29 17:18:25 +00:00
* Fri Feb 01 2008 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.2.p4
======================================================================
2021-12-29 17:16:17 +00:00
2021-12-29 17:18:25 +00:00
- Fixed AFT memory leak
Memory leak introduced in 3.3 release
- Fixed AFT 56K bug
Bug introduced in 3.3 releae
2021-12-29 17:16:17 +00:00
2021-12-29 17:18:25 +00:00
* Fri Feb 01 2008 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.2.p3
======================================================================
2021-12-29 17:16:17 +00:00
2021-12-29 17:18:25 +00:00
- Fix bug in BRI protocol for fast local hangups.
2021-12-29 17:16:17 +00:00
2021-12-29 17:18:25 +00:00
* Mon Jan 18 2008 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.2.p1
======================================================================
2021-12-29 17:16:17 +00:00
2021-12-29 17:18:25 +00:00
- Bug fix in Hardware EC code for E1.
Bug introduced in 3.3 release.
2021-12-29 17:16:17 +00:00
2021-12-29 17:18:25 +00:00
* Mon Jan 18 2008 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.1
====================================================================
2021-12-29 17:15:48 +00:00
2021-12-29 17:18:25 +00:00
* Mon Jan 16 2008 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.0.22
====================================================================
2021-12-29 17:15:48 +00:00
2021-12-29 17:18:25 +00:00
- BRI protocol:Increased internal timer that could cause issue in systems with
- more than 8 BRI spans
2021-12-29 17:15:08 +00:00
2021-12-29 17:18:25 +00:00
* Mon Jan 15 2008 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.0.21
====================================================================
2021-12-29 17:14:45 +00:00
2021-12-29 17:18:25 +00:00
- BRI protocol:Fix for smg_brid daemon crashing on race condition
- BRI protocol:default_tei parameter is not ignored when using point to
- multipoint anymore
2021-12-29 17:15:08 +00:00
2021-12-29 17:18:25 +00:00
* Mon Jan 14 2008 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.0.20
====================================================================
2021-12-29 17:15:08 +00:00
2021-12-29 17:18:25 +00:00
- BRI protocol: Additional prefix options.
- BRI protocol: Check is caller ID number is all digits on incoming calls
- Sangoma MGD: Removed dynamic user period causing skb panics
- chan_woomera: Fixed issue with rxgain and txgain values set to 0 if
- coding not set in woomera.conf
- wancfg_zaptel: Support for fractional T1/E1 spans.
- wancfg_zaptel: fix issue BRI always being configured as bri_net introduced in v3.3.0.19
2021-12-29 17:15:08 +00:00
2021-12-29 17:18:25 +00:00
* Mon Jan 07 2008 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.0.19
====================================================================
2021-12-29 17:15:08 +00:00
2021-12-29 17:18:25 +00:00
- Support for national/international prefix in BRI stack
2021-12-29 17:15:08 +00:00
2021-12-29 17:18:25 +00:00
* Mon Jan 07 2008 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.0.18
====================================================================
2021-12-29 17:15:08 +00:00
2021-12-29 17:18:25 +00:00
- Changed Makefile in wanpipe/api/fr causing compilation errors
2021-12-29 17:15:08 +00:00
2021-12-29 17:14:45 +00:00
2021-12-29 17:18:25 +00:00
* Thu Dec 20 2007 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.0.17
====================================================================
2021-12-29 17:14:45 +00:00
2021-12-29 17:18:25 +00:00
- Fix for smg_ctrl boot script starting before network services on some systems
- Support for language parameter in chan_woomera
2021-12-29 17:14:12 +00:00
2021-12-29 17:18:25 +00:00
* Thu Dec 20 2007 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.0.16
====================================================================
2021-12-29 17:14:12 +00:00
2021-12-29 17:18:25 +00:00
- Fix for Sangoma BRI Daemon crashing on incoming call if chan_woomera is not installed on that system
2021-12-29 17:14:12 +00:00
2021-12-29 17:18:25 +00:00
* Tue Dec 18 2007 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.0.15
====================================================================
- Fix for caller ID value being corrupted sometimes
- Support for call confirmation in chan_woomera
* Tue Dec 18 2007 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.0.14
====================================================================
- Fix in smg_brid not releasing some b-channels properly
- Fix in wancfg_smg not setting MTU to 80 when configuring cards for SS7
* Fri Dec 14 2007 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.0.13
====================================================================
2021-12-29 17:14:12 +00:00
2021-12-29 17:18:25 +00:00
- Fix for Kernel panic on 64-bit systems when enabling hardware echo canceller
2021-12-29 17:14:12 +00:00
2021-12-29 17:18:25 +00:00
* Thu Dec 5 2007 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.0.11
====================================================================
2021-12-29 17:14:12 +00:00
2021-12-29 17:18:25 +00:00
- Support for AFT Serial Cards
2021-12-29 17:14:12 +00:00
- Updates for AFT PMC and MAXIM framers
PMC - lowered LOS sensitivity
Fixes fake up/down state changes on
started inactive lines.
MAXIM - lowered sensistivy
Fixes cable cross talk on 8 port cards.
- Enabled Unframed E1
- Enabled Tri-State Mode
- Fixed loopback commands
- Fixed HWEC_PERSIST_DISABLE
This option was broken in previous release
This option lets Asterisk control HWEC
on each call start/stop.
By default all hwec channels are enabled on
device startup.
- Updated SMG/SS7
- Updated loopback commands for AFT Maxim cards
- Updated for AstLinux
The make file can now build all WAN and Voice Protocols
- Fixed add_timer warnings for ALL AFT cards
Caused when a port is left in unconnected state.
- Updated legacy protocols for new front end architecture
- Updated Setup script
2021-12-29 17:03:04 +00:00
2021-12-29 17:18:25 +00:00
* Thu Nov 8 2007 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.0.4
====================================================================
2021-12-29 17:03:04 +00:00
2021-12-29 17:18:25 +00:00
- Fixed A101/2 (Old) bug introduced in previous releaes
2021-12-29 17:03:04 +00:00
2021-12-29 17:18:25 +00:00
* Mon Oct 31 2007 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.0.4
====================================================================
2021-12-29 17:03:04 +00:00
2021-12-29 17:18:25 +00:00
- Updated BRI caller name
- Updaged Setup
2021-12-29 17:03:04 +00:00
2021-12-29 17:00:21 +00:00
2021-12-29 17:18:25 +00:00
* Mon Oct 15 2007 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.0.1
2021-12-29 16:59:00 +00:00
====================================================================
2021-12-29 17:18:25 +00:00
- Major Updates
- New BRI architecture/support
SMG with Netbricks BRI Stack
- Support for Hardware DTMF
2021-12-29 16:59:00 +00:00
2021-12-29 17:18:25 +00:00
* Thu Aug 22 2007 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.0.p3
======================================================================
2021-12-29 16:56:27 +00:00
2021-12-29 17:18:25 +00:00
- Updated wancfg_zaptel to support HW DTMF
2021-12-29 16:56:27 +00:00
2021-12-29 17:18:25 +00:00
* Thu Aug 21 2007 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.3.0.p2
======================================================================
2021-12-29 16:56:27 +00:00
2021-12-29 17:18:25 +00:00
- Major Updates
- Hardware DTMF for Asterisk and TDM API
2021-12-29 16:59:00 +00:00
- - END -