[sems] Fixed FTBFS in F20+

Peter Lemenkov peter at fedoraproject.org
Sat Sep 7 07:01:22 UTC 2013


commit cf9390363a9f5bb02f4b41ed43c053fc382db54b
Author: Peter Lemenkov <lemenkov at gmail.com>
Date:   Sat Sep 7 11:01:06 2013 +0400

    Fixed FTBFS in F20+
    
    Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>

 ...001-Force-to-use-system-wide-GSM-includes.patch |    4 +-
 ...llow-rewrite-of-custom-makefiles-by-CMake.patch |    4 +-
 ...Set-CFG_PREFIX-to-empty-string-by-default.patch |    4 +-
 ...ql-in-conference-and-early_announce-modul.patch |    4 +-
 ...aid_sip-plugin-to-default-exclude-list-du.patch |    4 +-
 sems-0006-Don-t-start-py_sems-by-default.patch     |    4 +-
 sems-0007-Change-default-msg_storage-path.patch    |    4 +-
 sems-0008-Fix-building-with-IPv6-support.patch     |    4 +-
 ...009-Correct-version-number-in-CMake-files.patch |    4 +-
 ...ng-etc-sysconfig-sems-file-to-the-pkg-rpm.patch |    4 +-
 ...script-Fix-directory-for-storing-pid-file.patch |    4 +-
 sems-0012-systemd-Restart-in-case-of-failure.patch |    4 +-
 ...13-Search-for-possibly-missing-res_search.patch |    4 +-
 sems-0014-Allow-build-against-external-iLBC.patch  |    4 +-
 ...0015-Add-check-for-mysql_version.h-header.patch |    4 +-
 sems-0016-Drop-unused-variables.patch              |    4 +-
 ...Allow-building-against-external-iLBC-copy.patch |    4 +-
 ...-as-a-underlying-library-for-g.729-plugin.patch |    4 +-
 ...n-t-use-versioned-dir-for-installing-docs.patch |   34 ++++++
 sems.spec                                          |  120 ++++++++++----------
 20 files changed, 131 insertions(+), 95 deletions(-)
---
diff --git a/sems-0001-Force-to-use-system-wide-GSM-includes.patch b/sems-0001-Force-to-use-system-wide-GSM-includes.patch
index bbe2afd..71bca82 100644
--- a/sems-0001-Force-to-use-system-wide-GSM-includes.patch
+++ b/sems-0001-Force-to-use-system-wide-GSM-includes.patch
@@ -1,7 +1,7 @@
 From 79c3f4ac561f69d4a3db07b539f45d1a8d912853 Mon Sep 17 00:00:00 2001
 From: Peter Lemenkov <lemenkov at gmail.com>
 Date: Wed, 31 Mar 2010 11:52:52 +0400
-Subject: [PATCH 01/18] Force to use system-wide GSM includes
+Subject: [PATCH 01/19] Force to use system-wide GSM includes
 
 Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>
 ---
@@ -22,5 +22,5 @@ index 286a989..3517e59 100644
  
  #include <stdlib.h>
 -- 
-1.8.0
+1.8.3.1
 
diff --git a/sems-0002-Allow-rewrite-of-custom-makefiles-by-CMake.patch b/sems-0002-Allow-rewrite-of-custom-makefiles-by-CMake.patch
index dd86abe..f3d241b 100644
--- a/sems-0002-Allow-rewrite-of-custom-makefiles-by-CMake.patch
+++ b/sems-0002-Allow-rewrite-of-custom-makefiles-by-CMake.patch
@@ -1,7 +1,7 @@
 From 9148b9c37b3ced81683ebc691c090f84ddb97b2b Mon Sep 17 00:00:00 2001
 From: Peter Lemenkov <lemenkov at gmail.com>
 Date: Wed, 31 Mar 2010 11:53:48 +0400
-Subject: [PATCH 02/18] Allow rewrite of custom makefiles by CMake
+Subject: [PATCH 02/19] Allow rewrite of custom makefiles by CMake
 
 Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>
 ---
@@ -29,5 +29,5 @@ index 8f83c5d..68b0c26 100644
  OPTION(SEMS_USE_LIBSAMPLERATE "Build with libsamplerate" OFF)
  OPTION(SEMS_USE_ZRTP          "Build with ZRTP" OFF)
 -- 
-1.8.0
+1.8.3.1
 
diff --git a/sems-0003-Set-CFG_PREFIX-to-empty-string-by-default.patch b/sems-0003-Set-CFG_PREFIX-to-empty-string-by-default.patch
index d3c4c5b..09c96a4 100644
--- a/sems-0003-Set-CFG_PREFIX-to-empty-string-by-default.patch
+++ b/sems-0003-Set-CFG_PREFIX-to-empty-string-by-default.patch
@@ -1,7 +1,7 @@
 From 42c18a0fd5f78ec154ae7e6f442fc083dd84e339 Mon Sep 17 00:00:00 2001
 From: Peter Lemenkov <lemenkov at gmail.com>
 Date: Wed, 31 Mar 2010 18:56:39 +0400
