pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

graphviz: Import version 9.0.0



Module Name:	pkgsrc-wip
Committed By:	Michael Baeuerle <micha%NetBSD.org@localhost>
Pushed By:	micha
Date:		Wed Oct 11 19:07:30 2023 +0200
Changeset:	846315ac654201b95cb73221dabb3944aaf97b55

Modified Files:
	Makefile
Added Files:
	graphviz/DEINSTALL
	graphviz/DESCR
	graphviz/INSTALL
	graphviz/Makefile
	graphviz/PLIST
	graphviz/buildlink3.mk
	graphviz/distinfo
	graphviz/options.mk
	graphviz/patches/patch-config_config__perl.pl
	graphviz/patches/patch-configure.ac
	graphviz/patches/patch-lib_gvc_Makefile.am
	graphviz/patches/patch-plugin_gs_gvloadimage__gs.c
	graphviz/patches/patch-plugin_xlib_gvdevice__xlib.c

Log Message:
graphviz: Import version 9.0.0

- On non-Windows platforms, new `-Tkitty` and `-Tkittyz` output formats are
  available that render to the Kitty terminal emulator’s graphvics protocol.
- HTML/CSS-style 3 letter hex colors are supported. Each R/G/B letter is
  duplicated to form a 6 letter hex color. E.g. `#09c` is equivalent to
  `#0099cc`. #2377

- **Breaking**: The definition of `adjmatrix_t` is no longer exposed in public
  headers.
- **Breaking**: The upper limit for minimum edge length (`Agedgeinfo_t.minlen`)
  has been expanded from `USHRT_MAX` to `INT_MAX`. #2413
- **Breaking**: The libcdt macros `DTTREEMATCH`, `DTTREESEARCH`, `dtvnext`,
  `dtvcount`, `dtvhere`, and `dtcharhash` have been removed.
- **Breaking**: The libcgraph macros `AGHEADPOINTER`, `AGRIGHTPOINTER`,
  `AGLEFTPOINTER`, `FIRSTNREF`, `NEXTNREF`, `PREVNREF`, `LASTNREF`, `NODEOF`,
  `FIRSTOUTREF`, `LASTOUTREF`, `FIRSTINREF`, `NEXTEREF`, and `PREVEREF` have
  been removed.
- **Breaking**: The libcgraph types `Agnoderef_t` and `Agedgeref_t` have been
  removed.
- **Breaking**: The libcgraph function `agflatten` has been removed.
- **Breaking**: The `Agdesc_s.flatlock` field has been removed.
- **Breaking**: The `str` parameter from `gvPluginList` has been removed.
- **Breaking**: The definition of the `elist_append` and `alloc_elist` macros
  have been changed to use newer allocation functions. Users were/are not
  expected to call these macros.
- The functions `ageqedge`, `agtail`, `aghead`, `agopp`, `agmkout`, and `agmkin`
  have been reintroduced. These were previously removed in Graphviz 3.0.0. #2433
- **Breaking**: The first parameter `dt` to the `makef` and `freef` callbacks
  defined in cdt.h has been removed.
- Gvedit now identifies itself with organization name “Graphviz” and application
  name “gvedit” when reading and writing Qt-based settings. It would previously
  use organization name “Trolltech” and application name “MDI Example”. If you
  have existing settings under the old identification, Gvedit will attempt to
  migrate them to the new identification the first time it reads then writes
  settings. #2383
- **Breaking**: `gvprintf` is now tagged with
  `__attribute__((format(printf, …)))` when compiling with Clang or GCC. This
  enables the compiler to spot more misuses of this function. #2373
- **Breaking**: The `hashf` and `eventf` members of `Dtdisc_t` have been
  removed. Correspondingly, the `hshf` and `evf` parameters to the `DTDISC`
  macro have been removed. Also the `_DTHSH` macro has been removed.
- **Breaking**: The `Dtdata_t.minp` field has been removed.
- The print functionality of the macOS Graphviz app scales the graph to fit the
  output page size.
- **Breaking**: The libcdt containers `Dtbag`, `Dthash`, `Dtlist`, `Dtorder`,
  `Dtdeque`, and `Dtstack` have been removed.
- **Breaking**: The libcdt `dtappend` and `dtattach`  macros have been removed.
- Support for Lua 5.0 has been removed. Building the Graphviz Lua bindings now
  requires Lua ≥ 5.1.
- **Breaking**: The `Dt_t*` parameter to the callback for `dtwalk` has been
  removed.
- **Breaking**: The `POINTS_PER_PC` macro has been removed.
- **Breaking**: The `INITIAL_XDOT_CAPACITY` macro has been removed.
- **Breaking**: The `type` parameter to `dtdisc` has been removed.
- **Breaking**: The `h` parameter to `dtstrhash` has been removed.
- In addition to Guile 2.0 and Guile 2.2, Guile 3.0 is now supported by the
  Graphviz Guile bindings.
- **Breaking**: The concept of “memory allocator discipline” has been removed,
  along with the type `Agmemdisc_t` and fields `Agdisc_t.mem` and
  `Agdstate_t.mem`.
- **Breaking**: The `agcallbacks` function and `Agclos_t.callbacks_enabled` have
  been removed.
- **Breaking**: `pack_info.doSplines` is now a C99 `bool`. Correspondingly, the
  `doSplines` parameter to `shiftGraphs` is now a C99 `bool`.

- Processing large graphs that induce ranks containing more than 46340
  (`floor(√INT_MAX)`) nodes no longer results in an integer overflow during
  crossing matrix allocation. Ranks of up to `floor(√SIZE_MAX)` nodes are now
  supported.
- Double arrow head types like `invdot` and `onormalonormal` once again display
  correctly. This was a regression in Graphviz 8.0.1. #2406
- The `lvee` and `rvee` edge arrow shapes are slighty incorrect for
  penwidths &gt; 1. #2399
