]> granicus.if.org Git - graphviz/log
graphviz
3 years agochkPos: remove strcmp micro-optimization
Matthew Fernandez [Sat, 4 Sep 2021 16:24:19 +0000 (09:24 -0700)]
chkPos: remove strcmp micro-optimization

3 years agoMerge branch 'smattr/7890fb90-8b73-4677-a4f3-0f3a17dcf0ca' into 'main'
Matthew Fernandez [Thu, 9 Sep 2021 02:10:41 +0000 (02:10 +0000)]
Merge branch 'smattr/7890fb90-8b73-4677-a4f3-0f3a17dcf0ca' into 'main'

more SWIG bindings clean up

See merge request graphviz/graphviz!2147

3 years agoOCaml bindings: fix: only pass -fpermissive when compiling C++
Matthew Fernandez [Mon, 6 Sep 2021 22:11:19 +0000 (15:11 -0700)]
OCaml bindings: fix: only pass -fpermissive when compiling C++

The `-fpermissive` flag is only valid for Objective-C and C++, but was being set
for C and C++. When compiling the C part of these bindings, this was generating
the warning:

  cc1: warning: command line option ‘-fpermissive’ is valid for C++/ObjC++ but
    not for C

This flag was introduced in 8f4667edb410a6d11b53746849304fb953b5c6ae to work
around non-conformant code generation by SWIG. In future, it might be worth
investigating whether the underlying issue has been fixed in SWIG and this work
around can be removed.

3 years agoJava bindings gv_channel_writer: suppress -Wunused-parameter compiler warnings
Matthew Fernandez [Mon, 6 Sep 2021 22:07:14 +0000 (15:07 -0700)]
Java bindings gv_channel_writer: suppress -Wunused-parameter compiler warnings

3 years agoGo bindings: suppress -Wunused-function compiler warnings
Matthew Fernandez [Mon, 6 Sep 2021 22:02:58 +0000 (15:02 -0700)]
Go bindings: suppress -Wunused-function compiler warnings

SWIG generates some functions that go unused in the Graphviz bindings. There is
no value to warning about these.

3 years agoMerge branch 'smattr/ab033750-c4e7-4e83-930b-4c85fa29cdb3' into 'main'
Matthew Fernandez [Thu, 9 Sep 2021 01:04:00 +0000 (01:04 +0000)]
Merge branch 'smattr/ab033750-c4e7-4e83-930b-4c85fa29cdb3' into 'main'

BinaryHeap clean up

See merge request graphviz/graphviz!2148

3 years agoBinaryHeap: switch 'mask' in sanity check to 0 vs 1
Matthew Fernandez [Mon, 6 Sep 2021 23:53:11 +0000 (16:53 -0700)]
BinaryHeap: switch 'mask' in sanity check to 0 vs 1

Using this instead of -1 vs 1 allows slightly more efficient code.

3 years agoBinaryHeap: use 'size_t' to track heap sizes/positions instead of 'int'
Matthew Fernandez [Mon, 6 Sep 2021 23:47:36 +0000 (16:47 -0700)]
BinaryHeap: use 'size_t' to track heap sizes/positions instead of 'int'

3 years agoBinaryHeap: use 'calloc' instead of 'malloc' when allocating arrays
Matthew Fernandez [Mon, 6 Sep 2021 23:08:58 +0000 (16:08 -0700)]
BinaryHeap: use 'calloc' instead of 'malloc' when allocating arrays

There is not much we can do about the `realloc` calls, but we can at least do
initial allocation in a less error prone way.

3 years agoBinaryHeap: rephrase 'sizeof(type)' code to 'sizeof(arr[0])'
Matthew Fernandez [Mon, 6 Sep 2021 22:58:55 +0000 (15:58 -0700)]
BinaryHeap: rephrase 'sizeof(type)' code to 'sizeof(arr[0])'

This has no effect on functionality, but it makes it clearer what this code is
doing and makes it more robust against changing the underlying types.

3 years agoBinaryHeap_realloc: rephrase division by 5 code
Matthew Fernandez [Mon, 6 Sep 2021 22:39:12 +0000 (15:39 -0700)]
BinaryHeap_realloc: rephrase division by 5 code

This makes the intent of this code clearer as well as squashing a
-Wfloat-conversion compiler warning.

3 years agoMerge branch 'add-ubuntu21-04-static-build-job-to-CI' into 'main'
Magnus Jacobsson [Wed, 8 Sep 2021 20:16:24 +0000 (20:16 +0000)]
Merge branch 'add-ubuntu21-04-static-build-job-to-CI' into 'main'

Add static build for Ubuntu 21.04 to CI