-Subject: [PATCH 03/18] Set CFG_PREFIX to empty string by default
+Subject: [PATCH 03/19] Set CFG_PREFIX to empty string by default
 
 Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>
 ---
@@ -22,5 +22,5 @@ index 68b0c26..a3264e3 100644
  MESSAGE(STATUS "SEMS cfg prefix was set to: ${SEMS_CFG_PREFIX}")
  
 -- 
-1.8.0
+1.8.3.1
 
diff --git a/sems-0004-Disable-mysql-in-conference-and-early_announce-modul.patch b/sems-0004-Disable-mysql-in-conference-and-early_announce-modul.patch
index 9f7cb62..8e0af1b 100644
--- a/sems-0004-Disable-mysql-in-conference-and-early_announce-modul.patch
+++ b/sems-0004-Disable-mysql-in-conference-and-early_announce-modul.patch
@@ -1,7 +1,7 @@
 From 536fcc248c8d8fda4c2523bf4c9a1fc5a3362d01 Mon Sep 17 00:00:00 2001
 From: Peter Lemenkov <lemenkov at gmail.com>
 Date: Fri, 25 Jun 2010 12:16:45 +0400
-Subject: [PATCH 04/18] Disable mysql++ in conference and early_announce
+Subject: [PATCH 04/19] Disable mysql++ in conference and early_announce
  modules
 
 Unfortunately, this breaks existing configurations, which is a
@@ -60,5 +60,5 @@ index 43c374e..03a1532 100644
  SET(sems_module_name early_announce)
  INCLUDE(${CMAKE_SOURCE_DIR}/cmake/module.rules.txt)
 -- 
-1.8.0
+1.8.3.1
 
diff --git a/sems-0005-Add-sw_prepaid_sip-plugin-to-default-exclude-list-du.patch b/sems-0005-Add-sw_prepaid_sip-plugin-to-default-exclude-list-du.patch
index d19f571..1f5895a 100644
--- a/sems-0005-Add-sw_prepaid_sip-plugin-to-default-exclude-list-du.patch
+++ b/sems-0005-Add-sw_prepaid_sip-plugin-to-default-exclude-list-du.patch
@@ -1,7 +1,7 @@
 From b3609436f25f48e6eab749e86487dae780e79870 Mon Sep 17 00:00:00 2001
 From: Peter Lemenkov <lemenkov at gmail.com>
 Date: Mon, 27 Sep 2010 14:13:00 +0400
