[12215] | 1 | %bcond_without python2 |
---|
[521] | 2 | %define build_compat32 %{?_with_compat32:1}%{!?_with_compat32:0} |
---|
| 3 | |
---|
| 4 | Summary: A development library for text mode user interfaces. |
---|
| 5 | Summary(ja): テキストモードインターフェースのための開発ライブラリ |
---|
| 6 | Name: newt |
---|
[12215] | 7 | Version: 0.52.21 |
---|
[5283] | 8 | Release: 1%{?_dist_release} |
---|
[12215] | 9 | License: LGPLv2 |
---|
[521] | 10 | Group: System Environment/Libraries |
---|
[12215] | 11 | URL: https://pagure.io/newt |
---|
| 12 | Source: https://pagure.io/releases/newt/newt-%{version}.tar.gz |
---|
[521] | 13 | |
---|
[4033] | 14 | # patches from mdv |
---|
| 15 | Patch1: newt-0.51.4-fix-wstrlen-for-non-utf8-strings.patch |
---|
[8831] | 16 | |
---|
[4033] | 17 | # patches from ubuntu |
---|
[8831] | 18 | Patch10: newt-python_memory_allocation.patch |
---|
[521] | 19 | |
---|
| 20 | BuildRoot: %{_tmppath}/%{name}-%{version}-root |
---|
[12215] | 21 | BuildRequires: python3-devel, popt-devel, slang-devel |
---|
| 22 | BuildRequires: python3-rpm-macros |
---|
| 23 | %if %{with python2} |
---|
| 24 | BuildRequires: python-devel |
---|
| 25 | BuildRequires: python-rpm-macros |
---|
| 26 | %endif |
---|
[521] | 27 | Provides: snack = %{version}-%{release} |
---|
| 28 | |
---|
[4033] | 29 | Vendor: Project Vine |
---|
| 30 | Distribution: Vine Linux |
---|
| 31 | Packager: daisuke |
---|
[521] | 32 | |
---|
[4033] | 33 | |
---|
[521] | 34 | %description |
---|
| 35 | Newt is a programming library for color text mode, widget based user |
---|
| 36 | interfaces. Newt can be used to add stacked windows, entry widgets, |
---|
| 37 | checkboxes, radio buttons, labels, plain text fields, scrollbars, |
---|
| 38 | etc., to text mode user interfaces. This package also contains the |
---|
| 39 | shared library needed by programs built with newt, as well as a |
---|
| 40 | /usr/bin/dialog replacement called whiptail. Newt is based on the |
---|
| 41 | slang library. |
---|
| 42 | |
---|
| 43 | |
---|
| 44 | %package devel |
---|
| 45 | Summary: Newt windowing toolkit development files. |
---|
| 46 | Summary(ja): Newt ウィンドウツールキット開発ファイル集 |
---|
| 47 | Requires: slang-devel %{name} = %{version} |
---|
| 48 | Group: Development/Libraries |
---|
| 49 | |
---|
| 50 | |
---|
| 51 | %description devel |
---|
| 52 | The newt-devel package contains the header files and libraries |
---|
| 53 | necessary for developing applications which use newt. Newt is a |
---|
| 54 | development library for text mode user interfaces. Newt is based on |
---|
| 55 | the slang library. |
---|
| 56 | |
---|
| 57 | Install newt-devel if you want to develop applications which will use |
---|
| 58 | newt. |
---|
| 59 | |
---|
| 60 | |
---|
[12215] | 61 | %package -n python3-newt |
---|
| 62 | %{?python_provide:%python_provide python3-newt} |
---|
| 63 | # Remove before F30 |
---|
| 64 | Provides: %{name}-python3 = %{version}-%{release} |
---|
| 65 | Provides: %{name}-python3%{?_isa} = %{version}-%{release} |
---|
| 66 | Provides: snack = %{version}-%{release} |
---|
| 67 | Summary: Python 3 bindings for newt |
---|
| 68 | Requires: %{name}%{?_isa} = %{version}-%{release} |
---|
| 69 | |
---|
| 70 | %description -n python3-newt |
---|
| 71 | The python3-newt package contains the Python 3 bindings for the newt library |
---|
| 72 | providing a python API for creating text mode interfaces. |
---|
| 73 | |
---|
| 74 | |
---|
[521] | 75 | ## to build compat32 for x86_64 architecture support |
---|
| 76 | %package -n compat32-%{name} |
---|
| 77 | Summary: A development library for text mode user interfaces. |
---|
| 78 | Group: System Environment/Libraries |
---|
| 79 | %description -n compat32-%{name} |
---|
| 80 | Newt is a programming library for color text mode, widget based user |
---|
| 81 | interfaces. Newt can be used to add stacked windows, entry widgets, |
---|
| 82 | checkboxes, radio buttons, labels, plain text fields, scrollbars, |
---|
| 83 | etc., to text mode user interfaces. This package also contains the |
---|
| 84 | shared library needed by programs built with newt, as well as a |
---|
| 85 | /usr/bin/dialog replacement called whiptail. Newt is based on the |
---|
| 86 | slang library. |
---|
| 87 | |
---|
| 88 | %package -n compat32-%{name}-devel |
---|
| 89 | Summary: Newt windowing toolkit development files. |
---|
| 90 | Group: Development/Libraries |
---|
| 91 | Requires: compat32-%{name} = %{version} |
---|
| 92 | %description -n compat32-%{name}-devel |
---|
| 93 | The newt-devel package contains the header files and libraries |
---|
| 94 | necessary for developing applications which use newt. Newt is a |
---|
| 95 | development library for text mode user interfaces. Newt is based on |
---|
| 96 | the slang library. |
---|
| 97 | |
---|
| 98 | Install newt-devel if you want to develop applications which will use |
---|
| 99 | newt. |
---|
| 100 | |
---|
| 101 | |
---|
| 102 | %prep |
---|
| 103 | %setup -q -n %{name}-%{version} |
---|
[4033] | 104 | %patch1 -p1 -b .fix-wstrlen-for-non-utf8-strings |
---|
| 105 | %patch10 -p1 -b .python_memory_allocation |
---|
[521] | 106 | |
---|
| 107 | %build |
---|
[12215] | 108 | SLANG_CFLAGS=$(pkg-config --cflags slang) |
---|
| 109 | export CFLAGS="%{optflags} $SLANG_CFLAGS" |
---|
| 110 | |
---|
[521] | 111 | %if %{build_compat32} |
---|
| 112 | export CC='gcc -m32' |
---|
| 113 | %configure --without-tcl |
---|
[12215] | 114 | make %{?_smp_mflags} CC='gcc -m32' |
---|
[521] | 115 | #make CC='gcc -m32' shared |
---|
| 116 | %else |
---|
| 117 | %configure --without-tcl |
---|
[12215] | 118 | make %{?_smp_mflags} all |
---|
| 119 | #make shared |
---|
[521] | 120 | %endif |
---|
| 121 | chmod 0644 peanuts.py popcorn.py |
---|
| 122 | |
---|
| 123 | %install |
---|
| 124 | rm -rf $RPM_BUILD_ROOT |
---|
[12215] | 125 | make DESTDIR=$RPM_BUILD_ROOT install |
---|
[521] | 126 | |
---|
| 127 | %find_lang %{name} |
---|
| 128 | |
---|
| 129 | %post -p /sbin/ldconfig |
---|
| 130 | |
---|
| 131 | %postun -p /sbin/ldconfig |
---|
| 132 | |
---|
| 133 | %if %{build_compat32} |
---|
| 134 | %post -n compat32-%{name} -p /sbin/ldconfig |
---|
| 135 | %postun -n compat32-%{name} -p /sbin/ldconfig |
---|
| 136 | %endif |
---|
| 137 | |
---|
| 138 | %clean |
---|
| 139 | rm -rf $RPM_BUILD_ROOT |
---|
| 140 | |
---|
| 141 | %files -f %{name}.lang |
---|
| 142 | %defattr (-,root,root) |
---|
[12215] | 143 | %license COPYING |
---|
| 144 | %doc AUTHORS CHANGES README |
---|
[521] | 145 | %{_libdir}/libnewt.so.* |
---|
| 146 | %{_bindir}/whiptail |
---|
| 147 | %{python_sitearch}/*.py* |
---|
| 148 | %{python_sitearch}/*.so |
---|
| 149 | %{_mandir}/man1/whiptail.1* |
---|
| 150 | |
---|
| 151 | %files devel |
---|
| 152 | %defattr (-,root,root) |
---|
| 153 | %doc tutorial.sgml peanuts.py popcorn.py |
---|
| 154 | %{_includedir}/newt.h |
---|
| 155 | %{_libdir}/libnewt.a |
---|
| 156 | %{_libdir}/libnewt.so |
---|
[4006] | 157 | %{_libdir}/pkgconfig/libnewt.pc |
---|
[521] | 158 | |
---|
[12215] | 159 | %files -n python3-newt |
---|
| 160 | %doc peanuts.py popcorn.py |
---|
| 161 | %{python3_sitearch}/*.so |
---|
| 162 | %{python3_sitearch}/*.py* |
---|
| 163 | |
---|
[521] | 164 | %if %{build_compat32} |
---|
| 165 | %files -n compat32-%{name} |
---|
| 166 | %defattr (-,root,root) |
---|
| 167 | %{_libdir}/libnewt.so.* |
---|
| 168 | |
---|
| 169 | %files -n compat32-%{name}-devel |
---|
| 170 | %defattr (-,root,root) |
---|
| 171 | %{_libdir}/libnewt.a |
---|
| 172 | %{_libdir}/libnewt.so |
---|
| 173 | %endif |
---|
| 174 | |
---|
| 175 | |
---|
| 176 | %changelog |
---|
[12215] | 177 | * Sun Sep 15 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 0.52.21-1 |
---|
| 178 | - updated to 0.52.21. |
---|
| 179 | - added python3 support. |
---|
| 180 | |
---|
[8831] | 181 | * Tue Jul 15 2014 Daisuke SUZUKI <daisuke@vinelinux.org> 0.52.17-1 |
---|
| 182 | - update to 0.52.17 |
---|
| 183 | |
---|
[5701] | 184 | * Sun Feb 19 2012 Yoji TOYODA <bsyamato@sea.plala.or.jp> 0.52.14-1 |
---|
| 185 | - new upstram release |
---|
| 186 | |
---|
[5283] | 187 | * Thu Oct 06 2011 Daisuke SUZUKI <daisuke@linux.or.jp> 0.52.13-1 |
---|
| 188 | - new upstram release |
---|
| 189 | |
---|
[4033] | 190 | * Sat Jun 04 2011 Daisuke SUZUKI <daisuke@linux.or.jp> 0.52.12-2 |
---|
| 191 | - add patch2,3 from mdv |
---|
| 192 | - add patch10 from ubuntu |
---|
| 193 | |
---|
[4006] | 194 | * Tue May 31 2011 Daisuke SUZUKI <daisuke@linux.or.jp> 0.52.12-1 |
---|
| 195 | - update to 0.52.12 |
---|
| 196 | - add patch0: don't hang in form when stdin disappears |
---|
| 197 | - remove patch100, fixed in upstream |
---|
| 198 | |
---|
[3536] | 199 | * Mon Apr 18 2011 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 0.52.10-7 |
---|
| 200 | - rebuilt with recent environment. |
---|
| 201 | |
---|
[521] | 202 | * Fri Feb 12 2010 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 0.52.10-6 |
---|
| 203 | - rebuilt with gcc-4.4.3-3 on ppc |
---|
| 204 | |
---|
| 205 | * Fri Feb 5 2010 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 0.52.10-5 |
---|
| 206 | - rebuilt with rpm-4.8.0-3 (on ppc) |
---|
| 207 | |
---|
| 208 | * Wed Feb 03 2010 Shu KONNO <owa@bg.wakwak.com> 0.52.10-4 |
---|
| 209 | - rebuilt with python-2.6.4 |
---|
| 210 | |
---|
| 211 | * Thu Oct 8 2009 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 0.52.10-3 |
---|
| 212 | - fix build_compat32 if-endif |
---|
| 213 | |
---|
| 214 | * Sat Sep 26 2009 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 0.52.10-2 |
---|
| 215 | - add patch100 for fix CVE-2009-2905 (textbox BoF) from fc10 |
---|
| 216 | |
---|
| 217 | * Sun Aug 24 2008 Daisuke SUZUKI <daisuke@linux.or.jp> 0.52.10-1 |
---|
| 218 | - new upstream release |
---|
| 219 | - use %%python_sitearch macro |
---|
| 220 | - remove --with-gpm-support |
---|
| 221 | - drop obsolete patches |
---|
| 222 | |
---|
| 223 | * Sun Aug 20 2006 NAKAMURA Kenta <kenta@vinelinux.org> 0.50.35-0vl6 |
---|
| 224 | - rebuild to fix dependency problem on x86_64 architecture |
---|
| 225 | |
---|
| 226 | * Thu Feb 16 2006 Shu KONNO <owa@bg.wakwak.com> 0.50.35-0vl5 |
---|
| 227 | - added BuildRequires: slang-devel |
---|
| 228 | - added newt-0.50.35-Makefile.in.patch |
---|
| 229 | - updated newt-0.50.35-make.patch |
---|
| 230 | - changed /usr/lib to %%{_libdir} |
---|
| 231 | - added compat32-* packages for x86_64 architecture support |
---|
| 232 | |
---|
| 233 | * Sun Apr 03 2005 Shu KONNO <owa@bg.wakwak.com> 0.50.35-0vl4 |
---|
| 234 | - rebuild with python-2.4.1-0vl1 |
---|
| 235 | |
---|
| 236 | * Sat Apr 17 2004 Shu KONNO <owa@bg.wakwak.com> 0.50.35-0vl3 |
---|
| 237 | - rebuild with python-2.3.3-0vl1 |
---|
| 238 | |
---|
| 239 | * Sat Apr 10 2004 Shu KONNO <owa@bg.wakwak.com> 0.50.35-0vl2.1 |
---|
| 240 | - rebuild with python-2.3.3-0vl0.3 (for TestPkg) |
---|
| 241 | |
---|
| 242 | * Wed Jan 29 2003 Tomoya TAKA <taka@vinelinux.org> 0.50.35-0vl2 |
---|
| 243 | - build against python-2.2 |
---|
| 244 | - drop Patch20 |
---|
| 245 | |
---|
| 246 | * Thu Oct 10 2002 MATSUBAYASHI Kohji <shaolin@vinelinux.org> 0.50.35-0vl1 |
---|
| 247 | - updated to new upstream release 0.50.35 |
---|
| 248 | - updated Patch11 and added Patch20 |
---|
| 249 | (Patch20 is for python 1.5: REMOVE IT WHEN WE DECIDED TO GO WITH PYTHON2) |
---|
| 250 | |
---|
| 251 | * Sat Mar 09 2002 Tomoya TAKA <taka@vinelinux.org> 0.50.33-0vl1 |
---|
| 252 | - update to new upstream release |
---|
| 253 | |
---|
| 254 | * Mon Jul 2 2001 MATUBARA Kazuyuki <matubara@mb.asmnet.ne.jp> |
---|
| 255 | - 0.50.22-0vl1 |
---|
| 256 | - updated to 0.50.22 |
---|
| 257 | - use Release No for Vine Linux |
---|
| 258 | - use better macros |
---|
| 259 | - bytecompile the snack python module |
---|
| 260 | |
---|
| 261 | * Wed Sep 29 1999 Norihito Ohmori <ohmori@flatout.rog> |
---|
| 262 | - fix spec file |
---|
| 263 | |
---|
[8831] | 264 | * Sat Sep 11 1999 Norihito Ohmori <ohmori@flatout.org> |
---|
[521] | 265 | - added Japanese support patch |
---|
| 266 | |
---|
| 267 | * Wed Sep 01 1999 Erik Troan <ewt@redhat.com> |
---|
| 268 | - added suspend/resume to snack |
---|
| 269 | |
---|
| 270 | * Tue Aug 31 1999 Matt Wilson <msw@redhat.com> |
---|
| 271 | - enable gpm support |
---|
| 272 | |
---|
| 273 | * Fri Aug 27 1999 Matt Wilson <msw@redhat.com> |
---|
| 274 | - added hotkey assignment for gridforms, changed listbox.setcurrent to |
---|
| 275 | take the item key |
---|
| 276 | |
---|
| 277 | * Wed Aug 25 1999 Matt Wilson <msw@redhat.com> |
---|
| 278 | - fixed snack callback function refcounts, as well as optional data args |
---|
| 279 | - fixed suspend callback ref counts |
---|
| 280 | |
---|
| 281 | * Mon Aug 23 1999 Matt Wilson <msw@redhat.com> |
---|
| 282 | - added buttons argument to entrywindow |
---|
| 283 | |
---|
| 284 | * Thu Aug 12 1999 Bill Nottingham <notting@redhat.com> |
---|
| 285 | - multi-state checkboxtrees. Woohoo. |
---|
| 286 | |
---|
| 287 | * Mon Aug 9 1999 Matt Wilson <msw@redhat.com> |
---|
| 288 | - added snack wrappings for checkbox flag setting |
---|
| 289 | |
---|
| 290 | * Thu Aug 5 1999 Matt Wilson <msw@redhat.com> |
---|
| 291 | - added snack bindings for setting current listbox selection |
---|
| 292 | - added argument to set default selection in snack ListboxChoiceWindow |
---|
| 293 | |
---|
| 294 | * Mon Aug 2 1999 Matt Wilson <msw@redhat.com> |
---|
| 295 | - added checkboxtree |
---|
| 296 | - improved snack binding |
---|
| 297 | |
---|
| 298 | * Fri Apr 9 1999 Matt Wilson <msw@redhat.com> |
---|
| 299 | - fixed a glibc related bug in reflow that was truncating all text to 1000 |
---|
| 300 | chars |
---|
| 301 | |
---|
| 302 | * Fri Apr 09 1999 Matt Wilson <msw@redhat.com> |
---|
| 303 | - fixed bug that made newt apps crash when you hit <insert> followed by lots |
---|
| 304 | of keys |
---|
| 305 | |
---|
| 306 | * Mon Mar 15 1999 Matt Wilson <msw@redhat.com> |
---|
| 307 | - fix from Jakub Jelinek for listbox keypresses |
---|
| 308 | |
---|
[8831] | 309 | * Sat Feb 27 1999 Matt Wilson <msw@redhat.com> |
---|
[521] | 310 | - fixed support for navigating listboxes with alphabetical keypresses |
---|
| 311 | |
---|
| 312 | * Thu Feb 25 1999 Matt Wilson <msw@redhat.com> |
---|
| 313 | - updated descriptions |
---|
| 314 | - added support for navigating listboxes with alphabetical keypresses |
---|
| 315 | |
---|
| 316 | * Mon Feb 8 1999 Matt Wilson <msw@redhat.com> |
---|
| 317 | - made grid wrapped windows at least the size of their title bars |
---|
| 318 | |
---|
| 319 | * Fri Feb 5 1999 Matt Wilson <msw@redhat.com> |
---|
| 320 | - Function to set checkbox flags. This will go away later when I have |
---|
| 321 | a generic flag setting function and signals to comps to go insensitive. |
---|
| 322 | |
---|
| 323 | * Tue Jan 19 1999 Matt Wilson <msw@redhat.com> |
---|
| 324 | - Stopped using libgpm, internalized all gpm calls. Still need some cleanups. |
---|
| 325 | |
---|
| 326 | * Thu Jan 7 1999 Matt Wilson <msw@redhat.com> |
---|
| 327 | - Added GPM mouse support |
---|
| 328 | - Moved to autoconf to allow compiling without GPM support |
---|
| 329 | - Changed revision to 0.40 |
---|
| 330 | |
---|
| 331 | * Wed Oct 21 1998 Bill Nottingham <notting@redhat.com> |
---|
| 332 | - built against slang-1.2.2 |
---|
| 333 | |
---|
| 334 | * Wed Aug 19 1998 Bill Nottingham <notting@redhat.com> |
---|
| 335 | - bugfixes for text reflow |
---|
| 336 | - added docs |
---|
| 337 | |
---|
| 338 | * Fri May 01 1998 Cristian Gafton <gafton@redhat.com> |
---|
| 339 | - devel package moved to Development/Libraries |
---|
| 340 | |
---|
| 341 | * Thu Apr 30 1998 Erik Troan <ewt@redhat.com> |
---|
| 342 | - removed whiptcl.so -- it should be in a separate package |
---|
| 343 | |
---|
| 344 | * Mon Feb 16 1998 Erik Troan <ewt@redhat.com> |
---|
| 345 | - added newtWinMenu() |
---|
| 346 | - many bug fixes in grid code |
---|
| 347 | |
---|
| 348 | * Wed Jan 21 1998 Erik Troan <ewt@redhat.com> |
---|
| 349 | - removed newtWinTernary() |
---|
| 350 | - made newtWinChoice() return codes consistent with newtWinTernary() |
---|
| 351 | |
---|
| 352 | * Fri Jan 16 1998 Erik Troan <ewt@redhat.com> |
---|
| 353 | - added changes from Bruce Perens |
---|
| 354 | - small cleanups |
---|
| 355 | - lets whiptail automatically resize windows |
---|
| 356 | - the order of placing a grid and adding components to a form no longer |
---|
| 357 | matters |
---|
| 358 | - added newtGridAddComponentsToForm() |
---|
| 359 | |
---|
| 360 | * Wed Oct 08 1997 Erik Troan <ewt@redhat.com> |
---|
| 361 | - added newtWinTernary() |
---|
| 362 | |
---|
| 363 | * Tue Oct 07 1997 Erik Troan <ewt@redhat.com> |
---|
| 364 | - made Make/spec files use a buildroot |
---|
| 365 | - added grid support (for newt 0.11 actually) |
---|
| 366 | |
---|
| 367 | * Mon Jun 02 1997 Erik Troan <ewt@redhat.com> |
---|
| 368 | - Added patched from Clarence Smith for setting the size of a listbox |
---|
| 369 | - Version 0.9 |
---|
| 370 | |
---|
[8831] | 371 | * Wed May 28 1997 Elliot Lee <sopwith@redhat.com> 0.8-2 |
---|
[521] | 372 | - Touchups on Makefile |
---|
| 373 | - Cleaned up NEWT_FLAGS_* |
---|
| 374 | |
---|
| 375 | * Tue Mar 18 1997 Erik Troan <ewt@redhat.com> |
---|
| 376 | - Cleaned up listbox |
---|
| 377 | - Added whiptail |
---|
| 378 | - Added newtButtonCompact button type and associated colors |
---|
| 379 | - Added newtTextboxGetNumLines() and newtTextboxSetHeight() |
---|
| 380 | |
---|
| 381 | * Tue Feb 25 1997 Erik Troan <ewt@redhat.com> |
---|
| 382 | - Added changes from sopwith for C++ cleanliness and some listbox fixes. |
---|
| 383 | |
---|