2 # - build from source (get-source.sh fetches it)
4 %include /usr/lib/rpm/macros.java
5 Summary: Closure Compiler - JavaScript compressor
10 Group: Applications/WWW
11 Source0: http://closure-compiler.googlecode.com/files/compiler-%{version}.tar.gz
12 # Source0-md5: 6108a6f2c3b3e357f8758a24ea8b01c6
14 Source2: get-source.sh
15 URL: http://closure-compiler.appspot.com/
16 BuildRequires: rpm-javaprov
17 BuildRequires: rpmbuild(macros) >= 1.300
19 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
22 The Closure Compiler is a tool for making JavaScript download and run
23 faster. It is a true compiler for JavaScript. Instead of compiling
24 from a source language to machine code, it compiles from JavaScript to
25 better JavaScript. It parses your JavaScript, analyzes it, removes
26 dead code and rewrites and minimizes what's left. It also checks
27 syntax, variable references, and types, and warns about common
34 rm -rf $RPM_BUILD_ROOT
35 install -d $RPM_BUILD_ROOT{%{_bindir},%{_javadir}}
36 install -p %{SOURCE1} $RPM_BUILD_ROOT%{_bindir}/%{name}
39 cp -p compiler.jar $RPM_BUILD_ROOT%{_javadir}/%{name}-%{version}.jar
40 ln -s %{name}-%{version}.jar $RPM_BUILD_ROOT%{_javadir}/%{name}.jar
43 rm -rf $RPM_BUILD_ROOT
46 %defattr(644,root,root,755)
48 %attr(755,root,root) %{_bindir}/%{name}