-Subject: [PATCH 05/18] Add sw_prepaid_sip plugin to default exclude list (due
+Subject: [PATCH 05/19] Add sw_prepaid_sip plugin to default exclude list (due
  to missing cc_acc)
 
 Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>
@@ -23,5 +23,5 @@ index c4f900f..f36cb69 100644
  # optional parameter: application
  # 
 -- 
-1.8.0
+1.8.3.1
 
diff --git a/sems-0006-Don-t-start-py_sems-by-default.patch b/sems-0006-Don-t-start-py_sems-by-default.patch
index b151fc5..ac1a3c7 100644
--- a/sems-0006-Don-t-start-py_sems-by-default.patch
+++ b/sems-0006-Don-t-start-py_sems-by-default.patch
@@ -1,7 +1,7 @@
 From adff391d26ffe2bb5fcc5b3f0611b146925d9580 Mon Sep 17 00:00:00 2001
 From: Peter Lemenkov <lemenkov at gmail.com>
 Date: Wed, 29 Dec 2010 17:02:49 +0300
-Subject: [PATCH 06/18] Don't start py_sems by default
+Subject: [PATCH 06/19] Don't start py_sems by default
 
 Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>
 ---
@@ -22,5 +22,5 @@ index f36cb69..7276602 100644
  # optional parameter: application
  # 
 -- 
-1.8.0
+1.8.3.1
 
diff --git a/sems-0007-Change-default-msg_storage-path.patch b/sems-0007-Change-default-msg_storage-path.patch
index 05210aa..82b4aeb 100644
--- a/sems-0007-Change-default-msg_storage-path.patch
+++ b/sems-0007-Change-default-msg_storage-path.patch
@@ -1,7 +1,7 @@
 From 0c64018f8dd8462affb397cc9c8cf3640fecd7c6 Mon Sep 17 00:00:00 2001
 From: Peter Lemenkov <lemenkov at gmail.com>
 Date: Thu, 24 Nov 2011 19:57:05 +0400
-Subject: [PATCH 07/18] Change default msg_storage path
+Subject: [PATCH 07/19] Change default msg_storage path
 
 Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>
 ---
@@ -19,5 +19,5 @@ index efab27f..dadf5d8 100644
 -#storage_dir=/var/spool/voicebox/
 +storage_dir=/var/spool/sems/voicebox/
 -- 
-1.8.0
+1.8.3.1
 
diff --git a/sems-0008-Fix-building-with-IPv6-support.patch b/sems-0008-Fix-building-with-IPv6-support.patch
index 2cf11fa..4bdd52c 100644
--- a/sems-0008-Fix-building-with-IPv6-support.patch
+++ b/sems-0008-Fix-building-with-IPv6-support.patch
@@ -1,7 +1,7 @@
 From ad89c8cc396a6d1461a0fc6adb06585aafa3bc7f Mon Sep 17 00:00:00 2001
 From: Peter Lemenkov <lemenkov at gmail.com>
 Date: Thu, 19 Apr 2012 16:43:45 +0400
-Subject: [PATCH 08/18] Fix building with IPv6 support
+Subject: [PATCH 08/19] Fix building with IPv6 support
 
 Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>
 ---
@@ -22,5 +22,5 @@ index bb2b0a4..be2ac9b 100644
  
  int AmRtpStream::ping()
 -- 
-1.8.0
+1.8.3.1
 
diff --git a/sems-0009-Correct-version-number-in-CMake-files.patch b/sems-0009-Correct-version-number-in-CMake-files.patch
index 5affbe2..f741e4b 100644
--- a/sems-0009-Correct-version-number-in-CMake-files.patch
+++ b/sems-0009-Correct-version-number-in-CMake-files.patch
@@ -1,7 +1,7 @@
 From aec12cf6735e0731496f783a48ac94290f2cb71b Mon Sep 17 00:00:00 2001
 From: Peter Lemenkov <lemenkov at gmail.com>
 Date: Sat, 5 May 2012 12:36:51 +0400
-Subject: [PATCH 09/18] Correct version number in CMake-files
+Subject: [PATCH 09/19] Correct version number in CMake-files
 
 Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>
 ---
@@ -22,5 +22,5 @@ index a3264e3..1302857 100644
  
  IF(EXISTS ${CMAKE_SOURCE_DIR}/.git)
 -- 
-1.8.0
+1.8.3.1
 
diff --git a/sems-0010-Added-missing-etc-sysconfig-sems-file-to-the-pkg-rpm.patch b/sems-0010-Added-missing-etc-sysconfig-sems-file-to-the-pkg-rpm.patch
index 0b777c9..a47756b 100644
--- a/sems-0010-Added-missing-etc-sysconfig-sems-file-to-the-pkg-rpm.patch
+++ b/sems-0010-Added-missing-etc-sysconfig-sems-file-to-the-pkg-rpm.patch
@@ -1,7 +1,7 @@
 From e8a9f3e78f3310c42bb4e56de28ff9c91c79a1f0 Mon Sep 17 00:00:00 2001
 From: Peter Lemenkov <lemenkov at gmail.com>
 Date: Sat, 5 May 2012 12:50:33 +0400
-Subject: [PATCH 10/18] Added missing /etc/sysconfig/sems file to the pkg/rpm
+Subject: [PATCH 10/19] Added missing /etc/sysconfig/sems file to the pkg/rpm
 
 Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>
 ---
@@ -17,5 +17,5 @@ index 0000000..9186ef7
 @@ -0,0 +1 @@
 +OPTIONS=""
 -- 
-1.8.0
+1.8.3.1
 
diff --git a/sems-0011-init-script-Fix-directory-for-storing-pid-file.patch b/sems-0011-init-script-Fix-directory-for-storing-pid-file.patch
index 6aa28bd..9241e41 100644
--- a/sems-0011-init-script-Fix-directory-for-storing-pid-file.patch
+++ b/sems-0011-init-script-Fix-directory-for-storing-pid-file.patch
@@ -1,7 +1,7 @@
 From 80a16df44b7594a69e331103f3b3041ad292acec Mon Sep 17 00:00:00 2001
 From: Peter Lemenkov <lemenkov at gmail.com>
 Date: Thu, 19 Jul 2012 14:41:01 +0400
-Subject: [PATCH 11/18] [init-script] Fix directory for storing pid-file
+Subject: [PATCH 11/19] [init-script] Fix directory for storing pid-file
 
 Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>
 ---
@@ -22,5 +22,5 @@ index 15e9847..c39a721 100755
  conffile=/etc/$prog/$prog.conf
  
 -- 
-1.8.0
+1.8.3.1
 
diff --git a/sems-0012-systemd-Restart-in-case-of-failure.patch b/sems-0012-systemd-Restart-in-case-of-failure.patch
index 40a8fd6..f90a155 100644
--- a/sems-0012-systemd-Restart-in-case-of-failure.patch
+++ b/sems-0012-systemd-Restart-in-case-of-failure.patch
@@ -1,7 +1,7 @@
 From cfc119ac698a24ad1bc011dbdf551425ec82782b Mon Sep 17 00:00:00 2001
 From: Peter Lemenkov <lemenkov at gmail.com>
 Date: Thu, 19 Jul 2012 14:42:01 +0400
-Subject: [PATCH 12/18] [systemd] Restart in case of failure
+Subject: [PATCH 12/19] [systemd] Restart in case of failure
 
 Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>
 ---
@@ -23,5 +23,5 @@ index 7d66886..43996a5 100644
  
  [Install]
 -- 
-1.8.0
+1.8.3.1
 
diff --git a/sems-0013-Search-for-possibly-missing-res_search.patch b/sems-0013-Search-for-possibly-missing-res_search.patch
index 44b1c88..bc176ee 100644
--- a/sems-0013-Search-for-possibly-missing-res_search.patch
+++ b/sems-0013-Search-for-possibly-missing-res_search.patch
@@ -1,7 +1,7 @@
 From 5203c6c7b388e65ceeb7315c5bafa93e71d17a8e Mon Sep 17 00:00:00 2001
 From: Peter Lemenkov <lemenkov at gmail.com>
 Date: Sat, 2 Oct 2010 17:54:11 +0400
-Subject: [PATCH 13/18] Search for possibly missing res_search
+Subject: [PATCH 13/19] Search for possibly missing res_search
 
 Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>
 ---
@@ -117,5 +117,5 @@ index 0000000..d48b65f
 +  ENDIF("${VARIABLE}" MATCHES "^${VARIABLE}$")
 +ENDMACRO(CHECK_SYMBOL_EXISTS)
 -- 
-1.8.0
+1.8.3.1
 
diff --git a/sems-0014-Allow-build-against-external-iLBC.patch b/sems-0014-Allow-build-against-external-iLBC.patch
index 393492e..ae8972a 100644
--- a/sems-0014-Allow-build-against-external-iLBC.patch
+++ b/sems-0014-Allow-build-against-external-iLBC.patch
@@ -1,7 +1,7 @@
 From eaa6776ea95df00bf9fa3a6dbcd91e7503bed24d Mon Sep 17 00:00:00 2001
 From: Peter Lemenkov <lemenkov at gmail.com>
 Date: Fri, 3 Aug 2012 13:18:37 +0400
-Subject: [PATCH 14/18] Allow build against external iLBC
+Subject: [PATCH 14/19] Allow build against external iLBC
 
 Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>
 ---
@@ -86,5 +86,5 @@ index 1f4dcfb..bf77875 100644
  INCLUDE(${CMAKE_SOURCE_DIR}/cmake/module.rules.txt)
  
 -- 
-1.8.0
+1.8.3.1
 
diff --git a/sems-0015-Add-check-for-mysql_version.h-header.patch b/sems-0015-Add-check-for-mysql_version.h-header.patch
index efa50cd..5203954 100644
--- a/sems-0015-Add-check-for-mysql_version.h-header.patch
+++ b/sems-0015-Add-check-for-mysql_version.h-header.patch
@@ -1,7 +1,7 @@
 From d56f60341f1cdd1337ed140e9cff99618a174450 Mon Sep 17 00:00:00 2001
 From: Peter Lemenkov <lemenkov at gmail.com>
 Date: Fri, 3 Aug 2012 13:56:23 +0400
-Subject: [PATCH 15/18] Add check for mysql_version.h header
+Subject: [PATCH 15/19] Add check for mysql_version.h header
 
 Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>
 ---
@@ -26,5 +26,5 @@ index 94050c9..248624c 100644
 +	ENDIF(MYSQL_INCLUDE_BURIED_MYSQL_VERSION_H)
 +ENDIF(NOT MYSQL_INCLUDE_MYSQL_VERSION_H)
 -- 
-1.8.0
+1.8.3.1
 
diff --git a/sems-0016-Drop-unused-variables.patch b/sems-0016-Drop-unused-variables.patch
index 8f2853e..5cf7297 100644
--- a/sems-0016-Drop-unused-variables.patch
+++ b/sems-0016-Drop-unused-variables.patch
@@ -1,7 +1,7 @@
 From 3ec797d96b9c5c751d133f8a7d37eb4541feabb1 Mon Sep 17 00:00:00 2001
 From: Peter Lemenkov <lemenkov at gmail.com>
 Date: Fri, 3 Aug 2012 13:39:54 +0400
-Subject: [PATCH 16/18] Drop unused variables
+Subject: [PATCH 16/19] Drop unused variables
 
 Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>
 ---
@@ -31,5 +31,5 @@ index 79594c1..326576d 100644
  			     unsigned int channels, unsigned int rate, long h_codec, int mode );
  
 -- 
