This commit is contained in:
Rex Dieter 2013-03-19 16:33:54 -05:00
parent 7083e15888
commit 294f126e3b
5 changed files with 8 additions and 68 deletions

2
.gitignore vendored
View File

@ -1,2 +1,2 @@
/lensfun-0.2.5.tar.bz2
/lensfun-0.2.6.tar.bz2
/lensfun-0.2.7.tar.bz2

View File

@ -1,12 +0,0 @@
diff -up lensfun-0.2.6/CMakeLists.txt.LIB_SUFFIX lensfun-0.2.6/CMakeLists.txt
--- lensfun-0.2.6/CMakeLists.txt.LIB_SUFFIX 2012-06-10 09:19:35.000000000 -0500
+++ lensfun-0.2.6/CMakeLists.txt 2012-06-28 08:32:16.628591449 -0500
@@ -74,7 +74,7 @@ ENDIF()
# define destination dirs (relative to prefix)
SET(BINDIR bin)
-SET(LIBDIR lib)
+SET(LIBDIR lib${LIB_SUFFIX})
SET(INCLUDEDIR include)
SET(DATADIR share/lensfun)
SET(DOCDIR share/doc/lensfun-${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_MICRO}.${VERSION_BUGFIX})

View File

@ -1,32 +0,0 @@
diff --git a/libs/lensfun/CMakeLists.txt b/libs/lensfun/CMakeLists.txt
index ef3dcf0..253a08c 100644
--- a/libs/lensfun/CMakeLists.txt
+++ b/libs/lensfun/CMakeLists.txt
@@ -26,3 +26,8 @@ INSTALL(TARGETS lensfun
RUNTIME DESTINATION ${BINDIR}
LIBRARY DESTINATION ${LIBDIR}
ARCHIVE DESTINATION ${LIBDIR})
+
+# pkgconfig support
+CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/lensfun.pc.cmake ${CMAKE_CURRENT_BINARY_DIR}/lensfun.pc @ONLY)
+INSTALL( FILES ${CMAKE_CURRENT_BINARY_DIR}/lensfun.pc DESTINATION ${LIBDIR}/pkgconfig )
+
diff --git a/libs/lensfun/lensfun.pc.cmake b/libs/lensfun/lensfun.pc.cmake
new file mode 100644
index 0000000..6d14b12
--- /dev/null
+++ b/libs/lensfun/lensfun.pc.cmake
@@ -0,0 +1,13 @@
+prefix=@CMAKE_INSTALL_PREFIX@
+bindir=@CMAKE_INSTALL_PREFIX@/@BINDIR@
+libdir=@CMAKE_INSTALL_PREFIX@/@LIBDIR@
+includedir=@CMAKE_INSTALL_PREFIX@/@INCLUDEDIR@
+datadir=@CMAKE_INSTALL_PREFIX@/@DATADIR@
+docdir=@CMAKE_INSTALL_PREFIX@/@DOCDIR@
+
+Name: lensfun
+Description: A photographic lens database and access library
+Version: @VERSION_MAJOR@.@VERSION_MINOR@.@VERSION_MICRO@.@VERSION_BUGFIX@
+Requires.private: glib-2.0
+Libs: -L${libdir} -llensfun
+Cflags: -I${includedir} -I${includedir}/lensfun

View File

@ -1,21 +1,14 @@
Name: lensfun
Version: 0.2.6
Version: 0.2.7
Summary: Library to rectify defects introduced by photographic lenses
Release: 4%{?dist}
Release: 1%{?dist}
License: LGPLv3 and CC-BY-SA
Group: System Environment/Libraries
URL: http://lensfun.berlios.de/
# an odd redirect is going on, spectool doesn't work (for 0.2.6 anyway)
Source0: http://download.berlios.de/lensfun/lensfun-%{version}.tar.bz2
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
Source0: http://downloads.sourceforge.net/project/lensfun.berlios/lensfun-%{version}.tar.bz2
## upstreamable patches
# add LIB_SUFFIX support (and not hardcode prefix/lib)
Patch50: lensfun-0.2.6-cmake_LIB_SUFFIX.patch
# add pkgconfig support
Patch51: lensfun-0.2.6-cmake_pkgconfig.patch
BuildRequires: cmake
BuildRequires: doxygen
@ -33,7 +26,6 @@ vignetting and color contribution of a lens.
%package devel
Summary: Development toolkit for %{name}
Group: Development/Libraries
License: LGPLv3
Requires: %{name}%{?_isa} = %{version}-%{release}
%description devel
@ -44,9 +36,6 @@ using lensfun.
%prep
%setup -q
%patch50 -p1 -b .LIB_SUFFIX
%patch51 -p1 -b .cmake_pkgconfig
%build
@ -63,20 +52,13 @@ make doc -C %{_target_platform}
%install
rm -rf $RPM_BUILD_ROOT
make install/fast DESTDIR=$RPM_BUILD_ROOT -C %{_target_platform}
%clean
rm -rf %{buildroot}
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%files
%defattr(-,root,root,-)
%doc README
%doc docs/cc-by-sa-3.0.txt docs/lgpl-3.0.txt
%doc docs/adobe-lens-profile.txt
@ -84,7 +66,6 @@ rm -rf %{buildroot}
%{_libdir}/liblensfun.so.0*
%files devel
%defattr(-,root,root,-)
%doc %{_target_platform}/doc_doxygen/*
%{_includedir}/lensfun/
%{_libdir}/liblensfun.so
@ -92,6 +73,9 @@ rm -rf %{buildroot}
%changelog
* Tue Mar 19 2013 Rex Dieter <rdieter@fedoraproject.org> 0.2.7-1
- 0.2.7
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.2.6-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild

View File

@ -1 +1 @@
740e4749db04da0a597630dd6339b966 lensfun-0.2.6.tar.bz2
6061cc2d00a42d3e62512878426fc841 lensfun-0.2.7.tar.bz2