Sophie

Sophie

distrib > Mandriva > 2009.0 > x86_64 > by-pkgid > 63e5bb78c5a7539e59c866ebcb7f5c36 > files > 10

newt-0.52.6-5mdv2009.0.src.rpm

%define majver 0.52
%define libname %mklibname %{name} %{majver}
%define libdevel %{libname}-devel

Summary:	A development library for text mode user interfaces
Name:		newt
Version:	0.52.6
Release:	%mkrel 5
License:	LGPL
Group:		System/Libraries
URL:		http://www.mandriva.com/
Source0:	ftp://ftp.redhat.com/pub/redhat/linux/code/newt/newt-%{version}.tar.gz
Patch0: 	newt-gpm-fix.diff
Patch1: 	newt-0.52.6-mdvconf.patch
Patch2: 	newt-0.51.4-fix-wstrlen-for-non-utf8-strings.patch
Patch3: 	newt-0.51.6-assorted-fixes.patch
Patch4: 	newt-0.52.6-entry.patch
Patch5: 	newt-0.52.6-countitems.patch
Patch6: 	newt-0.52.6-cursor.patch
Patch7: 	newt-0.52.6-memleaks.patch
BuildRequires:	glibc-static-devel
BuildRequires:	popt-devel
BuildRequires:	python-devel >= 2.2
BuildRequires:	slang-devel
Requires:	slang
Provides:	python-snack
Provides:	whiptail
BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root

%description
Newt is a programming library for color text mode, widget based user
interfaces. Newt can be used to add stacked windows, entry widgets, checkboxes,
radio buttons, labels, plain text fields, scrollbars, etc., to text mode user
interfaces.  This package contains a /usr/bin/dialog replacement called
whiptail. Newt is based on the slang library.

%package -n	%{libname}
Summary:	Newt windowing toolkit development files library
Group:		Development/C
Provides:	lib%{name} = %{version}-%{release}

%description -n %{libname}
Newt is a programming library for color text mode, widget based user
interfaces. Newt can be used to add stacked windows, entry widgets, checkboxes,
radio buttons, labels, plain text fields, scrollbars, etc., to text mode user
interfaces.  This package contains a /usr/bin/dialog replacement called
whiptail. Newt is based on the slang library.

%package -n	%libdevel
Summary:	Newt windowing toolkit development files
Group:		Development/C
Requires:	slang-devel %{libname} = %{version}
Provides:	lib%{name}-devel = %{version}-%{release}
Provides:	%{name}-devel = %{version}-%{release}
Obsoletes:	%{name}-devel
Conflicts:	libnewt0.51-devel

%description -n %libdevel
Newt is a programming library for color text mode, widget based user
interfaces. Newt can be used to add stacked windows, entry widgets, checkboxes,
radio buttons, labels, plain text fields, scrollbars, etc., to text mode user
interfaces.  This package contains a /usr/bin/dialog replacement called
whiptail. Newt is based on the slang library.

Install newt-devel if you want to develop applications which will use newt.

%prep
%setup -q
%patch0 -p0 -b .gpm-fix
%patch1 -p1 -b .mdvconf
%patch2 -p1 -b .fix-wstrlen-for-non-utf8-strings
%patch3 -p1 -b .assorted-fixes
%patch4 -p0 -b .entry
%patch5 -p0 -b .countitems
%patch6 -p0 -b .cursor
%patch7 -p0 -b .memleaks

%build
%configure --with-gpm-support --without-tcl
%make
%make shared

%install
rm -rf %{buildroot}

install -d %{buildroot}
%makeinstall

ln -snf lib%{name}.so.%{version} %{buildroot}%{_libdir}/lib%{name}.so.%{majver}

rm -rf %{buildroot}%{_libdir}/python{1.5,2.0,2.1,2.2}

%find_lang %{name}

%if %mdkversion < 200900
%post -n %{libname} -p /sbin/ldconfig
%endif

%if %mdkversion < 200900
%postun -n %{libname} -p /sbin/ldconfig
%endif

%clean
rm -rf %{buildroot}

%files -n %{libname}
%defattr (-,root,root)
%doc CHANGES
%{_libdir}/libnewt.so.*

