]>
Commit | Line | Data |
---|---|---|
ac1c6bec | 1 | # |
cbc96169 | 2 | # Conditional build: |
a049c7b6 | 3 | %bcond_without static_libs # don't build static library |
cbc96169 | 4 | # |
1ed90f3b | 5 | %define snap 20230828 |
32348ae5 | 6 | %define rel 1 |
2bc2f465 | 7 | Summary: Editline Library |
369d939f | 8 | Summary(pl.UTF-8): Biblioteka Editline (edytor linii poleceń) |
2bc2f465 | 9 | Name: libedit |
21f6cce6 | 10 | Version: 3.1 |
e13e33a7 | 11 | Release: 1.%{snap}.%{rel} |
dd4ddf7f | 12 | Epoch: 0 |
2bc2f465 AM |
13 | License: BSD |
14 | Group: Libraries | |
62390697 | 15 | Source0: https://thrysoee.dk/editline/%{name}-%{snap}-%{version}.tar.gz |
1ed90f3b | 16 | # Source0-md5: 16bb2ab0d33bce3467f5cd4ec7d8f3ee |
7d6e819f | 17 | Patch0: %{name}-man.patch |
62390697 | 18 | URL: https://thrysoee.dk/editline/ |
aa8f1c9c | 19 | BuildRequires: autoconf >= 2.61 |
83d0e4e2 | 20 | BuildRequires: automake |
62390697 | 21 | BuildRequires: libtool >= 2:2 |
2bc2f465 AM |
22 | BuildRequires: ncurses-devel |
23 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
24 | ||
25 | %description | |
26 | Port of the NetBSD Editline library (libedit). This Berkeley-style | |
27 | licensed command line editor library provides generic line editing, | |
28 | history, and tokenization functions, similar to those found in GNU | |
29 | Readline. | |
30 | ||
64fca64f | 31 | %description -l pl.UTF-8 |
dd4ddf7f | 32 | Port biblioteki Editline z NetBSD (libedit). Jest to biblioteka |
64fca64f JR |
33 | edytora linii poleceń na licencji w stylu BSD udostępniająca |
34 | funkcjonalność ogólnego modyfikowania linii, historii oraz tokenizacji | |
35 | podobną do obecnych w GNU Readline. | |
dd4ddf7f | 36 | |
2bc2f465 | 37 | %package devel |
dd4ddf7f | 38 | Summary: Header files and development documentation for libedit |
369d939f | 39 | Summary(pl.UTF-8): Pliki nagłówkowe i dokumentacja programisty do libedit |
2bc2f465 AM |
40 | Group: Development/Libraries |
41 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
83d0e4e2 JB |
42 | Requires: ncurses-devel |
43 | Conflicts: heimdal-devel <= 0.6.3-1 | |
2bc2f465 AM |
44 | |
45 | %description devel | |
dd4ddf7f JB |
46 | Header files and development documentation for libedit. |
47 | ||
64fca64f JR |
48 | %description devel -l pl.UTF-8 |
49 | Pliki nagłówkowe i dokumentacja programisty do libedit. | |
2bc2f465 AM |
50 | |
51 | %package static | |
52 | Summary: Static libedit library | |
369d939f | 53 | Summary(pl.UTF-8): Statyczna biblioteka libedit |
2bc2f465 AM |
54 | Group: Development/Libraries |
55 | Requires: %{name}-devel = %{epoch}:%{version}-%{release} | |
56 | ||
57 | %description static | |
dd4ddf7f JB |
58 | Static libedit library. |
59 | ||
64fca64f | 60 | %description static -l pl.UTF-8 |
dd4ddf7f | 61 | Statyczna biblioteka libedit. |
2bc2f465 AM |
62 | |
63 | %prep | |
32348ae5 | 64 | %setup -q -n %{name}-%{snap}-%{version} |
83d0e4e2 | 65 | %patch0 -p1 |
2bc2f465 AM |
66 | |
67 | %build | |
83d0e4e2 | 68 | %{__libtoolize} |
62390697 | 69 | %{__aclocal} -I m4 |
83d0e4e2 JB |
70 | %{__autoconf} |
71 | %{__autoheader} | |
72 | %{__automake} | |
2bc2f465 AM |
73 | LANG=C; export LANG |
74 | LC_ALL=C; export LC_ALL | |
2d67fe8b | 75 | CPPFLAGS="%{rpmcppflags} -I/usr/include/ncurses" |
a049c7b6 | 76 | %configure \ |
9bf70de9 | 77 | --enable-widec \ |
aa8f1c9c | 78 | --disable-silent-rules \ |
a049c7b6 | 79 | %{!?with_static_libs:--disable-static} |
9bf70de9 | 80 | |
2bc2f465 | 81 | %{__make} -C src vi.h emacs.h common.h |
62390697 | 82 | |
2bc2f465 AM |
83 | %{__make} |
84 | ||
85 | %install | |
86 | rm -rf $RPM_BUILD_ROOT | |
87 | ||
88 | %{__make} install \ | |
89 | DESTDIR=$RPM_BUILD_ROOT | |
90 | ||
d592e7db JB |
91 | # conflicts with readline |
92 | %{__rm} $RPM_BUILD_ROOT%{_mandir}/man3/history.3 | |
2d67fe8b JB |
93 | # obsoleted by pkg-config |
94 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/libedit.la | |
d592e7db | 95 | |
2bc2f465 AM |
96 | %clean |
97 | rm -rf $RPM_BUILD_ROOT | |
98 | ||
99 | %post -p /sbin/ldconfig | |
100 | %postun -p /sbin/ldconfig | |
101 | ||
102 | %files | |
103 | %defattr(644,root,root,755) | |
104 | %doc ChangeLog THANKS | |
83d0e4e2 | 105 | %attr(755,root,root) %{_libdir}/libedit.so.*.*.* |
54a08473 | 106 | %attr(755,root,root) %ghost %{_libdir}/libedit.so.0 |
83d0e4e2 | 107 | %{_mandir}/man5/editrc.5* |
2bc2f465 AM |
108 | |
109 | %files devel | |
110 | %defattr(644,root,root,755) | |
83d0e4e2 | 111 | %attr(755,root,root) %{_libdir}/libedit.so |
54a08473 JB |
112 | %{_includedir}/editline |
113 | %{_includedir}/histedit.h | |
114 | %{_pkgconfigdir}/libedit.pc | |
115 | %{_mandir}/man3/editline.3* | |
116 | %{_mandir}/man3/el_*.3* | |
d592e7db JB |
117 | %{_mandir}/man3/history_end.3* |
118 | %{_mandir}/man3/history_init.3* | |
119 | %{_mandir}/man3/history_w.3* | |
120 | %{_mandir}/man3/history_wend.3* | |
121 | %{_mandir}/man3/history_winit.3* | |
122 | %{_mandir}/man3/tok_end.3* | |
123 | %{_mandir}/man3/tok_init.3* | |
124 | %{_mandir}/man3/tok_line.3* | |
125 | %{_mandir}/man3/tok_reset.3* | |
126 | %{_mandir}/man3/tok_str.3* | |
127 | %{_mandir}/man3/tok_wend.3* | |
128 | %{_mandir}/man3/tok_winit.3* | |
129 | %{_mandir}/man3/tok_wline.3* | |
130 | %{_mandir}/man3/tok_wreset.3* | |
131 | %{_mandir}/man3/tok_wstr.3* | |
132 | %{_mandir}/man7/editline.7* | |
2bc2f465 | 133 | |
a049c7b6 | 134 | %if %{with static_libs} |
2bc2f465 AM |
135 | %files static |
136 | %defattr(644,root,root,755) | |
83d0e4e2 | 137 | %{_libdir}/libedit.a |
a049c7b6 | 138 | %endif |