%define drupaldir %{_datadir}/drupal6 Name: drupal6-mimedetect Version: 1.3 Release: 3%{?dist} Summary: MimeDetect provides an API for consistent server side mime detection Group: Applications/Publishing License: GPLv2+ URL: http://drupal.org/project/mimedetect Source0: http://ftp.drupal.org/files/projects/mimedetect-6.x-%{version}.tar.gz Source1: %{name}-fedora-README.txt BuildArch: noarch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) Requires: drupal6 %description MimeDetect provides an API for consistent server side mime detection using the PHP FileInfo extension, the UNIX 'file' command, user supplied mime data, or file extension look ups. It is distributed with its own magic library for use with the PHP FileInfo extension to make mime detection more consistent in different environments. %prep %setup -qn mimedetect chmod -x mimedetect.module cp -p %{SOURCE1} . %build %install rm -rf %{buildroot} install -d %{buildroot}%{drupaldir}/modules/mimedetect cp -pr * %{buildroot}%{drupaldir}/modules/mimedetect %clean rm -rf %{buildroot} %files %defattr(-,root,root,-) %doc LICENSE.txt %{name}-fedora-README.txt README.txt %dir %{drupaldir}/modules/mimedetect %{drupaldir}/modules/mimedetect/magic* %{drupaldir}/modules/mimedetect/mimedetect* %exclude %{drupaldir}/modules/mimedetect/*.txt %changelog * Mon Jan 31 2011 Peter Borsa - 1.3-3 - Version macro is added. * Mon Jan 24 2011 Peter Borsa - 1.3-2 - Changed License to GPLv2+. - Chmod and cp are copied under prep section. - Fixed exclude lines. * Thu Nov 23 2010 Peter Borsa - 1.3-1 - Initial packaging.