|
@@ -1,22 +1,34 @@
|
|
|
-
|
|
|
-# Fedora pkg-review: http://bugzilla.redhat.com/466764
|
|
|
+%global sse -DBUILD_FOR_SSE:BOOL=OFF
|
|
|
+%global sse2 -DBUILD_FOR_SSE2:BOOL=OFF
|
|
|
+%ifarch x86_64
|
|
|
+%global sse -DBUILD_FOR_SSE:BOOL=ON
|
|
|
+%global sse2 -DBUILD_FOR_SSE2:BOOL=ON
|
|
|
+%endif
|
|
|
|
|
|
Name: lensfun
|
|
|
-Version: 0.2.5
|
|
|
-Summary: Library to rectify defects introduced by photographic lenses
|
|
|
+Version: 0.3.0
|
|
|
Release: 1%{?_dist_release}
|
|
|
+Summary: Library to rectify defects introduced by photographic lenses
|
|
|
+
|
|
|
License: LGPLv3 and CC-BY-SA
|
|
|
Group: System Environment/Libraries
|
|
|
-URL: http://lensfun.berlios.de/
|
|
|
-Source0: http://download.berlios.de/lensfun/lensfun-%{version}.tar.bz2
|
|
|
-Patch0: lensfun-0.2.5-cpuid.patch
|
|
|
-BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
|
|
+URL: http://lensfun.sourceforge.net/
|
|
|
+
|
|
|
+Source0: http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.bz2
|
|
|
+
|
|
|
+## upstreamable patches
|
|
|
+# install manpages only when INSTALL_HELPER_SCRIPTS=ON
|
|
|
+Patch1: lensfun-0.3.0-INSTALL_HELPER_SCRIPTS.patch
|
|
|
+# install manpages in the correct place
|
|
|
+Patch2: lensfun-0.3.0-mandir.patch
|
|
|
|
|
|
+BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
|
|
|
+BuildRequires: cmake >= 2.8
|
|
|
BuildRequires: doxygen
|
|
|
BuildRequires: glib2-devel
|
|
|
BuildRequires: libpng-devel
|
|
|
BuildRequires: pkgconfig
|
|
|
-BuildRequires: python
|
|
|
+BuildRequires: python-docutils
|
|
|
BuildRequires: zlib-devel
|
|
|
|
|
|
Distribution: Vine Linux
|
|
@@ -44,36 +56,34 @@ using lensfun.
|
|
|
|
|
|
%prep
|
|
|
%setup -q
|
|
|
-%patch0 -p1 -b .cpuid
|
|
|
+%patch1 -p1 -b .INSTALL_HELPER_SCRIPTS
|
|
|
+%patch2 -p1 -b .mandir
|
|
|
|
|
|
|
|
|
%build
|
|
|
-# We can't use macro configure
|
|
|
-./configure \
|
|
|
- --cflags="${CFLAGS:-%optflags}" \
|
|
|
- --cxxflags="${CXXFLAGS:-%optflags}" \
|
|
|
- --prefix=%{_prefix} \
|
|
|
- --bindir=%{_bindir} \
|
|
|
- --sysconfdir=%{_sysconfdir} \
|
|
|
- --datadir=%{_datadir}/lensfun \
|
|
|
- --libdir=%{_libdir} \
|
|
|
- --includedir=%{_includedir} \
|
|
|
- --libexecdir=%{_libexecdir} \
|
|
|
-%ifnarch %{ix86} x86_64
|
|
|
- --vectorization \
|
|
|
-%endif
|
|
|
- --target=..generic
|
|
|
-
|
|
|
-# set GCC.LDFLAGS to avoid stripping and useless -debuginfo
|
|
|
-make AUTODEP=0 %{?_smp_mflags} lensfun manual \
|
|
|
- V=1 \
|
|
|
- GCC.LDFLAGS.release=""
|
|
|
-
|
|
|
+mkdir -p %{_target_platform}
|
|
|
+pushd %{_target_platform}
|
|
|
+%cmake \
|
|
|
+ -DBUILD_DOC:BOOL=ON \
|
|
|
+ -DBUILD_TESTS:BOOL=OFF \
|
|
|
+ -DCMAKE_BUILD_TYPE:STRING=Release \
|
|
|
+ %{?sse} %{?sse2} \
|
|
|
+ ..
|
|
|
+popd
|
|
|
+
|
|
|
+make %{?_smp_mflags} -C %{_target_platform}
|
|
|
+make doc -C %{_target_platform}
|
|
|
|
|
|
%install
|
|
|
rm -rf %{buildroot}
|
|
|
-make AUTODEP=0 INSTALL_PREFIX=%{buildroot} install
|
|
|
+make install/fast DESTDIR=%{buildroot} -C %{_target_platform}
|
|
|
|
|
|
+## unpackaged files
|
|
|
+# omit cmake-installed doxygen docs, we handle that manually
|
|
|
+rm -rfv %{buildroot}%{_docdir}/%{name}-%{version}*
|
|
|
+# omit g-lensfun-update-data because it needs gksudo which we don't ship
|
|
|
+rm -fv %{buildroot}%{_bindir}/g-lensfun-update-data \
|
|
|
+ %{buildroot}%{_mandir}/man1/g-lensfun-update-data.*
|
|
|
|
|
|
%clean
|
|
|
rm -rf %{buildroot}
|
|
@@ -86,24 +96,27 @@ rm -rf %{buildroot}
|
|
|
|
|
|
%files
|
|
|
%defattr(-,root,root,-)
|
|
|
-%dir %{_docdir}/%{name}-%{version}/
|
|
|
-%doc %{_docdir}/%{name}-%{version}/README
|
|
|
-%doc %{_docdir}/%{name}-%{version}/*.txt
|
|
|
-# currently, nothing is covered by GPLv3 (no apps in the package), no need to
|
|
|
-# confuse people:
|
|
|
-%exclude %{_docdir}/%{name}-%{version}/gpl-3.0.txt
|
|
|
-%{_datadir}/lensfun/
|
|
|
+%doc README
|
|
|
+%doc docs/cc-by-sa-3.0.txt docs/lgpl-3.0.txt
|
|
|
+%doc docs/adobe-lens-profile.txt
|
|
|
+%{_bindir}/*
|
|
|
%{_libdir}/liblensfun.so.0*
|
|
|
+%{_datadir}/lensfun/
|
|
|
+%{_mandir}/man1/*
|
|
|
|
|
|
%files devel
|
|
|
%defattr(-,root,root,-)
|
|
|
-%doc %{_docdir}/%{name}-%{version}/manual/
|
|
|
-%{_includedir}/lensfun.h
|
|
|
+%doc %{_target_platform}/doc_doxygen/*
|
|
|
+%{_includedir}/lensfun/
|
|
|
%{_libdir}/liblensfun.so
|
|
|
%{_libdir}/pkgconfig/lensfun.pc
|
|
|
|
|
|
|
|
|
%changelog
|
|
|
+* Sun Feb 1 2015 Ryoichi INAGAKI <ryo1@toki.waseda.jp> 0.3.0-1
|
|
|
+- new upstream release
|
|
|
+- added BR: cmake
|
|
|
+
|
|
|
* Sun Sep 4 2011 IWAI, Masaharu <iwai@alib.jp> 0.2.5-1
|
|
|
- build for Vine Linux: based Fedora 0.2.5-5
|
|
|
|