%define _prefix /opt/freeware %define _defaultdocdir %{_prefix}/doc %define pkgconfig_version 0.15.0 Summary: A library of handy utility functions. Name: glib2 Version: 2.2.3 Release: 2 License: LGPL Group: System Environment/Libraries Source: glib-%{version}.tar.bz2 Patch0: glib-2.2.3-aix.patch Patch1: glib-2.2.3-autotools.patch BuildRoot: %{_tmppath}/%{name}-%{version}-root URL: http://www.gtk.org Requires: gettext BuildRequires: pkgconfig >= 0.15.0 Obsoletes: glib-gtkbeta %description GLib is the low-level core library that forms the basis for projects such as GTK+ and GNOME. It provides data structure handling for C, portability wrappers, and interfaces for such runtime functionality as an event loop, threads, dynamic loading, and an object system. This package provides version 2.0 of GLib. %package devel Summary: The GIMP ToolKit (GTK+) and GIMP Drawing Kit (GDK) support library Group: Development/Libraries Obsoletes: glib-gtkbeta-devel Requires: pkgconfig >= 0.15.0 Requires: %{name} = %{version} #Conflicts: glib-devel <= 1:1.2.8 %description devel The glib-devel package includes the header files for version 2.0 of the GLib library. %prep %setup -q -n glib-%{version} if test x$PATCH = x ; then PATCH=patch ; fi $PATCH -p2 -s < %{_sourcedir}/glib-2.2.3-aix.patch $PATCH -p2 -s < %{_sourcedir}/glib-2.2.3-autotools.patch %build PATH=%{_bindir}:$PATH ./configure --prefix=%{_prefix} --disable-gtk-doc PATH=%{_bindir}:$PATH make %install if test "%{buildroot}" != "/"; then rm -rf %{buildroot} fi mkdir -p %{buildroot} make DESTDIR=%{buildroot} install-strip # make links cd %{buildroot} for dir in bin lib include do mkdir -p usr/$dir cd usr/$dir ln -sf ../..%{_prefix}/$dir/* . cd - done %files %defattr(-, root, system) %doc AUTHORS COPYING ChangeLog NEWS README %config %{_libdir}/charset.alias %{_libdir}/lib*.a /usr/lib/lib*.a %{_datadir}/locale/*/LC_MESSAGES/glib20.mo %files devel %defattr(-, root, system) %{_libdir}/glib-2.0 %{_libdir}/lib*.la /usr/lib/lib*.la %{_includedir}/* /usr/include/* %{_datadir}/aclocal/* %{_datadir}/gtk-doc/ %{_libdir}/pkgconfig/* %{_datadir}/glib-2.0 %{_bindir}/* /usr/bin/* %{_mandir}/man1/*