提交 e7d04724 authored 作者: Ken Rice's avatar Ken Rice 提交者: Travis Cross

centos: rework CentOS spec files

 * break out modules
 * conform to FHS
 * support CentOS v5
上级 08d8a1a7
...@@ -7,8 +7,8 @@ ...@@ -7,8 +7,8 @@
# chkconfig: 345 89 14 # chkconfig: 345 89 14
# description: Starts and stops the freeswitch server daemon # description: Starts and stops the freeswitch server daemon
# processname: freeswitch # processname: freeswitch
# config: /opt/freeswitch/conf/freeswitch.conf # config: /usr/local/freeswitch/conf/freeswitch.conf
# pidfile: /opt/freeswitch/run/freeswitch.pid # pidfile: /usr/local/freeswitch/run/freeswitch.pid
# #
# Source function library. # Source function library.
...@@ -17,13 +17,13 @@ ...@@ -17,13 +17,13 @@
PROG_NAME=freeswitch PROG_NAME=freeswitch
PID_FILE=${PID_FILE-/var/run/freeswitch/freeswitch.pid} PID_FILE=${PID_FILE-/var/run/freeswitch/freeswitch.pid}
FS_USER=${FS_USER-freeswitch} FS_USER=${FS_USER-freeswitch}
FS_FILE=${FS_FILE-/opt/freeswitch/bin/freeswitch} FS_FILE=${FS_FILE-/usr/freeswitch}
FS_HOME=${FS_HOME-/opt/freeswitch} FS_HOME=${FS_HOME-/var/run/freeswitch}
LOCK_FILE=/var/lock/subsys/freeswitch LOCK_FILE=/var/lock/subsys/freeswitch
FREESWITCH_ARGS="-nc" FREESWITCH_ARGS="-nc"
RETVAL=0 RETVAL=0
# Source options file # Source usr/localions file
if [ -f /etc/sysconfig/freeswitch ]; then if [ -f /etc/sysconfig/freeswitch ]; then
. /etc/sysconfig/freeswitch . /etc/sysconfig/freeswitch
fi fi
......
%define prefix /opt/freeswitch %define PREFIX %{_prefix}
%define _prefix %{prefix} %define EXECPREFIX %{_exec_prefix}
%define BINDIR %{_bindir}
%define SBINDIR %{_sbindir}
%define LIBEXECDIR %{_libexecdir}/%{fsname}
%define SYSCONFDIR %{_sysconfdir}/%{fsname}
%define SHARESTATEDIR %{_sharedstatedir}/%{fsname}
%define LOCALSTATEDIR %{_localstatedir}/lib/%{fsname}
%define LIBDIR %{_libdir}
%define INCLUDEDIR %{_includedir}
%define _datarootdir %{_prefix}/share
%define DATAROOTDIR %{_datarootdir}
%define DATADIR %{_datadir}
%define INFODIR %{_infodir}
%define LOCALEDIR %{_datarootdir}/locale
%define MANDIR %{_mandir}
%define DOCDIR %{_defaultdocdir}/%{fsname}
%define HTMLDIR %{_defaultdocdir}/%{fsname}/html
%define DVIDIR %{_defaultdocdir}/%{fsname}/dvi
%define PDFDIR %{_defaultdocdir}/%{fsname}/pdf
%define PSDIR %{_defaultdocdir}/%{fsname}/ps
%define LOGFILEDIR /var/log/%{fsname}
%define MODINSTDIR %{_libdir}/%{fsname}/mod
%define RUNDIR %{_localstatedir}/run/%{fsname}
%define DBDIR %{LOCALSTATEDIR}/db
%define HTDOCSDIR %{_datarootdir}/%{fsname}/htdocs
%define SOUNDSDIR %{_datarootdir}/%{fsname}/sounds
%define GRAMMARDIR %{_datarootdir}/%{fsname}/grammar
%define SCRIPTDIR %{_datarootdir}/%{fsname}/scripts
%define RECORDINGSDIR %{LOCALSTATEDIR}/recordings
%define PKGCONFIGDIR %{_datarootdir}/%{fsname}/pkgconfig
%define HOMEDIR %{LOCALSTATEDIR}
Summary: FreeSWITCH Music on Hold soundfiles Summary: FreeSWITCH Music on Hold soundfiles
Name: freeswitch-sounds-music Name: freeswitch-sounds-music
Version: 1.0.8 Version: 1.0.8
Release: 1%{?dist} Release: 2%{?dist}
License: MPL License: MPL
Group: Productivity/Telephony/Servers Group: Productivity/Telephony/Servers
Packager: Joseph L. Casale <jcasale@activenetwerx.com> Packager: Joseph L. Casale <jcasale@activenetwerx.com>
...@@ -80,8 +110,8 @@ FreeSWITCH 48kHz Music On Hold soundfiles ...@@ -80,8 +110,8 @@ FreeSWITCH 48kHz Music On Hold soundfiles
%install %install
%{__rm} -rf %{buildroot} %{__rm} -rf %{buildroot}
%{__install} -d -m 0750 %{buildroot}/%{_prefix}/sounds/music/{8000,16000,32000,48000} %{__install} -d -m 0750 %{buildroot}/%{SOUNDSDIR}/music/{8000,16000,32000,48000}
%{__cp} -prv ./{8000,16000,32000,48000} %{buildroot}%{_prefix}/sounds/music %{__cp} -prv ./{8000,16000,32000,48000} %{buildroot}%{SOUNDSDIR}/music
%clean %clean
...@@ -99,28 +129,30 @@ FreeSWITCH 48kHz Music On Hold soundfiles ...@@ -99,28 +129,30 @@ FreeSWITCH 48kHz Music On Hold soundfiles
%files -n freeswitch-sounds-music-8000 %files -n freeswitch-sounds-music-8000
%defattr(-,root,root,-) %defattr(-,root,root,-)
%dir %{_prefix}/sounds/music/8000 %dir %{SOUNDSDIR}/music/8000
%{_prefix}/sounds/music/8000/*.wav %{SOUNDSDIR}/music/8000/*.wav
%files -n freeswitch-sounds-music-16000 %files -n freeswitch-sounds-music-16000
%defattr(-,root,root,-) %defattr(-,root,root,-)
%dir %{_prefix}/sounds/music/16000 %dir %{SOUNDSDIR}/music/16000
%{_prefix}/sounds/music/16000/*.wav %{SOUNDSDIR}/music/16000/*.wav
%files -n freeswitch-sounds-music-32000 %files -n freeswitch-sounds-music-32000
%defattr(-,root,root,-) %defattr(-,root,root,-)
%dir %{_prefix}/sounds/music/32000 %dir %{SOUNDSDIR}/music/32000
%{_prefix}/sounds/music/32000/*.wav %{SOUNDSDIR}/music/32000/*.wav
%files -n freeswitch-sounds-music-48000 %files -n freeswitch-sounds-music-48000
%defattr(-,root,root,-) %defattr(-,root,root,-)
%dir %{_prefix}/sounds/music/48000 %dir %{SOUNDSDIR}/music/48000
%{_prefix}/sounds/music/48000/*.wav %{SOUNDSDIR}/music/48000/*.wav
%changelog %changelog
* Sat Jul 16 2011 Joseph Casale <jcasale@activenetwerx.com> 1.0.8-2
- Fix up for FreeSWITCH FHS and AutoBuild System
* Sat Jul 16 2011 Joseph Casale <jcasale@activenetwerx.com> 1.0.8-1 * Sat Jul 16 2011 Joseph Casale <jcasale@activenetwerx.com> 1.0.8-1
- Initial release - Initial release
This source diff could not be displayed because it is too large. You can view the blob instead.
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论