# FORCE NOARCH # This package is noarch intentionally, although it supplies binaries, # as they're not intended for the build platform, but for AVR. # The related discussion can be found here: # https://www.redhat.com/archives/fedora-devel-list/2009-February/msg02261.html %global _binaries_in_noarch_packages_terminate_build 0 Name: avr-libc Version: 1.7.0 Release: 1%{?dist} Summary: C library for use with GCC on Atmel AVR microcontrollers Group: Development/Tools License: BSD URL: http://www.nongnu.org/avr-libc/ Source0: http://download.savannah.gnu.org/releases/avr-libc/avr-libc-%{version}.tar.bz2 Source1: http://download.savannah.gnu.org/releases/avr-libc/avr-libc-user-manual-%{version}.tar.bz2 Patch0: avr-libc-1.6.4-documentation.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-%(%{__id_u} -n) BuildRequires: avr-gcc doxygen transfig netpbm-progs tetex-latex BuildArch: noarch %description AVR Libc is a Free Software project whose goal is to provide a high quality C library for use with GCC on Atmel AVR microcontrollers. AVR Libc is licensed under a single unified license. This so-called modified Berkeley license is intented to be compatible with most Free Software licenses like the GPL, yet impose as little restrictions for the use of the library in closed-source commercial applications as possible. %package docs Summary: AVR C library docs in html and pdf format Group: Development/Tools Requires: %{name} = %{version}-%{release} %description docs This package contains the AVR C library docs in html and pdf format, the main package already contains the docs in man-page format (use "avr-man xxxx" to access these). %prep %setup -q -a1 %patch0 -p0 for i in doc/api/faq.dox doc/api/overview.dox include/stdio.h include/stdlib.h; do iconv -f CP1252 -t UTF8 $i > tmp mv tmp $i done sed -i 's|@DOC_INST_DIR@/man|%{_prefix}/avr/share/man|' scripts/avr-man.in %build # The ps doc ways in at 7Mb versus 2.5 for the pdf and has little added value ./configure --prefix=%{_prefix} --host=avr --build=`./config.guess` \ --enable-doc --disable-ps-doc # don't use %{?_smp_mflags}, it breaks the build make %install rm -rf $RPM_BUILD_ROOT make install DESTDIR=$RPM_BUILD_ROOT # put the man-pages in the FHS mandir and gzip them mkdir -p $RPM_BUILD_ROOT%{_prefix}/avr/share mv $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}/man \ $RPM_BUILD_ROOT%{_prefix}/avr/share gzip $RPM_BUILD_ROOT%{_prefix}/avr/share/man/man3/* # we only want to use %doc with an absolute path to avoid rpmbuild from erasing # %{_docdir}/%{name}-%{version} install -p -m 644 doc/TODO doc/CHANGES.old AUTHORS ChangeLog* LICENSE NEWS \ README $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version} # despite us being noarch redhat-rpm-config insists on stripping our files %define __os_install_post /usr/lib/rpm/redhat/brp-compress %clean rm -rf $RPM_BUILD_ROOT %files %defattr(-,root,root,-) %dir %{_prefix}/avr %dir %{_prefix}/avr/share %doc %{_prefix}/avr/share/man %dir %{_docdir}/%{name}-%{version} %doc %{_docdir}/%{name}-%{version}/AUTHORS %doc %{_docdir}/%{name}-%{version}/C* %doc %{_docdir}/%{name}-%{version}/LICENSE %doc %{_docdir}/%{name}-%{version}/NEWS %doc %{_docdir}/%{name}-%{version}/README %doc %{_docdir}/%{name}-%{version}/TODO %doc %{_docdir}/%{name}-%{version}/examples %{_prefix}/avr/include %{_prefix}/avr/lib %{_bindir}/avr-man %files docs %defattr(-,root,root,-) %doc %{_docdir}/%{name}-%{version}/%{name}-user-manual-%{version}* %doc %{name}-user-manual-%{version}* %changelog * Sun Jul 11 2010 Thibault North 1.7.0-1 - Version 1.7.0 * Fri Mar 12 2010 Thibault North 1.6.8-1 - New upstream release. Fixes in power.h for 8-bits AVR * Mon Nov 30 2009 Thibault North 1.6.5-2 - Rebuild with new avr-gcc * Wed Nov 25 2009 Thibault North 1.6.5-1 - Updated to 1.6.7 * Fri Nov 20 2009 Thibault North 1.6.5-1 - New upstream release * Fri Jul 24 2009 Fedora Release Engineering - 1.6.4-5 - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild * Tue May 26 2009 Michael Schwendt - 1.6.4-4 - Fix unowned versioned documentation directory (#473625). * Sat Apr 18 2009 Milos Jakubicek - 1.6.4-3 - Fix FTBFS: force noarch (see comment in the top of the spec file). * Mon Feb 23 2009 Fedora Release Engineering - 1.6.4-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild * Thu Feb 19 2009 Thibault North 1.6.4-1 - New upstream release - Patches update * Tue Jul 17 2007 Hans de Goede 1.4.6-4 - Gzip manpages - Make manpages %%doc - Install -docs documentation in same dir as the main package docs - Change License field from GPL to BSD (oops) * Sun Jun 8 2007 Hans de Goede 1.4.6-3 - Move man pages to /usr/avr/share/man * Fri May 25 2007 Hans de Goede 1.4.6-2 - Add patch from Trond Danielsen (trond.danielsen@gmail.com) to fix pdf doc generation - Put html and pdf docs in a seperate -docs subpackage * Thu May 24 2007 Hans de Goede 1.4.6-1 - Initial Fedora package