]> git.pld-linux.org Git - packages/mosh.git/blob - mosh.spec
up to RC2 (1.2.4.95rc2)
[packages/mosh.git] / mosh.spec
1 #
2 # Conditional build:
3 %bcond_with     agent           # with ssh agent forwarding patch
4
5 # force gcc4 for ac
6 %if "%{pld_release}" == "ac"
7 # add suffix, but allow ccache, etc in ~/.rpmmacros
8 %{expand:%%define       __cc    %(echo '%__cc' | sed -e 's,-gcc,-gcc4,')}
9 %{expand:%%define       __cxx   %(echo '%__cxx' | sed -e 's,-g++,-g++4,')}
10 %{expand:%%define       __cpp   %(echo '%__cpp' | sed -e 's,-gcc,-gcc4,')}
11 %endif
12
13 %include        /usr/lib/rpm/macros.perl
14 Summary:        Mosh mobile shell
15 Name:           mosh
16 Version:        1.2.4.95rc2
17 Release:        0.1
18 License:        GPL v3+
19 Group:          X11/Applications
20 #Source0:       http://mosh.mit.edu/%{name}-%{version}.tar.gz
21 Source0:        https://github.com/keithw/mosh/archive/%{name}-%{version}.tar.gz
22 # Source0-md5:  8ef57d233d662cfac7b28747802b346a
23 Patch0:         https://github.com/keithw/mosh/pull/583.patch
24 # Patch0-md5:   7eb14665ef06072591e5bcd80780c0e4
25 URL:            http://mosh.mit.edu/
26 BuildRequires:  autoconf
27 BuildRequires:  automake
28 BuildRequires:  binutils >= 2.20.51.0.2
29 BuildRequires:  libstdc++-devel >= 5:4.0
30 BuildRequires:  libtool
31 BuildRequires:  libutempter-devel
32 BuildRequires:  ncurses-devel
33 BuildRequires:  openssl-devel
34 BuildRequires:  patchutils
35 BuildRequires:  pkgconfig
36 BuildRequires:  protobuf
37 BuildRequires:  protobuf-devel
38 BuildRequires:  rpm-perlprov >= 4.1-13
39 BuildRequires:  sed >= 4.0
40 BuildRequires:  zlib-devel
41 # gcc4 might be installed, but not current __cc
42 %if "%(echo %{cc_version} | cut -d. -f1,2)" < "4.0"
43 BuildRequires:  __cc >= 4.0
44 %endif
45 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
46
47 # PLD stack protector flags are weaker than upstream, filter them out
48 # https://github.com/keithw/mosh/issues/203
49 %define         _ssp_cflags     %{nil}
50
51 %define         specflags       -Wno-error=non-virtual-dtor
52
53 %description
54 Remote terminal application that allows roaming, supports intermittent
55 connectivity, and provides intelligent local echo and line editing of
56 user keystrokes.
57
58 Mosh is a replacement for SSH. It's more robust and responsive,
59 especially over Wi-Fi, cellular, and long-distance links.
60
61 %prep
62 %setup -qc
63 mv mosh-mosh-%{version}/* .
64 %if %{with agent}
65 %patch0 -p1
66 %endif
67 %{__sed} -i -e '1s,^#!.*perl,#!%{__perl},' scripts/mosh.pl
68
69 %build
70 %{__libtoolize}
71 %{__aclocal}
72 %{__autoconf}
73 %{__autoheader}
74 %{__automake}
75 %configure \
76         --disable-silent-rules \
77         --enable-compile-warnings=error
78 %{__make}
79
80 %install
81 rm -rf $RPM_BUILD_ROOT
82 %{__make} install \
83         DESTDIR=$RPM_BUILD_ROOT
84
85 %clean
86 rm -rf $RPM_BUILD_ROOT
87
88 %files
89 %defattr(644,root,root,755)
90 %doc AUTHORS ChangeLog NEWS THANKS
91 %attr(755,root,root) %{_bindir}/%{name}
92 %attr(755,root,root) %{_bindir}/%{name}-client
93 %attr(755,root,root) %{_bindir}/%{name}-server
94 %{_mandir}/man1/%{name}.1*
95 %{_mandir}/man1/%{name}-client.1*
96 %{_mandir}/man1/%{name}-server.1*
This page took 0.088055 seconds and 3 git commands to generate.