# # spec file for package giac # # Copyright (c) 2015 SUSE LINUX 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/ # %define soname 0 %bcond_with cocoa Name: giac Version: 1.2.2 Release: 0 Summary: Computer algebra system License: GPL-3.0+ Group: Productivity/Scientific/Math Url: http://www-fourier.ujf-grenoble.fr/~parisse/giac.html Source: http://www-fourier.ujf-grenoble.fr/~parisse/giac/giac_stable.tgz BuildRequires: blas-devel BuildRequires: fdupes BuildRequires: fltk-devel BuildRequires: gcc-c++ BuildRequires: gmp-devel BuildRequires: hicolor-icon-theme BuildRequires: lapack-devel BuildRequires: latex2html BuildRequires: libjpeg-devel BuildRequires: mpfi-devel BuildRequires: mpfr-devel BuildRequires: ntl-devel BuildRequires: pari-devel BuildRequires: pkgconfig BuildRequires: readline-devel BuildRequires: shared-mime-info BuildRequires: update-desktop-files BuildRequires: pkgconfig(fontconfig) BuildRequires: pkgconfig(gl) BuildRequires: pkgconfig(gsl) BuildRequires: pkgconfig(gio-2.0) BuildRequires: pkgconfig(libpng12) BuildRequires: pkgconfig(x11) BuildRequires: pkgconfig(xext) BuildRequires: pkgconfig(xft) BuildRequires: pkgconfig(xinerama) Recommends: giac-doc Requires(post): %install_info_prereq Requires(preun): %install_info_prereq %if !%{with cocoa} BuildRequires: pkgconfig(ao) %endif %description Free computer algebra system, compatible with existing CAS, as a C++ library with various user interfaces (GUI with formal spreadsheet and exact dynamic geometry, on-line, readline, emacs, texmacs...). %package -n lib%{name}%{soname} Summary: The core library for %{name} Group: System/Libraries %description -n lib%{name}%{soname} Free computer algebra system, compatible with existing CAS, as a C++ library with various user interfaces (GUI with formal spreadsheet and exact dynamic geometry, on-line, readline, emacs, texmacs...). %package devel Summary: Development files for %{name} Group: Development/Libraries/C and C++ Requires: lib%{name}%{soname} = %{version} Requires: fltk-devel Requires: mpfi-devel Requires: mpfr-devel Requires: ntl-devel Requires: pkgconfig(ao) Requires: pkgconfig(gsl) %description devel Computer algebra system. This package contains header files and libraries needed to develop application that use %{name}. %package doc Summary: Documentation for %{name} Group: Documentation/HTML BuildArch: noarch %description doc Computer algebra system. This document describes the basic structure and provides information on usage of %{name}. %lang_package %prep %setup -q # remove all hidden files find . -type f -iname '.*' -exec rm -f {} \; %build %configure \ --enable-gui \ --enable-static=no make %{?_smp_mflags} %install %make_install # use the freedesktop standard rm -rf %{buildroot}%{_datadir}/application-registry # install man page find debian -type f -name \*.1 | while read i; do f=$(basename $i) install -Dm 0644 $i %{buildroot}%{_mandir}/man1/$f; done # install mimeinfo install -Dm 0644 debian/%{name}.sharedmimeinfo %{buildroot}%{_datadir}/mime/packages/%{name}.xml # remove makefiles from %%doc find %{buildroot}%{_datadir}/%{name}/doc -type f -name \*akefile* -exec rm -f {} \; # remove zero-length find %{buildroot}%{_datadir}/%{name}/doc -type f -empty -exec rm -f {} \; %find_lang %{name} %fdupes -s %{buildroot}%{_datadir} %post %mime_database_post %desktop_database_post %icon_theme_cache_post %info_add %{name}_es.info %info_add %{name}_us.info %preun if [ $1 -eq 0 ]; then %install_info_delete --info-dir=%{_infodir} %{_infodir}/%{name}_es.info%{ext_info} %install_info_delete --info-dir=%{_infodir} %{_infodir}/%{name}_us.info%{ext_info} fi %postun %mime_database_postun %desktop_database_postun %icon_theme_cache_postun %post -n lib%{name}%{soname} -p /sbin/ldconfig %postun -n lib%{name}%{soname} -p /sbin/ldconfig %files %defattr(0644,root,root,0755) %doc AUTHORS COPYING %attr(0755,root,root) %{_bindir}/icas %attr(0755,root,root) %{_bindir}/pgiac %attr(0755,root,root) %{_bindir}/xcas %attr(0755,root,root) %{_bindir}/cas_help ###it's a symbolic link### %{_bindir}/giac %{_bindir}/xcasnew %{_bindir}/en_cas_help %{_bindir}/es_cas_help %{_bindir}/fr_cas_help ########################## %{_datadir}/%{name} %{_datadir}/icons/hicolor/*/apps/*xcas.png %{_datadir}/icons/hicolor/*/mimetypes/*xcas.png %{_datadir}/pixmaps/xcas.xpm %{_datadir}/applications/xcas.desktop %{_datadir}/mime/packages/%{name}.xml %{_infodir}/%{name}_es.info%{ext_info} %{_infodir}/%{name}_us.info%{ext_info} %{_mandir}/man1/cas_help.1%{ext_info} %{_mandir}/man1/fr_cas_help.1%{ext_info} %{_mandir}/man1/giac.1%{ext_info} %{_mandir}/man1/icas.1%{ext_info} %{_mandir}/man1/pgiac.1%{ext_info} %{_mandir}/man1/xcas.1%{ext_info} %exclude %{_datadir}/%{name}/doc %exclude %{_datadir}/%{name}/aide_cas %exclude %{_datadir}/%{name}/examples %files -n lib%{name}%{soname} %defattr(0644,root,root,0755) %{_libdir}/lib%{name}.so.* %files devel %defattr(0644,root,root,0755) %{_includedir}/%{name} %{_libdir}/lib%{name}.so %{_datadir}/%{name}/examples %exclude %{_libdir}/lib%{name}.la %files doc %defattr(0644,root,root,0755) %{_datadir}/%{name}/doc %{_datadir}/%{name}/aide_cas %exclude %{_datadir}/doc %files lang -f %{name}.lang %defattr(0644,root,root,0755) %changelog