Oliver Smith | d6877eb | 2020-05-14 11:47:38 +0200 | [diff] [blame] | 1 | # |
| 2 | # spec file for package osmo-mgw |
| 3 | # |
| 4 | # Copyright (c) 2017, Martin Hauke <mardnh@gmx.de> |
| 5 | # |
| 6 | # All modifications and additions to the file contributed by third parties |
| 7 | # remain the property of their copyright owners, unless otherwise agreed |
| 8 | # upon. The license for this file, and modifications and additions to the |
| 9 | # file, is the same license as for the pristine package itself (unless the |
| 10 | # license for the pristine package is not an Open Source License, in which |
| 11 | # case the license is the MIT License). An "Open Source License" is a |
| 12 | # license that conforms to the Open Source Definition (Version 1.9) |
| 13 | # published by the Open Source Initiative. |
| 14 | |
| 15 | # Please submit bugfixes or comments via http://bugs.opensuse.org/ |
| 16 | # |
| 17 | |
| 18 | Name: osmo-mgw |
Oliver Smith | 6500d72 | 2020-05-14 11:48:29 +0200 | [diff] [blame] | 19 | Version: @VERSION@ |
Oliver Smith | d6877eb | 2020-05-14 11:47:38 +0200 | [diff] [blame] | 20 | Release: 0 |
| 21 | Summary: Osmocom's Media Gateway for 2G and 3G circuit-switched mobile networks |
| 22 | License: AGPL-3.0-or-later AND GPL-2.0-or-later |
| 23 | Group: Hardware/Mobile |
| 24 | URL: https://osmocom.org/projects/osmo-mgw |
| 25 | Source: %{name}-%{version}.tar.xz |
| 26 | BuildRequires: automake >= 1.9 |
| 27 | BuildRequires: libtool >= 2 |
| 28 | BuildRequires: pkgconfig >= 0.20 |
Oliver Smith | 6500d72 | 2020-05-14 11:48:29 +0200 | [diff] [blame] | 29 | %if 0%{?suse_version} |
Oliver Smith | d6877eb | 2020-05-14 11:47:38 +0200 | [diff] [blame] | 30 | BuildRequires: systemd-rpm-macros |
Oliver Smith | 6500d72 | 2020-05-14 11:48:29 +0200 | [diff] [blame] | 31 | %endif |
Pau Espin Pedrol | 730a1f2 | 2023-09-12 14:48:51 +0200 | [diff] [blame] | 32 | BuildRequires: pkgconfig(libosmo-netif) >= 1.4.0 |
| 33 | BuildRequires: pkgconfig(libosmocore) >= 1.9.0 |
| 34 | BuildRequires: pkgconfig(libosmoctrl) >= 1.9.0 |
| 35 | BuildRequires: pkgconfig(libosmogsm) >= 1.9.0 |
| 36 | BuildRequires: pkgconfig(libosmovty) >= 1.9.0 |
| 37 | BuildRequires: pkgconfig(libosmocoding) >= 1.9.0 |
| 38 | BuildRequires: pkgconfig(libosmoabis) >= 1.5.0 |
| 39 | BuildRequires: pkgconfig(libosmotrau) >= 1.5.0 |
Oliver Smith | d6877eb | 2020-05-14 11:47:38 +0200 | [diff] [blame] | 40 | %{?systemd_requires} |
| 41 | |
| 42 | %description |
| 43 | OsmoMGW is Osmocom's Media Gateway for 2G and 3G circuit-switched mobile networks. |
| 44 | |
Pau Espin Pedrol | 730a1f2 | 2023-09-12 14:48:51 +0200 | [diff] [blame] | 45 | %package -n libosmo-mgcp-client12 |
Oliver Smith | d6877eb | 2020-05-14 11:47:38 +0200 | [diff] [blame] | 46 | Summary: Osmocom's Media Gateway Control Protocol client library |
| 47 | Group: System/Libraries |
| 48 | |
Pau Espin Pedrol | 730a1f2 | 2023-09-12 14:48:51 +0200 | [diff] [blame] | 49 | %description -n libosmo-mgcp-client12 |
Oliver Smith | d6877eb | 2020-05-14 11:47:38 +0200 | [diff] [blame] | 50 | Osmocom's Media Gateway Control Protocol client library. |
| 51 | |
| 52 | %package -n libosmo-mgcp-client-devel |
| 53 | Summary: Development files for Osmocom's Media Gateway Control Protocol client library |
| 54 | Group: Development/Libraries/C and C++ |
Pau Espin Pedrol | 730a1f2 | 2023-09-12 14:48:51 +0200 | [diff] [blame] | 55 | Requires: libosmo-mgcp-client12 = %{version} |
Oliver Smith | d6877eb | 2020-05-14 11:47:38 +0200 | [diff] [blame] | 56 | |
| 57 | %description -n libosmo-mgcp-client-devel |
| 58 | Osmocom's Media Gateway Control Protocol client librarary. |
| 59 | |
| 60 | This subpackage contains libraries and header files for developing |
| 61 | applications that want to make use of libosmo-mgcp-client. |
| 62 | |
| 63 | %package -n libosmo-mgcp-devel |
| 64 | Summary: Development files for Osmocom's Media Gateway server library |
| 65 | Group: Development/Libraries/C and C++ |
| 66 | |
| 67 | %description -n libosmo-mgcp-devel |
| 68 | Osmocom's Media Gateway Control Protocol server library. |
| 69 | |
| 70 | This subpackage contains libraries and header files for developing |
| 71 | applications that want to make use of libosmo-mgcp. |
| 72 | |
| 73 | %prep |
| 74 | %setup -q |
| 75 | |
| 76 | %build |
| 77 | echo "%{version}" >.tarball-version |
| 78 | autoreconf -fi |
| 79 | %configure \ |
| 80 | --disable-static \ |
| 81 | --docdir=%{_docdir}/%{name} \ |
| 82 | --with-systemdsystemunitdir=%{_unitdir} |
| 83 | |
| 84 | make %{?_smp_mflags} |
| 85 | |
| 86 | %install |
| 87 | %make_install |
| 88 | find %{buildroot} -type f -name "*.la" -delete -print |
| 89 | |
| 90 | %check |
| 91 | make %{?_smp_mflags} check || (find . -name testsuite.log -exec cat {} +) |
| 92 | |
Pau Espin Pedrol | 730a1f2 | 2023-09-12 14:48:51 +0200 | [diff] [blame] | 93 | %post -n libosmo-mgcp-client12 -p /sbin/ldconfig |
| 94 | %postun -n libosmo-mgcp-client12 -p /sbin/ldconfig |
Oliver Smith | 6500d72 | 2020-05-14 11:48:29 +0200 | [diff] [blame] | 95 | |
| 96 | %if 0%{?suse_version} |
Oliver Smith | d6877eb | 2020-05-14 11:47:38 +0200 | [diff] [blame] | 97 | %preun |
| 98 | %service_del_preun osmo-mgw.service |
| 99 | |
| 100 | %postun |
| 101 | %service_del_postun osmo-mgw.service |
| 102 | |
| 103 | %pre |
| 104 | %service_add_pre osmo-mgw.service |
| 105 | |
| 106 | %post |
| 107 | %service_add_post osmo-mgw.service |
Oliver Smith | 6500d72 | 2020-05-14 11:48:29 +0200 | [diff] [blame] | 108 | %endif |
Oliver Smith | d6877eb | 2020-05-14 11:47:38 +0200 | [diff] [blame] | 109 | |
| 110 | %files |
| 111 | %license COPYING |
| 112 | %doc AUTHORS README |
| 113 | %dir %{_docdir}/%{name}/examples |
| 114 | %dir %{_docdir}/%{name}/examples/osmo-mgw |
| 115 | %{_docdir}/%{name}/examples/osmo-mgw/osmo-mgw.cfg |
Harald Welte | 9e494e6 | 2020-08-28 14:59:47 +0200 | [diff] [blame] | 116 | %{_docdir}/%{name}/examples/osmo-mgw/osmo-mgw-abis_e1.cfg |
Oliver Smith | d6877eb | 2020-05-14 11:47:38 +0200 | [diff] [blame] | 117 | %{_bindir}/osmo-mgw |
| 118 | %{_unitdir}/osmo-mgw.service |
| 119 | %dir %{_sysconfdir}/osmocom |
Harald Welte | 41f77d8 | 2020-06-22 14:20:53 +0200 | [diff] [blame] | 120 | %config(noreplace) %{_sysconfdir}/osmocom/osmo-mgw.cfg |
Oliver Smith | d6877eb | 2020-05-14 11:47:38 +0200 | [diff] [blame] | 121 | |
Pau Espin Pedrol | 730a1f2 | 2023-09-12 14:48:51 +0200 | [diff] [blame] | 122 | %files -n libosmo-mgcp-client12 |
| 123 | %{_libdir}/libosmo-mgcp-client.so.12* |
Oliver Smith | d6877eb | 2020-05-14 11:47:38 +0200 | [diff] [blame] | 124 | |
| 125 | %files -n libosmo-mgcp-client-devel |
| 126 | %{_libdir}/libosmo-mgcp-client.so |
| 127 | %{_libdir}/pkgconfig/libosmo-mgcp-client.pc |
| 128 | %dir %{_includedir}/osmocom |
| 129 | %dir %{_includedir}/osmocom/mgcp_client |
| 130 | %{_includedir}/osmocom/mgcp_client/*.h |
| 131 | |
| 132 | %files -n libosmo-mgcp-devel |
| 133 | %dir %{_includedir}/osmocom |
| 134 | %dir %{_includedir}/osmocom/mgcp |
| 135 | %{_includedir}/osmocom/mgcp/*.h |
| 136 | |
| 137 | %changelog |