See merge request graphviz/graphviz!2134

3 years agoCI: add ubuntu21-04-static-build job
Magnus Jacobsson [Sat, 7 Aug 2021 15:22:44 +0000 (17:22 +0200)]
CI: add ubuntu21-04-static-build job

3 years agoCI: remove incorrect path to .gz file in deb build template
Magnus Jacobsson [Sat, 4 Sep 2021 16:53:24 +0000 (18:53 +0200)]
CI: remove incorrect path to .gz file in deb build template

No .gz file is produced by the builds that use this template anyway.

3 years agoci/build.sh: add support for static builds using configure options
Magnus Jacobsson [Mon, 30 Aug 2021 13:48:10 +0000 (15:48 +0200)]
ci/build.sh: add support for static builds using configure options

3 years agotclpkg: install .so files only when linking dynamically
Magnus Jacobsson [Sat, 4 Sep 2021 13:55:54 +0000 (15:55 +0200)]
tclpkg: install .so files only when linking dynamically

Fixes errors like this when using static linking:

cp: cannot stat '/home/magjac/graphviz/build/lib/graphviz/ruby/libgv_ruby.so': No such file or directory

3 years agogvpack_static: force the C++ compiler to be used also for static linking
Magnus Jacobsson [Wed, 1 Sep 2021 05:27:25 +0000 (07:27 +0200)]
gvpack_static: force the C++ compiler to be used also for static linking

The trick to force the C++ compiler to be used for linking was applied
only for gvpack, not for gvpack_static.

Fixes many errors like this:

/usr/bin/ld: ../../lib/vpsc/.libs/libvpsc_C.a(csolve_VPSC.o): in function `newVariable':
csolve_VPSC.cpp:(.text+0x20): undefined reference to `operator new(unsigned long)'

3 years agoMerge branch 'add-cygwin-cmake-build-to-ci' into 'main'
Magnus Jacobsson [Wed, 8 Sep 2021 19:08:04 +0000 (19:08 +0000)]
Merge branch 'add-cygwin-cmake-build-to-ci' into 'main'

Add Cygwin CMake build to CI

See merge request graphviz/graphviz!2137

3 years agoCI: add windows-cygwin-cmake-build job
Magnus Jacobsson [Sat, 21 Aug 2021 09:09:58 +0000 (11:09 +0200)]
CI: add windows-cygwin-cmake-build job

3 years agoCPack: silence CPACK_CYGWIN_PATCH_NUMBER not set warning
Magnus Jacobsson [Thu, 2 Sep 2021 22:19:22 +0000 (00:19 +0200)]
CPack: silence CPACK_CYGWIN_PATCH_NUMBER not set warning

Silences this warning:

CPack Warning: CPACK_CYGWIN_PATCH_NUMBER not specified using 1

3 years agoCPack: generate Cygwin binary installer on Cygwin
Magnus Jacobsson [Thu, 2 Sep 2021 22:14:02 +0000 (00:14 +0200)]
CPack: generate Cygwin binary installer on Cygwin

3 years agotools: add workaround for cpack problem with Cygwin
Magnus Jacobsson [Thu, 2 Sep 2021 21:50:51 +0000 (23:50 +0200)]
tools: add workaround for cpack problem with Cygwin

Copy the gml2gv executable to to the gv2gml alias instead of
symlinking it. Creating a symlink to gml2gv works fine in itself, but
results in an error like this when running cpack:

CPack Error: Problem while adding file </home/magja/graphviz/build/_CPack_Packages/CYGWIN/ZIP/Graphviz-2.49.1~dev.20210902.2049-CYGWIN/bin/gv2gml> to archive </home/magja/graphviz/build/_CPack_Packages/CYGWIN/ZIP/Graphviz-2.49.1~dev.20210902.2049-CYGWIN.zip>, ERROR = Unable to read from file 'Graphviz-2.49.1~dev.20210902.2049-CYGWIN/bin/gv2gml': Couldn't list extended attributes

gv2gml is a symlink. Trying to read the extended attributes manually gives:

attr -l /cygdrive/c/Users/magja/graphviz/build/_CPack_Packages/CYGWIN/ZIP/Graphviz-2.49.1~dev.20210902.2049-CYGWIN/bin/gv2gml
attr_list: Permission denied
Could not list /cygdrive/c/Users/magja/graphviz/build/_CPack_Packages/CYGWIN/ZIP/Graphviz-2.49.1~dev.20210902.2049-CYGWIN/bin/gv2gml

3 years agodot: add workaround for cpack problem with Cygwin
Magnus Jacobsson [Thu, 2 Sep 2021 21:50:51 +0000 (23:50 +0200)]
dot: add workaround for cpack problem with Cygwin