-1.8.0
+1.8.3.1
 
diff --git a/sems-0017-Allow-building-against-external-iLBC-copy.patch b/sems-0017-Allow-building-against-external-iLBC-copy.patch
index b5444a4..f1b5529 100644
--- a/sems-0017-Allow-building-against-external-iLBC-copy.patch
+++ b/sems-0017-Allow-building-against-external-iLBC-copy.patch
@@ -1,7 +1,7 @@
 From 22baa75e02f2a4eba252da0dfa549670bfbad36f Mon Sep 17 00:00:00 2001
 From: Peter Lemenkov <lemenkov at gmail.com>
 Date: Tue, 20 Nov 2012 15:57:22 +0400
-Subject: [PATCH 17/18] Allow building against external iLBC copy
+Subject: [PATCH 17/19] Allow building against external iLBC copy
 
 Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>
 ---
@@ -28,5 +28,5 @@ index 326576d..3adb1b0 100644
  			     unsigned int channels, unsigned int rate, long h_codec, int mode );
  
 -- 
-1.8.0
+1.8.3.1
 
diff --git a/sems-0018-Use-bcg729-as-a-underlying-library-for-g.729-plugin.patch b/sems-0018-Use-bcg729-as-a-underlying-library-for-g.729-plugin.patch
index 2afbf71..6156536 100644
--- a/sems-0018-Use-bcg729-as-a-underlying-library-for-g.729-plugin.patch
+++ b/sems-0018-Use-bcg729-as-a-underlying-library-for-g.729-plugin.patch
@@ -1,7 +1,7 @@
 From e6fa8fa4578175314eddd8a48dd4f19c9fa1e5b6 Mon Sep 17 00:00:00 2001
 From: Peter Lemenkov <lemenkov at gmail.com>
 Date: Tue, 20 Nov 2012 12:50:24 +0400
