1 Name: ceres-solver 2 Version: 1.7.0 3 # Release candidate versions are messy. Give them a release of 4 # e.g. "0.1.0%{?dist}" for RC1 (and remember to adjust the Source0 5 # URL). Non-RC releases go back to incrementing integers starting at 1. 6 Release: 0.3.0%{?dist} 7 Summary: A non-linear least squares minimizer 8 9 Group: Development/Libraries 10 License: BSD 11 URL: http://code.google.com/p/ceres-solver/ 12 Source0: http://%{name}.googlecode.com/files/%{name}-%{version}rc3.tar.gz 13 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) 14 15 %if (0%{?rhel} == 06) 16 BuildRequires: cmake28 17 %else 18 BuildRequires: cmake 19 %endif 20 BuildRequires: eigen3-devel 21 # suitesparse <= 3.4.0-7 ships without *.hpp C++ headers 22 # https://bugzilla.redhat.com/show_bug.cgi?id=1001869 23 BuildRequires: suitesparse-devel > 3.4.0-7 24 # If the suitesparse package was built with TBB then we need TBB too 25 %ifarch %{ix86} x86_64 ia64 26 BuildRequires: tbb-devel 27 %endif 28 # Use atlas for BLAS and LAPACK 29 BuildRequires: atlas-devel 30 BuildRequires: gflags-devel 31 BuildRequires: glog-devel 32 33 %description 34 Ceres Solver is a portable C++ library that allows for modeling and solving 35 large complicated nonlinear least squares problems. Features include: 36 37 - A friendly API: build your objective function one term at a time 38 - Automatic differentiation 39 - Robust loss functions 40 - Local parameterizations 41 - Threaded Jacobian evaluators and linear solvers 42 - Levenberg-Marquardt and Dogleg (Powell & Subspace) solvers 43 - Dense QR and Cholesky factorization (using Eigen) for small problems 44 - Sparse Cholesky factorization (using SuiteSparse) for large sparse problems 45 - Specialized solvers for bundle adjustment problems in computer vision 46 - Iterative linear solvers for general sparse and bundle adjustment problems 47 - Runs on Linux, Windows, Mac OS X and Android. An iOS port is underway 48 49 Notable use of Ceres Solver is for the image alignment in Google Maps and for 50 vehicle pose in Google Street View. 51 52 53 %package devel 54 Summary: A non-linear least squares minimizer 55 Group: Development/Libraries 56 Requires: %{name} = %{version}-%{release} 57 58 %description devel 59 The %{name}-devel package contains libraries and header files for 60 developing applications that use %{name}. 61 62 63 %prep 64 %setup -q 65 66 %build 67 mkdir build 68 pushd build 69 70 # Disable the compilation flags that rpmbuild macros try to apply to all 71 # packages because it breaks the build since release 1.5.0rc1 72 %define optflags "" 73 %if (0%{?rhel} == 06) 74 %{cmake28} .. 75 %else 76 %{cmake} .. 77 %endif 78 make %{?_smp_mflags} 79 80 81 %install 82 rm -rf $RPM_BUILD_ROOT 83 pushd build 84 make install DESTDIR=$RPM_BUILD_ROOT 85 find $RPM_BUILD_ROOT -name '*.la' -delete 86 87 # Make the subdirectory in /usr/share match the name of this package 88 mv $RPM_BUILD_ROOT%{_datadir}/{Ceres,%{name}} 89 90 91 %clean 92 rm -rf $RPM_BUILD_ROOT 93 94 95 %post -p /sbin/ldconfig 96 97 %postun -p /sbin/ldconfig 98 99 100 %files 101 %defattr(-,root,root,-) 102 %doc README LICENSE 103 %{_libdir}/*.so.* 104 105 %files devel 106 %defattr(-,root,root,-) 107 %{_includedir}/* 108 %{_libdir}/*.so 109 %{_datadir}/%{name}/*.cmake 110 111 112 %changelog 113 * Thu Aug 29 2013 Taylor Braun-Jones <taylor@braun-jones.org> - 1.7.0-0.3.0 114 - Bump version 115 116 * Mon Aug 26 2013 Sameer Agarwal <sameeragarwal@google.com> - 1.7.0-0.2.0 117 - Bump version 118 119 * Mon Jul 18 2013 Sameer Agarwal <sameeragarwal@google.com> - 1.7.0-0.1.0 120 - Bump version 121 122 * Mon Apr 29 2013 Sameer Agarwal <sameeragarwal@google.com> - 1.6.0-1 123 - Bump version 124 125 * Mon Apr 29 2013 Sameer Agarwal <sameeragarwal@google.com> - 1.6.0-0.2.0 126 - Bump version 127 128 * Mon Apr 29 2013 Sameer Agarwal <sameeragarwal@google.com> - 1.6.0-0.1.0 129 - Bump version 130 131 * Sun Feb 24 2013 Taylor Braun-Jones <taylor@braun-jones.org> - 1.5.0-0.1.0 132 - Bump version. 133 134 * Sun Oct 14 2012 Taylor Braun-Jones <taylor@braun-jones.org> - 1.4.0-0 135 - Initial creation 136