]> git.pld-linux.org Git - packages/folly.git/blob - folly.spec
- fix building with ggc 5.x
[packages/folly.git] / folly.spec
1 #
2 # Conditional build:
3 %bcond_without  static_libs     # don't build static libraries
4 %bcond_with     tests           # build with tests
5
6 Summary:        Library of C++11 components designed with practicality and efficiency in mind
7 Name:           folly
8 Version:        0.41.0
9 Release:        1
10 License:        Apache v2.0
11 Group:          Libraries
12 Source0:        https://github.com/facebook/folly/archive/v%{version}/%{name}-%{version}.tar.gz
13 # Source0-md5:  d7ff7682850ea0846881fb1fb42136e9
14 Patch0:         gcc5.patch
15 URL:            https://github.com/facebook/folly
16 BuildRequires:  autoconf
17 BuildRequires:  automake
18 BuildRequires:  boost-devel >= 1.20.0
19 BuildRequires:  double-conversion-devel
20 BuildRequires:  gflags-devel
21 BuildRequires:  glog-devel
22 %{?with_tests:BuildRequires:    gtest-devel >= 1.6.0}
23 BuildRequires:  libevent-devel
24 BuildRequires:  libstdc++-devel
25 BuildRequires:  libtool
26 BuildRequires:  m4
27 BuildRequires:  openssl-devel
28 BuildRequires:  python
29 BuildRequires:  python-modules
30 BuildRequires:  rpmbuild(macros) >= 1.583
31 ExclusiveArch:  %{x8664}
32 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
33
34 %define         sover   %(echo %{version} | cut -d. -f2)
35
36 # missing openssl linking
37 %define         skip_post_check_so      libfolly.so.%{sover}.0.0
38
39 %description
40 Folly (acronymed loosely after Facebook Open Source Library) is a
41 library of C++11 components designed with practicality and efficiency
42 in mind. It complements (as opposed to competing against) offerings
43 such as Boost and of course std. In fact, we embark on defining our
44 own component only when something we need is either not available, or
45 does not meet the needed performance profile.
46
47 Performance concerns permeate much of Folly, sometimes leading to
48 designs that are more idiosyncratic than they would otherwise be (see
49 e.g. PackedSyncPtr.h, SmallLocks.h). Good performance at large scale
50 is a unifying theme in all of Folly.
51
52 %package devel
53 Summary:        Header files for %{name} library
54 Summary(pl.UTF-8):      Pliki nagłówkowe biblioteki %{name}
55 Group:          Development/Libraries
56 Requires:       %{name} = %{version}-%{release}
57
58 %description devel
59 Header files for %{name} library.
60
61 %description devel -l pl.UTF-8
62 Pliki nagłówkowe biblioteki %{name}.
63
64 %package static
65 Summary:        Static %{name} library
66 Summary(pl.UTF-8):      Statyczna biblioteka %{name}
67 Group:          Development/Libraries
68 Requires:       %{name}-devel = %{version}-%{release}
69
70 %description static
71 Static %{name} library.
72
73 %description static -l pl.UTF-8
74 Statyczna biblioteka %{name}.
75
76 %prep
77 %setup -q
78 %patch0 -p1
79
80 #ln -s %{_usrsrc}/gtest folly/test/gtest-1.7.0
81
82 %build
83 cd folly
84 %{__libtoolize}
85 %{__aclocal}
86 %{__autoconf}
87 %{__autoheader}
88 %{__automake}
89 %configure \
90         %{!?with_static_libs:--disable-static}
91 %{__make}
92 %{?with_tests:%{__make} check}
93
94 %install
95 rm -rf $RPM_BUILD_ROOT
96 %{__make} -C folly install \
97         DESTDIR=$RPM_BUILD_ROOT
98
99 # these aren't supposed to be installed!
100 #rm $RPM_BUILD_ROOT%{_libdir}/libgtest*
101
102 %clean
103 rm -rf $RPM_BUILD_ROOT
104
105 %post   -p /sbin/ldconfig
106 %postun -p /sbin/ldconfig
107
108 %files
109 %defattr(644,root,root,755)
110 %doc README.md LICENSE
111 %attr(755,root,root) %{_libdir}/libfolly.so.*.*.*
112 %ghost %{_libdir}/libfolly.so.%{sover}
113 %attr(755,root,root) %{_libdir}/libfollybenchmark.so.*.*.*
114 %ghost %{_libdir}/libfollybenchmark.so.%{sover}
115
116 %files devel
117 %defattr(644,root,root,755)
118 %{_libdir}/libfolly.so
119 %{_libdir}/libfollybenchmark.so
120 %{_libdir}/libfolly.la
121 %{_libdir}/libfollybenchmark.la
122 %{_includedir}/folly
123
124 %if %{with static_libs}
125 %files static
126 %defattr(644,root,root,755)
127 %{_libdir}/libfolly.a
128 %{_libdir}/libfollybenchmark.a
129 %endif
This page took 0.108666 seconds and 3 git commands to generate.