%files -f %{name}.lang
%defattr (-,root,root)
%doc CHANGES COPYING
%{_bindir}/whiptail
%{_libdir}/python%pyver/site-packages/*
%{_mandir}/man1/whiptail.1*

%files -n %libdevel
%defattr (-,root,root)
%doc tutorial.sgml
%{_includedir}/newt.h
%{_libdir}/libnewt.a
%{_libdir}/libnewt.so




%changelog
* Tue Jun 17 2008 Thierry Vignaud <tvignaud@mandriva.com> 0.52.6-5mdv2009.0
+ Revision: 223345
- rebuild

  + Pixel <pixel@mandriva.com>
    - do not call ldconfig in %%post/%%postun, it is now handled by filetriggers

* Tue Jan 15 2008 Thierry Vignaud <tvignaud@mandriva.com> 0.52.6-4mdv2008.1
+ Revision: 153283
- rebuild
- kill re-definition of %%buildroot on Pixel's request

  + Olivier Blin <oblin@mandriva.com>
    - restore BuildRoot

  + Pixel <pixel@mandriva.com>
    - rename the "snack" provide into "python-snack"
      (there is a package named libsnack which provides snack)

* Mon Aug 13 2007 Pixel <pixel@mandriva.com> 0.52.6-3mdv2008.0
+ Revision: 62757
- provide whiptail (it's clearer for a package to require "whiptail" instead of "newt")

* Mon Aug 13 2007 Pixel <pixel@mandriva.com> 0.52.6-2mdv2008.0
+ Revision: 62756
- the library should not provide newt (#32315)

* Wed May 30 2007 Herton Ronaldo Krzesinski <herton@mandriva.com.br> 0.52.6-1mdv2008.0
+ Revision: 32788
- Added upstream/fedora patches entry, countitems, cursor, memleaks.
- Updated to version 0.52.6.
- Redid mdkconf patch -> newt-0.52.6-mdvconf.patch
- Removed allow-textbox-to-take-focus patch, not needed anymore (#15067,
  #31012).
- libnewt0.52-devel, soname change: added needed Conflicts for
  libnewt0.51-devel.

* Thu May 24 2007 Herton Ronaldo Krzesinski <herton@mandriva.com.br> 0.51.6-14mdv2008.0
+ Revision: 30894
- Removed listbox part of patch
  do-not-ignore-EARLY-events-in-listbox--and-allow-textbox-to-take-focus
  and Renamed it to allow-textbox-to-take-focus, because it's breaking
  listbox NEWT_FLAG_RETURNEXIT feature here; with the listbox part of
  the patch applied, the newtFormRun function on exit never return the
  listbox when it's selected and Enter is pressed. From the changelogs,
  this patch is for ticket #15067, I tested it here without the listbox
  part and seems to be ok. Same description and also a testcase reported
  on bugzilla also (#31012).


* Wed Nov 22 2006 Oden Eriksson <oeriksson@mandriva.com> 0.51.6-13mdv2007.0
+ Revision: 86416
- spec file massage

  + bcornec <bcornec>
    - import newt-0.51.6-12mdk

* Mon Dec 12 2005 Gwenole Beauchesne <gbeauchesne@mandriva.com> 0.51.6-12mdk
- assorted bug fixes from code review, others are in DrakX

* Wed Apr 27 2005 Pixel <pixel@mandriva.com> 0.51.6-11mdk
- do not ignore EARLY events in listbox and allow textbox to take focus
  => this fixes drakauth which has a scrollbar for the text and also for the entries
  (bugzilla #15067)

* Sun Dec 05 2004 Michael Scherer <misc@mandrake.org> 0.51.6-10mdk
- Rebuild for new python
- fix dir ownership

* Sat Jul 24 2004 Marcel Pol <mpol@mandrake.org> 0.51.6-9mdk
- again build against new slang

* Thu Jul 22 2004 Marcel Pol <mpol@mandrake.org> 0.51.6-8mdk
- build against new slang

* Wed Jan 28 2004 Warly <warly@mandrakesoft.com> 0.51.6-7mdk
- new version