Copy the dot executable to its alias commands instead of symlinking
it. Creating symlinks to dot works fine in itself, but results in an
error like this when running cpack:

CPack Error: Problem while adding file </cygdrive/c/Users/magja/graphviz/build/_CPack_Packages/CYGWIN/ZIP/Graphviz-2.49.0~dev.20210812.2025-CYGWIN/bin/circo> to archive </cygdrive/c/Users/magja/graphviz/build/_CPack_Packages/CYGWIN/ZIP/Graphviz-2.49.0~dev.20210812.2025-CYGWIN.zip>, ERROR = Unable to read from file 'Graphviz-2.49.0~dev.20210812.2025-CYGWIN/bin/circo': Couldn't list extended attributes

circo is a symlink. Trying to read the extended attributes manually gives:

attr -l /cygdrive/c/Users/magja/graphviz/build/_CPack_Packages/CYGWIN/ZIP/Graphviz-2.49.0~dev.20210812.2025-CYGWIN/bin/circo
attr_list: Permission denied
Could not list /cygdrive/c/Users/magja/graphviz/build/_CPack_Packages/CYGWIN/ZIP/Graphviz-2.49.0~dev.20210812.2025-CYGWIN/bin/circo

3 years agoadd ci/cygwin-build.sh script
Magnus Jacobsson [Wed, 1 Sep 2021 18:01:09 +0000 (20:01 +0200)]
add ci/cygwin-build.sh script

3 years agoci/build.sh: remove trailing text after actual version ID
Magnus Jacobsson [Tue, 7 Sep 2021 17:44:57 +0000 (19:44 +0200)]
ci/build.sh: remove trailing text after actual version ID

Fixes a problem on Cygwin where 'uname -r' gives:

3.2.0(0.340/5/3)

which, when used as the name of a directory, actually represents a
directory named '3.2.0(0.340', containing a subdirectory named '5'
containing a subdirectory named '3)'.

3 years agoci/build.sh: add support for Cygwin
Magnus Jacobsson [Thu, 12 Aug 2021 12:22:53 +0000 (14:22 +0200)]
ci/build.sh: add support for Cygwin

The /etc/os-release file does not exist on Cygwin so we use the more
reliable built-in bash variable OSTYPE instead.

3 years agoplugin/core: make awk crlf agnostic when generating ps.h
Magnus Jacobsson [Thu, 12 Aug 2021 20:02:48 +0000 (22:02 +0200)]
plugin/core: make awk crlf agnostic when generating ps.h

Fixes errors like this with Cygwin in a crlf environment with
SHELLOPTS=igncr:

/cygdrive/c/Users/magja/graphviz/build/plugin/core/ps.h:2:1: error: missing terminating " character
    2 | "%%BeginProlog ",
      | ^~~~~~~~~~~~~~

Although not shown in the error message, this line actually contained
a carriage return after %%BeginProlog:

"%%BeginProlog\r",

3 years agocommon: make awk crlf agnostic when generating svgcolor_lib
Magnus Jacobsson [Thu, 12 Aug 2021 19:57:44 +0000 (21:57 +0200)]
common: make awk crlf agnostic when generating svgcolor_lib

Fixes errors like this with Cygwin in a crlf environment with
SHELLOPTS=igncr:

/cygdrive/c/Users/magja/graphviz/build/lib/common/common/colortbl.h:1524:2: error: missing terminating " character
 1524 | {"/svg/ ",0,255,255,255,0,0,0},
      |  ^~~~~~

Although not shown in the error message, this line actually contained
a carriage return after /svg/:

{"/svg/\r",0,255,255,255,0,0,0},

3 years agoMerge branch 'smattr/C617D6FE-BA39-4D70-BF6F-7FAAFAEA2A69' into 'main'
Matthew Fernandez [Wed, 8 Sep 2021 14:23:55 +0000 (14:23 +0000)]
Merge branch 'smattr/C617D6FE-BA39-4D70-BF6F-7FAAFAEA2A69' into 'main'

fix: write Graphviz build version to GRAPHVIZ_VERSION file instead of VERSION

Closes #2122

See merge request graphviz/graphviz!2149

3 years agofix: write Graphviz build version to GRAPHVIZ_VERSION file instead of VERSION
Matthew Fernandez [Wed, 8 Sep 2021 03:53:51 +0000 (20:53 -0700)]
fix: write Graphviz build version to GRAPHVIZ_VERSION file instead of VERSION