- Small gap between `lcurve` or `rcurve` arrow shaft and node. #2426
- Failure of arrowhead and arrowtail to respect penwidth #372 \
  Fixed also for the `crow` and `vee`
  [edge arrow shapes](https://graphviz.org/doc/info/arrows.html#primitive-shapes)
  and [record based nodes](https://graphviz.org/doc/info/shapes.html#record).
- Various incorrect calls to `gvprintf` have been corrected. On some platforms
  like x86-64, these problems were benign thanks to coincidences in the
  Application Binary Interface (ABI). On other platforms, these problems may
  have caused stack corruption and crashes. #2373
- The font dictionary is now initialized even if a configuration file is not
  found. Previously this situation could lead to a crash when using Graphviz
  programmatically. This problem was present as least as far back as Graphviz
  2.38.0. #1520
- **Breaking**: The `vt100` output format has been renamed to `vt`. This fixes a
  problem where it was not discoverable on macOS. #2429
- Escape sequences like `\"` are recognized in strings and double escaping
  (producing `\\"`) is avoided. #2397
- The Autotools build system no longer uses headers and libraries from the
  `--prefix` path given on the command line. This previously caused
  cross-compilation to incorrectly pick up host headers and libraries. #2442

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=846315ac654201b95cb73221dabb3944aaf97b55

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 Makefile                                           |   1 +
 graphviz/DEINSTALL                                 |   9 +
 graphviz/DESCR                                     |  10 +
 graphviz/INSTALL                                   |   9 +
 graphviz/Makefile                                  | 142 +++++++++
 graphviz/PLIST                                     | 316 +++++++++++++++++++++
 graphviz/buildlink3.mk                             |  20 ++
 graphviz/distinfo                                  |  10 +
 graphviz/options.mk                                | 140 +++++++++
 graphviz/patches/patch-config_config__perl.pl      |  15 +
 graphviz/patches/patch-configure.ac                |  87 ++++++
 graphviz/patches/patch-lib_gvc_Makefile.am         |  15 +
 graphviz/patches/patch-plugin_gs_gvloadimage__gs.c |  33 +++
 .../patches/patch-plugin_xlib_gvdevice__xlib.c     |  16 ++
 14 files changed, 823 insertions(+)

diffs:
diff --git a/Makefile b/Makefile
index 151b111ba0..9b83cf132e 100644
--- a/Makefile
+++ b/Makefile
@@ -1390,6 +1390,7 @@ SUBDIR+=	gramscii
 SUBDIR+=	grandr
 SUBDIR+=	granite
 SUBDIR+=	graphmonkey
+SUBDIR+=	graphviz
 SUBDIR+=	grass-Spearfish
 SUBDIR+=	graveman
 SUBDIR+=	grc
diff --git a/graphviz/DEINSTALL b/graphviz/DEINSTALL
new file mode 100644
index 0000000000..c747484fad
--- /dev/null
+++ b/graphviz/DEINSTALL
@@ -0,0 +1,9 @@
+# $NetBSD: DEINSTALL,v 1.2 2009/05/17 12:55:52 sno Exp $
+
+: ${PKG_PREFIX=@PREFIX@}
+
+case ${STAGE} in
+DEINSTALL)
+	${RM} ${PKG_PREFIX}/lib/graphviz/config6
+	;;
+esac
diff --git a/graphviz/DESCR b/graphviz/DESCR
new file mode 100644
index 0000000000..0f0918af1c
--- /dev/null
+++ b/graphviz/DESCR
@@ -0,0 +1,10 @@
+Graphviz is a set of graph drawing tools from AT&T Research and Lucent Bell
+Laboratories.
+
+It includes:
+- dot: makes hierarchical layouts of directed graphs
+- neato: makes "spring" model layouts of undirected graphs
+- tcldot: a customizable graphical interface written in TCL
+  (part of "tcl" option)
+- libcgraph: the base library for graph tools
+- various associated utilities
diff --git a/graphviz/INSTALL b/graphviz/INSTALL
new file mode 100644
index 0000000000..fe5def208f
--- /dev/null
+++ b/graphviz/INSTALL
@@ -0,0 +1,9 @@
+# $NetBSD: INSTALL,v 1.1 2007/09/21 17:40:38 joerg Exp $
+
+: ${PKG_PREFIX=@PREFIX@}
+
+case ${STAGE} in
+POST-INSTALL)
+	${PKG_PREFIX}/bin/dot -c
+	;;
+esac
diff --git a/graphviz/Makefile b/graphviz/Makefile
new file mode 100644
index 0000000000..0319d9b873
--- /dev/null
+++ b/graphviz/Makefile
@@ -0,0 +1,142 @@
+# $NetBSD$
+
+DISTNAME=	graphviz-9.0.0
+CATEGORIES=	graphics
+MASTER_SITES=	${MASTER_SITE_GITLAB:=api/v4/projects/4207231/packages/generic/graphviz-releases/${PKGVERSION_NOREV}/}
+EXTRACT_SUFX=	.tar.xz
+
+MAINTAINER=	micha%NetBSD.org@localhost
+HOMEPAGE=	https://www.graphviz.org/
+COMMENT=	Graph Drawing Programs from AT&T Research and Lucent Bell Labs
+LICENSE=	epl-v1.0
+
+CHECK_FILES_SKIP+=		${PREFIX}/lib/graphviz/config6
+CHECK_PORTABILITY_SKIP+=	windows/*
+
+USE_LANGUAGES=		c c++
+USE_CC_FEATURES+=	c99
+USE_CXX_FEATURES+=	c++11 unique_ptr
+
+USE_TOOLS+=		automake autoreconf makeinfo bison flex gmake groff pkg-config
+USE_LIBTOOL=		yes
+GNU_CONFIGURE=		yes
+GNU_CONFIGURE_STRICT=	no # has sub-configures
+CONFIGURE_ARGS+=	--disable-d
+CONFIGURE_ARGS+=	--disable-debug
+CONFIGURE_ARGS+=	--disable-go
+CONFIGURE_ARGS+=	--disable-guile
+CONFIGURE_ARGS+=	--disable-io
+CONFIGURE_ARGS+=	--disable-java
+CONFIGURE_ARGS+=	--disable-javascript
+CONFIGURE_ARGS+=	--disable-man-pdfs
+CONFIGURE_ARGS+=	--disable-ocaml
+CONFIGURE_ARGS+=	--disable-php
+CONFIGURE_ARGS+=	--disable-python
+CONFIGURE_ARGS+=	--disable-python3
+CONFIGURE_ARGS+=	--disable-r
+CONFIGURE_ARGS+=	--disable-ruby
+CONFIGURE_ARGS+=	--disable-sharp
+CONFIGURE_ARGS+=	--enable-ltdl
+CONFIGURE_ARGS+=	--enable-rpath
+CONFIGURE_ARGS+=	--without-ann
+CONFIGURE_ARGS+=	--without-devil
+CONFIGURE_ARGS+=	--without-gdiplus
+CONFIGURE_ARGS+=	--without-glade
+CONFIGURE_ARGS+=	--without-glitz
+CONFIGURE_ARGS+=	--without-glut
+CONFIGURE_ARGS+=	--without-gtkgl
+CONFIGURE_ARGS+=	--without-gtkglext
+CONFIGURE_ARGS+=	--without-lasi
+CONFIGURE_ARGS+=	--without-ming
+CONFIGURE_ARGS+=	--without-qt
+CONFIGURE_ARGS+=	--without-smyrna
+CONFIGURE_ARGS+=	--with-digcola
+CONFIGURE_ARGS+=	--with-expat
+CONFIGURE_ARGS+=	--with-fontconfig
+CONFIGURE_ARGS+=	--with-freetype2
+CONFIGURE_ARGS+=	--with-gts
+CONFIGURE_ARGS+=	--with-ipsepcola
+CONFIGURE_ARGS+=	--with-ortho
+CONFIGURE_ARGS+=	--with-pangocairo
+CONFIGURE_ARGS+=	--with-sfdp
+CONFIGURE_ARGS+=	--with-visio
+CONFIGURE_ARGS+=	--with-webp
+# build fails when PHP and/or Ruby are also installed
+CONFIGURE_ENV+=		ac_cv_prog_PHP=
+CONFIGURE_ENV+=		ac_cv_prog_RUBY=
+
+CPPFLAGS+=		-DNO_POSTSCRIPT_ALIAS=1
+LDFLAGS.SunOS+=		-lsocket -lnsl
+
+PKGCONFIG_OVERRIDE+=	lib/cdt/libcdt.pc.in
+PKGCONFIG_OVERRIDE+=	lib/cgraph/libcgraph.pc.in
+PKGCONFIG_OVERRIDE+=	lib/edgepaint/liblab_gamut.pc.in
+PKGCONFIG_OVERRIDE+=	lib/expr/libexpr.pc.in
+PKGCONFIG_OVERRIDE+=	lib/gvc/libgvc.pc.in
+PKGCONFIG_OVERRIDE+=	lib/gvpr/libgvpr.pc.in
+PKGCONFIG_OVERRIDE+=	lib/pack/libpack.pc.in
+PKGCONFIG_OVERRIDE+=	lib/pathplan/libpathplan.pc.in
+PKGCONFIG_OVERRIDE+=	lib/sfdpgen/libsfdp.pc.in
+PKGCONFIG_OVERRIDE+=	lib/xdot/libxdot.pc.in
+
+# With lua51 there's a PLIST divergence and it isn't obvious whether
+# it's serious or not, or what causes it.
+LUA_VERSIONS_INCOMPATIBLE=	51
+
+REPLACE_LUA+=		tclpkg/gv/demo/modgraph.lua
+
+REPLACE_INTERPRETER+=	tclsh
+REPLACE.tclsh.old=	.*tclsh
+REPLACE.tclsh.new=	${PREFIX}/bin/tclsh
+REPLACE_FILES.tclsh=	tclpkg/gv/demo/modgraph.tcl
+
+REPLACE_PERL+=		tclpkg/gv/demo/modgraph.pl contrib/dotmcl.pl \
+			contrib/dirgraph/dirgraph.pl
+
+.include "../../mk/bsd.prefs.mk"
+
+# Override Xaw type configured by user
+XAW_TYPE=		standard
+
+.if (${OPSYS} == "NetBSD" && ${MACHINE_ARCH} == "powerpc")
+# Forces link with -lgomp directly instead of via dlopen()
+# so we don't overflow thread-local storage in ld.elf_so
+CFLAGS+=		-fopenmp
+CONFIGURE_ARGS+=	CFLAGS="${CFLAGS}"
+.endif
+
+.if ${OPSYS} == "FreeBSD"
+SUBST_CLASSES+=		sfflags
+SUBST_STAGE.sfflags=	pre-configure
+SUBST_MESSAGE.sfflags=	Fixing SF_FLAGS identifier for FreeBSD.
+SUBST_FILES.sfflags=	lib/sfio/sfclrlock.c lib/sfio/sfio_t.h lib/sfio/sfio.h
+SUBST_FILES.sfflags+=	lib/sfio/sfnew.c lib/sfio/sfopen.c lib/sfio/sfset.c
+SUBST_SED.sfflags=	-e 's|SF_FLAGS|SFIO_FLAGS|g'
+.endif
+
+pre-configure:
+	cd ${WRKSRC} && autoreconf -fiv
+
+# Remove temporary files and directories created by re-linking "libgv_lua.la".
+post-install:
+	${RM} -rf ${DESTDIR}${PREFIX}/lib/graphviz/lua/gv.so \
+		${DESTDIR}${PREFIX}/lib/graphviz/tcl/tcl \
+		${DESTDIR}${PREFIX}/lib/lua/5.1/gv.so
+
+.include "options.mk"
+
+DEPENDS+=	urw-fonts-[0-9]*:../../fonts/urw-fonts
+
+.include "../../converters/libiconv/buildlink3.mk"
+.include "../../devel/gettext-lib/buildlink3.mk"
+.include "../../devel/libltdl/buildlink3.mk"
+BUILDLINK_API_DEPENDS.pango+=	pango>=1.22.0
+.include "../../devel/pango/buildlink3.mk"
+.include "../../fonts/fontconfig/buildlink3.mk"
+.include "../../graphics/freetype2/buildlink3.mk"
+.include "../../graphics/gts/buildlink3.mk"
+.include "../../graphics/libwebp/buildlink3.mk"
+.include "../../mk/pthread.buildlink3.mk"
+.include "../../textproc/expat/buildlink3.mk"
+
+.include "../../mk/bsd.pkg.mk"
diff --git a/graphviz/PLIST b/graphviz/PLIST
new file mode 100644
index 0000000000..37193cd609
--- /dev/null
+++ b/graphviz/PLIST
@@ -0,0 +1,316 @@
+@comment $NetBSD: PLIST,v 1.60 2023/07/07 13:38:11 micha Exp $
+bin/acyclic
+bin/bcomps
+bin/ccomps
+bin/circo
+bin/cluster
+${PLIST.gd}bin/diffimg
+bin/dijkstra
+bin/dot
+bin/dot2gxl
+bin/dot_builtins
+bin/edgepaint
+bin/fdp
+bin/gc
+bin/gml2gv
+bin/graphml2gv
+bin/gv2gml
+bin/gv2gxl
+bin/gvcolor
+bin/gvgen
+bin/gvmap
+bin/gvmap.sh
+bin/gvpack
+bin/gvpr
+bin/gxl2dot
+bin/gxl2gv
+bin/mm2gv
+bin/neato
+bin/nop
+bin/osage
+bin/patchwork
+bin/prune
+bin/sccmap
+bin/sfdp
+bin/tred
+bin/twopi
+bin/unflatten
+${PLIST.x11}bin/vimdot
+include/graphviz/arith.h
+include/graphviz/cdt.h
+include/graphviz/cgraph.h
+include/graphviz/color.h
+include/graphviz/geom.h
+include/graphviz/graphviz_version.h
+include/graphviz/gv.cpp
+include/graphviz/gv.i
+include/graphviz/gvc.h
+include/graphviz/gvcext.h
+include/graphviz/gvcjob.h
+include/graphviz/gvcommon.h
+include/graphviz/gvconfig.h
+include/graphviz/gvplugin.h
+include/graphviz/gvplugin_device.h
+include/graphviz/gvplugin_layout.h
+include/graphviz/gvplugin_loadimage.h
+include/graphviz/gvplugin_render.h
+include/graphviz/gvplugin_textlayout.h
+include/graphviz/gvpr.h
+include/graphviz/pack.h
+include/graphviz/pathgeom.h
+include/graphviz/pathplan.h
+include/graphviz/textspan.h
+include/graphviz/types.h
+include/graphviz/usershape.h
+include/graphviz/xdot.h
+lib/graphviz/libgvplugin_core.la
+lib/graphviz/libgvplugin_dot_layout.la
+${PLIST.gd}lib/graphviz/libgvplugin_gd.la
+${PLIST.gtk}lib/graphviz/libgvplugin_gdk.la
+${PLIST.ghostscript}${PLIST.x11}lib/graphviz/libgvplugin_gs.la
+${PLIST.gtk}lib/graphviz/libgvplugin_gtk.la
+lib/graphviz/libgvplugin_neato_layout.la
+lib/graphviz/libgvplugin_pango.la
+${PLIST.poppler}lib/graphviz/libgvplugin_poppler.la
+${PLIST.quartz}lib/graphviz/libgvplugin_quartz.la
+${PLIST.svg}lib/graphviz/libgvplugin_rsvg.la
+lib/graphviz/libgvplugin_vt100.la
+lib/graphviz/libgvplugin_webp.la
+${PLIST.x11}lib/graphviz/libgvplugin_xlib.la
+${PLIST.lua}lib/graphviz/lua/libgv_lua.la
+${PLIST.perl}lib/graphviz/perl/gv.pm
+${PLIST.perl}lib/graphviz/perl/gv.so
+${PLIST.perl}lib/graphviz/perl/libgv_perl.la
+${PLIST.tcl}${PLIST.x11}lib/graphviz/tcl/libgdtclft.la
+${PLIST.tcl}lib/graphviz/tcl/libgv_tcl.la
+${PLIST.tcl}lib/graphviz/tcl/libtcldot.la
+${PLIST.tcl}lib/graphviz/tcl/libtcldot_builtin.la
+${PLIST.tcl}lib/graphviz/tcl/libtclplan.la
+${PLIST.tcl}lib/graphviz/tcl/pkgIndex.tcl
+lib/libcdt.la
+lib/libcgraph.la
+lib/libgvc.la
+lib/libgvpr.la
+lib/liblab_gamut.la
+lib/libpathplan.la
+lib/libxdot.la
+${PLIST.lua}lib/lua/gv.so
+${PLIST.perl}${PERL5_SUB_INSTALLVENDORARCH}/gv.pm
+${PLIST.perl}${PERL5_SUB_INSTALLVENDORARCH}/gv.so
+lib/pkgconfig/libcdt.pc
+lib/pkgconfig/libcgraph.pc
+lib/pkgconfig/libgvc.pc
+lib/pkgconfig/libgvpr.pc
+lib/pkgconfig/liblab_gamut.pc
+lib/pkgconfig/libpathplan.pc
+lib/pkgconfig/libxdot.pc
+${PLIST.tcl}${PLIST.x11}lib/tcl${TCL_BASEVER}/graphviz/libgdtclft.la
+${PLIST.tcl}lib/tcl${TCL_BASEVER}/graphviz/libgv_tcl.la
+${PLIST.tcl}lib/tcl${TCL_BASEVER}/graphviz/libtcldot.la
+${PLIST.tcl}lib/tcl${TCL_BASEVER}/graphviz/libtcldot_builtin.la
+${PLIST.tcl}lib/tcl${TCL_BASEVER}/graphviz/libtclplan.la
+${PLIST.tcl}lib/tcl${TCL_BASEVER}/graphviz/pkgIndex.tcl
+man/man1/acyclic.1
+man/man1/bcomps.1
+man/man1/ccomps.1
+man/man1/circo.1
+man/man1/cluster.1
+${PLIST.gd}man/man1/diffimg.1
+man/man1/dijkstra.1
+man/man1/dot.1
+man/man1/dot2gxl.1
+man/man1/edgepaint.1
+man/man1/fdp.1
+man/man1/gc.1
+man/man1/gml2gv.1
+man/man1/graphml2gv.1
+man/man1/gv2gml.1
+man/man1/gv2gxl.1
+man/man1/gvcolor.1
+man/man1/gvgen.1
+man/man1/gvmap.1
+man/man1/gvmap.sh.1
+man/man1/gvpack.1
+man/man1/gvpr.1
+man/man1/gxl2dot.1
+man/man1/gxl2gv.1
+man/man1/mm2gv.1
+man/man1/neato.1
+man/man1/nop.1
+man/man1/osage.1
+man/man1/patchwork.1
+man/man1/prune.1
+man/man1/sccmap.1
+man/man1/sfdp.1
+man/man1/tred.1
+man/man1/twopi.1
+man/man1/unflatten.1
+${PLIST.x11}man/man1/vimdot.1
+man/man3/cdt.3
+man/man3/cgraph.3
+man/man3/expr.3
+${PLIST.tcl}${PLIST.gd}man/man3/gdtclft.3tcl
+${PLIST.lua}man/man3/gv.3lua
+${PLIST.perl}man/man3/gv.3perl
+${PLIST.swig}man/man3/gv.3python
+${PLIST.tcl}man/man3/gv.3tcl
+man/man3/gvc.3
+man/man3/gvpr.3
+man/man3/pack.3
+man/man3/pathplan.3
+${PLIST.tcl}man/man3/tcldot.3tcl
+man/man3/xdot.3
+man/man7/graphviz.7
+share/doc/graphviz/AUTHORS
+share/doc/graphviz/Agraph.pdf
+share/doc/graphviz/CHANGELOG.md
+share/doc/graphviz/COPYING
+share/doc/graphviz/Dot.ref
+share/doc/graphviz/FAQ.html
+share/doc/graphviz/NEWS
+share/doc/graphviz/build.html
+share/doc/graphviz/char.html
+share/doc/graphviz/cpl1.0.txt
+share/doc/graphviz/dotguide.pdf
+share/doc/graphviz/gdtclft.entities.example.png
+share/doc/graphviz/index.html
+share/doc/graphviz/info/arrows.html
+share/doc/graphviz/info/attrs.html
+share/doc/graphviz/info/colors.html
+share/doc/graphviz/info/command.html
+share/doc/graphviz/info/index.html
+share/doc/graphviz/info/lang.html
+share/doc/graphviz/info/output.html
+share/doc/graphviz/info/shapes.html
+share/doc/graphviz/internal_todo.html
+share/doc/graphviz/latex_suggestions.txt
+share/doc/graphviz/libguide.pdf
+share/doc/graphviz/neatoguide.pdf
+share/doc/graphviz/pspdf.png
+share/doc/graphviz/schema/arguments.xml
+share/doc/graphviz/schema/attributes.xml
+share/doc/graphviz/schema/attributes.xslt
+${PLIST.tcl}share/doc/graphviz/tcldot.html
+share/doc/graphviz/todo.html
+share/doc/graphviz/winbuild.html
+${PLIST.tcl}share/graphviz/demo/doted.tcl
+${PLIST.tcl}share/graphviz/demo/doted.tcl.README
+${PLIST.tcl}share/graphviz/demo/entities.html
+${PLIST.tcl}share/graphviz/demo/entities.tcl
+${PLIST.tcl}share/graphviz/demo/entities.tcl.README
+${PLIST.tcl}share/graphviz/demo/gcat.tcl
+${PLIST.tcl}share/graphviz/demo/gcat.tcl.README
+${PLIST.lua}share/graphviz/demo/modgraph.lua
+${PLIST.perl}share/graphviz/demo/modgraph.pl
+${PLIST.tcl}share/graphviz/demo/modgraph.tcl
+${PLIST.tcl}share/graphviz/demo/pathplan.tcl
+${PLIST.tcl}share/graphviz/demo/pathplan.tcl.README
+${PLIST.tcl}share/graphviz/demo/pathplan_data/boxes.dat
+${PLIST.tcl}share/graphviz/demo/pathplan_data/dpd.dat
+${PLIST.tcl}share/graphviz/demo/pathplan_data/funny.dat
+${PLIST.tcl}share/graphviz/demo/pathplan_data/maze.dat
+${PLIST.tcl}share/graphviz/demo/pathplan_data/nested.dat
+${PLIST.tcl}share/graphviz/demo/pathplan_data/northo.dat
+${PLIST.tcl}share/graphviz/demo/pathplan_data/obs.dat
+${PLIST.tcl}share/graphviz/demo/pathplan_data/other.dat
+${PLIST.tcl}share/graphviz/demo/pathplan_data/paths.dat
+${PLIST.tcl}share/graphviz/demo/pathplan_data/rotor.dat
+${PLIST.tcl}share/graphviz/demo/pathplan_data/u.dat
+${PLIST.tcl}share/graphviz/demo/pathplan_data/unknown.dat
+share/graphviz/graphs/directed/KW91.gv
+share/graphviz/graphs/directed/Latin1.gv
+share/graphviz/graphs/directed/NaN.gv
+share/graphviz/graphs/directed/abstract.gv
+share/graphviz/graphs/directed/alf.gv
+share/graphviz/graphs/directed/arrows.gv
+share/graphviz/graphs/directed/awilliams.gv
+share/graphviz/graphs/directed/biological.gv
+share/graphviz/graphs/directed/clust.gv
+share/graphviz/graphs/directed/clust1.gv
+share/graphviz/graphs/directed/clust2.gv
+share/graphviz/graphs/directed/clust3.gv
+share/graphviz/graphs/directed/clust4.gv
+share/graphviz/graphs/directed/clust5.gv
+share/graphviz/graphs/directed/crazy.gv
+share/graphviz/graphs/directed/ctext.gv
+share/graphviz/graphs/directed/dfa.gv
+share/graphviz/graphs/directed/fig6.gv
+share/graphviz/graphs/directed/fsm.gv
+share/graphviz/graphs/directed/grammar.gv
+share/graphviz/graphs/directed/hashtable.gv
+share/graphviz/graphs/directed/honda-tokoro.gv
+share/graphviz/graphs/directed/japanese.gv
+share/graphviz/graphs/directed/jcctree.gv
+share/graphviz/graphs/directed/jsort.gv
+share/graphviz/graphs/directed/ldbxtried.gv
+share/graphviz/graphs/directed/longflat.gv
+share/graphviz/graphs/directed/mike.gv
+share/graphviz/graphs/directed/nhg.gv
+share/graphviz/graphs/directed/oldarrows.gv
+share/graphviz/graphs/directed/pgram.gv
+share/graphviz/graphs/directed/pm2way.gv
+share/graphviz/graphs/directed/pmpipe.gv
+share/graphviz/graphs/directed/polypoly.gv
+share/graphviz/graphs/directed/proc3d.gv
+share/graphviz/graphs/directed/psfonttest.gv
+share/graphviz/graphs/directed/record2.gv
+share/graphviz/graphs/directed/records.gv
+share/graphviz/graphs/directed/rowe.gv
+share/graphviz/graphs/directed/russian.gv
+share/graphviz/graphs/directed/sdh.gv
+share/graphviz/graphs/directed/shells.gv
+share/graphviz/graphs/directed/states.gv
+share/graphviz/graphs/directed/structs.gv
+share/graphviz/graphs/directed/switch.gv
+share/graphviz/graphs/directed/table.gv
+share/graphviz/graphs/directed/train11.gv
+share/graphviz/graphs/directed/trapeziumlr.gv
+share/graphviz/graphs/directed/tree.gv
+share/graphviz/graphs/directed/triedds.gv
+share/graphviz/graphs/directed/try.gv
+share/graphviz/graphs/directed/unix.gv
+share/graphviz/graphs/directed/unix2.gv
+share/graphviz/graphs/directed/viewfile.gv
+share/graphviz/graphs/directed/world.gv
+share/graphviz/graphs/undirected/ER.gv
+share/graphviz/graphs/undirected/Heawood.gv
+share/graphviz/graphs/undirected/Petersen.gv
+share/graphviz/graphs/undirected/ngk10_4.gv
+share/graphviz/graphs/undirected/process.gv
+share/graphviz/gvpr/addedges
+share/graphviz/gvpr/addranks
+share/graphviz/gvpr/addrings
+share/graphviz/gvpr/anon
+share/graphviz/gvpr/attr
+share/graphviz/gvpr/bb
+share/graphviz/gvpr/bbox
+share/graphviz/gvpr/binduce
+share/graphviz/gvpr/bipart
+share/graphviz/gvpr/chkclusters
+share/graphviz/gvpr/chkedges
+share/graphviz/gvpr/cliptree
+share/graphviz/gvpr/col
+share/graphviz/gvpr/collapse
+share/graphviz/gvpr/color
+share/graphviz/gvpr/cycle
+share/graphviz/gvpr/dechain
+share/graphviz/gvpr/deghist
+share/graphviz/gvpr/deledges
+share/graphviz/gvpr/delmulti
+share/graphviz/gvpr/delnodes
+share/graphviz/gvpr/depath
+share/graphviz/gvpr/dijkstra
+share/graphviz/gvpr/flatten
+share/graphviz/gvpr/get-layers-list
+share/graphviz/gvpr/group
+share/graphviz/gvpr/histogram
+share/graphviz/gvpr/indent
+share/graphviz/gvpr/knbhd
+share/graphviz/gvpr/maxdeg
+share/graphviz/gvpr/path
+share/graphviz/gvpr/rotate
+share/graphviz/gvpr/scale
+share/graphviz/gvpr/scalexy
+share/graphviz/gvpr/span
+share/graphviz/gvpr/topon
+share/graphviz/gvpr/treetoclust
diff --git a/graphviz/buildlink3.mk b/graphviz/buildlink3.mk
new file mode 100644
index 0000000000..670f8707a8
--- /dev/null
+++ b/graphviz/buildlink3.mk
@@ -0,0 +1,20 @@
+# $NetBSD$
+
+BUILDLINK_TREE+=	graphviz
+
+.if !defined(GRAPHVIZ_BUILDLINK3_MK)
+GRAPHVIZ_BUILDLINK3_MK:=
+
+USE_CC_FEATURES+=	c99
+USE_CXX_FEATURES+=	c++11 unique_ptr
+
+BUILDLINK_API_DEPENDS.graphviz+=	graphviz>=2.26.3
+BUILDLINK_ABI_DEPENDS.graphviz+=	graphviz>=9.0.0
+BUILDLINK_PKGSRCDIR.graphviz?=		../../wip/graphviz
+
+.include "../../converters/libiconv/buildlink3.mk"
+.include "../../fonts/fontconfig/buildlink3.mk"
+.include "../../textproc/expat/buildlink3.mk"
+.endif # GRAPHVIZ_BUILDLINK3_MK
+
+BUILDLINK_TREE+=	-graphviz
diff --git a/graphviz/distinfo b/graphviz/distinfo
new file mode 100644
index 0000000000..1b1805ac49
--- /dev/null
+++ b/graphviz/distinfo
@@ -0,0 +1,10 @@
+$NetBSD: distinfo,v 1.82 2023/07/07 13:38:11 micha Exp $
+
+BLAKE2s (graphviz-9.0.0.tar.xz) = dc5bb0e4b72c6187068414e2061116f5d56f32f96b9d649effee2db7966eab08
+SHA512 (graphviz-9.0.0.tar.xz) = 912f31a4a90e21de9601ffcf8a85d2650d46f07e61aeb0e5124e5a91c67f444d08d40d49f15f2e4078d53d01fb9ca6f54dc9d18c1c08406da91b8ba9ad61416c
+Size (graphviz-9.0.0.tar.xz) = 21412796 bytes
+SHA1 (patch-config_config__perl.pl) = 430acb7d7ee3e149de0af9832c5a29602884f83e
+SHA1 (patch-configure.ac) = 80e303d6a9b95c5bb732677a0f1f63d209b39856
+SHA1 (patch-lib_gvc_Makefile.am) = 180b45f810e5bb3948509d50b5be3b159b38a78f
+SHA1 (patch-plugin_gs_gvloadimage__gs.c) = 982ac1db252e3224633069db956c5dc803cd5ea9
+SHA1 (patch-plugin_xlib_gvdevice__xlib.c) = 05d1549db3b9221f5bcb947173034775b0df7c6c
diff --git a/graphviz/options.mk b/graphviz/options.mk
new file mode 100644
index 0000000000..3a384a55d0
--- /dev/null
+++ b/graphviz/options.mk
@@ -0,0 +1,140 @@
+# $NetBSD$
+
+PKG_OPTIONS_VAR=	PKG_OPTIONS.graphviz
+PKG_SUPPORTED_OPTIONS=	gd ghostscript gtk lua perl poppler svg tcl x11
+.if exists(/System/Library/Frameworks/Quartz.framework)
+PKG_SUPPORTED_OPTIONS+=	quartz
+PKG_SUGGESTED_OPTIONS+=	quartz
+.else
+PKG_SUGGESTED_OPTIONS+=	x11
+.endif
+PKG_SUGGESTED_OPTIONS=	gd
+# Explanation of consequence of options, to help those trying to slim down:
+#   lua tcl perl: extension language support
+#   x11: Omits all linking with x11, which means x11 graphics supports as
+#     well as x11 frontend support.
+#   gtk: basic graphic format support (in addition to gd, which isn't
+#     maintained anymore)
+#   svg: Omitting loses svg support. librsvg has large dependencies
+#     including some GNOME libs.
+#   gd: basic graphic format support, especially gif
+#   ghostscript: provides better ps/pdf-support, plus eps
+
+.include "../../mk/bsd.options.mk"
+
+PLIST_VARS+=		gd ghostscript gtk lua perl poppler quartz svg swig tcl x11
+
+.if !empty(PKG_OPTIONS:Mgd)
+.  include "../../graphics/gd/buildlink3.mk"
+PLIST.gd=		yes
+CONFIGURE_ARGS+=	--with-libgd
+.else
+CONFIGURE_ARGS+=	--without-libgd
+.endif
+
+.if !empty(PKG_OPTIONS:Mghostscript)
+.  include "../../print/ghostscript/buildlink3.mk"
+# Also required as tool dependency according to documentation
+TOOL_DEPENDS+=		ghostscript-[0-9]*:../../print/ghostscript
+PLIST.ghostscript=	yes
+CONFIGURE_ARGS+=	--with-ghostscript
+.else
+CONFIGURE_ARGS+=	--without-ghostscript
+.endif
+
+.if !empty(PKG_OPTIONS:Mgtk)
+.  include "../../x11/gtk2/buildlink3.mk"
+PLIST.gtk=		yes
+CONFIGURE_ARGS+=	--with-gdk
+CONFIGURE_ARGS+=	--with-gdk-pixbuf
+CONFIGURE_ARGS+=	--with-gtk
+CONFIGURE_ARGS+=	--with-gnomeui
+.else
+CONFIGURE_ARGS+=	--without-gdk
+CONFIGURE_ARGS+=	--without-gdk-pixbuf
+CONFIGURE_ARGS+=	--without-gtk
+CONFIGURE_ARGS+=	--without-gnomeui
+.endif
+
+.if !empty(PKG_OPTIONS:Mpoppler)
+.  include "../../print/poppler-glib/buildlink3.mk"
+PLIST.poppler=		yes
+CONFIGURE_ARGS+=	--with-poppler
+.else
+CONFIGURE_ARGS+=	--without-poppler
+.endif
+
+.if !empty(PKG_OPTIONS:Mquartz)
+PLIST.quartz=		yes
+CONFIGURE_ARGS+=	--with-quartz
+.else
+CONFIGURE_ARGS+=	--without-quartz
+.endif
+
+.if !empty(PKG_OPTIONS:Msvg)
+BUILDLINK_API_DEPENDS.librsvg+=	librsvg>=2.36.0
+.  include "../../graphics/librsvg/buildlink3.mk"
+PLIST.svg=		yes
+CONFIGURE_ARGS+=	--with-rsvg
+.else
+CONFIGURE_ARGS+=	--without-rsvg
+.endif
+
+.if !empty(PKG_OPTIONS:Mx11)
+.  include "../../mk/xaw.buildlink3.mk"
+.  include "../../x11/libXrender/buildlink3.mk"
+PLIST.x11=		yes
+CONFIGURE_ENV+=		X11BASE=${X11BASE}
+CONFIGURE_ARGS+=	--with-x
+.else
+CONFIGURE_ARGS+=	--without-x
+.endif
+
+USING_SWIG=	no
+
+.if !empty(PKG_OPTIONS:Mlua)
+USING_SWIG=	yes
+.  include "../../lang/lua/tool.mk"
+.  include "../../lang/lua/buildlink3.mk"
+.  include "../../lang/lua/application.mk"
+PLIST.lua=		yes
+CONFIGURE_ARGS+=	--enable-lua
+.else
+CONFIGURE_ARGS+=	--disable-lua
+.endif
+
+.if !empty(PKG_OPTIONS:Mtcl)
+.  if empty(PKG_OPTIONS:Mx11)
+PKG_FAIL_REASON=	"tcl option requires x11 option"
+.  endif
+USING_SWIG=	yes
+.  include "../../lang/tcl/Makefile.version"
+.  include "../../x11/tk/buildlink3.mk"
+PLIST.tcl=		yes
+PLIST_SUBST+=		TCL_BASEVER=${TCL_BASEVER}
+CONFIGURE_ENV+=		TCLCONFIG=${TCLCONFIG_SH:Q}
+CONFIGURE_ENV+=		TKCONFIG=${TKCONFIG_SH:Q}
+CONFIGURE_ARGS+=	--with-tclsh=${TCLSH:Q}
+CONFIGURE_ARGS+=	--enable-tcl
+.else
+CONFIGURE_ARGS+=	--disable-tcl
+.endif
+
+.if !empty(PKG_OPTIONS:Mperl)
+USING_SWIG=	yes
+.  include "../../lang/perl5/buildlink3.mk"
+PLIST.perl=		yes
+USE_TOOLS+=		perl
+CONFIGURE_ARGS+=	--enable-perl
+.else
+CONFIGURE_ARGS+=	--disable-perl
+.endif
+
+.if !empty(USING_SWIG:Myes)
+PLIST.swig=		yes
+# Tool dependency according to documentation
+TOOL_DEPENDS+=		swig>=1.3.29:../../devel/swig
+CONFIGURE_ARGS+=	--enable-swig
+.else
+CONFIGURE_ARGS+=	--disable-swig
+.endif
diff --git a/graphviz/patches/patch-config_config__perl.pl b/graphviz/patches/patch-config_config__perl.pl
new file mode 100644
index 0000000000..82e73ce63f
--- /dev/null
+++ b/graphviz/patches/patch-config_config__perl.pl
@@ -0,0 +1,15 @@
+$NetBSD: patch-config_config__perl.pl,v 1.4 2022/07/22 12:04:46 micha Exp $
+
+Add rpath for pkgsrc
+
+--- config/config_perl.pl.orig	2013-08-01 17:35:15.000000000 +0000
++++ config/config_perl.pl
+@@ -4,7 +4,7 @@ if ($ARGV[0] eq "PERL_LIBS") {
+ 	$archlib = $Config{archlib};
+ 	$libperl = $Config{libperl};
+ 	$libperl =~ s/lib([^\.]+).*/$1/;
+-	print "-L$archlib/CORE -l$libperl";
++	print "-Wl,-rpath,$archlib/CORE -L$archlib/CORE -l$libperl";
+ }
+ if ($ARGV[0] eq "PERL_INCLUDES") {
+ 	$archlib = $Config{archlib};
diff --git a/graphviz/patches/patch-configure.ac b/graphviz/patches/patch-configure.ac
new file mode 100644
index 0000000000..90f4b974cc
--- /dev/null
+++ b/graphviz/patches/patch-configure.ac
@@ -0,0 +1,87 @@
+$NetBSD: patch-configure.ac,v 1.12 2023/01/23 13:44:02 micha Exp $
+
+Use the same path for all platforms in pkgsrc.
+Use lua from pkgsrc.
+
+--- configure.ac.orig	2023-01-06 05:16:50.000000000 +0000
++++ configure.ac
+@@ -92,8 +92,7 @@ if test -z "$LIBPOSTFIX"; then
+   case "${host_os}" in
+     *linux* )
+       case "${host_cpu}" in
+-        aarch64 | powerpc64 | powerpc64le | s390x | x86_64 | sparc64 | mips64* | riscv64 | e2k )
+-          LIBPOSTFIX="64"
++        aarch64* | powerpc64 | powerpc64le | s390x | x86_64 | sparc64 | mips64* | riscv64 | e2k )
+           INTGOSIZE=64
+           ;;
+       esac
+@@ -101,7 +100,6 @@ if test -z "$LIBPOSTFIX"; then
+     *solaris* )
+       case "${host_cpu}" in
+         x86_64 | sparc64 )
+-          LIBPOSTFIX="/64"
+           INTGOSIZE=64
+           ;;
+       esac
+@@ -858,7 +856,7 @@ else
+ 	            if test "x$?" = "x0" ; then
+                         LUA_INCLUDES="$LUA_CFLAGS "`$PKG_CONFIG --cflags lua$l`
+                         LUA_LIBS="$LUA_LFLAGS "`$PKG_CONFIG --libs lua$l`
+-		        LUA_INSTALL_DIR="/usr/lib$LIBPOSTFIX/lua/`$PKG_CONFIG --variable=V lua`"
++		        LUA_INSTALL_DIR="${PREFIX}/lib$LIBPOSTFIX/lua/`$PKG_CONFIG --variable=V lua`"
+ 
+ 		        pkgconfig_lualib_found=`$PKG_CONFIG --exists lualib$l 2>/dev/null`
+ 		        if test  "x$?" = "x0"; then
+@@ -879,7 +877,7 @@ else
+ 	        echo
+                 LUA_INCLUDES=`$LUACONFIG --include`
+                 LUA_LIBS=`$LUACONFIG --libs`
+-	        LUA_INSTALL_DIR="/usr/lib$LIBPOSTFIX/lua/5.0"
++	        LUA_INSTALL_DIR="${PREFIX}/lib$LIBPOSTFIX/lua/5.0"
+             fi
+         fi
+ 
+@@ -2053,43 +2051,6 @@ fi
+ AM_CONDITIONAL(WITH_QUARTZ, [test "x$use_quartz" = "xYes"])
+ 
+ dnl -----------------------------------
+-dnl INCLUDES and LIBS for PLATFORMSDK
+-
+-AC_ARG_WITH(platformsdkincludedir,
+-  [AS_HELP_STRING([--with-platformsdkincludedir=DIR],[use Platform SDK (Windows) includes from DIR])],
+-  [PLATFORMSDKINCLUDE=$withval])
+-
+-AC_ARG_WITH(platformsdklibdir,
+-  [AS_HELP_STRING([--with-platformsdklibdir=DIR],[use Platform SDK (Windows) libraries from DIR])],
+-  [PLATFORMSDKLIB=$withval])
+-
+-AC_SUBST([PLATFORMSDKINCLUDE])
+-AC_SUBST([PLATFORMSDKLIB])
+-
+-dnl -----------------------------------
+-dnl INCLUDES and LIBS for GDI+
+-
+-AC_ARG_WITH(gdiplus,
+-  [AS_HELP_STRING([--with-gdiplus=no],[GDI+ framework (Windows)])],
+-  [], [with_gdiplus=no])
+-
+-if test "x$with_gdiplus" != "xyes"; then
+-  use_gdiplus="No (disabled by default - Windows only)"
+-else
+-  if test -f "$PLATFORMSDKINCLUDE\GdiPlus.h" -a -f "$PLATFORMSDKLIB\GdiPlus.lib"; then
+-    use_gdiplus="Yes"
+-    AC_DEFINE_UNQUOTED(HAVE_GDIPLUS,1,[Define if you have the GDI+ framework for Windows])
+-    GDIPLUS_HEADS=`cd "$PLATFORMSDKINCLUDE" && echo GdiPlus*.h`
+-    GDIPLUS_CFLAGS=''
+-    GDIPLUS_LIBS=''
+-    AC_SUBST([GDIPLUS_HEADS])
+-    AC_SUBST([GDIPLUS_CFLAGS])
+-    AC_SUBST([GDIPLUS_LIBS])
+-  else
+-    use_gdiplus="No (missing headers)"
+-    AC_MSG_WARN(--with-gdiplus requires valid --with-platformsdkincludedir and --with-platformsdklibdir.)
+-  fi
+-fi
+ AM_CONDITIONAL(WITH_GDIPLUS, [test "x$use_gdiplus" = "xYes"])
+ 
+ dnl -----------------------------------
diff --git a/graphviz/patches/patch-lib_gvc_Makefile.am b/graphviz/patches/patch-lib_gvc_Makefile.am
new file mode 100644
index 0000000000..1d0559792c
--- /dev/null
+++ b/graphviz/patches/patch-lib_gvc_Makefile.am
@@ -0,0 +1,15 @@
+$NetBSD: patch-lib_gvc_Makefile.am,v 1.3 2022/11/23 13:10:00 micha Exp $
+
+Link with pthread library, if needed.
+
+--- lib/gvc/Makefile.am.orig	2022-07-07 15:43:58.000000000 +0000
++++ lib/gvc/Makefile.am
+@@ -54,7 +54,7 @@ libgvc_la_LIBADD = $(libgvc_C_la_LIBADD)
+ 	$(top_builddir)/lib/cdt/libcdt.la \
+ 	$(top_builddir)/lib/cgraph/libcgraph.la \
+ 	$(top_builddir)/lib/pathplan/libpathplan.la \
+-	$(EXPAT_LIBS) $(Z_LIBS) $(MATH_LIBS)
++	$(EXPAT_LIBS) $(Z_LIBS) $(MATH_LIBS) ${PTHREAD_LDFLAGS} ${PTHREAD_LIBS}
+ libgvc_la_DEPENDENCIES = $(libgvc_C_la_DEPENDENCIES)
+ 
+ .3.3.pdf:
diff --git a/graphviz/patches/patch-plugin_gs_gvloadimage__gs.c b/graphviz/patches/patch-plugin_gs_gvloadimage__gs.c
new file mode 100644
index 0000000000..ed88dd4f19
--- /dev/null
+++ b/graphviz/patches/patch-plugin_gs_gvloadimage__gs.c
@@ -0,0 +1,33 @@
+$NetBSD: patch-plugin_gs_gvloadimage__gs.c,v 1.4 2022/10/17 09:12:53 adam Exp $
+
+ghostscript-agpl enforces using gserrors.h which is not included
+by default in ghostscript-gpl, so conditionalise based upon which
+one is being used.
+
+--- plugin/gs/gvloadimage_gs.c.orig	2022-10-11 18:31:29.000000000 +0000
++++ plugin/gs/gvloadimage_gs.c
+@@ -77,6 +77,16 @@ static void gs_error(GVJ_t * job, const 
+ 
+     assert (err < 0);
+ 
++#ifdef gserrors_INCLUDED /* ghostscript-agpl uses gserrors.h */
++    if (err >= gs_error_VMerror) 
++	errsrc = "PostScript Level 1"; 
++    else if (err >= gs_error_unregistered)
++	errsrc = "PostScript Level 2";
++    else if (err >= gs_error_invalidid)
++	errsrc = "DPS error";
++    else
++	errsrc = "Ghostscript internal error";
++#else
+     if (err >= e_VMerror) 
+ 	errsrc = "PostScript Level 1"; 
+     else if (err >= e_unregistered)
+@@ -85,6 +95,7 @@ static void gs_error(GVJ_t * job, const 
+ 	errsrc = "DPS error";
+     else
+ 	errsrc = "Ghostscript internal error";
++#endif
+ 
+     job->common->errorfn("%s: %s() returned: %d (%s)\n",
+ 		name, funstr, err, errsrc);
diff --git a/graphviz/patches/patch-plugin_xlib_gvdevice__xlib.c b/graphviz/patches/patch-plugin_xlib_gvdevice__xlib.c
new file mode 100644
index 0000000000..26e3c0455c
--- /dev/null
+++ b/graphviz/patches/patch-plugin_xlib_gvdevice__xlib.c
@@ -0,0 +1,16 @@
+$NetBSD: patch-plugin_xlib_gvdevice__xlib.c,v 1.3 2022/07/22 12:04:46 micha Exp $
+
+SunOS inotify requires sys/filio.h for FIONREAD.
+
+--- plugin/xlib/gvdevice_xlib.c.orig	2020-04-08 07:51:58.000000000 +0000
++++ plugin/xlib/gvdevice_xlib.c
+@@ -32,6 +32,9 @@
+ #endif
+ #ifdef HAVE_SYS_INOTIFY_H
+ #include <sys/inotify.h>
++#ifdef __sun
++#include <sys/filio.h>
++#endif
+ #endif
+ #include <errno.h>
+ #ifdef HAVE_FCNTL_H


Home | Main Index | Thread Index | Old Index