File chemtool.spec of Package chemtool

# spec file for package chemtool (Version 1.6.11)
# Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany.
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via

# norootforbuild

Name:           chemtool
%define name0 cht
Summary:        Program for Drawing 2D Organic Molecules
Version:        1.6.11
Release:        74
License:        GPL v2 or later
PreReq:         shared-mime-info
BuildRequires:  gtk2-devel shared-mime-info update-desktop-files
Group:          Productivity/Graphics/Other
Source:         %{name}-%{version}.tar.bz2
Source1:        %{name}.desktop
Patch1:         %{name}-%{version}-mime.diff
Patch2:         %{name}-%{version}-memmove.diff
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

Chemtool is a program for drawing organic molecules easily and storing
them as an X bitmap, Xfig, or EPS file. It runs under the X Window
System using the GTK widget set.

    Thomas Volk
    Dr. Martin Kroeker

%setup -q

# to convince configure to install also gnome stuff
%configure \
make %{?jobs:-j%jobs}
# rebuild the .mo files -- the distributed cs/ didn't work in 1.6.7
# for po in locales/*/*.po; do
#	msgfmt -o "${po/%.po/.mo}" "$po"
# done

%find_lang %{name}
mkdir -p $RPM_BUILD_ROOT/usr/share/applications
install -m 0644 %SOURCE1 \
install -d $RPM_BUILD_ROOT%{_datadir}/pixmaps
install -m 644 gnome/gnome-application-%{name}.png $RPM_BUILD_ROOT%{_datadir}/pixmaps
DESTDIR=$RPM_BUILD_ROOT mime-info-to-mime
%suse_update_desktop_file %name Chemistry


if [ -x usr/bin/update-mime-database ]; then
	usr/bin/update-mime-database /usr/share/mime >/dev/null

if [ -x usr/bin/update-mime-database ]; then
	usr/bin/update-mime-database /usr/share/mime >/dev/null

%files -f %{name}.lang
%doc %{_mandir}/man1/%{name}.1*
%doc %{_mandir}/man1/%{name0}.1*

* Mon Sep 22 2008
- fix some rpmlint warnings and beautify specfile
* Wed Feb 27 2008
- updated to version 1.6.11
  - Key sequences @+ and @- now generate "circle" variants of plus and minus signs
  - Bond length and zoom factor are now saved in chemtool files and restored on loading
  - Corrected length calculation for labels without sub- or superscripts (thereby fixing
  truncation of labels near the edges of a drawing)
  - Corrected positioning and inter-character spacing of labels with sub- or superscripts
  - Changed OpenOffice output to avoid LaTeX formatting (that fig2sxd does not support)
  - Improved clipping of double and triple bonds around labels in the screen view
  - Improved the preview function to cope with older (pre-1.6) chemtool files
  - The "gtklp" frontend for CUPS is now available from the "print command" menu
  - Updated documentation
- dropped patch (Makefile.diff)
* Wed Apr 25 2007
- updated to version 1.6.10
  - Added a "round parentheses" option to the bracket tool.
  - Added export to PNG (through fig2dev/gs).
  - Added template entries for morphine and several diazoles.
  - Improved truncation of bonds around labels in the screen view.
  - Redesigned Configuration dialogs.
  - XFig and related export modes now support text in non-western
  european character sets ("Times" font only) through fig2dev's
  "international" option.
  - The KDE "kprinter" frontend is now available from the "print command"
  configuration dialog
  - Cleanup no longer removes drop shadows from boxes
  - Fixed a potential crash with non-ascii characters in labels (including
  electron-pair dots) and gtk2.
  - Fixed menu shortcuts getting intercepted by the labeling shortcut mechanism.
  - Fixed width of arrowheads in ps/eps.
  - Fixed superscript position, national characters and arrowhead size in SVG.
  - Fixed a bug in SVG export that could truncate labels in subsequent save or
  export actions.
- removed obsolete zoom.diff
* Wed Jan 17 2007
- changed prefix /opt/gnome -> /usr
* Tue Dec 05 2006
- fixed comparison with string literal [#224840]
* Fri Nov 10 2006
- fix manpage permissions
* Thu Aug 03 2006
- updated to 1.6.9
  - Fixed placement of right-justified labels containing sub-
  and/or superscripts on screen and in all XFig-based export modes.
  - Worked around a bug in fig2dev that prevented creation of EMF files
  - Improved spacing of sub/superscripted labels in GTK2 builds
  - Corrected line spacing of triple and quadruple bonds.
- removed not existing .desktop category Edutainment
* Wed Jan 25 2006
- converted neededforbuild to BuildRequires
* Thu Jan 05 2006
- update to 1.6.8
* Tue Oct 25 2005
- correctly fix #122542 (thanks to
* Tue Oct 18 2005
- updated to 1.6.7
- build with gtk2
- added workaround for some gcc-4.0 bug [#122542] to be able to test
  the package
* Mon Jun 13 2005
- avoid redefining memcpy
* Tue Apr 12 2005
- update to 1.6.6
* Tue Sep 07 2004
- Generated shared mime info.
* Sat Jan 10 2004
- build as user
* Thu Sep 25 2003
- fixed undo_* prototypes, fixing #31724
* Sat Aug 16 2003
- add desktop file
* Wed Jul 09 2003
- updated sources to version 1.6
- fixed Gnome-related files installation
- use %%find_lang macro
* Tue Nov 12 2002
- changed neededforbuild <xf86 xdevel> to <x-devel-packages>
* Thu Mar 21 2002
- moved ChangeLog, TODO and README to %%{_docdir}/%%{_name}-%%{_version}
* Fri Oct 26 2001
- New package: initial version 1.4.1
openSUSE Build Service is sponsored by