C++20 standardizes a new `version` header.¹ A side effect of this is that
Autotools-driven Graphviz compilation fails when using both (1) a C++20-capable
compiler and (2) a case-insensitive file system:

  Making all in vpsc
  CXX      block.lo
  In file included from block.cpp:20:
  In file included from …/include/c++/v1/memory:667:
  In file included from …/include/c++/v1/type_traits:417:
  In file included from …/include/c++/v1/cstddef:37:
  ../../version:1:1: error: expected unqualified-id
  2.49.1~dev.20210907.1517
  ^

The core problem is that the root of the repository checkout (or unpacked
tarball) is in the compiler’s include path in order to allow including
`config.h`. But the generated `VERSION` file is also in this same directory.
Nothing in Graphviz attempts to include the C++20 `version` header, but some of
the other stdlib headers transitively include `version`.

To avoid this confusion, we rename Graphviz’ generated file.

Fixes #2122.

¹ https://en.cppreference.com/w/cpp/header/version

3 years agoautogen.sh: remove computation of GRAPHVIZ_VERSION
Matthew Fernandez [Wed, 8 Sep 2021 03:40:01 +0000 (20:40 -0700)]
autogen.sh: remove computation of GRAPHVIZ_VERSION

As of commit 46fadbefa1c7810513129051c8fa01a506316e6e, this is not longer used.

3 years agoMerge branch 'smattr/960bee28-a488-4e56-90bf-10b4b3408ad8' into 'main'
Matthew Fernandez [Tue, 7 Sep 2021 15:17:33 +0000 (15:17 +0000)]
Merge branch 'smattr/960bee28-a488-4e56-90bf-10b4b3408ad8' into 'main'

clean up of SWIG bindings code

See merge request graphviz/graphviz!2135

3 years agoclang-format tclpkg/gv/gv.cpp
Matthew Fernandez [Thu, 2 Sep 2021 02:07:22 +0000 (19:07 -0700)]
clang-format tclpkg/gv/gv.cpp

3 years agouse C++ way of #including C headers in SWIG bindings
Matthew Fernandez [Thu, 2 Sep 2021 02:08:28 +0000 (19:08 -0700)]
use C++ way of #including C headers in SWIG bindings

3 years agorephrase some integer to boolean conversions in the SWIG bindings code
Matthew Fernandez [Thu, 2 Sep 2021 02:03:12 +0000 (19:03 -0700)]
rephrase some integer to boolean conversions in the SWIG bindings code

3 years agofix comment typo in SWIG bindings code
Matthew Fernandez [Thu, 2 Sep 2021 01:59:54 +0000 (18:59 -0700)]
fix comment typo in SWIG bindings code

3 years agomove declarations closer to their usage in SWIG bindings code
Matthew Fernandez [Thu, 2 Sep 2021 01:53:31 +0000 (18:53 -0700)]
move declarations closer to their usage in SWIG bindings code

3 years agorephrase some nullptr tests in the SWIG bindings code
Matthew Fernandez [Thu, 2 Sep 2021 01:50:53 +0000 (18:50 -0700)]
rephrase some nullptr tests in the SWIG bindings code

3 years agoremove unnecessary conditional guards in the SWIG bindings code
Matthew Fernandez [Thu, 2 Sep 2021 01:50:18 +0000 (18:50 -0700)]
remove unnecessary conditional guards in the SWIG bindings code

It is fine to reinterpret_cast nullptr.

3 years agoremove an unnecessary use of C string functions in SWIG bindings code
Matthew Fernandez [Thu, 2 Sep 2021 01:37:14 +0000 (18:37 -0700)]
remove an unnecessary use of C string functions in SWIG bindings code

3 years agouse more modern reinterpret_cast instead of C-style casts in SWIG bindings code
Matthew Fernandez [Thu, 2 Sep 2021 01:29:11 +0000 (18:29 -0700)]
use more modern reinterpret_cast instead of C-style casts in SWIG bindings code

3 years agoremove unnecessary realloc in SWIG bindings code
Matthew Fernandez [Thu, 2 Sep 2021 01:20:51 +0000 (18:20 -0700)]
remove unnecessary realloc in SWIG bindings code

This is attempting to shrink a buffer that was allocated by gvRenderData to its
tight bounds. This kind of thing is no longer a necessary optimization and, in
some cases, can be a de-optimization.

3 years agoremove commented out code in SWIG bindings code
Matthew Fernandez [Thu, 2 Sep 2021 01:13:28 +0000 (18:13 -0700)]
remove commented out code in SWIG bindings code

3 years agoreplace NULL with more modern nullptr in SWIG bindings code
Matthew Fernandez [Thu, 2 Sep 2021 01:03:31 +0000 (18:03 -0700)]
replace NULL with more modern nullptr in SWIG bindings code

