%define css_major 0 %define css_minor 0 %define major 3 %define minor 1 %define libname %mklibname %{name} %{major} %define devel %mklibname -d %{name} %define cssdev %mklibname cssparser %{css_major} %define csslib %mklibname -d cssparser Name: htmlcxx Version: 0.87 Release: %mkrel 4 Summary: htmlcxx is a simple non-validating css1 and html parser for C++ Group: Development/Other License: LGPLv2 URL: http://htmlcxx.sourceforge.net/ Source0: https://sourceforge.net/projects/htmlcxx/files/v%{version}/%{name}-%{version}.tar.gz Patch0: htmlcxx-0.86-linking.patch Patch1: htmlcxx-0.87-c++17.patch %description htmlcxx is a simple non-validating css1 and html parser for C++. Although there are several other html parsers available, htmlcxx has some characteristics that make it unique: - STL like navigation of DOM tree, using the excellent tree.hh library from Kasper Peeters. - It is possible to reproduce exactly, character by character, the original document from the parse tree - Bundled css parser - Optional parsing of attributes - C++ code that looks like C++ (not so true anymore) - Offsets of tags/elements in the original document are stored in the nodes of the DOM tree %package -n %{devel} Summary: Development files Group: System/Libraries Requires: %{libname} = %{version}-%{release} Conflicts: %{libname} < 0.8.6-4 %description -n %{devel} Development files %package -n %{libname} Summary: These are the main libraries Group: Development/Other Conflicts: %{devel} < 0.8.6-4 %description -n %{libname} The main libraries %package -n %{cssdev} Summary: These are the css_parser development files Group: Development/Other Conflicts: %{devel} < 0.8.6-4 %description -n %{cssdev} Development files for libcss_* %package -n %{csslib} Summary: These are the css_parser libraries Group: System/Libraries %description -n %{csslib} Libraries containing the libcss_* files %prep %autosetup -p1 %build autoreconf -vfi %configure %make_build %install %make_install # Delete static libraries find %{buildroot} -name *.*a -delete %files %{_bindir}/%{name} %files -n %{libname} %{_libdir}/libhtmlcxx.so.%{major}{,.*} %files -n %{devel} %{_includedir}/%{name}/html/ %{_libdir}/libhtmlcxx.so %{_libdir}/pkgconfig/%{name}.pc %files -n %{cssdev} %{_includedir}/%{name}/css/ %{_datadir}/%{name}/ %{_libdir}/libcss_parser.so %{_libdir}/libcss_parser_pp.so %files -n %{csslib} %{_libdir}/libcss_parser.so.%{css_major}{,.*} %{_libdir}/libcss_parser_pp.so.%{css_major}{,.*} %changelog * Thu Jul 21 2022 papoteur <papoteur> 0.87-4.mga9 + Revision: 1869717 - fix build with C++17 + umeabot <umeabot> - Mageia 9 Mass Rebuild * Fri Feb 14 2020 umeabot <umeabot> 0.87-2.mga8 + Revision: 1522346 - Mageia 8 Mass Rebuild + wally <wally> - replace deprecated %%configure2_5x * Thu Jan 24 2019 kekepower <kekepower> 0.87-1.mga7 + Revision: 1360518 - Update to version 0.87 * Sun Sep 23 2018 umeabot <umeabot> 0.86-5.mga7 + Revision: 1298213 - Mageia 7 Mass Rebuild * Sun Jan 28 2018 kekepower <kekepower> 0.86-4.mga7 + Revision: 1197578 - Removed macros in Summary and Group - Conflicts should be less than the recent version + wally <wally> - add patch to fix linking * Sun Jan 28 2018 kekepower <kekepower> 0.86-3.mga7 + Revision: 1197549 - Fixed issues pointed out by wally_ on IRC - cssparser devel and libraries now in separate packages * Sat Jan 27 2018 kekepower <kekepower> 0.86-2.mga7 + Revision: 1197446 - Oops, files in the wrong place... - Switched devel and libname to their correct places * Sat Jan 27 2018 kekepower <kekepower> 0.86-1.mga7 + Revision: 1197440 - imported package htmlcxx