# Note that this is NOT a relocatable package %define ver 1.0.12 %define rel 2 %define prefix %{_prefix} Summary: The LibGTop library Name: libgtop Version: %ver Release: %rel Copyright: LGPL Group: System Environment/Libraries Source: ftp://ftp.gnome.org/pub/GNOME/stable/sources/libgtop/libgtop-%{ver}.tar.gz Patch0: libgtop-1.0.12-security.patch Patch1: libgtop-1.0.12-libtool135a.patch URL: http://www.home-of-linux.org/gnome/libgtop/ Prereq: /sbin/install-info Docdir: %{prefix}/doc BuildRoot: /var/tmp/libgtop-%{PACKAGE_VERSION}-root BuildRequires: libtool >= 1.3.5 make %define stdlib lib %define liblink ../.. %define DEFCC cc %description A library that fetches information about the running system such as CPU and memory useage, active processes and more. On Linux systems, this information is taken directly from the /proc filesystem while on other systems a server is used to read that information from other /dev/kmem, among others. %package devel Summary: Libraries, includes and other files to develop LibGTop applications. Group: Development/Libraries Requires: libgtop = %{PACKAGE_VERSION} %description devel Install this package if you wish to develop applications that access information on system statistics such as CPU and memory usage. %changelog * Fri Mar 15 2002 Dan McNichol - Include the security fix from Intexxia. - This version builds better with libtool 1.3.5.a. * Thu Aug 23 2001 Dan McNichol - Update to version 1.0.12. * Fri Mar 09 2001 Marc Stephenson - Add logic for default compiler - Rebuild against new shared objects * Fri Feb 16 2001 aixtoolbox - Account for different standard lib location in IA64 32-bit ABI * Fri Oct 27 2000 pkgmgr - Modify for AIX Freeware distribution * Wed Sep 08 1999 Elliot Lee - Update to 1.0.2 * Tue Aug 19 1998 Martin Baulig - released LibGTop 0.25.0 * Sun Aug 16 1998 Martin Baulig - first version of the RPM %prep %setup -q %patch0 -p1 -b .security %patch1 -p1 -b .libtool135a %build %ifarch alpha MYARCH_FLAGS="--host=alpha-redhat-linux" %endif # Use the default compiler for this platform - gcc otherwise if [[ -z "$CC" ]] then if test "X`type %{DEFCC} 2>/dev/null`" != 'X'; then export CC=%{DEFCC} else export CC=gcc fi fi if test "X$CC" != "Xgcc" then export RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS | sed 's:-fsigned-char::'` export CFLAGS="$RPM_OPT_FLAGS" fi #libtoolize --force # Needed for snapshot releases. if [ ! -f configure ]; then CFLAGS="$RPM_OPT_FLAGS" LDFLAGS="-Wl,-brtl" ./autogen.sh --prefix=%prefix \ $MYARCH_FLAGS else CFLAGS="$RPM_OPT_FLAGS" LDFLAGS="-Wl,-brtl" ./configure --prefix=%prefix \ $MYARCH_FLAGS fi if [ "$SMP" != "" ]; then make MAKE="make -j$SMP" else make fi %install rm -rf $RPM_BUILD_ROOT make prefix=$RPM_BUILD_ROOT%{prefix} install /usr/bin/strip $RPM_BUILD_ROOT%{prefix}/bin/* ||: # # msf - remove these as they are really supposed to come from gnome-libs # # martin - don't remove since they are no longer installed if build # with GNOME # # rm -f $RPM_BUILD_ROOT/%{prefix}/lib/libgnomesupport.a # rm -f $RPM_BUILD_ROOT/%{prefix}/lib/libgnomesupport.la # rm -f $RPM_BUILD_ROOT/%{prefix}/lib/libgnomesupport.so.0 # rm -f $RPM_BUILD_ROOT/%{prefix}/lib/libgnomesupport.so.0.0.0 # Eh why? # rm -fr $RPM_BUILD_ROOT/%{prefix}/include/libgtop ( cd $RPM_BUILD_ROOT for dir in bin include do mkdir -p usr/$dir cd usr/$dir ln -sf ../..%{prefix}/$dir/* . cd - done mkdir -p usr/%{stdlib} cd usr/%{stdlib} ln -sf %{liblink}%{prefix}/lib/* . ) %clean rm -rf $RPM_BUILD_ROOT %files %defattr(-, root, root) %doc RELNOTES-0.25 RELNOTES-1.0 AUTHORS ChangeLog NEWS README %doc copyright.txt %doc src/inodedb/README.inodedb %{prefix}/lib/lib*.so* %{prefix}/lib/*a %{prefix}/bin/* /usr/%{stdlib}/lib*.so* /usr/%{stdlib}/*a /usr/bin/* %files devel %defattr(-, root, root) %{prefix}/lib/*.sh %{prefix}/lib/*.def %{prefix}/include/* /usr/%{stdlib}/*.sh /usr/%{stdlib}/*.def /usr/include/*