3 years agoMerge branch 'clean-up-build.sh' into 'main'
Magnus Jacobsson [Tue, 7 Sep 2021 06:49:06 +0000 (06:49 +0000)]
Merge branch 'clean-up-build.sh' into 'main'

Clean up ci/build.sh and fix MinGW artifact archiving

See merge request graphviz/graphviz!2143

3 years agoCI: archive build artifacts in windows-mingw64-cmake-build job
Magnus Jacobsson [Sun, 5 Sep 2021 11:35:22 +0000 (13:35 +0200)]
CI: archive build artifacts in windows-mingw64-cmake-build job

3 years agoCI: archive build artifacts in windows-mingw32-cmake-build job
Magnus Jacobsson [Sun, 5 Sep 2021 11:35:16 +0000 (13:35 +0200)]
CI: archive build artifacts in windows-mingw32-cmake-build job

3 years agoci/build.sh: fail if trying to use an unset variable
Magnus Jacobsson [Sun, 5 Sep 2021 06:24:22 +0000 (08:24 +0200)]
ci/build.sh: fail if trying to use an unset variable

3 years agoci/build.sh: fix missing VERSION_ID on MSYS2/MinGW
Magnus Jacobsson [Sun, 5 Sep 2021 11:02:31 +0000 (13:02 +0200)]
ci/build.sh: fix missing VERSION_ID on MSYS2/MinGW

This change will allow treating unset variables as errors in an
upcoming commit.

This problem also caused the build artifacts to be moved to the wrong
directory, but that did not have any consequences since the build
artifacts are currently not archived in the CI jobs. An upcoming
commit in this series will however change that.

3 years agoci/build.sh: CMake: use fallback for unset CMAKE_OPTIONS
Magnus Jacobsson [Sun, 5 Sep 2021 07:55:50 +0000 (09:55 +0200)]
ci/build.sh: CMake: use fallback for unset CMAKE_OPTIONS

This is no functional change but will allow treating unset variables
as errors in an upcoming commit.

3 years agoci/build.sh: explicitly set build_system to autotools by default
Magnus Jacobsson [Sun, 5 Sep 2021 07:43:34 +0000 (09:43 +0200)]
ci/build.sh: explicitly set build_system to autotools by default

This is no functional change but will allow treating unset variables
as errors in an upcoming commit.

3 years agoci/build.sh: remove obsolete workaround for missing ID_LIKE in /etc/os-release
Magnus Jacobsson [Sat, 4 Sep 2021 13:40:40 +0000 (15:40 +0200)]
ci/build.sh: remove obsolete workaround for missing ID_LIKE in /etc/os-release

This workaround was introduced in
029acf11d1d9a9eb20eddae84cadb61447da95f3, but was actually never
brought into use when 9ca0ccd4e368d0e9bd545e5f1698b8eef931dbbc
introduced an ASan build to CI, which used a Ubunutu docker container
instead of the native GitLab Debian Linux runner for which the
workaround was intended.

Also Fedora doesn't have ID_LIKE, but the workaround was really never
necessary for it either.

3 years agoci/build.sh: use /etc/os-release if and only if it exists
Magnus Jacobsson [Sun, 5 Sep 2021 09:19:54 +0000 (11:19 +0200)]
ci/build.sh: use /etc/os-release if and only if it exists

An upcoming MR will introduce Cygwin builds that also do not have
/etc/os-release.

3 years agoci/build.sh: autotools: fail if OSTYPE is unknown
Magnus Jacobsson [Sun, 5 Sep 2021 19:24:57 +0000 (21:24 +0200)]
ci/build.sh: autotools: fail if OSTYPE is unknown

3 years agoci/build.sh: autotools: use OSTYPE to determine if on GNU/Linux
Magnus Jacobsson [Sat, 4 Sep 2021 13:37:13 +0000 (15:37 +0200)]
ci/build.sh: autotools: use OSTYPE to determine if on GNU/Linux

OSTYPE is a built-in variable in bash and exists on all operating
systems.

As a second discriminator, use ID_LIKE to determine if on a Debian
like OS, e.g. Ubuntu.

3 years agoci/build.sh: CMake: fail if OSTYPE is unknown
Magnus Jacobsson [Sun, 5 Sep 2021 19:24:57 +0000 (21:24 +0200)]
ci/build.sh: CMake: fail if OSTYPE is unknown

3 years agoci/build.sh: CMake: use OSTYPE to determine if on GNU/Linux
Magnus Jacobsson [Sat, 4 Sep 2021 13:37:13 +0000 (15:37 +0200)]
ci/build.sh: CMake: use OSTYPE to determine if on GNU/Linux