-Subject: [PATCH 18/18] Use bcg729 as a underlying library for g.729 plugin
+Subject: [PATCH 18/19] Use bcg729 as a underlying library for g.729 plugin
 
 Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>
 ---
@@ -515,5 +515,5 @@ index a850345..bd2c973 100644
 -} 
 -#endif
 -- 
-1.8.0
+1.8.3.1
 
diff --git a/sems-0019-Don-t-use-versioned-dir-for-installing-docs.patch b/sems-0019-Don-t-use-versioned-dir-for-installing-docs.patch
new file mode 100644
index 0000000..70bca3b
--- /dev/null
+++ b/sems-0019-Don-t-use-versioned-dir-for-installing-docs.patch
@@ -0,0 +1,34 @@
+From f7777188ddbca3a9279c970bede5f9d27b8fc4cb Mon Sep 17 00:00:00 2001
+From: Peter Lemenkov <lemenkov at gmail.com>
+Date: Sat, 7 Sep 2013 10:06:42 +0400
+Subject: [PATCH 19/19] Don't use versioned dir for installing docs
+
+Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>
+---
+ cmake/doc.rules.txt | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/cmake/doc.rules.txt b/cmake/doc.rules.txt
+index 727c789..15be3fd 100644
+--- a/cmake/doc.rules.txt
++++ b/cmake/doc.rules.txt
+@@ -2,14 +2,14 @@ MACRO(SEMS_INSTALL_DOCS doc_files doc_dirs)
+ 
+ 	FOREACH (doc_file ${doc_files})
+ 		INSTALL(
+-			FILES ${doc_file} DESTINATION ${SEMS_DOC_PREFIX}/sems-${SEMS_VERSION}
++			FILES ${doc_file} DESTINATION ${SEMS_DOC_PREFIX}/sems
+ 		)
+ 	ENDFOREACH(doc_file ${doc_files})
+ 
+ 	FOREACH (doc_dir ${doc_dirs})
+ 		INSTALL(
+ 			DIRECTORY ${doc_dir}
+-			DESTINATION ${SEMS_DOC_PREFIX}/sems-${SEMS_VERSION}
++			DESTINATION ${SEMS_DOC_PREFIX}/sems
+ 		)
+ 	ENDFOREACH(doc_dir ${doc_dirs})
+ 
+-- 
+1.8.3.1
+
diff --git a/sems.spec b/sems.spec
index 343bb06..b7768f3 100644
--- a/sems.spec
+++ b/sems.spec
@@ -1,11 +1,11 @@
 Summary:	SIP Express Media Server, an extensible SIP media server
 Name:		sems
 Version:	1.4.3
