From: Maximilian Friedersdorff Date: Thu, 18 Jul 2019 11:57:17 +0000 (+0100) Subject: media-gfx/graphviz: Add git version of graphviz X-Git-Url: https://git.friedersdorff.com/?a=commitdiff_plain;ds=inline;h=refs%2Fheads%2Fmaster;p=max%2Fgentoo-overlay.git media-gfx/graphviz: Add git version of graphviz Package-Manager: Portage-2.3.69, Repoman-2.3.16 Manifest-Sign-Key: BA1CE947376048A4B3C4D4E50B3B880CF5E7FCB3 --- diff --git a/media-gfx/graphviz/Manifest b/media-gfx/graphviz/Manifest new file mode 100644 index 0000000..fbe4d5e --- /dev/null +++ b/media-gfx/graphviz/Manifest @@ -0,0 +1,3 @@ +AUX graphviz-2.34.0-Xaw-configure.patch 2445 BLAKE2B fc1b3820fd72821ac431f5d93d0b4b0c8f596ca9d2c2f516961f5baab9fd54ba870df75434d2ed59fd9034bb7e2ce38c00faef9c12a79c7ec4da2d5e416d7117 SHA512 473d2ed9070329512cbc26929267b25fb8d7726e21ed01d2921d4d8ac13b8ffaf166f07229fa7409192cfa14fabb0cf68b299bb3331b3cc953ae5363274fd15c +EBUILD graphviz-9999.ebuild 7770 BLAKE2B 647ee10afae59893c94ee638d5ac02e3786c26adcc3d7a30bd519bf5c63a2326e6e4e6ca1055bf81bea241d7acc51c7a80d33c324a9834c508d4ed38c4194e83 SHA512 6a338cc60882d8a153c0e1087ebb6f149951434b4149265188e436114d22c4f0948f9580a48981cda3ecdb1d019f009b0ad37f2324869af50814f6a17b127722 +MISC metadata.xml 2154 BLAKE2B 6d4f465488af95c9b49dc6997bc1ea91f87ed83661eab81bf6287afde99ae75c0cdef1a0ee1b1d99269b7fa484aacdbed13e13bb4a79b196564e04872aea0832 SHA512 1063c868fd3d0b6ad636e24d5eb00be84b19ea23266e0cffdc8c1c8da86bfcf05d3f48f29540b6452a2d7485463108e0e91f8546c24e13f95da4ebfb3283cb43 diff --git a/media-gfx/graphviz/files/graphviz-2.34.0-Xaw-configure.patch b/media-gfx/graphviz/files/graphviz-2.34.0-Xaw-configure.patch new file mode 100644 index 0000000..2283cc5 --- /dev/null +++ b/media-gfx/graphviz/files/graphviz-2.34.0-Xaw-configure.patch @@ -0,0 +1,81 @@ +--- a/configure.ac ++++ b/configure.ac +@@ -560,8 +560,8 @@ + use_xlib="Yes" + #no x11.pc on centos4 + # PKG_CHECK_MODULES(X11, [x11]) +- PKG_CHECK_MODULES(XRENDER, [xrender],HAVE_XRENDER="yes" ,HAVE_XRENDER="no") + fi ++PKG_CHECK_MODULES(XRENDER, [xrender],HAVE_XRENDER="yes" ,HAVE_XRENDER="no") + AM_CONDITIONAL(WITH_X, [test "x$use_xlib" = "xYes"]) + AM_CONDITIONAL(WITH_XRENDER, [test "x$,HAVE_XRENDER" = "xyes"]) + +@@ -1924,6 +1924,10 @@ + # so we set HAVE_LIBXPMFORLEFTY instead of the usual HAVE_LIBXPM + # + ++AC_ARG_WITH(lefty, ++ [AS_HELP_STRING([--with-lefty=yes],[build lefty])], ++ [],[with_xaw=yes]) ++ + AC_ARG_WITH(Xpmincludedir, + [AS_HELP_STRING([--with-Xpmincludedir=DIR],[use Xpm includes from DIR])], + [XPM_INCLUDES="-I$withval"]) +@@ -1931,6 +1935,17 @@ + [AS_HELP_STRING([--with-Xpmlibdir=DIR],[use Xpm libraries from DIR])], + [XPM_LIBS="-L$withval"]) + ++AC_ARG_WITH(Xawincludedir, ++ [AS_HELP_STRING([--with-Xawincludedir=DIR],[use Xaw includes from DIR])], ++ [XAW_INCLUDES="-I$withval"]) ++AC_ARG_WITH(Xawlibdir, ++ [AS_HELP_STRING([--with-Xawlibdir=DIR],[use Xaw libraries from DIR])], ++ [XAW_LIBS="-L$withval"]) ++ ++if test "x$with_xaw" != "xyes"; then ++ use_lefty="No (disabled)" ++else ++ + save_CPPFLAGS=$CPPFLAGS + save_LDFLAGS=$LDFLAGS + CPPFLAGS="$CPPFLAGS $XPM_INCLUDES $X_CFLAGS" +@@ -1941,18 +1956,10 @@ + AC_MSG_WARN(Optional Xpm library not available), [-lXmu -lXt -lX11 -lXext $SOCKET_LIBS]) + LDFLAGS=$save_LDFLAGS + CPPFLAGS=$save_CPPFLAGS +-AC_SUBST([XPM_INCLUDES]) +-AC_SUBST([XPM_LIBS]) + + dnl ----------------------------------- + dnl INCLUDES and LIBS for XAW + +-AC_ARG_WITH(Xawincludedir, +- [AS_HELP_STRING([--with-Xawincludedir=DIR],[use Xaw includes from DIR])], +- [XAW_INCLUDES="-I$withval"]) +-AC_ARG_WITH(Xawlibdir, +- [AS_HELP_STRING([--with-Xawlibdir=DIR],[use Xaw libraries from DIR])], +- [XAW_LIBS="-L$withval"]) + save_CPPFLAGS=$CPPFLAGS + save_LDFLAGS=$LDFLAGS + CPPFLAGS="$CPPFLAGS $XAW_INCLUDES $X_CFLAGS" +@@ -1978,12 +1985,17 @@ + fi + LDFLAGS=$save_LDFLAGS + CPPFLAGS=$save_CPPFLAGS ++ ++fi ++ ++AC_SUBST([XPM_INCLUDES]) ++AC_SUBST([XPM_LIBS]) + AC_SUBST([XAW_INCLUDES]) + AC_SUBST([XAW_LIBS]) +-AM_CONDITIONAL(WITH_XAW, [test "x$with_xaw" != "xno"]) +-if test "x$with_xaw" = "xno"; then ++AM_CONDITIONAL(WITH_XAW, [test "x$with_xaw" = "xyes"]) ++if test "x$with_xaw" != "xyes"; then + if test "x$no_x" != "xyes"; then +- AC_MSG_WARN(Lefty cannot be built) ++ AC_MSG_WARN(Lefty will not be built) + fi + fi + diff --git a/media-gfx/graphviz/graphviz-9999.ebuild b/media-gfx/graphviz/graphviz-9999.ebuild new file mode 100644 index 0000000..d5d3eeb --- /dev/null +++ b/media-gfx/graphviz/graphviz-9999.ebuild @@ -0,0 +1,289 @@ +# Copyright 1999-2019 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 +PYTHON_COMPAT=( python2_7 ) + +inherit autotools flag-o-matic java-pkg-opt-2 python-single-r1 qmake-utils git-r3 + +DESCRIPTION="Open Source Graph Visualization Software" +HOMEPAGE="https://www.graphviz.org/ https://gitlab.com/graphviz/graphviz/" + +EGIT_REPO_URI="https://gitlab.com/graphviz/graphviz.git" +EGIT_SUBMODULES=() + +LICENSE="CPL-1.0" +SLOT="0" +KEYWORDS="" +IUSE="+cairo devil doc examples gdk-pixbuf gtk gts guile java lasi nls pdf perl postscript python qt5 ruby static-libs svg tcl X elibc_FreeBSD" + +REQUIRED_USE=" + !cairo? ( !X !gtk !postscript !lasi ) + python? ( ${PYTHON_REQUIRED_USE} )" + +# Requires ksh +RESTRICT="test" + +COMMON_DEPEND=" + >=dev-libs/expat-2 + >=dev-libs/glib-2.11.1:2 + dev-libs/libltdl:0 + >=media-libs/fontconfig-2.3.95 + >=media-libs/freetype-2.1.10 + >=media-libs/gd-2.0.34:=[fontconfig,jpeg,png,truetype,zlib] + >=media-libs/libpng-1.2:0 + sys-libs/zlib + virtual/jpeg:0 + virtual/libiconv + cairo? ( + >=x11-libs/cairo-1.1.10[svg] + >=x11-libs/pango-1.12 + ) + devil? ( media-libs/devil[png,jpeg] ) + gtk? ( x11-libs/gtk+:2 ) + gts? ( sci-libs/gts ) + lasi? ( media-libs/lasi ) + pdf? ( app-text/poppler ) + perl? ( dev-lang/perl:= ) + postscript? ( app-text/ghostscript-gpl ) + python? ( ${PYTHON_DEPS} ) + qt5? ( + dev-qt/qtcore:5 + dev-qt/qtgui:5 + dev-qt/qtprintsupport:5 + dev-qt/qtwidgets:5 + ) + ruby? ( dev-lang/ruby:* ) + svg? ( gnome-base/librsvg ) + tcl? ( >=dev-lang/tcl-8.3:0= ) + X? ( + x11-libs/libX11 + x11-libs/libXaw + x11-libs/libXmu + x11-libs/libXpm + x11-libs/libXt + )" +DEPEND="${COMMON_DEPEND} + sys-devel/flex + sys-devel/libtool + virtual/pkgconfig + guile? ( dev-lang/swig dev-scheme/guile ) + java? ( dev-lang/swig >=virtual/jdk-1.5 ) + nls? ( >=sys-devel/gettext-0.14.5 ) + perl? ( dev-lang/swig ) + python? ( dev-lang/swig ) + ruby? ( dev-lang/swig ) + tcl? ( dev-lang/swig )" +RDEPEND="${COMMON_DEPEND} + !<=sci-chemistry/cluster-1.3.081231" + +# Dependency description / Maintainer-Info: + +# Rendering is done via the following plugins (/plugins): +# - core, dot_layout, neato_layout, gd , dot +# the ones which are always compiled in, depend on zlib, gd +# - gtk +# Directly depends on gtk-2. +# needs 'pangocairo' enabled in graphviz configuration +# gtk-2 depends on pango, cairo and libX11 directly. +# - gdk-pixbuf +# Disabled, GTK-1 junk. +# - glitz +# Disabled, no particular reason +# needs 'pangocairo' enabled in graphviz configuration +# - ming +# flash plugin via -Tswf requires media-libs/ming-0.4. Disabled as it's +# incomplete. +# - cairo/pango: +# Needs pango for text layout, uses cairo methods to draw stuff +# - xlib: +# needs cairo+pango, +# can make use of gnomeui and inotify support (??? unsure), +# needs libXaw for UI +# UI also links directly against libX11, libXmu, and libXt +# and uses libXpm if available so we make sure it always is + +# There can be swig-generated bindings for the following languages (/tclpkg/gv): +# - c-sharp (disabled) +# - scheme (enabled via guile) ... no longer broken on ~x86 +# - io (disabled) +# - java (enabled via java) *2 +# - lua (enabled via lua) +# - ocaml (enabled via ocaml) +# - perl (enabled via perl) *1 +# - php (enabled via php) *2 +# - python (enabled via python) *1 +# - ruby (enabled via ruby) *1 +# - tcl (enabled via tcl) +# *1 = The ${P}-bindings.patch takes care that those bindings are installed to the right location +# *2 = Those bindings don't build because the paths for the headers/libs aren't +# detected correctly and/or the options passed to swig are wrong (-php instead of -php4/5) + +# There are several other tools in /tclpkg: +# gdtclft, tcldot, tclhandle, tclpathplan, tclstubs ; enabled with: --with-tcl +# tkspline, tkstubs ; enabled with: --with-tk + +# And the commands (/cmd): +# - dot, dotty, gvedit, gvpr, lefty, lneato, smyrna, tools/* :) +# sci-libs/gts can be used for some of these +# - lefty: +# needs Xaw and X to build +# - gvedit (via 'qt5'): +# based on ./configure it needs qt-core and qt-gui only +# - smyrna : experimental opengl front-end (via 'smyrna') +# currently disabled -- it segfaults a lot +# needs x11-libs/gtkglext, gnome-base/libglade, media-libs/freeglut +# sci-libs/gts, x11-libs/gtk. Also needs 'gtk','glade','glut','gts' and 'png' +# with flags enabled at configure time + +PATCHES=( + "${FILESDIR}"/${PN}-2.34.0-Xaw-configure.patch +) + +pkg_setup() { + use python && python-single-r1_pkg_setup + + java-pkg-opt-2_pkg_setup +} + +src_prepare() { + ./autogen.sh + + default + + # ToDo: Do the same thing for examples and/or + # write a patch for a configuration-option + # and send it to upstream + # note - the longer sed expression removes multi-line assignments that are extended via '\' + if ! use doc ; then + find . -iname Makefile.am \ + | xargs sed -i -e '/^\(html\|pdf\)_DATA.*\\[[:space:]]*$/{:m;N;s/\\\n//;tm;d}' \ + -e '/^\(html\|pdf\)_DATA/d' || die + fi + + # This is an old version of libtool + # use the ./configure option to exclude its use, and + # delete the dir since we don't need to eautoreconf it + rm -r libltdl || die + + # no nls, no gettext, no iconv macro, so disable it + if ! use nls ; then + sed -i -e '/^AM_ICONV/d' configure.ac || die + fi + + # Nuke the dead symlinks for the bindings + sed -i -e '/$(pkgluadir)/d' tclpkg/gv/Makefile.am || die + + # replace the whitespace with tabs + sed -i -e 's: :\t:g' doc/info/Makefile.am || die + + # use correct version of qmake. bug #567236 + sed -i -e "/AC_CHECK_PROGS(QMAKE/a AC_SUBST(QMAKE,$(qt5_get_bindir)/qmake)" configure.ac || die + + # workaround for http://www.graphviz.org/mantisbt/view.php?id=1895 + use elibc_FreeBSD && append-flags $(test-flags -fno-builtin-sincos) + + use java && append-cppflags $(java-pkg_get-jni-cflags) + + append-cxxflags -std=c++11 # bug 648764 + + eautoreconf +} + +src_configure() { + local myconf=( + --enable-ltdl + --disable-silent-rules + $(use_enable static-libs static) + ) + + # libtool file collision, bug 276609 + myconf+=( --without-included-ltdl --disable-ltdl-install ) + + myconf+=( + $(use_with cairo pangocairo) + $(use_with devil) + $(use_with gtk) + $(use_with gts) + $(use_with qt5 qt) + $(use_with lasi) + $(use_with pdf poppler) + $(use_with postscript ghostscript) + $(use_with svg rsvg) + $(use_with X x) + $(use_with X xaw) + $(use_with X lefty) + --with-digcola + --with-fontconfig + --with-freetype2 + --with-ipsepcola + --with-libgd + --with-sfdp + $(use_enable gdk-pixbuf) + --without-ming + ) + + # new/experimental features, to be tested, disable for now + myconf+=( + --with-cgraph + --without-glitz + --without-ipsepcola + --without-smyrna + --without-visio + ) + + # Bindings: + myconf+=( + $(use_enable guile) + --disable-io + $(use_enable java) + --disable-lua + --disable-ocaml + $(use_enable perl) + --disable-php + $(use_enable python) + --disable-r + $(use_enable ruby) + --disable-sharp + $(use_enable tcl) + ) + + econf ${myconf[@]} +} + +src_install() { + sed -i -e "s:htmldir:htmlinfodir:g" doc/info/Makefile || die + + emake DESTDIR="${D}" \ + txtdir="${EPREFIX}"/usr/share/doc/${PF} \ + htmldir="${EPREFIX}"/usr/share/doc/${PF}/html \ + htmlinfodir="${EPREFIX}"/usr/share/doc/${PF}/html/info \ + pdfdir="${EPREFIX}"/usr/share/doc/${PF}/pdf \ + pkgconfigdir="${EPREFIX}"/usr/$(get_libdir)/pkgconfig \ + install + + if ! use examples; then + rm -rf "${ED}"/usr/share/graphviz/demo || die + fi + + if ! use static-libs; then + find "${ED}" -name '*.la' -delete || die + fi + + dodoc AUTHORS ChangeLog NEWS README + + use python && python_optimize \ + "${D}$(python_get_sitedir)" \ + "${D}/usr/$(get_libdir)/graphviz/python" +} + +pkg_postinst() { + # This actually works if --enable-ltdl is passed + # to configure + dot -c || die +} + +pkg_postrm() { + # Remove cruft, bug #547344 + rm -rf "${EROOT}"usr/lib/graphviz/config{,6} || die +} diff --git a/media-gfx/graphviz/metadata.xml b/media-gfx/graphviz/metadata.xml new file mode 100644 index 0000000..8d0090a --- /dev/null +++ b/media-gfx/graphviz/metadata.xml @@ -0,0 +1,41 @@ + + + + + graphics@gentoo.org + Gentoo Graphics Project + + + graphviz is a set of graph drawing tools for Unix or MS-Windows + (win32), including a web service interface (webdot). Source code and + binary executables for common platforms are available. Graph drawing + addresses the problem of visualizing structural information by + constructing geometric representations of abstract graphs and networks. + Automatic generation of graph drawings has important applications in key + technologies such as database design, software engineering, VLSI and + network design and visual interfaces in other domains. Situations where + these tools might be particularly useful include: + + * you would like to restructure a program and first need to + understand the relationships between its types, procedures, and source + files. + * you need to find the bottlenecks in an Internet backbone - not + only individual links, but their relationships + * you're debugging a protocol or microarchitecture represented as a + finite state machine and need to figure out how a certain error state arises + * you would like to browse a database schema, knowledge base, or + distributed program represented pictorially + * you would like to see an overview of a collection of linked + documents + * you would like to discover patterns and communities of interest in + a database of telephone calls or e-mail messages + + + Enables DevIL output plugin -Tdevil + Enables gdk-pixbuf2 plugin + Enables gtk+ output plugin -Tgtk (needs cairo) + Enables support for gts + Enables PostScript output via media-libs/lasi, for plugin -Tlasi (needs cairo) + Builds lefty front-end, builds plugin -Txlib, and enables support for x11 in various other modules (needs cairo) + +