]>
Commit | Line | Data |
---|---|---|
2f12528f JB |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without apidocs # do not build and package API docs | |
4 | %bcond_without static_libs # don't build static libraries | |
5 | # | |
6 | Summary: COIN-OR Utilities library | |
7 | Summary(pl.UTF-8): Biblioteka narzędziowa COIN-OR Utilities | |
8 | Name: CoinUtils | |
9 | Version: 2.9.17 | |
10 | Release: 1 | |
11 | License: Eclipse Public License v1.0 | |
12 | Group: Libraries | |
13 | Source0: http://www.coin-or.org/download/source/CoinUtils/%{name}-%{version}.tgz | |
14 | # Source0-md5: e91ff822dc535055968094d88bcaabce | |
15 | Patch0: %{name}-format.patch | |
16 | Patch1: %{name}-destdir.patch | |
17 | URL: https://projects.coin-or.org/CoinUtils | |
18 | BuildRequires: autoconf >= 2.59 | |
19 | BuildRequires: automake | |
20 | BuildRequires: blas-devel | |
21 | BuildRequires: bzip2-devel | |
22 | %{?with_apidocs:BuildRequires: doxygen} | |
23 | BuildRequires: lapack-devel | |
24 | BuildRequires: libstdc++-devel | |
25 | BuildRequires: libtool >= 2:1.5 | |
26 | BuildRequires: zlib-devel | |
27 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
28 | ||
29 | %description | |
30 | CoinUtils (Coin-or Utilities) is an open-source collection of classes | |
31 | and functions that are generally useful to more than one COIN-OR | |
32 | project. These utilities include: | |
33 | - Vector classes | |
34 | - Matrix classes | |
35 | - MPS file reading | |
36 | - Comparing floating point numbers with a tolerance | |
37 | ||
38 | %description -l pl.UTF-8 | |
39 | CoinUtils (Coin-or Utilities) to mający otwarte źródła zbiór klas i | |
40 | funkcji ogólnie przydatnych dla więcej niż jednego projektu COIN-OR. | |
41 | Narzędzia Coin-or zawirają: | |
42 | - klasy wektorów | |
43 | - klasy macierzy | |
44 | - odczyt plików MPS | |
45 | - porównywanie liczb zmiennoprzecinkowych z określoną dokładnością | |
46 | ||
47 | %package devel | |
48 | Summary: Header files for CoinUtils library | |
49 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki CoinUtils | |
50 | Group: Development/Libraries | |
51 | Requires: %{name} = %{version}-%{release} | |
52 | Requires: blas-devel | |
53 | Requires: bzip2-devel | |
54 | Requires: lapack-devel | |
55 | Requires: libstdc++-devel | |
56 | Requires: zlib-devel | |
57 | ||
58 | %description devel | |
59 | Header files for CoinUtils library. | |
60 | ||
61 | %description devel -l pl.UTF-8 | |
62 | Pliki nagłówkowe biblioteki CoinUtils. | |
63 | ||
64 | %package static | |
65 | Summary: Static CoinUtils library | |
66 | Summary(pl.UTF-8): Statyczna biblioteka CoinUtils | |
67 | Group: Development/Libraries | |
68 | Requires: %{name}-devel = %{version}-%{release} | |
69 | ||
70 | %description static | |
71 | Static CoinUtils library. | |
72 | ||
73 | %description static -l pl.UTF-8 | |
74 | Statyczna biblioteka CoinUtils. | |
75 | ||
76 | %package apidocs | |
77 | Summary: CoinUtils API documentation | |
78 | Summary(pl.UTF-8): Dokumentacja API biblioteki CoinUtils | |
79 | Group: Documentation | |
80 | ||
81 | %description apidocs | |
82 | API documentation for CoinUtils library. | |
83 | ||
84 | %description apidocs -l pl.UTF-8 | |
85 | Dokumentacja API biblioteki CoinUtils. | |
86 | ||
87 | %prep | |
88 | %setup -q | |
89 | %patch0 -p1 | |
90 | %patch1 -p1 | |
91 | ||
92 | ln -s ../BuildTools CoinUtils/BuildTools | |
93 | ||
94 | %build | |
95 | cd CoinUtils | |
96 | %{__libtoolize} | |
97 | %{__aclocal} -I BuildTools | |
98 | %{__autoconf} | |
99 | %{__autoheader} | |
100 | %{__automake} | |
101 | cd .. | |
102 | %configure \ | |
103 | --enable-dependency-linking \ | |
104 | %{?with_static_libs:--enable-static} | |
105 | %{__make} | |
106 | ||
107 | %if %{with apidocs} | |
108 | %{__make} doxydoc | |
109 | %endif | |
110 | ||
111 | %install | |
112 | rm -rf $RPM_BUILD_ROOT | |
113 | ||
114 | %{__make} install \ | |
115 | DESTDIR=$RPM_BUILD_ROOT | |
116 | ||
117 | # obsoleted by pkg-config | |
118 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/libCoinUtils.la | |
119 | # packages as %doc | |
120 | %{__rm} $RPM_BUILD_ROOT%{_datadir}/coin/doc/CoinUtils/{AUTHORS,LICENSE,README} | |
121 | ||
122 | %clean | |
123 | rm -rf $RPM_BUILD_ROOT | |
124 | ||
125 | %post -p /sbin/ldconfig | |
126 | %postun -p /sbin/ldconfig | |
127 | ||
128 | %files | |
129 | %defattr(644,root,root,755) | |
130 | %doc CoinUtils/{AUTHORS,LICENSE,README} | |
131 | %attr(755,root,root) %{_libdir}/libCoinUtils.so.*.*.* | |
132 | %attr(755,root,root) %ghost %{_libdir}/libCoinUtils.so.3 | |
133 | %dir %{_datadir}/coin | |
134 | %{_datadir}/coin/Data | |
135 | ||
136 | %files devel | |
137 | %defattr(644,root,root,755) | |
138 | %attr(755,root,root) %{_libdir}/libCoinUtils.so | |
139 | %dir %{_includedir}/coin | |
140 | %{_includedir}/coin/CoinUtilsConfig.h | |
141 | %{_includedir}/coin/Coin_C_defines.h | |
142 | %{_includedir}/coin/Coin*.hpp | |
143 | %{_pkgconfigdir}/coindatasample.pc | |
144 | %{_pkgconfigdir}/coinutils.pc | |
145 | %dir %{_datadir}/coin/doc | |
146 | %dir %{_datadir}/coin/doc/CoinUtils | |
147 | %{_datadir}/coin/doc/CoinUtils/coinutils_addlibs.txt | |
148 | ||
149 | %if %{with static_libs} | |
150 | %files static | |
151 | %defattr(644,root,root,755) | |
152 | %{_libdir}/libCoinUtils.a | |
153 | %endif | |
154 | ||
155 | %if %{with apidocs} | |
156 | %files apidocs | |
157 | %defattr(644,root,root,755) | |
158 | %doc doxydoc/html/* | |
159 | %endif |