Summary: Public Domain Curses for X11 Name: PDCurses Version: 3.3 Release: 1 Copyright: LGPL Group: Development/Libraries Source0: %{name}-%{version}.tar.gz Patch0: %{name}-%{version}-aix.patch URL: http://pdcurses.sourceforge.net/ BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root BuildRequires: make BuildRequires: libXpm-devel >= 3.5.7 Requires: libXpm >= 3.5.7 %description PDCurses for X11, also known as XCurses, is an implementation of the curses library that lets you rebuild existing text-mode curses programs as native X11 applications, with very little modification. For more information, visit http://pdcurses.sourceforge.net/. The library is available as 32-bit and 64-bit. %package devel Summary: Development tools for Theora applications. Group: Development/Libraries Requires: %{name} = %{version}-%{release} %description devel The PDCurses-devel package contains the header files and documentation needed to develop applications with PDCurses. If you are compiling a 32-bit program, no special compiler options are needed. If you are compiling a 64-bit program, you have to compile and link your application with "xlc_r -q64" or "gcc -maix64". %prep %setup -q %patch0 %build # setup environment for 32-bit and 64-bit builds export AR="ar -X32_64" export NM="nm -X32_64" # first build the 64-bit version export CC="xlc_r -q64" ./configure \ --prefix=%{_prefix} \ --enable-shared --disable-static gmake %{?_smp_mflags} mkdir 64 cp *.h 64/ mv x11/shr.o shr64.o gmake distclean # now build the 32-bit version export CC="xlc_r" ./configure \ --prefix=%{_prefix} \ --enable-shared --disable-static gmake %{?_smp_mflags} # add the 64-bit shared objects to the shared library containing already the # 32-bit shared objects ${AR} -q x11/libXCurses.a ./shr64.o %install [ "${RPM_BUILD_ROOT}" != "/" ] && rm -rf ${RPM_BUILD_ROOT} gmake DESTDIR=${RPM_BUILD_ROOT} install rm -f ${RPM_BUILD_ROOT}%{_libdir}/libXpanel.a cd ${RPM_BUILD_ROOT}%{_libdir} ln -s libXCurses.a libXpanel.a ( cd ${RPM_BUILD_ROOT} for dir in bin include lib do mkdir -p usr/${dir} cd usr/${dir} ln -sf ../..%{_prefix}/${dir}/* . cd - done ) %clean [ "${RPM_BUILD_ROOT}" != "/" ] && rm -rf ${RPM_BUILD_ROOT} %files %defattr(-,root,system) %doc README HISTORY maintain.er %{_libdir}/* /usr/lib/* %files devel %defattr(-,root,system) %{_bindir}/* %{_includedir}/* /usr/bin/* /usr/include/* %changelog * Mon Jun 02 2008 Michael Perzl - 3.3-1 - first version for AIX V5.1 and higher