%global ctpl_docdir %{_defaultdocdir}/ctpl-%{version} Name: ctpl Version: 0.3.4 Release: 3%{?dist} Summary: Template library and engine written in C Group: Development/Tools License: GPLv3+ URL: http://ctpl.tuxfamily.org/ Source0: http://download.tuxfamily.org/ctpl/releases/ctpl-%{version}.tar.gz # Patch adds possibility to disable the build of the command line tool. # The patch is pulled from upstream at # http://git.tuxfamily.org/ctpl/ctpl/?p=gitroot/ctpl/ctpl.git;a=summary # Patch0: ctpl-0.3.2-add-disable-cli-tool.patch #Patch1: http://ausil.fedorapeople.org/aarch64/ctpl/ctpl-aarch64.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: glib2-devel >= 2.10 Requires: ctpl-libs = %{version}-%{release} %description CTPL is a template library written in C. It allows fast and easy parsing of templates from many sources (including in-memory data and local and remote streaming, thanks to GIO) and fine control over template parsing environment. CTPL has following features: * It is a library, then it can be easily used from programs * Separated lexer and parser * It is written in portable C * Simple syntax * Fast and strict parsing * Possible in-memory parsing, allowing non-file data parsing and avoiding I/O-latency, through GIO's GMemoryInputStream and GMemoryOutputStream %package libs Summary: Template library written in C Group: Development/Tools %description libs This package contains the CTPL library. %post libs -p /sbin/ldconfig %postun libs -p /sbin/ldconfig %package devel Summary: Development headers of the template library written in C Group: Development/Tools Requires: ctpl-libs = %{version}-%{release} %description devel This package contains the development headers of the CTPL library. %package doc Summary: Documentation for the CTPL library Group: Development/Tools Requires: ctpl-libs = %{version}-%{release} %if %{?fedora}%{!?fedora:0} >= 10 || %{?rhel}%{!?rhel:0} >= 6 BuildArch: noarch %endif %description doc This package contains the HTML documentation reference for the CTPL library. %prep %setup -q # remove waf since this isn't needed for the build, we're building the # package with autotools rm -f waf rm -f wscript #%patch1 -p1 %build %configure --docdir %{ctpl_docdir} sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool make %{?_smp_mflags} %install rm -rf $RPM_BUILD_ROOT make install DESTDIR=$RPM_BUILD_ROOT # Seems the --docdir flag is not working correctly, working around this here # for now install -d $RPM_BUILD_ROOT%{ctpl_docdir} install -Dpm0644 AUTHORS COPYING NEWS HACKING TODO README THANKS $RPM_BUILD_ROOT%{ctpl_docdir} rm -f $RPM_BUILD_ROOT%{_libdir}/libctpl.a rm -f $RPM_BUILD_ROOT%{_libdir}/libctpl.la %clean rm -rf $RPM_BUILD_ROOT %files %defattr(-,root,root,-) %doc %{_mandir}/man1/%{name}.1.* %{_bindir}/%{name} %files libs %defattr(-,root,root,-) %dir %{ctpl_docdir} %doc %{ctpl_docdir}/AUTHORS %doc %{ctpl_docdir}/COPYING %doc %{ctpl_docdir}/NEWS %{_libdir}/lib%{name}.so.* %{_datadir}/locale/fr/LC_MESSAGES/%{name}.mo %{_datadir}/locale/it/LC_MESSAGES/%{name}.mo %files devel %defattr(-,root,root,-) %doc %{ctpl_docdir}/HACKING %doc %{ctpl_docdir}/TODO %{_libdir}/lib%{name}.so %{_includedir}/%{name}/ %{_libdir}/pkgconfig/%{name}.pc %files doc %defattr(-,root,root,-) %doc %{ctpl_docdir}/README %doc %{ctpl_docdir}/THANKS %doc %{_datadir}/gtk-doc/html/%{name} %changelog * Thu Aug 20 2015 Oliver Haessler - 0.3.4-3 - removed Patch0 as it gives errors during build (no longer needed) - enable CLI tool again for EPEL7 * Wed Jun 17 2015 Fedora Release Engineering - 0.3.4-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild * Wed Feb 04 2015 Dominic Hopf - 0.3.4-1 - Update to 0.3.4 upstream release * Sat Aug 16 2014 Fedora Release Engineering - 0.3.3-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild * Fri Oct 18 2013 Dominic Hopf - 0.3.3-1 - Update to 0.3.3 upstream release * Sat Aug 03 2013 Fedora Release Engineering - 0.3.2-9 - Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild * Fri Jun 28 2013 Dominic Hopf - 0.3.2-8 - support build for aarch64 (RHBZ#925206) * Wed Feb 13 2013 Fedora Release Engineering - 0.3.2-7 - Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild * Wed Jul 18 2012 Fedora Release Engineering - 0.3.2-6 - Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild * Fri Jan 13 2012 Fedora Release Engineering - 0.3.2-5 - Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild * Sun Dec 18 2011 Dominic Hopf - 0.3.2-4 - do not build the CLI tool when building for EPEL * Wed May 25 2011 Dominic Hopf - 0.3.2-3 - remove depedency on gtk-doc (fixes #707547) * Tue Feb 08 2011 Fedora Release Engineering - 0.3.2-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild * Tue Jan 18 2011 Dominic Hopf - 0.3.2-1 - new upstream release: CTPL 0.3.2 * Tue Oct 26 2010 Dominic Hopf - 0.3-1 - new upstream release: CTPL 0.3 * Sat Jul 17 2010 Dominic Hopf - 0.2.2-4 - fix rpmlint binary-or-shlib-defines-rpath error - fix rpmlint library-without-ldconfig-* errors - make the -doc package noarch - remove the -bin subpackage, the binary files will now be installed with the main package, thus when typing 'yum install ctpl' - require gtk-doc for the -doc package - ctpl-libs now owns /usr/share/doc/ctpl-0.2.2 - fix redundant file listings - require -libs package with fully qualified version for the binary package * Fri Jul 16 2010 Dominic Hopf - 0.2.2-3 - move the %%{_libdir}/lib%%{name}.so back to the -devel package where it belongs to * Fri Jul 16 2010 Dominic Hopf - 0.2.2-2 - rename subpackage lib to libs - add Requires on the libs package to -bin, -devel and -doc package - install %%{_libdir}/lib%%{name}.so with a -static package - install manpage only with the binary - install HACKING and TODO only with the -devel package - install README and THANKS only with the -doc package - fix the installation path for documentation files * Thu Jul 15 2010 Dominic Hopf - 0.2.2-1 - initial specfile