2 %define apxs /usr/sbin/apxs
3 Summary: Terminal emulator in a web browser
9 Group: Networking/Daemons
10 Source0: http://anyterm.org/download/%{name}-%{version}.tbz2
11 # Source0-md5: cf841703b7438866e573f5a33137ff6f
12 Patch0: %{name}-makefile.patch
13 URL: http://anyterm.org/
14 BuildRequires: apache-devel >= 2.0.52-2
15 BuildRequires: apr-devel
16 BuildRequires: rote-devel >= 0.2.8
17 BuildRequires: rpmbuild(macros) >= 1.194
18 BuildRequires: %{apxs}
19 Requires: apache >= 2.0.52-2
20 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
22 %define _httpdir /home/services/httpd
23 %define _pkglibdir %(%{apxs} -q LIBEXECDIR 2>/dev/null)
24 %define _sysconfdir /etc/httpd
27 An apache module plus scripts to make a terminal within a web browser.
34 rm -rf $RPM_BUILD_ROOT
37 INCLUDES='-I%{_includedir}/apr-util' \
39 APR_CONFIG=apr-1-config
46 rm -rf $RPM_BUILD_ROOT
47 install -d $RPM_BUILD_ROOT{%{_sbindir},%{_sysconfdir}/httpd.conf,%{_pkglibdir},%{_mandir}/man8,%{_httpdir}}
49 cat > $RPM_BUILD_ROOT%{_sysconfdir}/httpd.conf/70_anyterm.conf <<END
50 LoadModule anyterm modules/%{name}.so
51 Alias /%{name} "%{_httpdir}/%{name}"
52 anyterm_command '%{_sbindir}/anygetty --remotehost "Anyterm: %h"'
55 install apachemod/.libs/%{name}.so $RPM_BUILD_ROOT%{_pkglibdir}/%{name}.so
56 cp -a browser $RPM_BUILD_ROOT/%{_httpdir}/%{name}
57 install anygetty/anygetty $RPM_BUILD_ROOT/%{_sbindir}
60 rm -rf $RPM_BUILD_ROOT
63 %defattr(644,root,root,755)
65 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/httpd.conf/*
66 %attr(755,root,root) %{_pkglibdir}/%{name}.so
67 %attr(755,root,root) %{_sbindir}/anygetty
72 For full function, setuid %{_sbindir}/anygetty.