Name: MochiKit Version: 1.4.2 Release: 2%{?dist} Summary: A lightweight JavaScript library Group: Applications/Internet License: MIT or AFL URL: http://www.mochikit.com/ Source0: http://www.mochikit.com/dist/%{name}-%{version}.zip Source1: %{name}.conf BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch #BuildRequires: Requires: httpd %description MochiKit is a highly-documented and well-tested suite of JavaScript libraries that will help you get stuff done, fast. %prep %setup -q find \( -name \*.js -o -name \*.css \) -exec sed -i 's/\r//g' {} \; # Fix for bug 440052 - fixes path of MochiKit libs in source # Thanks to ivasquez for the awesome regex find ./examples/ \( -name \*.html \) -exec sed -i -e 's!\(src="\)[^"]*\(/MochiKit/[^.]*\.js"\)!\1\2!' {} \; %build %install rm -rf $RPM_BUILD_ROOT mkdir -p $RPM_BUILD_ROOT%{_datadir}/%{name} install -p -m 0644 lib/MochiKit/* $RPM_BUILD_ROOT%{_datadir}/%{name} mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/httpd/conf.d install -p -m 0644 %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/httpd/conf.d %clean rm -rf $RPM_BUILD_ROOT %files %defattr(-,root,root,-) %doc Changes doc examples LICENSE.txt %{_datadir}/%{name} %config(noreplace) %{_sysconfdir}/httpd/conf.d/%{name}.conf %changelog * Wed Feb 11 2009 Adam Miller 1.4.2-2 - Fix for bug 440052 - fixes path of MochiKit libs in source - Thanks to ivasquez for the awesome regex * Wed Feb 11 2009 Adam Miller 1.4.2-1 - new release of MochiKit * Mon Jul 14 2008 Tom "spot" Callaway 1.3.1-2 - fix license tag * Sun May 21 2006 Ignacio Vazquez-Abrams 1.3.1-1 - Upstream update * Sun Feb 12 2006 Ignacio Vazquez-Abrams 1.2-1 - Initial RPM release