1 %define git_rev 7946e2c
3 Summary: Minimal replacement for readline
6 Release: 0.git%{git_rev}.%{rel}
7 # The licenses are a bit of a mess here...
8 # utf8.{c,h} contain incomplete license headers. They refer to a "LICENSE" file
9 # which is actually from jimtcl. A copy is committed in dist-git as
10 # jimtcl-LICENSE, retrieved from
11 # <https://raw.github.com/msteveb/jimtcl/master/LICENSE>. I received a mail
12 # from the author, committed as steve-bennett-license-confirmation, confirming
13 # that that is indeed the LICENSE file referred to and therefore utf8.{c,h} are
14 # under a BSD-like license.
15 # linenoise.{c,h} contain complete BSD-like license headers so they are fine.
16 # And it means the whole library is definitely under a BSD-like license.
17 # But there is no separate license file shipped in the tarball. I queried Tad
18 # Marshall on 2013-01-10 to include one but never received a reply. So
19 # I synthesized one as Source1.
22 Source0: https://github.com/tadmarshall/linenoise/tarball/%{git_rev}/%{name}-%{git_rev}.tar.gz
23 # Source0-md5: 7cb42d58db11bf3c33b8dd698ec92754
24 Patch0: %{name}-build-shared-lib.patch
25 Patch1: %{name}-symbol-visibility.patch
26 URL: https://github.com/tadmarshall/linenoise
27 BuildRequires: libstdc++-devel
28 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
31 Linenoise is a replacement for the readline line-editing library with
32 the goal of being smaller.
35 Summary: Development files for %{name}
36 Requires: %{name} = %{version}-%{release}
39 This package contains files needed for developing software that uses
43 %setup -q -n tadmarshall-%{name}-%{git_rev}
48 export CFLAGS="%{rpmcflags}"
52 INCLUDEDIR="%{_includedir}"
55 rm -rf $RPM_BUILD_ROOT
56 export CFLAGS="%{rpmcflags}"
59 INCLUDEDIR="%{_includedir}" \
60 DESTDIR=$RPM_BUILD_ROOT
63 rm -rf $RPM_BUILD_ROOT
65 %post -p /sbin/ldconfig
66 %postun -p /sbin/ldconfig
69 %defattr(644,root,root,755)
71 %attr(755,root,root) %{_libdir}/liblinenoise.so.*.*
72 %attr(755,root,root) %ghost %{_libdir}/liblinenoise.so.0
75 %defattr(644,root,root,755)
76 %{_includedir}/linenoise.h
77 %{_libdir}/liblinenoise.so