OSTYPE is a built-in variable in bash and exists on all operating
systems.

As a second discriminator, use ID_LIKE to determine if on a Debian
like OS, e.g. Ubuntu.

3 years agoci/build.sh: CMake: use OSTYPE to determine if on MSYS2/MinGW
Magnus Jacobsson [Sat, 4 Sep 2021 13:33:48 +0000 (15:33 +0200)]
ci/build.sh: CMake: use OSTYPE to determine if on MSYS2/MinGW

OSTYPE is a built-in variable in bash and exists on all operating
systems.

3 years agoci/build.sh: autotools: use OSTYPE to determine if on macOS
Magnus Jacobsson [Sat, 4 Sep 2021 13:32:11 +0000 (15:32 +0200)]
ci/build.sh: autotools: use OSTYPE to determine if on macOS

OSTYPE is a built-in variable in bash and exists on all operating
systems.

3 years agoci/build.sh: CMake: use OSTYPE to determine if on macOS
Magnus Jacobsson [Sat, 4 Sep 2021 13:32:11 +0000 (15:32 +0200)]
ci/build.sh: CMake: use OSTYPE to determine if on macOS

OSTYPE is a built-in variable in bash and exists on all operating
systems.

3 years agoMerge branch 'generated-cmake-dep' into 'main'
Matthew Fernandez [Mon, 6 Sep 2021 18:23:19 +0000 (18:23 +0000)]
Merge branch 'generated-cmake-dep' into 'main'

Ensure correct file-level dependency

See merge request graphviz/graphviz!2142

3 years agoadd CHANGELOG entry for prior commit
Matthew Fernandez [Mon, 6 Sep 2021 17:45:33 +0000 (10:45 -0700)]
add CHANGELOG entry for prior commit

3 years agoEnsure correct file-level dependency for generated file in cmake generated projects
Cameron Lowell Palmer [Sun, 5 Sep 2021 09:20:40 +0000 (11:20 +0200)]
Ensure correct file-level dependency for generated file in cmake generated projects

When using ninja parallel compilation, it is possible that the generated ninja
file might not create the necessary files, color_lib and svgcolor_lib, before
they are needed and this results in a failed build. Providing an absolute path
to depend on in the add_custom_command rectifies the situation.

Closes #2119

3 years agoMerge branch 'smattr/1264c66c-9666-43b2-b04a-877f0d54f2be' into 'main'
Matthew Fernandez [Sun, 5 Sep 2021 18:52:19 +0000 (18:52 +0000)]
Merge branch 'smattr/1264c66c-9666-43b2-b04a-877f0d54f2be' into 'main'

remove `make check` Python targets

Closes #2112

See merge request graphviz/graphviz!2131

3 years agoremove `make check` Python targets
Matthew Fernandez [Wed, 1 Sep 2021 02:53:57 +0000 (19:53 -0700)]
remove `make check` Python targets

The current Graphviz test suite is orchestrated via Pytest and assumes it is
dealing with an installed Graphviz (e.g. headers and libraries available in
expected locations). The legacy Autotools check targets gave the incorrect
impression that this was the current test suite and it was expected to pass. It
has not been possible to run these legacy test scripts for a long time.

This commit removes the legacy testing pieces to avoid future confusion. In
future it may be useful to plumb the current Pytest test suite to the Autotools
post-install test targets (`make installcheck`).

Closes #2112.

3 years agoMerge branch 'smattr/24AB31CD-C80E-4E3C-905F-C63B2C4382DD' into 'main'
Matthew Fernandez [Sun, 5 Sep 2021 17:51:22 +0000 (17:51 +0000)]
Merge branch 'smattr/24AB31CD-C80E-4E3C-905F-C63B2C4382DD' into 'main'

some typo fixes

See merge request graphviz/graphviz!2133

3 years agops_font_equiv.h: remove unused 'DARWIN' branch
Matthew Fernandez [Wed, 1 Sep 2021 14:56:20 +0000 (07:56 -0700)]
ps_font_equiv.h: remove unused 'DARWIN' branch

The macro defined on macOS is `__APPLE__`, not `DARWIN`. The build system
conditionally defines `DARWIN`, but config.h is not included in this file so
that has no effect. The else case of this logic is the same as the `DARWIN` case
so removing this has no effect.

3 years agofix message typo in D bindings configuration
Matthew Fernandez [Wed, 1 Sep 2021 14:54:22 +0000 (07:54 -0700)]
fix message typo in D bindings configuration

3 years agoremove Fedora 26 legacy comment
Matthew Fernandez [Wed, 1 Sep 2021 14:53:39 +0000 (07:53 -0700)]
remove Fedora 26 legacy comment