-Release:	7%{?dist}
+Release:	8%{?dist}
 URL:		http://www.iptel.org/sems
 Source0:	http://ftp.iptel.org/pub/%{name}/%{name}-%{version}.tar.gz
-%if 0%{?fedora} > 14
-BuildRequires:	systemd-units
+%if 0%{?el7}%{?fedora}
+BuildRequires:	systemd
 %endif
 License:	GPLv2+
 Group:		Applications/Communications
@@ -46,6 +46,8 @@ Patch16:	sems-0016-Drop-unused-variables.patch
 Patch17:	sems-0017-Allow-building-against-external-iLBC-copy.patch
 # Disabled for now.
 Patch18:	sems-0018-Use-bcg729-as-a-underlying-library-for-g.729-plugin.patch
+# Fedora/EPEL-specific (F20+)
+Patch19:	sems-0019-Don-t-use-versioned-dir-for-installing-docs.patch
 
 BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 BuildRequires:	python >= 2.3
@@ -63,7 +65,7 @@ BuildRequires:	mysql++-devel
 BuildRequires:	cmake >= 2.4
 Requires(pre):  /usr/sbin/useradd
 #Initscripts
-%if 0%{?fedora} > 14
+%if 0%{?el7}%{?fedora}
 Requires(post): systemd-units
 Requires(preun): systemd-units
 Requires(postun): systemd-units
@@ -86,8 +88,8 @@ SEMS supports g711u, g711a, GSM06.10 and wav file.
 %package	conf_auth
 Summary:	Conference with authorization
 Group:		Applications/Communications
-Requires:	%{name} = %{version}-%{release}
-Requires:	%{name}-ivr = %{version}-%{release}
+Requires:	%{name}%{?_isa} = %{version}-%{release}
+Requires:	%{name}-ivr%{?_isa} = %{version}-%{release}
 
 %description	conf_auth
 Conference with authorization by PIN-numbers.
@@ -95,7 +97,7 @@ Conference with authorization by PIN-numbers.
 %package	conference
 Summary:	Conferencing application
 Group:		Applications/Communications
-Requires:	%{name} = %{version}-%{release}
+Requires:	%{name}%{?_isa} = %{version}-%{release}
 Obsoletes:	%{name} < 1.2.0
 
 %description	conference
@@ -104,7 +106,7 @@ Conferencing application for SEMS.
 %package	diameter_client
 Summary:	A simple DIAMETER client implementation
 Group:		Applications/Communications
-Requires:	%{name} = %{version}-%{release}
+Requires:	%{name}%{?_isa} = %{version}-%{release}
 
 %description	diameter_client
 This is a very simple DIAMETER client implementation. it does
@@ -118,7 +120,7 @@ DIAMETER request.
 %package	dsm
 Summary:	The state machine interpreter for SEMS
 Group:		Applications/Communications
-Requires:	%{name} = %{version}-%{release}
+Requires:	%{name}%{?_isa} = %{version}-%{release}
 Obsoletes:	%{name} < 1.2.0
 
 %description	dsm
@@ -130,7 +132,7 @@ language, and executed by the dsm module as application in SEMS.
 %package	early_announce
 Summary:	Early announce application
 Group:		Applications/Communications
-Requires:	%{name} = %{version}-%{release}
+Requires:	%{name}%{?_isa} = %{version}-%{release}
 Obsoletes:	%{name} < 1.2.0
 
 %description	early_announce
@@ -139,7 +141,7 @@ Early annonce application for SEMS.
 %package	g722
 Summary:	G.722 support for SEMS
 Group:		Applications/Communications
-Requires:	%{name} = %{version}-%{release}
+Requires:	%{name}%{?_isa} = %{version}-%{release}
 
 %description	g722
 This is a wrapper around the g722 codec from the spandsp library.
@@ -150,7 +152,7 @@ This is a wrapper around the g722 codec from the spandsp library.
 Summary:	G.729 support for SEMS
 Group:		Applications/Communications
 BuildRequires:	bcg729-devel
-Requires:	%{name} = %{version}-%{release}
+Requires:	%{name}%{?_isa} = %{version}-%{release}
 
 %description	g729
 This is a wrapper around the g729 codec from the bcg729 library.
@@ -159,7 +161,7 @@ This is a wrapper around the g729 codec from the bcg729 library.
 #%package	gateway
 #Summary:	ISDN gateway for SEMS
 #Group:		Applications/Communications
-#Requires:	%{name} = %{version}-%{release}
+#Requires:	%{name}%{?_isa} = %{version}-%{release}
 
 #%description	gateway
 #ISDN gateway for SEMS.
@@ -167,7 +169,7 @@ This is a wrapper around the g729 codec from the bcg729 library.
 %package	gsm
 Summary:	GSM support for SEMS
 Group:		Applications/Communications
