]> git.pld-linux.org Git - packages/MathJax.git/blame - MathJax.spec
- pl
[packages/MathJax.git] / MathJax.spec
CommitLineData
4391dd54 1Summary: JavaScript display engine for mathematics
77fee7bf 2Summary(pl.UTF-8): Oparty na JavaScripcie silnik wyświetlania wzorów matematycznych
4391dd54 3Name: MathJax
14b438af 4Version: 1.1a
48fc5bfb 5Release: 3
4391dd54
JR
6License: Apache v2.0
7Group: Applications/WWW
14b438af
JR
8# https://github.com/mathjax/MathJax/zipball/v1.1a
9Source0: %{name}-%{version}.zip
10# Source0-md5: 63a0401cbf84bbeb173072d77c127299
77fee7bf 11URL: https://www.mathjax.org/
4391dd54 12BuildRequires: rpmbuild(macros) >= 1.268
d38386b9 13BuildRequires: unzip
4391dd54
JR
14Requires: webapps
15Requires: webserver(access)
16Requires: webserver(alias)
48fc5bfb 17Conflicts: apache-base < 2.4.0-1
4391dd54
JR
18BuildArch: noarch
19BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
20
21%define _webapps /etc/webapps
22%define _webapp %{name}
23%define _sysconfdir %{_webapps}/%{_webapp}
24%define _appdir %{_datadir}/%{_webapp}
25
26%description
27MathJax is an open source JavaScript display engine for mathematics
d38386b9 28that works in all modern browsers.
4391dd54 29
77fee7bf
JB
30%description -l pl.UTF-8
31MathJax to mający otwarte źródła, oparty na JavaScripcie silnik
32wyświetlania wzorów matematycznych, działający we wszystkich
33współczesnych przeglądarkach.
34
4391dd54 35%prep
14b438af 36%setup -q -n mathjax-MathJax-f5cd294
4391dd54
JR
37
38cat > apache.conf <<'EOF'
39Alias /%{name} %{_appdir}
40<Directory %{_appdir}>
41 Allow from all
42</Directory>
43EOF
44
ec08939d
JR
45cat > httpd.conf <<'EOF'
46Alias /%{name} %{_appdir}
47<Directory %{_appdir}>
48 Require all granted
49</Directory>
50EOF
51
4391dd54
JR
52cat > lighttpd.conf <<'EOF'
53alias.url += (
54 "/%{name}" => "%{_appdir}",
55)
56EOF
57
58%install
59rm -rf $RPM_BUILD_ROOT
60install -d $RPM_BUILD_ROOT{%{_sysconfdir},%{_appdir}}
61
62cp -a MathJax.js config extensions fonts jax $RPM_BUILD_ROOT%{_appdir}
63
64cp -a apache.conf $RPM_BUILD_ROOT%{_sysconfdir}/apache.conf
65cp -a apache.conf $RPM_BUILD_ROOT%{_sysconfdir}/httpd.conf
66cp -a lighttpd.conf $RPM_BUILD_ROOT%{_sysconfdir}/lighttpd.conf
67
68%triggerin -- apache1 < 1.3.37-3, apache1-base
69%webapp_register apache %{_webapp}
70
71%triggerun -- apache1 < 1.3.37-3, apache1-base
72%webapp_unregister apache %{_webapp}
73
ec08939d 74%triggerin -- apache-base
4391dd54
JR
75%webapp_register httpd %{_webapp}
76
ec08939d 77%triggerun -- apache-base
4391dd54
JR
78%webapp_unregister httpd %{_webapp}
79
80%triggerin -- lighttpd
81%webapp_register lighttpd %{_webapp}
82
83%triggerun -- lighttpd
84%webapp_unregister lighttpd %{_webapp}
85
86%clean
87rm -rf $RPM_BUILD_ROOT
88
89%files
90%defattr(644,root,root,755)
14b438af 91%doc README.* docs test unpacked
4391dd54
JR
92%dir %attr(750,root,http) %{_sysconfdir}
93%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/apache.conf
94%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/httpd.conf
95%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/lighttpd.conf
96%{_appdir}
This page took 0.056855 seconds and 4 git commands to generate.