Name:		diacanvas2
Summary:	Diagram widget for GTK+ 2.0
Version:	@VERSION@
Release:	1
License:	LGPL
Group:		Development/Libraries
Source:		http://prdownloads.sourceforge.net/diacanvas/diacanvas2-%{version}.tar.gz
BuildRoot:	/var/tmp/%{name}-%{version}-root
URL:		http://diacanvas.sourceforge.net
Requires:	gtk+ >= 1.3.11
Requires:	libgnomecanvas >= 1.107.0
#BuildRequires:	gtk+-devel
#BuildRequires:	libgnomecanvas-devel

%description
A diagram widget for GTK+-2.0 with a Visio look.
Development libs and headers are in diacanvas2-devel.

%package devel
Summary:	DiaCanvas2 development libraries
Group:		Development/Libraries
Requires:	%{name} = %{version}

%description devel
Static libraries and header files for the support library for DiaCanvas2.

%package python
Summary:	DiaCanvas2 development libraries
Group:		Development/Libraries
Requires:	%{name} = %{version}
Requires:	pygtk >= 1.99.8
Requires:	gnome-python >= 1.99.8

%description python
Python interface for DiaCanvas2.

%prep
%setup -q -n diacanvas2-%{version}

%build
CFLAGS="$RPM_OPT_FLAGS"
./configure --prefix=%{_prefix} \
    --bindir=%{_bindir} --mandir=%{_mandir} \
    --localstatedir=%{_localstatedir} --libdir=%{_libdir} \
    --datadir=%{_datadir} --includedir=%{_includedir} \
    --sysconfdir=%{_sysconfdir} --disable-gtk-doc
make

%install
rm -rf $RPM_BUILD_ROOT

make prefix=$RPM_BUILD_ROOT%{_prefix} bindir=$RPM_BUILD_ROOT%{_bindir} \
    mandir=$RPM_BUILD_ROOT%{_mandir} libdir=$RPM_BUILD_ROOT%{_libdir} \
    localstatedir=$RPM_BUILD_ROOT%{_localstatedir} \
    datadir=$RPM_BUILD_ROOT%{_datadir} \
    includedir=$RPM_BUILD_ROOT%{_includedir} \
    sysconfdir=$RPM_BUILD_ROOT%{_sysconfdir} install

%clean
rm -rf $RPM_BUILD_ROOT

%post -p /sbin/ldconfig

%postun -p /sbin/ldconfig

%files
%defattr(-, root, root)

%doc AUTHORS COPYING ChangeLog NEWS README
%{_libdir}/lib*.so.*

%files devel
%defattr(-, root, root)

#%{_libdir}/lib*.so
%{_libdir}/*a
%{_libdir}/pkgconfig/*.pc
%{_includedir}/diacanvas

%defattr(-, root, root)

%{_libdir}/python2.2/site-packages/diacanvasmodule.so

%changelog
* Tue Mar 05 2002 Arjan Molenaar <arjanmolenaar@hetnet.nl>
- Initial configuration: three packages:
	. diacanvas2
	. diacanvas2-devel
	. diacanvas2-python