-Requires:	%{name} = %{version}-%{release}
+Requires:	%{name}%{?_isa} = %{version}-%{release}
 
 %description	gsm
 GSM support for SEMS.
@@ -175,7 +177,7 @@ GSM support for SEMS.
 %package	ilbc
 Summary:	iLBC support for SEMS
 Group:		Applications/Communications
-Requires:	%{name} = %{version}-%{release}
+Requires:	%{name}%{?_isa} = %{version}-%{release}
 
 %description	ilbc
 iLBC support for SEMS.
@@ -184,7 +186,7 @@ iLBC support for SEMS.
 Summary:	IVR functionality for SEMS
 Group:		Applications/Communications
 Requires:	python >= 2.3
-Requires:	%{name} = %{version}-%{release}
+Requires:	%{name}%{?_isa} = %{version}-%{release}
 
 %description	ivr
 IVR functionality for SEMS.
@@ -192,8 +194,8 @@ IVR functionality for SEMS.
 %package	mailbox
 Summary:	Mailbox application
 Group:		Applications/Communications
-Requires:	%{name} = %{version}-%{release}
-Requires:	%{name}-ivr = %{version}-%{release}
+Requires:	%{name}%{?_isa} = %{version}-%{release}
+Requires:	%{name}-ivr%{?_isa} = %{version}-%{release}
 
 %description	mailbox
 The mailbox application is a mailbox where callers can leave messages
@@ -203,8 +205,8 @@ messages. It uses an IMAP server as back-end to store the voice messages.
 %package	pin_collect
 Summary:	Collects a PIN
 Group:		Applications/Communications
-Requires:	%{name} = %{version}-%{release}
-Requires:	%{name}-ivr = %{version}-%{release}
+Requires:	%{name}%{?_isa} = %{version}-%{release}
+Requires:	%{name}-ivr%{?_isa} = %{version}-%{release}
 
 %description	pin_collect
 This application collects a PIN and then transfers using a
@@ -214,7 +216,7 @@ This application collects a PIN and then transfers using a
 Summary:	Python bindings for SEMS
 Group:		Applications/Communications
 Requires:	python >= 2.3
-Requires:	%{name} = %{version}-%{release}
+Requires:	%{name}%{?_isa} = %{version}-%{release}
 
 %description	python
 Python bindings for SEMS.
@@ -222,7 +224,7 @@ Python bindings for SEMS.
 %package	speex
 Summary:	Speex support for SEMS
 Group:		Applications/Communications
-Requires:	%{name} = %{version}-%{release}
+Requires:	%{name}%{?_isa} = %{version}-%{release}
 
 %description	speex
 Speex support for SEMS.
@@ -230,7 +232,7 @@ Speex support for SEMS.
 %package	xmlrpc2di
 Summary:	XMLRPC interface for SEMS
 Group:		Applications/Communications
-Requires:	%{name} = %{version}-%{release}
+Requires:	%{name}%{?_isa} = %{version}-%{release}
 
 %description	xmlrpc2di
 This module makes the Dynamic Invocation (DI) Interfaces exported
@@ -261,6 +263,9 @@ rm -rf core/plug-in/ilbc/iLBC_rfc3951
 %patch16 -p1 -b .drop_unused_vars
 %patch17 -p1 -b .ext_ilbc2
 %patch18 -p1 -b .bcg729_disabled_by_default
+%if 0%{?fedora} > 19
+%patch19 -p1 -b .unversioned_docdirs
+%endif
 
 
 iconv -f iso8859-1 -t UTF-8 doc/Readme.diameter_client.txt > doc/Readme.diameter_client.utf8 && mv doc/Readme.diameter_client.{utf8,txt}
@@ -288,37 +293,37 @@ mv ./apps/dsm/fsmc/readme.txt  ./apps/dsm/fsmc/Readme.fsmc.txt
 make %{?_smp_mflags}
 
 %install
-rm -rf $RPM_BUILD_ROOT
-make install DESTDIR=$RPM_BUILD_ROOT
+rm -rf %{buildroot}
+make install DESTDIR=%{buildroot}
 
-install -D -m 0644 -p pkg/rpm/sems.sysconfig $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/%{name}
+install -D -m 0644 -p pkg/rpm/sems.sysconfig %{buildroot}%{_sysconfdir}/sysconfig/%{name}
 
-%if 0%{?fedora} > 14
+%if 0%{?el7}%{?fedora}
 # install systemd files
-install -D -m 0644 -p pkg/rpm/sems.systemd.service $RPM_BUILD_ROOT%{_unitdir}/%{name}.service
-install -D -m 0644 -p pkg/rpm/sems.systemd.tmpfiles.d.conf $RPM_BUILD_ROOT%{_sysconfdir}/tmpfiles.d/%{name}.conf
+install -D -m 0644 -p pkg/rpm/sems.systemd.service %{buildroot}%{_unitdir}/%{name}.service
+install -D -m 0644 -p pkg/rpm/sems.systemd.tmpfiles.d.conf %{buildroot}%{_tmpfilesdir}/%{name}.conf
 %else
 # install init-script
