SHA256
1
0
forked from pool/graphviz
graphviz/graphviz.spec

269 lines
7.6 KiB
RPMSpec
Raw Normal View History

#
# spec file for package graphviz
#
# Copyright (c) 2013 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/
#
#name of the plugin config file that dot creates
%define config_file config6
Name: graphviz
- Update to 2.34.0 (see changes for graphviz), - Remove patches accepted upstream: graphviz-missing_headers.patch, graphviz-aarch64_lib64_support.patch, graphviz-type_punning.patch, graphviz-buffer_overflow.patch, graphviz-proper_prototypes.patch, graphviz-python_version.patch, graphviz-guile.patch, graphviz-java_in_lib64.patch - Update to 2.34.0: - Resolved bugs: * graphviz will hangs if only one point and attribute given (gvz#2326) * Inconsistent text position in xdot with HTML-like label (gvz#2333) * Graphviz createsedges not asked for, with rank=same (gvz#2334) * Graph padding rectangle too big (gvz#2337) * labelloc has no effect for HTML-like labels with formatting (gvz#2338) * Global search and replace operation in the documentation seems to have gone awry (gvz#2340) * Rotated graph not quite centered (gvz#2343) * When arrowType is list and contains none all subsequent arrowTypes are dropped (gvz#2345) * arrowType none when included as a multiple arrowtype fails to render empty space (gvz#2346) * Buffer overflow in lib/common/shapes.c(round_corners) (gvz#2349). * Add aarch64 to the architectures using lib64 (gvz#2350) * Ask guile-config for includes and libraries (gvz#2351). * If string.h present, don't declare memcmp and strcmp (gvz#2352). * Include ast_common.h in cdt sources (gvz#2353) * Alternative way to get python's version (gvz#2354) * Unportable test(1) construct in configure script (gvz#2357) * Use parantheses around qw() call in loop (gvz#2359) * Saving in Vimdot can crash the graphical window (rh#847458). OBS-URL: https://build.opensuse.org/package/show/graphics/graphviz?expand=0&rev=61
2013-09-09 15:44:08 +02:00
Version: 2.34.0
Release: 0
Summary: Graph Visualization Tools
License: IPL-1.0
Group: Productivity/Graphics/Visualization/Graph
Url: http://www.graphviz.org/
Source: http://www.graphviz.org/pub/graphviz/ARCHIVE/%{name}-%{version}.tar.gz
Source2: graphviz-rpmlintrc
Patch2: graphviz-fix-pkgIndex.patch
#PATCH-FIX-UPSTREAM There are too many type-punnings in the vmalloc sources
Patch3: graphviz-no_strict_aliasing.patch
#PATCH-FIX-UPSTREAM print can only be called as function in python3
Patch4: graphviz-python3_version.patch
BuildRequires: autoconf
BuildRequires: automake
BuildRequires: bison
BuildRequires: fdupes
BuildRequires: flex
BuildRequires: freeglut-devel
BuildRequires: freetype2-devel >= 2
BuildRequires: gcc-c++
BuildRequires: libXaw-devel
BuildRequires: libexpat-devel
BuildRequires: libjpeg-devel
BuildRequires: libpng-devel
BuildRequires: libstdc++-devel
BuildRequires: libtool
BuildRequires: zlib-devel
BuildRequires: pkgconfig(fontconfig)
BuildRequires: pkgconfig(glib-2.0)
BuildRequires: pkgconfig(ice)
BuildRequires: pkgconfig(sm)
BuildRequires: pkgconfig(x11)
BuildRequires: pkgconfig(xext)
Requires(pre): /bin/cat
Requires(pre): /bin/rm
Recommends: graphviz-gd = %{version}
Recommends: graphviz-gnome = %{version}
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
A collection of tools and tcl packages for the manipulation and layout
of graphs (as in nodes and edges, not as in bar charts).
%package devel
Summary: Graphiviz development package
Group: Development/Libraries/C and C++
Requires: %{name} = %{version}
Requires: expat
Requires: fontconfig-devel
Requires: freetype2-devel
Requires: glibc-devel
Requires: libjpeg-devel
Requires: libpng-devel
Requires: libstdc++-devel
Requires: libtool
Requires: perl
Requires: tcl-devel
Requires: tk-devel
Requires: zlib-devel
%description devel
The graphviz-devel package contains all that's necessary for developing
programs that use the graphviz libraries including man3 pages.
Note: If you need output in png format you also need to install
graphviz-gnome.
%prep
%setup -q
%patch2
%patch3
%patch4 -p1
# Fix path in generated man pages
sed -e 's$@LIB_DIR@$%{_libdir}$g' tclpkg/gv/gv_doc_langs.tcl >tclpkg/gv/gv_doc_langs.tcl.new && mv tclpkg/gv/gv_doc_langs.tcl.new tclpkg/gv/gv_doc_langs.tcl
%build
autoreconf -fi
WARN_FLAGS="-W -Wall -Wno-unused-parameter -Wno-unknown-pragmas -Wstrict-prototypes -Wpointer-arith"
CFLAGS="%{optflags} $WARN_FLAGS"
%ifarch %ix86 x86_64
CFLAGS="$CFLAGS -ffast-math"
%endif
export CFLAGS="$CFLAGS"
export CPPFLAGS="%{optflags}"
%configure \
--with-x \
--with-mylibgd \
--disable-static \
--enable-ltdl-install=no \
--with-ipsepcola \
--without-ming \
--disable-io \
--disable-silent-rules \
--with-mylibgd=no \
--with-libgd=no
make %{?_smp_mflags} DESTDIR=%{buildroot}
%install
make install \
DESTDIR=%{buildroot} \
docdir=%{buildroot}%{_docdir}/%{name} \
pkgconfigdir=%{_libdir}/pkgconfig
find %{buildroot} -type f -name "*.la" -print0 | xargs -0 rm -f
mkdir -p %{buildroot}/%{_docdir}
mkdir -p %{buildroot}%{_datadir}/%{name}
rm -f %{buildroot}/%{_libdir}/%{name}/pkgIndex.tcl
chmod -x %{buildroot}%{_datadir}/%{name}/lefty/*
cp -a %{buildroot}%{_datadir}/%{name}/doc __doc
rm -rf %{buildroot}%{_datadir}/%{name}/doc
mkdir -p %{buildroot}%{_libdir}/graphviz
touch %{buildroot}%{_libdir}/graphviz/config
mkdir -p %{buildroot}%{_sysconfdir}/ld.so.conf.d/
cat <<EOF >%{buildroot}%{_sysconfdir}/ld.so.conf.d/%{name}.conf
%{_libdir}/%{name}
%{_libdir}/%{name}/sharp
%{_libdir}/%{name}/java
%{_libdir}/%{name}/perl
%{_libdir}/%{name}/php
%{_libdir}/%{name}/ocaml
%{_libdir}/%{name}/python
%{_libdir}/%{name}/lua
%{_libdir}/%{name}/tcl
%{_libdir}/%{name}/guile
%{_libdir}/%{name}/ruby
EOF
#Correct the path to the shared library
for manfile in $(find %{buildroot} -name \*.man); do
sed -e 's$/usr/lib/graphviz$%{_libdir}/%{name}$g' $manfile > ${manfile}.new && mv ${manfile}.new ${manfile}
done
rm -f %{buildroot}%{_libdir}/graphviz/libgvplugin_gd.*
rm -f %{_libdir}/graphviz/libgvplugin_pango*
rm -f %{_libdir}/graphviz/libgvplugin_gdk_pixbuf*
rm -f %{_libdir}/graphviz/libgvplugin_gtk*
%post
/sbin/ldconfig
# run "dot -c" to generate plugin config %%{_libdir}/graphviz/config
dot -c
test -s %{_libdir}/graphviz/%{config_file} || echo "%{_libdir}/graphviz/%{config_file} doesn't exist! Check installation."
%postun
/sbin/ldconfig
if ! test -x $RPM_INSTALL_PREFIX0/bin/dot; then rm -f $RPM_INSTALL_PREFIX0/%{_lib}/graphviz/%{config_file}; fi
%files
%defattr(-,root,root)
%doc doc/FAQ.html AUTHORS COPYING README NEWS ChangeLog
#%%attr(755,root,root) %{_bindir}/*
%{_bindir}/acyclic
%{_bindir}/bcomps
%{_bindir}/ccomps
%{_bindir}/circo
%{_bindir}/cluster
%{_bindir}/dijkstra
%{_bindir}/dot
%{_bindir}/dot2gxl
%{_bindir}/dot_builtins
%{_bindir}/dotty
%{_bindir}/fdp
%{_bindir}/gc
%{_bindir}/gml2gv
%{_bindir}/graphml2gv
%{_bindir}/gv2gml
%{_bindir}/gv2gxl
%{_bindir}/gvcolor
%{_bindir}/gvgen
%{_bindir}/gvmap
%{_bindir}/gvmap.sh
%{_bindir}/gvpack
%{_bindir}/gvpr
%{_bindir}/gxl2dot
%{_bindir}/gxl2gv
%{_bindir}/lefty
%{_bindir}/lneato
%{_bindir}/mm2gv
%{_bindir}/neato
%{_bindir}/nop
%{_bindir}/osage
%{_bindir}/patchwork
%{_bindir}/prune
%{_bindir}/sccmap
%{_bindir}/sfdp
%{_bindir}/tred
%{_bindir}/twopi
%{_bindir}/unflatten
%dir %{_datadir}/%{name}
%{_datadir}/%{name}/lefty
%{_datadir}/%{name}/graphs
%dir %{_datadir}/%{name}/gvpr
%{_datadir}/%{name}/gvpr/addranks
%{_datadir}/%{name}/gvpr/addrings
%{_datadir}/%{name}/gvpr/anon
%{_datadir}/%{name}/gvpr/attr
%{_datadir}/%{name}/gvpr/bb
%{_datadir}/%{name}/gvpr/bbox
%{_datadir}/%{name}/gvpr/cliptree
%{_datadir}/%{name}/gvpr/col
%{_datadir}/%{name}/gvpr/collapse
%{_datadir}/%{name}/gvpr/color
%{_datadir}/%{name}/gvpr/dechain
%{_datadir}/%{name}/gvpr/deghist
%{_datadir}/%{name}/gvpr/deledges
%{_datadir}/%{name}/gvpr/delmulti
%{_datadir}/%{name}/gvpr/delnodes
%{_datadir}/%{name}/gvpr/depath
%{_datadir}/%{name}/gvpr/dijkstra
%{_datadir}/%{name}/gvpr/flatten
%{_datadir}/%{name}/gvpr/get-layers-list
%{_datadir}/%{name}/gvpr/group
%{_datadir}/%{name}/gvpr/indent
%{_datadir}/%{name}/gvpr/knbhd
%{_datadir}/%{name}/gvpr/maxdeg
%{_datadir}/%{name}/gvpr/path
%{_datadir}/%{name}/gvpr/rotate
%{_datadir}/%{name}/gvpr/scale
%{_datadir}/%{name}/gvpr/scalexy
%{_datadir}/%{name}/gvpr/span
%{_datadir}/%{name}/gvpr/topon
%{_datadir}/%{name}/gvpr/treetoclust
%doc %{_mandir}/man1/*.1*
%doc %{_mandir}/man7/*.7*
%dir %{_libdir}/%{name}
%{_libdir}/*.so.*
%{_libdir}/graphviz/*.so*
%config %{_sysconfdir}/ld.so.conf.d/graphviz.conf
%ghost %{_libdir}/graphviz/config
%files devel
%defattr(-,root,root)
%{_includedir}/graphviz
%{_libdir}/*.so
%{_libdir}/pkgconfig/*.pc
%{_mandir}/man3/*.3.gz
%changelog