blob: fa08acda1f75da8c293a042ef18f0f2b8785c559 [file] [log] [blame]
Oliver Smithd6877eb2020-05-14 11:47:38 +02001#
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
18Name: osmo-mgw
Oliver Smith6500d722020-05-14 11:48:29 +020019Version: @VERSION@
Oliver Smithd6877eb2020-05-14 11:47:38 +020020Release: 0
21Summary: Osmocom's Media Gateway for 2G and 3G circuit-switched mobile networks
22License: AGPL-3.0-or-later AND GPL-2.0-or-later
23Group: Hardware/Mobile
24URL: https://osmocom.org/projects/osmo-mgw
25Source: %{name}-%{version}.tar.xz
26BuildRequires: automake >= 1.9
27BuildRequires: libtool >= 2
28BuildRequires: pkgconfig >= 0.20
Oliver Smith6500d722020-05-14 11:48:29 +020029%if 0%{?suse_version}
Oliver Smithd6877eb2020-05-14 11:47:38 +020030BuildRequires: systemd-rpm-macros
Oliver Smith6500d722020-05-14 11:48:29 +020031%endif
Pau Espin Pedrol730a1f22023-09-12 14:48:51 +020032BuildRequires: pkgconfig(libosmo-netif) >= 1.4.0
33BuildRequires: pkgconfig(libosmocore) >= 1.9.0
34BuildRequires: pkgconfig(libosmoctrl) >= 1.9.0
35BuildRequires: pkgconfig(libosmogsm) >= 1.9.0
36BuildRequires: pkgconfig(libosmovty) >= 1.9.0
37BuildRequires: pkgconfig(libosmocoding) >= 1.9.0
38BuildRequires: pkgconfig(libosmoabis) >= 1.5.0
39BuildRequires: pkgconfig(libosmotrau) >= 1.5.0
Oliver Smithd6877eb2020-05-14 11:47:38 +020040%{?systemd_requires}
41
42%description
43OsmoMGW is Osmocom's Media Gateway for 2G and 3G circuit-switched mobile networks.
44
Pau Espin Pedrol730a1f22023-09-12 14:48:51 +020045%package -n libosmo-mgcp-client12
Oliver Smithd6877eb2020-05-14 11:47:38 +020046Summary: Osmocom's Media Gateway Control Protocol client library
47Group: System/Libraries
48
Pau Espin Pedrol730a1f22023-09-12 14:48:51 +020049%description -n libosmo-mgcp-client12
Oliver Smithd6877eb2020-05-14 11:47:38 +020050Osmocom's Media Gateway Control Protocol client library.
51
52%package -n libosmo-mgcp-client-devel
53Summary: Development files for Osmocom's Media Gateway Control Protocol client library
54Group: Development/Libraries/C and C++
Pau Espin Pedrol730a1f22023-09-12 14:48:51 +020055Requires: libosmo-mgcp-client12 = %{version}
Oliver Smithd6877eb2020-05-14 11:47:38 +020056
57%description -n libosmo-mgcp-client-devel
58Osmocom's Media Gateway Control Protocol client librarary.
59
60This subpackage contains libraries and header files for developing
61applications that want to make use of libosmo-mgcp-client.
62
Oliver Smithd6877eb2020-05-14 11:47:38 +020063%prep
64%setup -q
65
66%build
67echo "%{version}" >.tarball-version
68autoreconf -fi
69%configure \
70 --disable-static \
71 --docdir=%{_docdir}/%{name} \
72 --with-systemdsystemunitdir=%{_unitdir}
73
74make %{?_smp_mflags}
75
76%install
77%make_install
78find %{buildroot} -type f -name "*.la" -delete -print
79
80%check
81make %{?_smp_mflags} check || (find . -name testsuite.log -exec cat {} +)
82
Pau Espin Pedrol730a1f22023-09-12 14:48:51 +020083%post -n libosmo-mgcp-client12 -p /sbin/ldconfig
84%postun -n libosmo-mgcp-client12 -p /sbin/ldconfig
Oliver Smith6500d722020-05-14 11:48:29 +020085
86%if 0%{?suse_version}
Oliver Smithd6877eb2020-05-14 11:47:38 +020087%preun
88%service_del_preun osmo-mgw.service
89
90%postun
91%service_del_postun osmo-mgw.service
92
93%pre
94%service_add_pre osmo-mgw.service
95
96%post
97%service_add_post osmo-mgw.service
Oliver Smith6500d722020-05-14 11:48:29 +020098%endif
Oliver Smithd6877eb2020-05-14 11:47:38 +020099
100%files
101%license COPYING
102%doc AUTHORS README
103%dir %{_docdir}/%{name}/examples
104%dir %{_docdir}/%{name}/examples/osmo-mgw
105%{_docdir}/%{name}/examples/osmo-mgw/osmo-mgw.cfg
Harald Welte9e494e62020-08-28 14:59:47 +0200106%{_docdir}/%{name}/examples/osmo-mgw/osmo-mgw-abis_e1.cfg
Oliver Smithd6877eb2020-05-14 11:47:38 +0200107%{_bindir}/osmo-mgw
108%{_unitdir}/osmo-mgw.service
109%dir %{_sysconfdir}/osmocom
Harald Welte41f77d82020-06-22 14:20:53 +0200110%config(noreplace) %{_sysconfdir}/osmocom/osmo-mgw.cfg
Oliver Smithd6877eb2020-05-14 11:47:38 +0200111
Pau Espin Pedrol730a1f22023-09-12 14:48:51 +0200112%files -n libosmo-mgcp-client12
113%{_libdir}/libosmo-mgcp-client.so.12*
Oliver Smithd6877eb2020-05-14 11:47:38 +0200114
115%files -n libosmo-mgcp-client-devel
116%{_libdir}/libosmo-mgcp-client.so
117%{_libdir}/pkgconfig/libosmo-mgcp-client.pc
118%dir %{_includedir}/osmocom
119%dir %{_includedir}/osmocom/mgcp_client
120%{_includedir}/osmocom/mgcp_client/*.h
121
Oliver Smithd6877eb2020-05-14 11:47:38 +0200122%changelog