3 %bcond_without verbose # verbose build (V=1)
5 %if "%{pld_release}" == "ac"
6 # add suffix, but allow ccache, etc in ~/.rpmmacros
7 %{expand:%%define __cc %(echo '%__cc' | sed -e 's,-gcc,-gcc4,')}
8 %{expand:%%define __cxx %(echo '%__cxx' | sed -e 's,-g++,-g++4,')}
9 %{expand:%%define __cpp %(echo '%__cpp' | sed -e 's,-gcc,-gcc4,')}
12 %include /usr/lib/rpm/macros.perl
13 Summary: Mosh mobile shell
18 Group: X11/Applications
19 Source0: https://github.com/downloads/keithw/mosh/%{name}-%{version}.tar.gz
20 # Source0-md5: 7ed5b857307685794dcd120afe5bdf52
21 URL: http://mosh.mit.edu/
22 BuildRequires: binutils >= 2.20.51.0.2
23 BuildRequires: libutempter-devel
24 BuildRequires: ncurses-devel
25 BuildRequires: protobuf
26 BuildRequires: protobuf-devel
27 BuildRequires: rpm-perlprov >= 4.1-13
28 BuildRequires: sed >= 4.0
29 BuildRequires: zlib-devel
30 # gcc4 might be installed, but not current __cc
31 %if "%(echo %{cc_version} | cut -d. -f1,2)" < "4.0"
32 BuildRequires: __cc >= 4.0
34 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
37 Remote terminal application that allows roaming, supports intermittent
38 connectivity, and provides intelligent local echo and line editing of
41 Mosh is a replacement for SSH. It's more robust and responsive,
42 especially over Wi-Fi, cellular, and long-distance links.
46 %{__sed} -i -e '1s,^#!.*perl,#!%{__perl},' scripts/mosh
50 --enable-compile-warnings=error \
51 CPPFLAGS="-I/usr/include/ncurses"
56 rm -rf $RPM_BUILD_ROOT
58 DESTDIR=$RPM_BUILD_ROOT
61 rm -rf $RPM_BUILD_ROOT
64 %defattr(644,root,root,755)
65 %doc AUTHORS ChangeLog NEWS THANKS
66 %attr(755,root,root) %{_bindir}/%{name}
67 %attr(755,root,root) %{_bindir}/%{name}-client
68 %attr(755,root,root) %{_bindir}/%{name}-server
69 %{_mandir}/man1/%{name}.1*
70 %{_mandir}/man1/%{name}-client.1*
71 %{_mandir}/man1/%{name}-server.1*