]> git.pld-linux.org Git - packages/libphonenumber.git/blame - libphonenumber.spec
- updated to 8.13.11
[packages/libphonenumber.git] / libphonenumber.spec
CommitLineData
874379c9
JB
1# TODO: java package
2#
3# Conditional build:
4%bcond_with re2 # RE2 regular expressions engine (broken as of 8.12.2)
5%bcond_without static_libs # static libraries
6#
7Summary: Library to handle international phone numbers
8Summary(pl.UTF-8): Biblioteka do obsługi międzynarodowych numerów telefonów
9Name: libphonenumber
c9e3b260 10Version: 8.13.11
279323ce 11Release: 1
874379c9
JB
12License: Apache v2.0 with BSD parts
13Group: Libraries
14#Source0Download: https://github.com/google/libphonenumber/releases/
15Source0: https://github.com/google/libphonenumber/archive/v%{version}/%{name}-%{version}.tar.gz
c9e3b260 16# Source0-md5: 688130209ffc810632ae6ca93af5506f
874379c9 17Patch0: %{name}-link.patch
4ded0a69 18Patch1: %{name}-no-fetch.patch
7d6fb481 19Patch2: no-static.patch
874379c9 20URL: https://github.com/google/libphonenumber/
4ded0a69 21BuildRequires: abseil-cpp-devel
874379c9 22BuildRequires: boost-devel >= 1.40.0
d9e2a5ef 23BuildRequires: cmake >= 3.11
874379c9
JB
24BuildRequires: gtest-devel
25BuildRequires: jre
26BuildRequires: libicu-devel >= 4.4
38501573 27BuildRequires: libstdc++-devel >= 6:7
874379c9
JB
28BuildRequires: pkgconfig
29BuildRequires: protobuf-devel >= 2.4
30%{?with_re2:BuildRequires: re2-devel}
3cce7a69 31BuildRequires: rpmbuild(macros) >= 1.605
874379c9
JB
32BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
33
34%description
35Google's common C++ library for parsing, formatting, storing and
36validating international phone numbers.
37
38%description -l pl.UTF-8
39Wspólna biblioteka C++ Google'a do analizy, formatowania,
40przechowywania oraz sprawdzania poprawności międzynarodowych numerów
41telefonów.
42
43%package devel
44Summary: Header files for libphonenumber library
45Summary(pl.UTF-8): Pliki nagłówkowe biblioteki libphonenumber
46Group: Development/Libraries
47Requires: %{name} = %{version}-%{release}
48Requires: boost-devel >= 1.40.0
49Requires: libicu-devel
50Requires: libstdc++-devel
51Requires: protobuf-devel
52
53%description devel
54Header files for libphonenumber library.
55
56%description devel -l pl.UTF-8
57Pliki nagłówkowe biblioteki libphonenumber.
58
59%package static
60Summary: Static libphonenumber libraries
61Summary(pl.UTF-8): Statyczne biblioteki libphonenumber
62Group: Development/Libraries
63Requires: %{name}-devel = %{version}-%{release}
64
65%description static
66Static libphonenumber libraries.
67
68%description static -l pl.UTF-8
69Statyczne biblioteki libphonenumber.
70
71%prep
72%setup -q
73%patch0 -p1
4ded0a69 74%patch1 -p1
7d6fb481 75%patch2 -p1
874379c9
JB
76
77%build
78install -d build/cpp
79cd build/cpp
80%cmake ../../cpp \
81 %{!?with_static_libs:-DBUILD_STATIC_LIB=OFF} \
82 %{?with_re2:-DUSE_RE2=ON}
83
84%{__make}
85
86%install
87rm -rf $RPM_BUILD_ROOT
88
89%{__make} -C build/cpp install \
90 DESTDIR=$RPM_BUILD_ROOT
91
92%clean
93rm -rf $RPM_BUILD_ROOT
94
95%post -p /sbin/ldconfig
96%postun -p /sbin/ldconfig
97
98%files
99%defattr(644,root,root,755)
100%doc AUTHORS CONTRIBUTORS FALSEHOODS.md FAQ.md LICENSE.Chromium README.md release_notes.txt cpp/{LICENSE,README}
101%attr(755,root,root) %{_libdir}/libgeocoding.so.*.*
102%attr(755,root,root) %ghost %{_libdir}/libgeocoding.so.8
103%attr(755,root,root) %{_libdir}/libphonenumber.so.*.*
104%attr(755,root,root) %ghost %{_libdir}/libphonenumber.so.8
105
106%files devel
107%defattr(644,root,root,755)
108%attr(755,root,root) %{_libdir}/libgeocoding.so
109%attr(755,root,root) %{_libdir}/libphonenumber.so
110%{_includedir}/phonenumbers
570e0eb5 111%{_libdir}/cmake/libphonenumber
874379c9
JB
112
113%if %{with static_libs}
114%files static
115%defattr(644,root,root,755)
116%{_libdir}/libgeocoding.a
117%{_libdir}/libphonenumber.a
118%endif
This page took 0.253936 seconds and 4 git commands to generate.