3 years agoMerge branch 'smattr/623e3f1a-6199-44f5-9e36-ee92e01a7630' into 'main'
Matthew Fernandez [Sat, 4 Sep 2021 17:10:06 +0000 (17:10 +0000)]
Merge branch 'smattr/623e3f1a-6199-44f5-9e36-ee92e01a7630' into 'main'

fix various problems with the Javascript bindings

See merge request graphviz/graphviz!2129

3 years agodefault the Javascript bindings to JSC
Matthew Fernandez [Tue, 31 Aug 2021 03:35:24 +0000 (20:35 -0700)]
default the Javascript bindings to JSC

SWIG is capable of targeting three Javascript runtimes when generating code:
JSC, V8, and NodeJS. One of these needs to be selected at generation time; there
is no default. In future it may be desirable to target the more popular of
these, NodeJS, but for now we leave it with the traditional JSC.

There are still multiple blockers to enabling this fully in the build system:

  1. The configuration setup checks for a `js` binary. I do not know what this
     is. Maybe it is intending to check for `jsc`, the JSC compiler?

  2. Even if that were true, this is the wrong thing to check for. Generation of
     bindings and their compilation requires not a Javascript compiler but the
     runtime’s C/C++ headers. For JSC, JavaScriptCore/JavaScript.h.

3 years agouse a less error prone pattern for output filenames in the bindings Makefile
Matthew Fernandez [Tue, 31 Aug 2021 03:10:08 +0000 (20:10 -0700)]
use a less error prone pattern for output filenames in the bindings Makefile

3 years agofix Javascript binding generation
Matthew Fernandez [Tue, 31 Aug 2021 03:02:39 +0000 (20:02 -0700)]
fix Javascript binding generation

This appears to have been copied from D bindings without updating the output
filename.

3 years agofix various typos in Javascript bindings configuration
Matthew Fernandez [Tue, 31 Aug 2021 02:59:20 +0000 (19:59 -0700)]
fix various typos in Javascript bindings configuration

This appears to have been copied from the D bindings in
aebb9927a3670e02a0c3e83933dfea3c7bf8dbbe, with numerous text chunks taken
verbatim.

3 years agoMerge branch 'smattr/F500167B-4E3B-48CB-B3CC-D74707171300' into 'main'
Matthew Fernandez [Sat, 4 Sep 2021 16:14:56 +0000 (16:14 +0000)]
Merge branch 'smattr/F500167B-4E3B-48CB-B3CC-D74707171300' into 'main'

yet more Pylint warning squashing

See merge request graphviz/graphviz!2136

3 years agotest_shapes.py: address missing docstrings
Matthew Fernandez [Thu, 2 Sep 2021 03:32:52 +0000 (20:32 -0700)]
test_shapes.py: address missing docstrings

3 years agortest.py: remove shadowing of 'TEST'
Matthew Fernandez [Thu, 2 Sep 2021 03:30:41 +0000 (20:30 -0700)]
rtest.py: remove shadowing of 'TEST'

3 years agortest.py: remove 'OUTDIR' parameter to 'doDiff'
Matthew Fernandez [Thu, 2 Sep 2021 03:28:39 +0000 (20:28 -0700)]
rtest.py: remove 'OUTDIR' parameter to 'doDiff'

This parameter is available as a global. This change removes a Pylint
redefined-outer-name warning.

3 years agortest.py: remove 'REFDIR' parameter to 'doDiff'
Matthew Fernandez [Thu, 2 Sep 2021 03:26:54 +0000 (20:26 -0700)]
rtest.py: remove 'REFDIR' parameter to 'doDiff'

This parameter is available as a global. This change removes a Pylint
redefined-outer-name warning and a Pylint too-many-arguments warning.

3 years agortest.py: remove unused TESTNAME
Matthew Fernandez [Thu, 2 Sep 2021 03:22:31 +0000 (20:22 -0700)]
rtest.py: remove unused TESTNAME

Every usage of this within this file is actually referring to a closer variable
that shadows this global.

3 years agortest.py: address Pylint missing-function-docstring warnings
Matthew Fernandez [Thu, 2 Sep 2021 03:18:17 +0000 (20:18 -0700)]
rtest.py: address Pylint missing-function-docstring warnings

3 years agoshapes.py: remove variable shadowing
Matthew Fernandez [Thu, 2 Sep 2021 03:13:24 +0000 (20:13 -0700)]
shapes.py: remove variable shadowing

Squashes Pylint redefined-outer-name warnings.

