File smalltalk.spec of Package smalltalk

#
# spec file for package smalltalk (Version 3.2.5)
#
# 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 http://bugs.opensuse.org/
#

# norootforbuild


Name:           smalltalk
BuildRequires:  gmp-devel gtk2-devel readline-devel tk-devel update-desktop-files zip
BuildRequires:  texlive-latex
BuildRequires:  libffi-devel
Requires:       libffi-devel
License:        GFDL-1.1 and GPL-2.0+ and LGPL-2.1+
Group:          Development/Languages/Other
PreReq:         %install_info_prereq
AutoReqProv:    no
Version:        3.2.5
Release:        0
Summary:        The GNU implementation of the Smalltalk language
Url:            http://www.gnu.org/software/smalltalk/
Source0:        ftp://ftp.gnu.org/pub/gnu/smalltalk/smalltalk-%{version}.tar.gz
Source1:        xgst
Patch1:         %{name}-3.2.5-64bit.patch
Patch2:         %{name}-3.0.3-strict-aliasing.patch
Patch4:         %{name}-3.2.5-integer_and_buffer_overflow.patch
Patch5:         %{name}-3.2.5-xpm-sec5.patch
Patch6:         %{name}-3.2.5-xpm-secfix-thomas.patch
Patch9:         %{name}-warning.patch
Patch10:        %{name}-config.diff
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
GNU Smalltalk is an implementation that closely follows the
Smalltalk-80 language as described in the book `Smalltalk-80: the
Language and its Implementation' by Adele Goldberg and David Robson.

For a complete explanation of Smalltalk there is a very nice tutorial.
Try the command: "info gst".



Authors:
--------
    Paolo Bonzini <bonzini@gnu.org>
    Steve Byrne <sbb@gnu.org>

%prep
%setup -q
%patch1
#%patch2
%patch4
%patch5
%patch6
#%patch9
#%patch10
#
cp %{S:1} .
# the original libtool.m4 does not recognize this host and does not generate
# dynamic linker characteristic, thereafter plugins are not working
#cp -v /usr/share/aclocal/libtool.m4 build-aux

%build
CFLAGS="$RPM_OPT_FLAGS" \
CXXFLAGS="$RPM_OPT_FLAGS" \
./configure --prefix=%{_prefix} \
	    --libdir=%{_libdir} \
            --infodir=%{_infodir} \
            --mandir=%{_mandir} \
            --libexecdir=%{_datadir} \
  	    --with-tcl=%{_libdir}
make

%package devel
Summary:        Development files for GNU Smalltalk
Group:          Development/Languages/Other
Requires:       smalltalk
License:        LGPL-2.1+
%description devel
GNU Smalltalk is an implementation that closely follows the
Smalltalk-80 language as described in the book `Smalltalk-80: the
Language and its Implementation' by Adele Goldberg and David Robson.

%install
make DESTDIR=$RPM_BUILD_ROOT install
install -m 755 xgst $RPM_BUILD_ROOT%{_bindir}/
#
# remove the unneeded gst.im
rm -f $RPM_BUILD_ROOT%{_datadir}/smalltalk/gst.im
# symlinks to BuildRoot are not allowed
ln -snf gst-load.1 $RPM_BUILD_ROOT%{_mandir}/man1/gst-reload.1

# arch-dependent files should not be under /usr/share
pushd $RPM_BUILD_ROOT%{_datadir}/smalltalk
mv gnutls-wrapper ../../../%{_bindir}
ln -s ../../../%{_bindir}/gnutls-wrapper .
popd

%clean
rm -rf $RPM_BUILD_ROOT

%post
%install_info --info-dir=%{_infodir} %{_infodir}/gst.info.gz

%postun
%install_info_delete --info-dir=%{_infodir} %{_infodir}/gst.info.gz

%files
%defattr(-,root,root)
%doc AUTHORS COPYING* ChangeLog NEWS README THANKS TODO
%doc %{_infodir}/gst**.gz
%doc %{_mandir}/man1/*
%{_datadir}/aclocal/*
%{_bindir}/*
%{_libdir}/lib*
%{_libdir}/smalltalk
%{_datadir}/smalltalk
%exclude %{_libdir}/libgst.a
%exclude %{_libdir}/libgst.la
%exclude %{_libdir}/libgst.so
%exclude %{_libdir}/smalltalk/*.a
%exclude %{_libdir}/smalltalk/*.la

%files devel
%defattr(-,root,root)
%{_libdir}/libgst.so
%{_libdir}/pkgconfig/gnu-smalltalk.pc
/usr/include/*


%changelog
openSUSE Build Service is sponsored by