-install -D -p -m755 pkg/rpm/sems.init $RPM_BUILD_ROOT%{_initrddir}/%{name}
+install -D -p -m755 pkg/rpm/sems.init %{buildroot}%{_initrddir}/%{name}
 %endif
-mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/run/%{name}
-mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/spool/%{name}/voicebox
+mkdir -p %{buildroot}%{_localstatedir}/run/%{name}
+mkdir -p %{buildroot}%{_localstatedir}/spool/%{name}/voicebox
 
 # Remove installed docs
-#rm -rf $RPM_BUILD_ROOT%{_docdir}/%{name}
-#rm -rf $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/default.template.sample
-#rm -rf $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/sems.conf.default
+#rm -rf %{buildroot}%{_docdir}/%{name}
+#rm -rf %{buildroot}%{_sysconfdir}/%{name}/default.template.sample
+#rm -rf %{buildroot}%{_sysconfdir}/%{name}/sems.conf.default
 
 # remove currently empty conf-file
-rm -f $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/etc/conf_auth.conf
+rm -f %{buildroot}%{_sysconfdir}/%{name}/etc/conf_auth.conf
 
 # add empty directories for audiofiles
-mkdir -p $RPM_BUILD_ROOT%{_datadir}/%{name}/audio/ann_b2b
-mkdir -p $RPM_BUILD_ROOT%{_datadir}/%{name}/audio/announcement
-mkdir -p $RPM_BUILD_ROOT%{_datadir}/%{name}/audio/announce_transfer
+mkdir -p %{buildroot}%{_datadir}/%{name}/audio/ann_b2b
+mkdir -p %{buildroot}%{_datadir}/%{name}/audio/announcement
+mkdir -p %{buildroot}%{_datadir}/%{name}/audio/announce_transfer
 
 %clean
-rm -rf $RPM_BUILD_ROOT
+rm -rf %{buildroot}
 
 
 %pre
@@ -327,30 +332,23 @@ getent passwd %{name} >/dev/null || \
 
 
 %post
-%if 0%{?fedora} > 14
-if [ $1 -eq 1 ] ; then
-    # Initial installation
-    /bin/systemctl daemon-reload >/dev/null 2>&1 || :
-fi
-%else
+%if 0%{?el5}%{?el6}
 if [ $1 -eq 1 ]; then
-	/sbin/chkconfig --add sems || :
+	/sbin/chkconfig --add %{name} || :
 fi
+%else
+%systemd_post %{name}.service
 %endif
 
 
 %preun
-%if 0%{?fedora} > 14
-if [ $1 -eq 0 ] ; then
-    # Package removal, not upgrade
-    /bin/systemctl --no-reload disable sems.service > /dev/null 2>&1 || :
-    /bin/systemctl stop sems.service > /dev/null 2>&1 || :
+%if 0%{?el5}%{?el6}
+if [ $1 = 0 ] ; then
+	/sbin/service %{name} stop >/dev/null 2>&1
+	/sbin/chkconfig --del %{name}
 fi
 %else
-if [ $1 -eq 0 ]; then
-	/sbin/service sems stop >/dev/null 2>&1 || :
-	/sbin/chkconfig --del sems || :
-fi
+%systemd_preun %{name}.service
 %endif
 
 
@@ -374,13 +372,13 @@ fi
 
 %config(noreplace) %{_sysconfdir}/sysconfig/%{name}
 
-%if 0%{?fedora} > 14
+%if 0%{?el7}%{?fedora}
 %{_unitdir}/%{name}.service
-%{_sysconfdir}/tmpfiles.d/%{name}.conf
+%{_tmpfilesdir}/%{name}.conf
 %else
 %{_initrddir}/%{name}
 %endif
-%dir %attr(0755, %{name}, %{name}) %{_localstatedir}/run/%{name}/
+%ghost %dir %attr(0755, %{name}, %{name}) %{_localstatedir}/run/%{name}/
 
 %config(noreplace) %{_sysconfdir}/%{name}/default.template
 %config(noreplace) %{_sysconfdir}/%{name}/%{name}.conf
@@ -707,6 +705,10 @@ fi
 
 
 %changelog
+* Fri Sep 06 2013 Peter Lemenkov <lemenkov at gmail.com> - 1.4.3-8
+- Spec-file cleanup
+- Fixed FTBFS in F20+
+
 * Sun Aug 04 2013 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 1.4.3-7
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
 


More information about the scm-commits mailing list