%define PATCHDATE 19991030 %define version 5.1 %define major 5 %define name ncurses %define release 8mdk Summary: A CRT screen handling and optimization package Name: %{name} Version: %{version} Release: %{release} Copyright: MIT Group: System/Libraries Source0: http://ring.jah.ne.jp/pub/GNU/ncurses/%{name}-%{version}.tar.bz2 Source4: ncurses-resetall.sh Source5: ncurses-usefull-terms #Patch0: ftp://ftp.clark.net/pub/dickey/ncurses/%{name}-%{version}-%{PATCHDATE}.patch.bz2 Patch1: ncurses-5.1-xterm-debian.patch Patch10: ncurses-5.1-arm.patch Patch12: ncurses-5.1-setuid2.patch #Patch14: ncurses-5.0-fixxterm.patch.bz2 #Patch15: ncurses-config.sub_k6isnoti686.patch.bz2 BuildRoot: %{_tmppath}/%{name}-root Obsoletes: ncurses3 Provides: libncurses.so.4 libncurses.so.3 libform.so.4 libform.so.3 libmenu.so.4 libmenu.so.3 libpanel.so.4 libpanel.so.3 PreReq: /sbin/ldconfig %ifarch alpha BuildRequires: egcs gpm-devel %endif %description The curses library routines are a terminal-independent method of updating character screens with reasonalble optimization. The ncurses (new curses) library is a freely distributable replacement for the discontinued 4.4BSD classic curses library. %package extraterms Summary: Some exotic terminal descriptions Group: System/Libraries Requires: ncurses %description extraterms Install the ncurses-extraterms package if you use some exotic terminals. %package devel Summary: The development files for applications which use ncurses Group: Development/C Requires: ncurses = %{PACKAGE_VERSION}-%{release} %description devel The header files and libraries for developing applications that use the ncurses CRT screen handling and optimization package. Install the ncurses-devel package if you want to develop applications which will use ncurses. %prep %setup -q -n ncurses-%{version} #%patch0 -p1 %patch1 -p1 %patch10 -p1 %patch12 -p1 #%patch14 -p1 -b .fixxterm #%patch15 -p0 find . -name "*.orig" -exec rm -f {} \; %build %ifnarch ppc %ifarch alpha CC="gcc -V `egcs-version`" %else CC=gcc %endif RPM_OPT_FLAGS=$(echo $RPM_OPT_FLAGS|sed 's/-fomit-frame-pointer//') CFLAGS="$RPM_OPT_FLAGS -DPURE_TERMINFO" CC=$CC \ CXXFLAGS="$RPM_OPT_FLAGS -DPURE_TERMINFO -fexceptions" ./configure \ --prefix=/usr --with-normal --with-shared --with-debug --with-profile \ --with-gpm --enable-termcap --enable-getcap \ --enable-const --enable-hard-tabs --enable-hash-map \ --enable-no-padding --enable-safe-sprintf --enable-sigwinch $RPM_ARCH-mandrake-linux make %else CFLAGS="%{optflags} -DPURE_TERMINFO" %define optflags $CFLAGS %configure \ --with-normal --with-shared --without-debug --without-profile \ --without-cxx --without-ada \ --with-gpm --enable-termcap --enable-getcap \ --enable-const --enable-hard-tabs --enable-hash-map make %endif %install rm -rf $RPM_BUILD_ROOT %makeinstall prefix=$RPM_BUILD_ROOT/usr \ includedir=$RPM_BUILD_ROOT/usr/include/ncurses ln -sf ../l/linux $RPM_BUILD_ROOT%{_datadir}/terminfo/c/console ln -sf ncurses/curses.h $RPM_BUILD_ROOT/usr/include/ncurses.h for I in curses unctrl eti form menu panel term; do ln -sf ncurses/$I.h $RPM_BUILD_ROOT/usr/include/$I.h done # strip $RPM_BUILD_ROOT%{_bindir}/* || : make clean -C test # find $RPM_BUILD_ROOT%{_mandir} -type f -exec bzip2 -9f {} \; # the resetall script install -m 755 %{SOURCE4} $RPM_BUILD_ROOT%{_bindir}/resetall # we don't want this in doc rm -f c++/demo mkdir -p $RPM_BUILD_ROOT/lib mv $RPM_BUILD_ROOT%{_libdir}/libncurses.so* $RPM_BUILD_ROOT/lib ln -s /lib/libncurses.so.%{version} $RPM_BUILD_ROOT%{_libdir}/libncurses.so.%{version} ln -s /lib/libncurses.so.%{version} $RPM_BUILD_ROOT%{_libdir}/libncurses.so.%{major} ln -s /lib/libncurses.so.%{version} $RPM_BUILD_ROOT%{_libdir}/libncurses.so # compatibility links... for v in 5.0 4.2 4 3.0 3 1.9.9e 1; do ln -s libncurses.so.%{version} $RPM_BUILD_ROOT/lib/libncurses.so.$v done for l in form panel menu; do for v in 5.0 4.2 4 3.0 3 1.9.9e 1; do ln -s ..%{_libdir}/lib$l.so.%{version} $RPM_BUILD_ROOT/lib/lib$l.so.$v done done # # FIXME # OK do not time to debbug it now # cp /$RPM_BUILD_ROOT/usr/share/terminfo/x/xterm /$RPM_BUILD_ROOT/usr/share/terminfo/x/xterm2 cp /$RPM_BUILD_ROOT/usr/share/terminfo/x/xterm-new /$RPM_BUILD_ROOT/usr/share/terminfo/x/xterm # # FIXME # (cd $RPM_BUILD_ROOT ; ls -d usr/share/terminfo/* | perl -pe 's||%%dir /|') > %{name}.list (cd $RPM_BUILD_ROOT ; ls usr/share/terminfo/*/* | perl -pe 's||/|') > %{name}-extraterms.list perl -pe 's||%{_datadir}/terminfo/|' %{SOURCE5} >> %{name}.list perl -ni -e 'BEGIN { open F, "%{name}.list"; /^%/ or $s{$_} = 1 foreach <F>; } print unless $s{$_}' %{name}-extraterms.list %post -p /sbin/ldconfig %postun -p /sbin/ldconfig %files -f %{name}.list %defattr(-,root,root) %doc doc README ANNOUNCE %attr(755,root,root) /lib/lib*.so.* %attr(755,root,root) %{_libdir}/lib*.so.* %{_datadir}/tabset %{_bindir}/* %{_mandir}/man1/* %{_mandir}/man5/* %{_mandir}/man7/* %files extraterms -f %{name}-extraterms.list %defattr(-,root,root) %files devel %defattr(-,root,root) %doc c++ test /lib/lib*.so %{_libdir}/lib*.so %{_libdir}/lib*.a /usr/include/ncurses /usr/include/*.h %{_mandir}/man3/* %clean rm -rf $RPM_BUILD_ROOT %changelog * Wed Oct 4 2000 Warly <warly@mandrakesoft.com> 5.1-8mdk - move xterm-new to xterm waiting for a better solution * Wed Sep 20 2000 Warly <warly@mandrakesoft.com> 5.1-7mdk - hum, typo fixes, terminfo comes back (i DO sux) * Tue Sep 19 2000 Warly <warly@mandrakesoft.com> 5.1-6mdk - really put ncurses-5.1 * Fri Sep 15 2000 Pixel <pixel@mandrakesoft.com> 5.1-5mdk - add vt420 and vt510 (tx2Ed :) * Sat Sep 2 2000 Pixel <pixel@mandrakesoft.com> 5.1-4mdk - move unused terminfo's to extraterms * Mon Aug 07 2000 Frederic Lepied <flepied@mandrakesoft.com> 5.1-3mdk - automatically added BuildRequires * Wed Jul 26 2000 Thierry Vignaud <tvignaud@mandrakesoft.com> 5.1-2mdk - BM - suprees binary from doc * Wed Jul 12 2000 Thierry Vignaud <tvignaud@mandrakesoft.com> 5.1-1mdk - new release - use new macros * Wed May 03 2000 Warly <warly@mandrakesoft.com> 5.0-13mdk - correct links in /lib * Mon Apr 10 2000 Geoffrey Lee <snailtalk@linux-mandrake.com> 5.0-12mdk - fix license (again) :-/ * Fri Mar 31 2000 Warly <warly@mandrakesoft.com> 5.0-11mdk - devel group: Development/C * Fri Mar 31 2000 Geoffrey Lee <snailtalk@linux-mandrake.com> 5.0-10mdk - changed group - fixed license * Sun Mar 19 2000 John Buswell <johnb@mandrakesoft.com> 5.0-9mdk - PPC fixes * Wed Jan 12 2000 Pixel <pixel@mandrakesoft.com> 5.0-8mdk - fix for alpha (use egcs instead of gcc-2.95.2) * Tue Jan 11 2000 Frederic Lepied <flepied@mandrakesoft.com> 5.0-7mdk - fix xterm entry for 3.3.6 * Sun Dec 25 1999 - David BAUDENS <baudens@mandrakesoft.com> - Fix build for K6 (another, AMD K6 is not an i686) * Fri Nov 19 1999 Chmouel Boudjnah <chmouel@mandrakesoft.com> - Add debian term. * Fri Nov 12 1999 Chmouel Boudjnah <chmouel@mandrakesoft.com> - Add resetall script(r). * Sun Nov 7 1999 Chmouel Boudjnah <chmouel@mandrakesoft.com> - 5.0 anounced final. * Mon Oct 25 1999 Chmouel Boudjnah <chmouel@mandrakesoft.com> - Build release. * Wed Sep 29 1999 Bernhard Rosenkraenzer <bero@linux-mandrake.com> - update to 990925 * Mon Sep 6 1999 Bernhard Rosenkraenzer <bero@linux-mandrake.com> - update to 990904 * Fri Jul 16 1999 Chmouel Boudjnah <chmouel@mandrakesoft.com> - Rebuild for new environement (4mdk). * Mon Jul 5 1999 Bernhard Rosenkraenzer <bero@linux-mandrake.com> - update to 990703 * Wed May 19 1999 Bernhard Rosenkraenzer <bero@linux-mandrake.com> - update to 990516 - Fix the -fomit-frame-pointer problem (using -fno-omit-frame-pointer with -pg where needed) * Mon Apr 12 1999 Chmouel Boudjnah <chmouel@mandrakesoft.com> - update to 990410. - some spec tweaks (yes again ;-)) - removing the patch and build a global ncurses-990410.tar.bz2 - Remove the -fomit-frame-pointer (incompatible with -pg ?) - Add patch for a bug (?) with two entry in linux-lat. * Sat Apr 10 1999 Bernhard Rosenkraenzer <bero@linux-mandrake.com> - add de locale - update to 990403 - some spec tweaks - take description + some patches from RH 6.0 * Sun Mar 28 1999 Bernhard Rosenkraenzer <bero@microsoft.sucks.eu.org> - update to 990327 * Wed Mar 10 1999 Bernhard Rosenkraenzer <bero@microsoft.sucks.eu.org> - update to 990307 - link /lib/libncurses.so* to %{_libdir} * Sun Feb 7 1999 Bernhard Rosenkraenzer <bero@microsoft.sucks.eu.org> - update to 990206 * Fri Jan 15 1999 Bernhard Rosenkraenzer <bero@microsoft.sucks.eu.org> - update to 990110 - move libncurses.so.* to /lib, where it belongs (needed by sh) * Thu Dec 24 1998 Bernhard Rosenkraenzer <bero@microsoft.sucks.eu.org> - update to 981220 * Tue Dec 15 1998 Bernhard Rosenkraenzer <bero@microsoft.sucks.eu.org> - start with RH release 10 - update to 981212; merge patches in tar file - bzip2 man pages - use -fno-omit-frame-pointer -pg rather than just -pg for profiled version - that way, we can handle RPM_OPT_FLAGS with -fomit-frame-pointer - Make compatibility links to libncurses.so.3 (they ARE binary compatible) - update terminfo file to 10.2.5 * Wed Oct 14 1998 Cristian Gafton <gafton@redhat.com> - make sure to strip the binaries * Wed Sep 23 1998 Cristian Gafton <gafton@redhat.com> - added another zillion of patches. The spec file *is* ugly - defattr * Mon Jul 20 1998 Cristian Gafton <gafton@redhat.com> - added lots of patches. This spec file is starting to look ugly * Wed Jul 01 1998 Alan Cox <alan@redhat.com> - Fix setuid trusting. Open termcap/info files as the real user. * Wed May 06 1998 Cristian Gafton <gafton@redhat.com> - added terminfo entry for the poor guys using lat1 and/or lat-2 on their consoles... Enjoy linux-lat ! Thanks, Erik ! * Tue Apr 21 1998 Cristian Gafton <gafton@redhat.com> - new patch to get xterm-color and nxterm terminfo entries - aliased them to rxvt, as that seems to satisfy everybody * Sun Apr 12 1998 Cristian Gafton <gafton@redhat.com> - added %clean section * Tue Apr 07 1998 Cristian Gafton <gafton@redhat.com> - removed %{_libdir}/terminfo symlink - we shouldn't need that * Mon Apr 06 1998 Cristian Gafton <gafton@redhat.com> - updated to 4.2 + patches - added BuildRoot * Sat Apr 04 1998 Cristian Gafton <gafton@redhat.com> - rebuilt with egcs on alpha * Wed Dec 31 1997 Erik Troan <ewt@redhat.com> - version 7 didn't rebuild properly on the Alpha somehow -- no real changes are in this version * Tue Dec 09 1997 Erik Troan <ewt@redhat.com> - TIOCGWINSZ wasn't used properly * Tue Jul 08 1997 Erik Troan <ewt@redhat.com> - built against glibc, linked shared libs against -lc