]>
Commit | Line | Data |
---|---|---|
7c1add51 JB |
1 | # |
2 | # Conditional build: | |
aaba5611 | 3 | %bcond_with tests # gtest/gmock based tests [signalhandler_unittest broken on x32 as of 0.4.0] |
c1854bdb | 4 | |
58b4ba18 | 5 | Summary: A C++ application logging library |
74c045b0 | 6 | Summary(pl.UTF-8): Biblioteka do logowania dla aplikacji w C++ |
58b4ba18 | 7 | Name: glog |
97ed79bd JB |
8 | Version: 0.4.0 |
9 | Release: 1 | |
58b4ba18 ER |
10 | License: BSD |
11 | Group: Libraries | |
bdc57d3d | 12 | #Source0Download: https://github.com/google/glog/releases |
47930f1c | 13 | Source0: https://github.com/google/glog/archive/v%{version}/%{name}-%{version}.tar.gz |
97ed79bd | 14 | # Source0-md5: 0daea8785e6df922d7887755c3d100d0 |
7c1add51 | 15 | Patch0: %{name}-gflags.patch |
c1854bdb | 16 | Patch1: avoid-inline-asm.patch |
47930f1c | 17 | URL: https://github.com/google/glog |
74c045b0 JB |
18 | BuildRequires: autoconf >= 2.57 |
19 | BuildRequires: automake | |
20 | BuildRequires: gflags-devel | |
47930f1c ER |
21 | BuildRequires: libstdc++-devel |
22 | BuildRequires: libtool >= 2:1.5 | |
23 | BuildRequires: pkgconfig | |
7c1add51 | 24 | %if %{with tests} |
7a7b4539 | 25 | BuildRequires: gmock-devel >= 1.10.0 |
7c1add51 | 26 | BuildRequires: gtest-devel |
54e3f726 JR |
27 | %else |
28 | BuildConflicts: gmock-devel | |
29 | BuildConflicts: gtest-devel | |
7c1add51 | 30 | %endif |
97ed79bd | 31 | %ifarch %{ix86} %{x8664} x32 %{arm} hppa ia64 mips ppc ppc64 sh |
74c045b0 | 32 | BuildRequires: libunwind-devel |
c1854bdb | 33 | %endif |
58b4ba18 ER |
34 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
35 | ||
36 | %description | |
37 | Google glog is a library that implements application-level logging. | |
38 | This library provides logging APIs based on C++-style streams and | |
39 | various helper macros. | |
40 | ||
74c045b0 JB |
41 | %description -l pl.UTF-8 |
42 | Google glog to biblioteka implementująca logowanie na poziomie | |
43 | aplikacji. Zapewnia API do logowania oparte na strumieniach w stylu | |
44 | C++ oraz różne makra pomocnicze | |
45 | ||
58b4ba18 | 46 | %package devel |
74c045b0 JB |
47 | Summary: Development files for glog library |
48 | Summary(pl.UTF-8): Pliki programistyczne biblioteki glog | |
58b4ba18 ER |
49 | Group: Development/Libraries |
50 | Requires: %{name} = %{version}-%{release} | |
74c045b0 JB |
51 | Requires: gflags-devel |
52 | Requires: libstdc++-devel | |
58b4ba18 ER |
53 | |
54 | %description devel | |
74c045b0 JB |
55 | This package contains the header files for developing applications |
56 | that use glog library. | |
57 | ||
58 | %description devel -l pl.UTF-8 | |
59 | Ten pakiet zawiera pliki nagłówkowe do tworzenia aplikacji | |
60 | wykorzystujących bibliotekę glog. | |
61 | ||
62 | %package static | |
63 | Summary: Static glog library | |
64 | Summary(pl.UTF-8): Statyczna biblioteka glog | |
65 | Group: Development/Libraries | |
66 | Requires: %{name}-devel = %{version}-%{release} | |
67 | ||
68 | %description static | |
69 | Static glog library. | |
70 | ||
71 | %description static -l pl.UTF-8 | |
72 | Statyczna biblioteka glog. | |
58b4ba18 ER |
73 | |
74 | %prep | |
75 | %setup -q | |
7c1add51 | 76 | %patch0 -p1 |
c1854bdb | 77 | %patch1 -p1 |
58b4ba18 ER |
78 | |
79 | %build | |
74c045b0 JB |
80 | %{__libtoolize} |
81 | %{__aclocal} -I m4 | |
58b4ba18 | 82 | %{__autoconf} |
74c045b0 JB |
83 | %{__autoheader} |
84 | %{__automake} | |
85 | %configure | |
58b4ba18 ER |
86 | |
87 | %{__make} | |
88 | ||
7c1add51 JB |
89 | %if %{with tests} |
90 | %{__make} check | |
91 | %endif | |
92 | ||
58b4ba18 ER |
93 | %install |
94 | rm -rf $RPM_BUILD_ROOT | |
95 | %{__make} install \ | |
96 | DESTDIR=$RPM_BUILD_ROOT | |
97 | ||
98 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/libglog.la | |
99 | %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version} | |
100 | ||
101 | %clean | |
102 | rm -rf $RPM_BUILD_ROOT | |
103 | ||
104 | %post -p /sbin/ldconfig | |
105 | %postun -p /sbin/ldconfig | |
106 | ||
107 | %files | |
108 | %defattr(644,root,root,755) | |
97ed79bd | 109 | %doc AUTHORS COPYING ChangeLog README.md |
58b4ba18 | 110 | %attr(755,root,root) %{_libdir}/libglog.so.*.*.* |
74c045b0 | 111 | %attr(755,root,root) %ghost %{_libdir}/libglog.so.0 |
58b4ba18 ER |
112 | |
113 | %files devel | |
114 | %defattr(644,root,root,755) | |
115 | %doc doc/designstyle.css doc/glog.html | |
74c045b0 JB |
116 | %attr(755,root,root) %{_libdir}/libglog.so |
117 | %{_includedir}/glog | |
58b4ba18 | 118 | %{_pkgconfigdir}/libglog.pc |
74c045b0 JB |
119 | |
120 | %files static | |
121 | %defattr(644,root,root,755) | |
122 | %{_libdir}/libglog.a |