[pugixml] Update to 1.4

Orion Poplawski orion at fedoraproject.org
Thu Sep 4 15:11:54 UTC 2014


commit d3919962dc42f368bc71d8d2f25cf3e9fb406708
Author: Orion Poplawski <orion at cora.nwra.com>
Date:   Thu Sep 4 09:11:46 2014 -0600

    Update to 1.4
    
    - Split documentation out into -doc sub-package
    - Add cmake export information

 .gitignore           |    1 +
 pugixml-export.patch |   11 +++++++++++
 pugixml.spec         |   50 +++++++++++++++++++++++++++-----------------------
 sources              |    2 +-
 4 files changed, 40 insertions(+), 24 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index f254169..cb5feb2 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1 +1,2 @@
 /pugixml-1.0.tar.gz
+/pugixml-1.4.tar.gz
diff --git a/pugixml-export.patch b/pugixml-export.patch
new file mode 100644
index 0000000..acbccc4
--- /dev/null
+++ b/pugixml-export.patch
@@ -0,0 +1,11 @@
+diff -up pugixml-1.4/scripts/CMakeLists.txt.export pugixml-1.4/scripts/CMakeLists.txt
+--- pugixml-1.4/scripts/CMakeLists.txt.export	2014-02-22 03:25:24.000000000 -0700
++++ pugixml-1.4/scripts/CMakeLists.txt	2014-09-03 14:02:39.535720801 -0600
+@@ -18,5 +18,6 @@ endif()
+ 
+ set_target_properties(pugixml PROPERTIES VERSION 1.4 SOVERSION 1)
+ 
+-install(TARGETS pugixml LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR})
++install(TARGETS pugixml EXPORT pugixml-config LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR})
+ install(FILES ${HEADERS} DESTINATION include)
++install(EXPORT pugixml-config DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/pugixml)
diff --git a/pugixml.spec b/pugixml.spec
index caf972b..ad42723 100644
--- a/pugixml.spec
+++ b/pugixml.spec
@@ -1,13 +1,15 @@
 Name:           pugixml
-Version:        1.0
-Release:        8%{?dist}
+Version:        1.4
+Release:        1%{?dist}
 Summary:        A light-weight C++ XML processing library
 Group:          Development/Libraries
 License:        MIT
 URL:            http://pugixml.org
 
-Source0:        http://pugixml.googlecode.com/files/%{name}-%{version}.tar.gz
-Patch0:         pugixml-1.0-set_lib_soversion.patch
+Source0:        http://github.com/zeux/pugixml/releases/download/v%{version}/pugixml-%{version}.tar.gz
+# Add pugixml-config.cmake
+# https://github.com/zeux/pugixml/pull/7
+Patch0:         pugixml-export.patch
 
 BuildRequires:  cmake
 
@@ -31,33 +33,29 @@ Requires:       %{name}%{?_isa} = %{version}-%{release}
 Development files for package %{name}
 
 
+%package doc
+Summary:        Documentation for %{name}
+Group:          Documentation
+
+%description doc
+Documentation for package %{name}
+
+
 %prep
-%setup -q -c %{name}-%{version}
-%patch0
+%setup -q
+%patch0 -p1 -b .export
 
 
 %build
 mkdir -p ./build && pushd build
-%cmake ../scripts
-
+%cmake -DCMAKE_INSTALL_LIBDIR=%{_lib} ../scripts
 make
 
 
 %install
-# Fix encodings
-#find ./docs -name '*.cpp' -exec dos2unix -k {} \;i
-#find ./docs -name '*.css' -exec dos2unix -k {} \;
-#find ./docs -name '*.xml' -exec dos2unix -k {} \;
-#find ./ -name '*.txt' -exec dos2unix -k {} \;
-
-mkdir -p %{buildroot}%{_includedir}
+make -C build install DESTDIR=%{buildroot}
 mkdir -p %{buildroot}%{_datadir}/%{name}/contrib
-mkdir -p %{buildroot}%{_libdir}
-
 install -p -m 0644 contrib/* %{buildroot}%{_datadir}/%{name}/contrib/
-install -p -m 0644 src/*.hpp %{buildroot}%{_includedir}/
-install -p -m 0755  build/*.so.* %{buildroot}%{_libdir}/
-mv build/*.so %{buildroot}%{_libdir}/
 
 
 %post -p /sbin/ldconfig
@@ -66,19 +64,25 @@ mv build/*.so %{buildroot}%{_libdir}/
 
 
 %files
-%defattr(-,root,root,-)
 %doc readme.txt
 %{_libdir}/*.so.*
 
 %files devel
-%defattr(-,root,root,-)
-%doc docs/*
 %{_libdir}/*.so
+%{_libdir}/cmake/%{name}/
 %{_datadir}/%{name}
 %{_includedir}/*.hpp
 
+%files doc
+%doc docs/*
+
 
 %changelog
+* Wed Sep 03 2014 Orion Poplawski <orion at cora.nwra.com> - 1.4-1
+- Update to 1.4
+- Split documentation out into -doc sub-package
+- Add cmake export information
+
 * Sun Aug 17 2014 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 1.0-8
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
 
diff --git a/sources b/sources
index e61a346..c1e4c0c 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-3c191771b942e805fe36d6a00b2655f8  pugixml-1.0.tar.gz
+7c56c91cfe3ecdee248a8e4892ef5781  pugixml-1.4.tar.gz


More information about the scm-commits mailing list