+#
+# Conditional build:
+%bcond_with ggi # GGI driver
+%bcond_with ggixmi # GGI XMI support for pm3d
+%bcond_with pdf # PDF terminal (based on PDFLib)
+%bcond_with qt # build Qt terminal
+%bcond_with svga # Linux SVGA console driver
+#
Summary: A program for plotting mathematical expressions and data
Summary(de.UTF-8): GNU-Plotter-Paket
Summary(es.UTF-8): Paquete para trazar gráficos
Summary(tr.UTF-8): Matematiksel görselleştirme paketi
Summary(uk.UTF-8): Програма для побудови графіків математичних виразів та даних
Name: gnuplot
-Version: 4.4.1
-Release: 1
+Version: 4.6.4
+Release: 2
License: distributable (with modifications properly marked if any)
Group: Applications/Math
Source0: http://downloads.sourceforge.net/gnuplot/%{name}-%{version}.tar.gz
-# Source0-md5: 296e2904363e508bd8cb7e8ea1d267e8
+# Source0-md5: 2d8d1be8c8b7ee9e89b5003cbd8696ee
Source1: %{name}.desktop
Source2: %{name}.png
Patch0: %{name}-info.patch
Patch2: %{name}-lua.patch
Patch3: %{name}-wx-config.patch
URL: http://gnuplot.sourceforge.net/
-BuildRequires: autoconf >= 2.59-9
-BuildRequires: automake
-BuildRequires: cairo-devel
-BuildRequires: gd-devel
+%if %{with qt}
+BuildRequires: QtCore-devel >= 4.5
+BuildRequires: QtGui-devel >= 4.5
+BuildRequires: QtNetwork-devel >= 4.5
+BuildRequires: QtSvg-devel >= 4.5
+BuildRequires: qt4-build >= 4.5
+BuildRequires: qt4-linguist >= 4.5
+%endif
+BuildRequires: autoconf >= 2.60
+BuildRequires: automake >= 1:1.7.9
+BuildRequires: cairo-devel >= 1.6
+BuildRequires: gd-devel >= 2.0
BuildRequires: glib2-devel
-BuildRequires: gtk+2-devel
+BuildRequires: gtk+2-devel >= 2:2.8.0
+%{?with_ggi:BuildRequires: libggi-devel}
+# ???
+%{?with_ggixmi:BuildRequires: libggi-xmi-devel}
BuildRequires: libpng-devel >= 1.0.8
BuildRequires: libtool
BuildRequires: lua51-devel
BuildRequires: ncurses-devel
-BuildRequires: pango-devel
+BuildRequires: pango-devel > 1:1.10.2
+# which version? it needs PDF_create_gstate,PDF_set_gstate symbols
+%{?with_pdf:BuildRequires: pdflib-devel > 4.0.2}
BuildRequires: pkgconfig
BuildRequires: readline-devel
+# libvga, libvgagl, lib3dkit
+%{?with_svga:BuildRequires: svgalib-devel}
BuildRequires: texinfo
BuildRequires: texlive
BuildRequires: texlive-format-pdflatex
BuildRequires: texlive-latex
-BuildRequires: wxGTK2-unicode-devel
+BuildRequires: wxGTK2-unicode-devel >= 2.6
#BuildRequires: xemacs-lisp-programming
BuildRequires: xorg-lib-libX11-devel
BuildRequires: zlib-devel
даних в 2-х та 3-х вимірах та в багатьох різних форматах.
%package latex
-Summary: LaTeX files
+Summary: gnuplot support for LaTeX
+Summary(pl.UTF-8): Obsługa gnuplota dla LaTeXa
Group: Applications/Publishing/TeX
+# which subpackages? required tex packages: tikz,xxcolor,ifpdf,ifxetex
+Requires: texlive
%description latex
-LaTeX files.
+gnuplot support for LaTeX.
+
+%description latex -l pl.UTF-8
+Obsługa gnuplota dla LaTeXa.
%prep
%setup -q
%{__automake}
%configure \
- --with-readline=gnu \
--enable-history-file \
+ %{?with_qt:--enable-qt} \
+ %{?with_ggi:--with-ggi} \
+ %{?with_svga:--with-linux-vga} \
+ --with-readline=gnu \
--with-png \
--with-gd \
--with-x \
+ %{?with_ggixmi:--with-xmi} \
--without-lisp-files \
--without-linux-vga \
%{!?with_pdf:--without-pdf} \
- --without-tutorial
-
-# The source tarball incorrectly includes a file that should not be there.
-rm -f src/getcolor_x11.*
+ --without-tutorial \
+ --with-texdir=%{_datadir}/texmf-dist/tex/latex/gnuplot
%{__make}
cd docs
DESTDIR=$RPM_BUILD_ROOT \
appdefaultdir=%{_datadir}/X11/app-defaults
-mv $RPM_BUILD_ROOT%{_datadir}/texmf{,-dist}
-
%clean
rm -rf $RPM_BUILD_ROOT