%define _prefix /opt/freeware %define _defaultdocdir %{_prefix}/doc %define libxml2_version 2.5.11 %define gtk2_version 2.2.4 %define pango_version 1.2.5 Summary: The libglade library for loading user interfaces. Name: libglade2 Version: 2.0.1 Release: 2 Copyright: LGPL Group: System Environment/Libraries Source: libglade-%{version}.tar.bz2 Patch0: libglade-2.0.1-aix.patch Patch1: libglade-2.0.1-autotools.patch URL: http://www.gnome.org BuildRoot: %{_tmppath}/%{name}-%{version}-root Requires: libxml2 >= %{libxml2_version} BuildRequires: libxml2-devel >= %{libxml2_version} BuildRequires: gtk2-devel >= %{gtk2_version} #BuildRequires: Xft #BuildRequires: fontconfig BuildRequires: pango-devel >= %{pango_version} %description Libglade is a small library that allows a program to load its user interface from am XML description at runtime. Libglade uses the XML file format used by the GLADE user interface builder GLADE, so libglade acts as an alternative to GLADE's code generation approach. Libglade also provides a simple interface for connecting handlers to the various signals in the interface (on platforms where the gmodule library works correctly, it is possible to connect all the handlers with a single function call). Once the interface has been instantiated, libglade gives no overhead, so other than the short initial interface loading time, there is no performance tradeoff. %package devel Summary: The files needed for libglade application development. Group: Development/Libraries Requires: %name = %{PACKAGE_VERSION} Requires: libxml2-devel >= %{libxml2_version} Requires: gtk2-devel >= %{gtk2_version} Conflicts: libglade < 0.17 %description devel The libglade-devel package contains the libraries and include files that you can use to develop libglade applications. %prep %setup -q -n libglade-%{version} if test x$PATCH = x ; then PATCH=patch ; fi $PATCH -p2 -s < %{_sourcedir}/libglade-2.0.1-aix.patch $PATCH -p2 -s < %{_sourcedir}/libglade-2.0.1-autotools.patch %build PATH=%{_bindir}:$PATH ./configure --prefix=%{_prefix} --disable-gtk-doc make %install if test "%{buildroot}" != "/"; then rm -rf %{buildroot} fi mkdir -p %{buildroot} PATH=%{_bindir}:$PATH 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 ChangeLog NEWS README COPYING %{_libdir}/lib*.a /usr/lib/lib*.a %{_datadir}/xml %files devel %defattr(-, root,system) %doc test-libglade.c %{_bindir}/* /usr/bin/* %{_libdir}/lib*.la %{_libdir}/pkgconfig/* %{_includedir}/* /usr/include/* %{_datadir}/gtk-doc