more cmmand moakroisation in specfile
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@7506 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
parent
5f13e0197e
commit
5119bd031c
|
@ -171,8 +171,6 @@ French language phrases module and directory structure for say module and voicem
|
||||||
%setup -q
|
%setup -q
|
||||||
|
|
||||||
%build
|
%build
|
||||||
#export CFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing -DLDAP_DEPRECATED -fPIC -DPIC"
|
|
||||||
#export CFLAGS="$RPM_OPT_FLAGS -fPIC -DPIC"
|
|
||||||
%if 0%{?suse_version} > 1000 && 0%{?suse_version} < 1030
|
%if 0%{?suse_version} > 1000 && 0%{?suse_version} < 1030
|
||||||
export CFLAGS="$CFLAGS -fstack-protector"
|
export CFLAGS="$CFLAGS -fstack-protector"
|
||||||
%endif
|
%endif
|
||||||
|
@ -229,32 +227,32 @@ touch .noversion
|
||||||
make
|
make
|
||||||
|
|
||||||
%install
|
%install
|
||||||
make DESTDIR=$RPM_BUILD_ROOT install
|
%{__make} DESTDIR=$RPM_BUILD_ROOT install
|
||||||
|
|
||||||
# Create a log dir
|
# Create a log dir
|
||||||
mkdir -p $RPM_BUILD_ROOT%{prefix}/log
|
%{__mkdir} -p $RPM_BUILD_ROOT%{prefix}/log
|
||||||
|
|
||||||
%ifos linux
|
%ifos linux
|
||||||
#Install the library path config so the system can find the modules
|
#Install the library path config so the system can find the modules
|
||||||
mkdir -p $RPM_BUILD_ROOT/etc/ld.so.conf.d
|
%{__mkdir} -p $RPM_BUILD_ROOT/etc/ld.so.conf.d
|
||||||
cp build/freeswitch.ld.so.conf $RPM_BUILD_ROOT/etc/ld.so.conf.d/
|
%{__cp} build/freeswitch.ld.so.conf $RPM_BUILD_ROOT/etc/ld.so.conf.d/
|
||||||
# Install init files
|
# Install init files
|
||||||
# On SuSE:
|
# On SuSE:
|
||||||
%if 0%{?suse_version} > 100
|
%if 0%{?suse_version} > 100
|
||||||
install -D -m 744 build/freeswitch.init.suse $RPM_BUILD_ROOT/etc/init.d/freeswitch
|
%{__install} -D -m 744 build/freeswitch.init.suse $RPM_BUILD_ROOT/etc/init.d/freeswitch
|
||||||
%else
|
%else
|
||||||
# On RedHat like
|
# On RedHat like
|
||||||
install -D -m 744 build/freeswitch.init.redhat $RPM_BUILD_ROOT/etc/init.d/freeswitch
|
%{__install} -D -m 744 build/freeswitch.init.redhat $RPM_BUILD_ROOT/etc/init.d/freeswitch
|
||||||
%endif
|
%endif
|
||||||
# On SuSE make /usr/sbin/rcfreeswitch a link to /etc/init.d/freeswitch
|
# On SuSE make /usr/sbin/rcfreeswitch a link to /etc/init.d/freeswitch
|
||||||
%if 0%{?suse_version} > 100
|
%if 0%{?suse_version} > 100
|
||||||
mkdir -p $RPM_BUILD_ROOT/usr/sbin
|
%{__mkdir} -p $RPM_BUILD_ROOT/usr/sbin
|
||||||
ln -sf /etc/init.d/freeswitch $RPM_BUILD_ROOT/usr/sbin/rcfreeswitch
|
%{__ln} -sf /etc/init.d/freeswitch $RPM_BUILD_ROOT/usr/sbin/rcfreeswitch
|
||||||
%endif
|
%endif
|
||||||
# Add the sysconfiguration file
|
# Add the sysconfiguration file
|
||||||
install -D -m 744 build/freeswitch.sysconfig $RPM_BUILD_ROOT/etc/sysconfig/freeswitch
|
%{__install} -D -m 744 build/freeswitch.sysconfig $RPM_BUILD_ROOT/etc/sysconfig/freeswitch
|
||||||
# Add monit file
|
# Add monit file
|
||||||
install -D -m 644 build/freeswitch.monitrc $RPM_BUILD_ROOT/etc/monit.d/freeswitch.monitrc
|
%{__install} -D -m 644 build/freeswitch.monitrc $RPM_BUILD_ROOT/etc/monit.d/freeswitch.monitrc
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
|
|
||||||
|
@ -265,16 +263,16 @@ install -D -m 644 build/freeswitch.monitrc $RPM_BUILD_ROOT/etc/monit.d/freeswitc
|
||||||
%post
|
%post
|
||||||
%{?run_ldconfig:%run_ldconfig}
|
%{?run_ldconfig:%run_ldconfig}
|
||||||
# Make FHS2.0 happy
|
# Make FHS2.0 happy
|
||||||
mkdir -p /etc/opt
|
%{__mkdir} -p /etc/opt
|
||||||
ln -sf %{prefix}/conf /etc%{prefix}
|
%{__ln} -sf %{prefix}/conf /etc%{prefix}
|
||||||
|
|
||||||
%postun
|
%postun
|
||||||
%{?run_ldconfig:%run_ldconfig}
|
%{?run_ldconfig:%run_ldconfig}
|
||||||
rm -rf %{prefix}
|
%{__rm} -rf %{prefix}
|
||||||
userdel freeswitch
|
userdel freeswitch
|
||||||
|
|
||||||
%clean
|
%clean
|
||||||
rm -rf $RPM_BUILD_ROOT
|
%{__rm} -rf $RPM_BUILD_ROOT
|
||||||
|
|
||||||
%files
|
%files
|
||||||
%defattr(-,freeswitch,daemon)
|
%defattr(-,freeswitch,daemon)
|
||||||
|
@ -484,6 +482,10 @@ rm -rf $RPM_BUILD_ROOT
|
||||||
%{prefix}/mod/mod_say_fr.so*
|
%{prefix}/mod/mod_say_fr.so*
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Sun Fri 03 2008 - michal.bielicki@voiceworks.pl
|
||||||
|
- abstraction of prefix
|
||||||
|
- more wrong stuff deleted
|
||||||
|
- abstraction of mkdir, mv, rm, install etc into macros
|
||||||
* Fri Jan 18 2008 - michal.bielicki@voiceworks.pl
|
* Fri Jan 18 2008 - michal.bielicki@voiceworks.pl
|
||||||
- fixes, fixes and more fixes in preparation for rc1
|
- fixes, fixes and more fixes in preparation for rc1
|
||||||
* Thu Dec 5 2007 - michal.bielicki@voiceworks.pl
|
* Thu Dec 5 2007 - michal.bielicki@voiceworks.pl
|
||||||
|
|
Loading…
Reference in New Issue