3 years agoMerge branch 'smattr/07ffb8b9-aba1-45d9-a6b4-abf34e9278e4' into 'main'
Matthew Fernandez [Sat, 4 Sep 2021 04:22:29 +0000 (04:22 +0000)]
Merge branch 'smattr/07ffb8b9-aba1-45d9-a6b4-abf34e9278e4' into 'main'

ellipse.c clean up

See merge request graphviz/graphviz!2125

3 years agochange ellipse.c #if STANDALONE to #ifdef
Matthew Fernandez [Sun, 29 Aug 2021 19:36:47 +0000 (12:36 -0700)]
change ellipse.c #if STANDALONE to #ifdef

From later usage of this macro in the same file, it looks like this is what was
intended. Squashes a -Wundef build warning.

3 years agogenEllipticPath: remove shadowing of 'etaB' variable
Matthew Fernandez [Sun, 29 Aug 2021 19:33:08 +0000 (12:33 -0700)]
genEllipticPath: remove shadowing of 'etaB' variable

3 years agogenEllipticPath: remove shadowing of 'dEta' variable
Matthew Fernandez [Sun, 29 Aug 2021 19:31:56 +0000 (12:31 -0700)]
genEllipticPath: remove shadowing of 'dEta' variable

3 years agoendPath: remove shadowing of global 'path' variable
Matthew Fernandez [Sun, 29 Aug 2021 19:30:21 +0000 (12:30 -0700)]
endPath: remove shadowing of global 'path' variable

3 years agocurveTo: remove shadowing of global 'path' variable
Matthew Fernandez [Sun, 29 Aug 2021 19:29:36 +0000 (12:29 -0700)]
curveTo: remove shadowing of global 'path' variable

3 years agolineTo: remove shadowing of global 'path' variable
Matthew Fernandez [Sun, 29 Aug 2021 19:27:57 +0000 (12:27 -0700)]
lineTo: remove shadowing of global 'path' variable

3 years agomoveTo: remove shadowing of global 'path' variable
Matthew Fernandez [Sun, 29 Aug 2021 19:27:05 +0000 (12:27 -0700)]
moveTo: remove shadowing of global 'path' variable

3 years agogenEllipticPath: remove shadowing of global 'path' variable
Matthew Fernandez [Sun, 29 Aug 2021 19:23:37 +0000 (12:23 -0700)]
genEllipticPath: remove shadowing of global 'path' variable

3 years agoremove some unused struct names
Matthew Fernandez [Sun, 29 Aug 2021 19:20:25 +0000 (12:20 -0700)]
remove some unused struct names

3 years agogenEllipticPath: remove 'degree' parameter
Matthew Fernandez [Sun, 29 Aug 2021 19:18:02 +0000 (12:18 -0700)]
genEllipticPath: remove 'degree' parameter

This function is only ever called with the argument 3.

3 years agogenEllipticPath: remove 'threshold' parameter
Matthew Fernandez [Sun, 29 Aug 2021 19:08:31 +0000 (12:08 -0700)]
genEllipticPath: remove 'threshold' parameter

This is always called with the same threshold.

3 years agoremove now-unused hand rolled boolean type
Matthew Fernandez [Sun, 29 Aug 2021 19:05:58 +0000 (12:05 -0700)]
remove now-unused hand rolled boolean type

3 years agoendPath: remove 'close' parameter
Matthew Fernandez [Sun, 29 Aug 2021 19:05:26 +0000 (12:05 -0700)]
endPath: remove 'close' parameter

This function is only ever called with the argument true.

3 years agogenEllipticPath: remove 'isSlice' parameter
Matthew Fernandez [Sun, 29 Aug 2021 19:04:10 +0000 (12:04 -0700)]
genEllipticPath: remove 'isSlice' parameter

This function is only ever called with the argument true.

3 years agogenEllipticPath: remove unnecessary bracketing
Matthew Fernandez [Sun, 29 Aug 2021 19:01:20 +0000 (12:01 -0700)]
genEllipticPath: remove unnecessary bracketing

3 years agogenEllipticPath: use a C99 bool instead of boolean type
Matthew Fernandez [Sun, 29 Aug 2021 18:58:51 +0000 (11:58 -0700)]
genEllipticPath: use a C99 bool instead of boolean type

3 years agoMerge branch 'smattr/CC730FC7-8FD1-477A-B0A9-3F40CD40836A' into 'main'
Matthew Fernandez [Sat, 4 Sep 2021 03:26:15 +0000 (03:26 +0000)]
Merge branch 'smattr/CC730FC7-8FD1-477A-B0A9-3F40CD40836A' into 'main'

clean up in lib/common

See merge request graphviz/graphviz!2126