#%%define snap 20030908.0723
-%define pre pre5
+%define pre pre3
-Summary: Dia - a gtk+ based diagram creation program
+Summary: Dia - a GTK+ based diagram creation program
Summary(es): Programa para dibujo de diagramas
Summary(pl): Dia - program do tworzenia diagramów
Summary(pt_BR): Programa para desenho de diagramas
Summary(ru): ðÒÏÇÒÁÍÍÁ ÄÌÑ ÒÉÓÏ×ÁÎÉÑ ÄÉÁÇÒÁÍÍ
Summary(uk): ðÒÏÇÒÁÍÁ ÄÌÑ ÍÁÌÀ×ÁÎÎÑ Ä¦ÁÇÒÁÍ
-Summary(zh_CN): »ùÓÚgtk+µÄÁ÷³Ìͼ³ÌÐò
+Summary(zh_CN): »ùÓÚGTK+µÄÁ÷³Ìͼ³ÌÐò
Name: dia
-Version: 0.92
-Release: 1.%{pre}.1
+Version: 0.94
+Release: 8
Epoch: 1
License: GPL
Group: X11/Applications/Graphics
Vendor: James Henstridge <james@daa.com.au>
-Source0: http://ftp.gnome.org/pub/GNOME/sources/dia/%{version}/%{name}-%{version}-%{pre}.tar.bz2
-# Source0-md5: 360d5cdda826a260711c4e25266b30be
+Source0: http://ftp.gnome.org/pub/GNOME/sources/%{name}/0.94/%{name}-%{version}.tar.bz2
+# Source0-md5: 63584224912dab49fed8d2cf87ea2d85
## this only for snapshots
##Source0: http://www.crans.org/~chepelov/dia/snapshots/%{name}-CVS-%(echo %{snap} | tr . -).tar.gz
-# this for pre releases
-Patch0: dia-state.patch
-Patch1: dia-am.patch
-URL: http://www.lysator.liu.se/~alla/dia/dia.html
+#Patch0: dia-state.patch
+#Patch1: %{name}-home_etc.patch
+Patch2: %{name}-locale-names.patch
+Patch3: %{name}-python.patch
+Patch4: %{name}-desktop.patch
+Patch5: %{name}-gcc4.patch
+URL: http://www.gnome.org/projects/dia/
BuildRequires: autoconf
BuildRequires: automake
BuildRequires: gettext-devel
-BuildRequires: intltool
-BuildRequires: libgnomeui-devel
+BuildRequires: howl-devel >= 0.9.10
+BuildRequires: intltool >= 0.21
+BuildRequires: libart_lgpl-devel
+BuildRequires: libgnomeui-devel >= 2.0.0
+BuildRequires: libpng-devel
+BuildRequires: libtool
+BuildRequires: libxml2-devel >= 2.3.9
BuildRequires: libxslt-devel
+BuildRequires: popt-devel
+BuildRequires: python-devel >= 1:2.3
+BuildRequires: python-pygtk-devel
+Requires(post,postun): desktop-file-utils
+Requires: python-modules >= 2.3
+Requires: python-pygtk-gtk
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
%description
Á ÔÁËÏÖ ÅËÓÐÏÒÔÕ×ÁÔÉ §È × PostScript(TM).
%prep
-%setup -q -n %{name}-%{version}-%{pre}
-%patch0 -p1
-%patch1 -p1
+%setup -q
+#%patch0 -p1
+#%patch1 -p1 - obsoleted?
+%patch2 -p1
+%patch3 -p1
+%patch4 -p1
+%patch5 -p1
+
+mv po/{no,nb}.po
%build
%{__libtoolize}
%{__autoheader}
%{__autoconf}
%{__automake}
-%configure
+%configure \
+ --enable-gnome \
+ --with-python
+
%{__make}
%install
DESTDIR=$RPM_BUILD_ROOT \
Applicationsdir=%{_desktopdir}
+rm -rf $RPM_BUILD_ROOT%{_datadir}/mime-info
+
%find_lang %{name} --with-gnome
%clean
rm -rf $RPM_BUILD_ROOT
+%post
+%update_desktop_database_post
+
+%postun
+%update_desktop_database_postun
+
%files -f %{name}.lang
%defattr(644,root,root,755)
%doc AUTHORS NEWS README TODO
%{_mandir}/man1/*
%{_datadir}/dia
-%{_datadir}/mime-info/*
%{_desktopdir}/dia.desktop
%{_pixmapsdir}/*