]> granicus.if.org Git - graphviz/log
graphviz
3 years agocommon: remove now obsolete exporting of geomprocs.h symbols from gvc.def
Magnus Jacobsson [Wed, 15 Dec 2021 20:41:12 +0000 (21:41 +0100)]
common: remove now obsolete exporting of geomprocs.h symbols from gvc.def

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agocommon: correct storage-class attribute declarations in geomprocs.h
Magnus Jacobsson [Wed, 28 Jul 2021 06:00:33 +0000 (08:00 +0200)]
common: correct storage-class attribute declarations in geomprocs.h

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agoMerge branch 'remove-colorprocs-h-symbols-from-gvc-def-file' into 'main'
Magnus Jacobsson [Wed, 29 Dec 2021 06:18:01 +0000 (06:18 +0000)]
Merge branch 'remove-colorprocs-h-symbols-from-gvc-def-file' into 'main'

Remove colorprocs.h symbols from gvc.def

See merge request graphviz/graphviz!2373

3 years agocommon: remove now obsolete exporting of colorprocs.h symbols from gvc.def
Magnus Jacobsson [Wed, 15 Dec 2021 06:46:15 +0000 (07:46 +0100)]
common: remove now obsolete exporting of colorprocs.h symbols from gvc.def

Note that the canontoken and colorCvt functions in colorprocs.h were
not exported from gvc.def.

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agocommon: add storage-class attribute declarations in colorprocs.h
Magnus Jacobsson [Tue, 27 Jul 2021 09:48:19 +0000 (11:48 +0200)]
common: add storage-class attribute declarations in colorprocs.h

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agocommon: include config.h in colorprocs.h to get GVDLL in autotools builds
Magnus Jacobsson [Sat, 11 Dec 2021 14:57:39 +0000 (15:57 +0100)]
common: include config.h in colorprocs.h to get GVDLL in autotools builds

An upcoming commit that corrects the storage-class attribute
declarations in colorprocs.h would otherwise cause this error:

/usr/lib/gcc/x86_64-pc-cygwin/10/../../../../x86_64-pc-cygwin/bin/ld: ../../lib/sparse/.libs/libsparse_C.a(DotIO.o): in function `Import_coord_clusters_from_dot':
/home/magja/graphviz/lib/sparse/DotIO.c:577: undefined reference to `colorxlate'

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agoMerge branch 'smattr/a45c8ab0-d6e4-4cb7-8f28-61abb60c7359' into 'main'
Matthew Fernandez [Tue, 28 Dec 2021 22:02:28 +0000 (22:02 +0000)]
Merge branch 'smattr/a45c8ab0-d6e4-4cb7-8f28-61abb60c7359' into 'main'

migrate some more bool arrays to bit arrays

See merge request graphviz/graphviz!2356

3 years agoMerge branch 'remove-gvcint-h-symbols-from-gvc-def-file' into 'main'
Magnus Jacobsson [Tue, 28 Dec 2021 21:34:18 +0000 (21:34 +0000)]
Merge branch 'remove-gvcint-h-symbols-from-gvc-def-file' into 'main'

Remove gvcint.h symbols from gvc.def

See merge request graphviz/graphviz!2371

3 years agogvc: remove now obsolete exporting of gvcint.h symbols from gvc.def
Magnus Jacobsson [Wed, 15 Dec 2021 06:30:26 +0000 (07:30 +0100)]
gvc: remove now obsolete exporting of gvcint.h symbols from gvc.def

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agogvc: add storage-class attribute declarations in gvcint.h
Magnus Jacobsson [Mon, 26 Jul 2021 15:01:07 +0000 (17:01 +0200)]
gvc: add storage-class attribute declarations in gvcint.h

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agoextract_adjacency: use bit arrays instead of bool arrays for neighbours lists
Matthew Fernandez [Wed, 22 Dec 2021 04:35:26 +0000 (20:35 -0800)]
extract_adjacency: use bit arrays instead of bool arrays for neighbours lists

This reduces memory usage of this function.

3 years agosgd_graph: use 'size_t' for 'sources' and 'targets'
Matthew Fernandez [Wed, 22 Dec 2021 04:24:06 +0000 (20:24 -0800)]
sgd_graph: use 'size_t' for 'sources' and 'targets'

Following on from 1c42bb82cd73cb45d3abee845c21819add00d982, this uses a more
appropriate type for these members, permitting collections that exceed 2³² - 1
and avoiding sign conversion issues.

3 years agoMerge branch 'smattr/FF411856-89EB-4528-B888-34D18055BAC2' into 'main'
Matthew Fernandez [Tue, 28 Dec 2021 00:14:10 +0000 (00:14 +0000)]
Merge branch 'smattr/FF411856-89EB-4528-B888-34D18055BAC2' into 'main'

osage: fix some function prototyping

See merge request graphviz/graphviz!2357

3 years agoprototype osage_layout and osage_cleanup in osage.h
Matthew Fernandez [Wed, 22 Dec 2021 16:15:29 +0000 (08:15 -0800)]
prototype osage_layout and osage_cleanup in osage.h

These are the only functions lib/osage exports. Yet neither were prototyped in a
header. It seems like this header could now be #included in
plugin/neato_layout/gvlayout_neato_layout.c, removing the need for that file to
prototype these functions. Except that it gives slightly different prototypes
for them.

3 years agoremove osage prototypes of unimplemented functions
Matthew Fernandez [Wed, 22 Dec 2021 16:13:03 +0000 (08:13 -0800)]
remove osage prototypes of unimplemented functions

3 years agoMerge branch 'smattr/47AD173A-739B-4728-A786-2C40BEE7D75C' into 'main'
Matthew Fernandez [Mon, 27 Dec 2021 21:01:54 +0000 (21:01 +0000)]
Merge branch 'smattr/47AD173A-739B-4728-A786-2C40BEE7D75C' into 'main'

some neatogen linkage clean up

See merge request graphviz/graphviz!2354

3 years agomove_node: make a static function
Matthew Fernandez [Mon, 20 Dec 2021 16:14:38 +0000 (08:14 -0800)]
move_node: make a static function

This function is not used outside of stuff.c.

3 years agomake_spring: make a static function
Matthew Fernandez [Mon, 20 Dec 2021 16:13:44 +0000 (08:13 -0800)]
make_spring: make a static function

This function is not used outside of stuff.c.

3 years agoheapup: make a static function
Matthew Fernandez [Mon, 20 Dec 2021 16:11:14 +0000 (08:11 -0800)]
heapup: make a static function

This function is not used outside of stuff.c.

3 years agoheapdown: make a static function
Matthew Fernandez [Mon, 20 Dec 2021 16:10:22 +0000 (08:10 -0800)]
heapdown: make a static function

This function is not used outside of stuff.c.

3 years agofpow32: make a static function
Matthew Fernandez [Mon, 20 Dec 2021 16:08:19 +0000 (08:08 -0800)]
fpow32: make a static function

This function is not used outside of stuff.c.

3 years agoremove unused 'final_energy'
Matthew Fernandez [Mon, 20 Dec 2021 16:07:45 +0000 (08:07 -0800)]
remove unused 'final_energy'

3 years agodistvec: make a static function
Matthew Fernandez [Mon, 20 Dec 2021 16:06:55 +0000 (08:06 -0800)]
distvec: make a static function

This function is not used outside of stuff.c.

3 years agoD2E: make a static
Matthew Fernandez [Mon, 20 Dec 2021 16:05:47 +0000 (08:05 -0800)]
D2E: make a static

This function is not used outside of stuff.c.

3 years agochoose_node: make a static function
Matthew Fernandez [Mon, 20 Dec 2021 16:04:07 +0000 (08:04 -0800)]
choose_node: make a static function

This is not used outside of stuff.c.

3 years agoremote prototype for unimplemented 'avoid_cycling'
Matthew Fernandez [Mon, 20 Dec 2021 16:03:46 +0000 (08:03 -0800)]
remote prototype for unimplemented 'avoid_cycling'

3 years agoMerge branch 'smattr/e18d313d-2db6-47c6-8bc4-3f8a7714252f' into 'main'
Matthew Fernandez [Mon, 27 Dec 2021 20:03:01 +0000 (20:03 +0000)]
Merge branch 'smattr/e18d313d-2db6-47c6-8bc4-3f8a7714252f' into 'main'

fix: configure output when Lefty is disabled

See merge request graphviz/graphviz!2360

3 years agoMerge branch 'remove-gvio-h-symbols-from-gvc-def-file' into 'main'
Magnus Jacobsson [Mon, 27 Dec 2021 19:24:55 +0000 (19:24 +0000)]
Merge branch 'remove-gvio-h-symbols-from-gvc-def-file' into 'main'

Remove gvio.h symbols from gvc.def

See merge request graphviz/graphviz!2368

3 years agofix: configure output when Lefty is disabled
Matthew Fernandez [Fri, 24 Dec 2021 18:39:53 +0000 (10:39 -0800)]
fix: configure output when Lefty is disabled

Commit 1a4ad00b59cc1e1e9302fcbd1a205495ee59cab5 disabled Lefty by default in the
Autotools build system but accidentally made the configure output say nothing
next to "Lefty: " when Lefty is disabled.

3 years agogvc: remove now obsolete exporting of gvio.h symbols from gvc.def
Magnus Jacobsson [Wed, 15 Dec 2021 05:19:15 +0000 (06:19 +0100)]
gvc: remove now obsolete exporting of gvio.h symbols from gvc.def

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agogvc: correct storage-class attribute declarations in gvio.h
Magnus Jacobsson [Mon, 26 Jul 2021 14:57:20 +0000 (16:57 +0200)]
gvc: correct storage-class attribute declarations in gvio.h

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agoMerge branch 'remove-gvplugin_loadimage-h-symbols-from-gvc-def-file' into 'main'
Magnus Jacobsson [Sun, 26 Dec 2021 20:18:58 +0000 (20:18 +0000)]
Merge branch 'remove-gvplugin_loadimage-h-symbols-from-gvc-def-file' into 'main'

Remove gvplugin_loadimage.h symbols from gvc.def

See merge request graphviz/graphviz!2367

3 years agogvc: remove now obsolete exporting of gvplugin_loadimage.h symbols from gvc.def
Magnus Jacobsson [Tue, 14 Dec 2021 20:25:58 +0000 (21:25 +0100)]
gvc: remove now obsolete exporting of gvplugin_loadimage.h symbols from gvc.def

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agogvc: correct storage-class attribute declarations in gvplugin_loadimage.h
Magnus Jacobsson [Mon, 26 Jul 2021 14:55:15 +0000 (16:55 +0200)]
gvc: correct storage-class attribute declarations in gvplugin_loadimage.h

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agoMerge branch 'remove-timing.h' into 'main'
Magnus Jacobsson [Sun, 26 Dec 2021 08:22:06 +0000 (08:22 +0000)]
Merge branch 'remove-timing.h' into 'main'

Remove timing.h

See merge request graphviz/graphviz!2363

3 years agocommon: remove now unused timing.h
Magnus Jacobsson [Wed, 4 Aug 2021 09:05:30 +0000 (11:05 +0200)]
common: remove now unused timing.h

3 years agocommon: autotools: remove now unused timing.h
Magnus Jacobsson [Wed, 4 Aug 2021 09:05:30 +0000 (11:05 +0200)]
common: autotools: remove now unused timing.h

3 years agotred: include common/utils.h instead of duplicate defs from common/timing.h
Magnus Jacobsson [Wed, 4 Aug 2021 09:04:58 +0000 (11:04 +0200)]
tred: include common/utils.h instead of duplicate defs from common/timing.h

3 years agotred: rename DIST macro to avoid shadowing
Magnus Jacobsson [Sun, 12 Dec 2021 09:24:35 +0000 (10:24 +0100)]
tred: rename DIST macro to avoid shadowing

The next commit in this series will include types.h which transitively
includes geom.h which has another DIST macro defined.

Without this change, this error would occur:

FAILED: cmd/tools/CMakeFiles/tred.dir/tred.c.obj
C:\tools\msys64\mingw64\bin\ccache.exe  gcc -DDEMAND_LOADING=0 -DDIGCOLA -DENABLE_LTDL -DGVDLL -DORTHO -DSFDP -IC:/Users/magja/graphviz/build -IC:/Users/magja/graphviz/lib -IC:/Users/magja/graphviz/cmd/tools -IC:/Users/magja/graphviz/build/cmd/tools -IC:/Users/magja/graphviz/lib/cdt -IC:/Users/magja/graphviz/lib/cgraph -IC:/Users/magja/graphviz/lib/common -IC:/Users/magja/graphviz/lib/gvc -IC:/Users/magja/graphviz/lib/pack -IC:/Users/magja/graphviz/lib/pathplan -Werror -Wall -std=gnu99 -MD -MT cmd/tools/CMakeFiles/tred.dir/tred.c.obj -MF cmd\tools\CMakeFiles\tred.dir\tred.c.obj.d -o cmd/tools/CMakeFiles/tred.dir/tred.c.obj -c C:/Users/magja/graphviz/cmd/tools/tred.c
C:/Users/magja/graphviz/cmd/tools/tred.c:38: error: "DIST" redefined [-Werror]
   38 | #define DIST(ninfo,n) (ninfo[AGSEQ(n)].dist)
      |
In file included from C:/Users/magja/graphviz/lib/common/types.h:31,
                 from C:/Users/magja/graphviz/cmd/tools/tred.c:24:
C:/Users/magja/graphviz/lib/common/geom.h:53: note: this is the location of the previous definition
   53 | #define DIST(p,q)  (sqrt(DIST2((p),(q))))
      |

3 years agotred: MSBuild: add pathplan include directory
Magnus Jacobsson [Wed, 4 Aug 2021 13:55:57 +0000 (15:55 +0200)]
tred: MSBuild: add pathplan include directory

An upcoming commit that changes tred.c to include utils.h instead of
timing.h would otherwise cause this error:

C:\Users\magja\graphviz\lib\common\types.h(33,10): fatal error C1083: Cannot open include file: 'pathgeom.h': No such file or directory

3 years agotred: MSBuild: add gvc include directory
Magnus Jacobsson [Wed, 4 Aug 2021 13:32:28 +0000 (15:32 +0200)]
tred: MSBuild: add gvc include directory

An upcoming commit that changes tred.c to include utils.h instead of
timing.h would otherwise cause this error:

C:\Users\magja\graphviz\lib\common\types.h(32,10): fatal error C1083: Cannot open include file: 'gvcext.h': No such file or directory

3 years agotred: autotools: link to the shared gvc lib instead of the static common lib
Magnus Jacobsson [Wed, 4 Aug 2021 09:04:58 +0000 (11:04 +0200)]
tred: autotools: link to the shared gvc lib instead of the static common lib

The common lib is built into the gvc lib.

An upcoming commit that changes tred.c to include utils.h instead of
timing.h would otherwise cause these errors:

/usr/lib/gcc/x86_64-pc-cygwin/11/../../../../x86_64-pc-cygwin/bin/ld: tred.o: in function `process':
/cygdrive/c/GitLab-Runner/builds/magjac/graphviz/cmd/tools/tred.c:296: undefined reference to `__imp_start_timer'
/usr/lib/gcc/x86_64-pc-cygwin/11/../../../../x86_64-pc-cygwin/bin/ld: /cygdrive/c/GitLab-Runner/builds/magjac/graphviz/cmd/tools/tred.c:299: undefined reference to `__imp_elapsed_sec'

3 years agotred: CMake: link to the gvc lib instead of the common lib
Magnus Jacobsson [Wed, 4 Aug 2021 09:04:58 +0000 (11:04 +0200)]
tred: CMake: link to the gvc lib instead of the common lib

The common lib is a static lib which is built into the shared gvc lib.

An upcoming commit that changes tred.c to include utils.h instead of
timing.h would otherwise cause these errors:

C:/tools/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: cmd/tools/CMakeFiles/tred.dir/tred.c.obj:tred.c:(.text+0xb47): undefined reference to `__imp_start_timer'
C:/tools/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: cmd/tools/CMakeFiles/tred.dir/tred.c.obj:tred.c:(.text+0xb7a): undefined reference to `__imp_elapsed_sec'

3 years agoMerge branch 'remove-pointset-h-symbols-from-gvc-def-file' into 'main'
Magnus Jacobsson [Sun, 26 Dec 2021 06:54:13 +0000 (06:54 +0000)]
Merge branch 'remove-pointset-h-symbols-from-gvc-def-file' into 'main'

Remove pointset.h symbols from gvc.def

See merge request graphviz/graphviz!2365

3 years agocommon: remove now obsolete exporting of pointset.h symbols from gvc.def
Magnus Jacobsson [Tue, 14 Dec 2021 20:20:06 +0000 (21:20 +0100)]
common: remove now obsolete exporting of pointset.h symbols from gvc.def

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agocommon: correct storage-class attribute declarations in pointset.h
Magnus Jacobsson [Mon, 26 Jul 2021 14:53:22 +0000 (16:53 +0200)]
common: correct storage-class attribute declarations in pointset.h

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agoMerge branch 'remove-pack-h-symbols-from-gvc-def' into 'main'
Magnus Jacobsson [Sat, 25 Dec 2021 23:09:12 +0000 (23:09 +0000)]
Merge branch 'remove-pack-h-symbols-from-gvc-def' into 'main'

Remove pack.h symbols from gvc.def

See merge request graphviz/graphviz!2364

3 years agopack: remove now obsolete exporting of pack.h symbols from gvc.def
Magnus Jacobsson [Tue, 14 Dec 2021 20:13:19 +0000 (21:13 +0100)]
pack: remove now obsolete exporting of pack.h symbols from gvc.def

Note that the packRects and shiftGraphs functions in pack.h was not
exported from gvc.def.

3 years agopack: correct storage-class attribute declarations in pack.h
Magnus Jacobsson [Mon, 26 Jul 2021 13:36:34 +0000 (15:36 +0200)]
pack: correct storage-class attribute declarations in pack.h

3 years agoMerge branch 'remove-utils-h-symbols-from-gvc-def-file' into 'main'
Magnus Jacobsson [Sat, 25 Dec 2021 22:00:50 +0000 (22:00 +0000)]
Merge branch 'remove-utils-h-symbols-from-gvc-def-file' into 'main'

Remove utils.h symbols from gvc.def file

See merge request graphviz/graphviz!2361

3 years agocommon: remove now obsolete exporting of utils.h symbols from gvc.def
Magnus Jacobsson [Sat, 18 Dec 2021 14:53:52 +0000 (15:53 +0100)]
common: remove now obsolete exporting of utils.h symbols from gvc.def

3 years agocommon: correct storage-class attribute declarations in utils.h
Magnus Jacobsson [Mon, 26 Jul 2021 13:33:57 +0000 (15:33 +0200)]
common: correct storage-class attribute declarations in utils.h

This will allow removing the utils.h symbols from the gvc.def file in
an upcoming commit.

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agocommon: include utils.h and types.h in timing.c also for _WIN32
Magnus Jacobsson [Sat, 25 Dec 2021 14:50:26 +0000 (15:50 +0100)]
common: include utils.h and types.h in timing.c also for _WIN32

This ensures that the timing functions are declared with the
storage-class attributes from utils.h.

An upcoming commit that corrects the storage-class attribute
declarations in utils.h would otherwise cause these errors:

/usr/lib/gcc/x86_64-pc-cygwin/10/../../../../x86_64-pc-cygwin/bin/ld: ../../lib/dotgen/.libs/libdotgen_C.a(mincross.o): in function `init_mincross':
/home/magja/graphviz/lib/dotgen/mincross.c:1163: undefined reference to `__imp_start_timer'
/usr/lib/gcc/x86_64-pc-cygwin/10/../../../../x86_64-pc-cygwin/bin/ld: ../../lib/dotgen/.libs/libdotgen_C.a(mincross.o): in function `cleanup2':
/home/magja/graphviz/lib/dotgen/mincross.c:996: undefined reference to `__imp_elapsed_sec'

The reason for also including types.h is that utils.h depends on it
without including it itself for unclear reasons.

Note that these functions are also redundantly declared in
timing.h. This file will be removed in an upcoming commit series.

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agocommon: include types.h instead of render.h in timing.c
Magnus Jacobsson [Sat, 25 Dec 2021 14:46:02 +0000 (15:46 +0100)]
common: include types.h instead of render.h in timing.c

This file does not explicitly need either of thoses files, but it
includes utils.h that needs types.h. It is better to include this file
directly rather transitively through render.h.

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agoMerge branch 'smattr/ce9e6cdc-f5de-4342-959e-4e83691b2521' into 'main'
Matthew Fernandez [Sat, 25 Dec 2021 20:40:50 +0000 (20:40 +0000)]
Merge branch 'smattr/ce9e6cdc-f5de-4342-959e-4e83691b2521' into 'main'

some warning squashing

See merge request graphviz/graphviz!2358

3 years agotranslate_drawing: [nfc] use a bool for 'shift' for clearer intent
Matthew Fernandez [Fri, 24 Dec 2021 16:53:03 +0000 (08:53 -0800)]
translate_drawing: [nfc] use a bool for 'shift' for clearer intent

3 years agopostproc.c: [nfc] remove excess parens and fix spacing
Matthew Fernandez [Fri, 24 Dec 2021 16:49:51 +0000 (08:49 -0800)]
postproc.c: [nfc] remove excess parens and fix spacing

3 years agogv_postprocess: squash a -Wswitch-default warning
Matthew Fernandez [Fri, 24 Dec 2021 16:35:18 +0000 (08:35 -0800)]
gv_postprocess: squash a -Wswitch-default warning

3 years agomkIntItem: [nfc] remove unnecessary cast
Matthew Fernandez [Fri, 24 Dec 2021 16:33:44 +0000 (08:33 -0800)]
mkIntItem: [nfc] remove unnecessary cast

3 years agointset.c: [nfc] squash unused parameter warnings
Matthew Fernandez [Fri, 24 Dec 2021 16:32:36 +0000 (08:32 -0800)]
intset.c: [nfc] squash unused parameter warnings

3 years agoMerge branch 'smattr/5b62a26e-782a-40b2-a9a7-ac1eea617c8b' into 'main'
Matthew Fernandez [Sat, 25 Dec 2021 19:38:01 +0000 (19:38 +0000)]
Merge branch 'smattr/5b62a26e-782a-40b2-a9a7-ac1eea617c8b' into 'main'

more boolean → bool modernization

See merge request graphviz/graphviz!2353

3 years agomakeObstacle: [nfc] take a C99 bool parameter instead of a boolean
Matthew Fernandez [Mon, 20 Dec 2021 04:10:56 +0000 (20:10 -0800)]
makeObstacle: [nfc] take a C99 bool parameter instead of a boolean

3 years agoremove prototype for unimplemented 'init_port'
Matthew Fernandez [Mon, 20 Dec 2021 04:08:50 +0000 (20:08 -0800)]
remove prototype for unimplemented 'init_port'

3 years agogvrender_usershape: [nfc] take a C99 bool parameter instead of a boolean
Matthew Fernandez [Mon, 20 Dec 2021 04:03:48 +0000 (20:03 -0800)]
gvrender_usershape: [nfc] take a C99 bool parameter instead of a boolean

3 years agogvloadimage: [nfc] take a C99 bool parameter instead of a boolean
Matthew Fernandez [Mon, 20 Dec 2021 04:01:22 +0000 (20:01 -0800)]
gvloadimage: [nfc] take a C99 bool parameter instead of a boolean

3 years agogvtextlayout: [nfc] return a C99 bool instead of a boolean
Matthew Fernandez [Mon, 20 Dec 2021 03:58:56 +0000 (19:58 -0800)]
gvtextlayout: [nfc] return a C99 bool instead of a boolean

3 years agogvconfig: [nfc] take a C99 bool parameter instead of a boolean
Matthew Fernandez [Mon, 20 Dec 2021 03:55:50 +0000 (19:55 -0800)]
gvconfig: [nfc] take a C99 bool parameter instead of a boolean

3 years agogv_nodesize: [nfc] take a C99 bool instead of a boolean
Matthew Fernandez [Mon, 20 Dec 2021 03:45:27 +0000 (19:45 -0800)]
gv_nodesize: [nfc] take a C99 bool instead of a boolean

3 years agopoly_init: rephrase some open coded 'fmax'
Matthew Fernandez [Mon, 20 Dec 2021 03:41:40 +0000 (19:41 -0800)]
poly_init: rephrase some open coded 'fmax'

3 years agoplace_portlabel: [nfc] take a C99 bool parameter instead of a boolean
Matthew Fernandez [Mon, 20 Dec 2021 03:36:24 +0000 (19:36 -0800)]
place_portlabel: [nfc] take a C99 bool parameter instead of a boolean

3 years agoshapes.c: [nfc] remove unnecessary parens
Matthew Fernandez [Mon, 20 Dec 2021 03:25:53 +0000 (19:25 -0800)]
shapes.c: [nfc] remove unnecessary parens

3 years agoisPolygon: [nfc] use a C99 bool return type instead of boolean
Matthew Fernandez [Mon, 20 Dec 2021 03:01:35 +0000 (19:01 -0800)]
isPolygon: [nfc] use a C99 bool return type instead of boolean

3 years agoMerge branch 'smattr/56143E8A-A8C1-4923-83EE-78FA1AA7FE44' into 'main'
Matthew Fernandez [Thu, 23 Dec 2021 02:00:00 +0000 (02:00 +0000)]
Merge branch 'smattr/56143E8A-A8C1-4923-83EE-78FA1AA7FE44' into 'main'

make 'solve1' and 'solve2' static functions

See merge request graphviz/graphviz!2351

3 years agomake 'solve1' and 'solve2' static functions
Matthew Fernandez [Sun, 19 Dec 2021 21:46:44 +0000 (13:46 -0800)]
make 'solve1' and 'solve2' static functions

As of 9550d5dae1a487617a8910b1b496ffd12c78a546, these functions are no longer
exported or needed outside of solvers.c. `solve3` has occasionally been a
hotspot for performance-constrained Graphviz use cases. So making it more
obvious to the compiler that it can inline and/or specialize `solve1` and
`solve2` may provide some speed up.

3 years agoMerge branch 'remove-gvc-h-symbols-from-gvc-def-file' into 'main'
Magnus Jacobsson [Wed, 22 Dec 2021 06:01:31 +0000 (06:01 +0000)]
Merge branch 'remove-gvc-h-symbols-from-gvc-def-file' into 'main'

Remove gvc.h symbols from gvc.def file

See merge request graphviz/graphviz!2355

3 years agoortho: MSBuild: define GVC_EXPORTS to ensure correct storage-class attributes
Magnus Jacobsson [Sun, 1 Aug 2021 16:01:01 +0000 (18:01 +0200)]
ortho: MSBuild: define GVC_EXPORTS to ensure correct storage-class attributes

The ortho lib is a static library which is linked into the
dynamic-link gvc lib and both use GVC_EXPORTS to control the
storage-class.

Removes many warnings like:

LINK : warning LNK4286: symbol '_gcalloc' defined in 'memory.obj' is imported by 'gvortho.lib(ortho.obj)' [C:\Users\magja\graphviz\lib\gvc.vcxproj]
LINK : warning LNK4217: symbol '_gcalloc' defined in 'memory.obj' is imported by 'gvortho.lib(trapezoid.obj)' in function '_construct_trapezoids' [C:\Users\magja\graphviz\lib\gvc.vcxproj]
C:\Users\magja\graphviz\lib\ortho\ortho.c(1250,1): warning C4273: 'orthoEdges': inconsistent dll linkage [C:\Users\magja\graphviz\lib\ortho\gvortho.vcxproj]

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agogvc: remove now obsolete exporting of gvc.h symbols from gvc.def
Magnus Jacobsson [Mon, 13 Dec 2021 21:30:24 +0000 (22:30 +0100)]
gvc: remove now obsolete exporting of gvc.h symbols from gvc.def

Note that the findStopColor function in gvc.h was missing in gvc.def.

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agogvc: unify diverged storage-class attributes in gvc.h
Magnus Jacobsson [Mon, 26 Jul 2021 12:44:47 +0000 (14:44 +0200)]
gvc: unify diverged storage-class attributes in gvc.h

More specifically, add support for the dllexport storage-class
attribute for all build systems under Windows, MinGW and Cygwin.

This will allow removing the gvc.h symbols from the gvc.def file in an
upcoming commit.

This change makes the gvc.h file conform to
https://gitlab.com/graphviz/graphviz/-/issues/2058#note_678679545.

This file had one set of Windows-specific storage-class attribute
declarations intended for use with the autotools build system and one
set intended for use with Visual Studio, with slightly different
control mechanisms.

It's unclear what effect changes made to these control mechanisms over
the years has had on the many operating systems that are not tested in
CI. The current state is that they partly overlap and are very hard to
understand.

This commit cleans this up by applying such declarations only if the
GVDLL or symbol is set. An export declaration is used if the
GVC_EXPORT symbol is defined and an import declaration otherwise.

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agogvc: add storage-class attribute declaration of gvLayoutDone in gvc.h
Magnus Jacobsson [Thu, 12 Aug 2021 09:23:06 +0000 (11:23 +0200)]
gvc: add storage-class attribute declaration of gvLayoutDone in gvc.h

This function was introduced in
6f46c2c224180dc238851d2fb88d1fb909548376 which was part of a branch
which initially originated before the storage-class attributes for the
other functions in this file were introduced. This was not noted when
this branch was rebased before merge.

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agoMerge branch 'smattr/5b8a0597-32a7-4c76-be6a-e874c07336b4' into 'main'
Matthew Fernandez [Wed, 22 Dec 2021 04:23:18 +0000 (04:23 +0000)]
Merge branch 'smattr/5b8a0597-32a7-4c76-be6a-e874c07336b4' into 'main'

introduce an abstraction for compacted boolean arrays

See merge request graphviz/graphviz!2345

3 years agograph_sgd: convert 'pinned' bool array to a bit array
Matthew Fernandez [Sat, 18 Dec 2021 22:51:17 +0000 (14:51 -0800)]
graph_sgd: convert 'pinned' bool array to a bit array

3 years agograph_sgd: track number of nodes as a 'size_t' instead of 'int'
Matthew Fernandez [Sun, 19 Dec 2021 21:16:00 +0000 (13:16 -0800)]
graph_sgd: track number of nodes as a 'size_t' instead of 'int'

This squashes a number of compiler warnings and allows this struct to deal with
> 2³² - 1 nodes in future. Dealing with this number of nodes now is still not
possible due to locations where conversion back to `int` is necessary. In
future the source and target index arrays in this struct should probably be
converted to `size_t` too, but that was not done in this commit as it involves
more invasive changes.

3 years agointroduce an abstraction for compacted boolean arrays
Matthew Fernandez [Thu, 16 Dec 2021 01:46:16 +0000 (17:46 -0800)]
introduce an abstraction for compacted boolean arrays

3 years agoMerge branch 'smattr/F1948FD5-8F64-4412-8925-3321F5EAC143' into 'main'
Matthew Fernandez [Tue, 21 Dec 2021 03:36:51 +0000 (03:36 +0000)]
Merge branch 'smattr/F1948FD5-8F64-4412-8925-3321F5EAC143' into 'main'

misc gvplugin.c clean up

See merge request graphviz/graphviz!2343

3 years agogvplugin.c: remove unnecessary parens
Matthew Fernandez [Thu, 4 Nov 2021 15:16:16 +0000 (08:16 -0700)]
gvplugin.c: remove unnecessary parens

3 years agogvplugin.c: fix comment typos
Matthew Fernandez [Thu, 4 Nov 2021 15:10:56 +0000 (08:10 -0700)]
gvplugin.c: fix comment typos

3 years agoMerge branch 'fix-neatogen-lib-warnings' into 'main'
Magnus Jacobsson [Mon, 20 Dec 2021 12:05:52 +0000 (12:05 +0000)]
Merge branch 'fix-neatogen-lib-warnings' into 'main'

Fix storage-class related warnings i the neatogen lib

See merge request graphviz/graphviz!2352

3 years agoset NEATOGEN_EXPORTS in sfdp.vcxproj
Magnus Jacobsson [Sun, 1 Aug 2021 17:17:34 +0000 (19:17 +0200)]
set NEATOGEN_EXPORTS in sfdp.vcxproj

Removes 6 warnings like the one below:

LINK : warning LNK4217: symbol '_neato_init_node' defined in 'neatogen.lib(neatoinit.obj)' is imported by 'sfdp.lib(sfdpinit.obj)' in function '_sfdp_layout' [C:\Users\magja\graphviz\plugin\neato_layout\gvplugin_neato_layout.vcxproj]

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agoset NEATOGEN_EXPORTS in gvtwopigen.vcxproj
Magnus Jacobsson [Sun, 1 Aug 2021 17:08:47 +0000 (19:08 +0200)]
set NEATOGEN_EXPORTS in gvtwopigen.vcxproj

Removes 4 warnings like the one below:

LINK : warning LNK4217: symbol '_neato_init_node' defined in 'neatogen.lib(neatoinit.obj)' is imported by 'twopigen.lib(twopiinit.obj)' in function '_twopi_init_graph' [C:\Users\magja\graphviz\plugin\neato_layout\gvplugin_neato_layout.vcxproj]

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agoset NEATOGEN_EXPORTS in gvfdpgen.vcxproj
Magnus Jacobsson [Sun, 1 Aug 2021 16:29:13 +0000 (18:29 +0200)]
set NEATOGEN_EXPORTS in gvfdpgen.vcxproj

Removes 18 warnings like the one below:

LINK : warning LNK4217: symbol '_spline_edges1' defined in 'neatogen.lib(neatosplines.obj)' is imported by 'fdpgen.lib(layout.obj)' in function '_fdp_layout' [C:\Users\magja\graphviz\plugin\neato_layout\gvplugin_neato_layout.vcxproj]

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agoset NEATOGEN_EXPORTS in gvcircogen.vcxproj
Magnus Jacobsson [Sun, 1 Aug 2021 16:25:37 +0000 (18:25 +0200)]
set NEATOGEN_EXPORTS in gvcircogen.vcxproj

Removes 4 warnings like the one below:

LINK : warning LNK4217: symbol '_neato_init_node' defined in 'neatogen.lib(neatoinit.obj)' is imported by 'circogen.lib(circularinit.obj)' in function '_circo_init_graph' [C:\Users\magja\graphviz\plugin\neato_layout\gvplugin_neato_layout.vcxproj]

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agoset NEATOGEN_EXPORTS in osage.vcxproj
Magnus Jacobsson [Sun, 1 Aug 2021 16:22:19 +0000 (18:22 +0200)]
set NEATOGEN_EXPORTS in osage.vcxproj

Removes 6 warnings like the one below:

LINK : warning LNK4217: symbol '_neato_init_node' defined in 'neatogen.lib(neatoinit.obj)' is imported by 'osage.lib(osageinit.obj)' in function '_layout' [C:\Users\magja\graphviz\plugin\neato_layout\gvplugin_neato_layout.vcxproj]

Towards https://gitlab.com/graphviz/graphviz/-/issues/2058.

3 years agoMerge branch 'remove-useless-exporting-of-symbols-in-gvc-def-file' into 'main'
Magnus Jacobsson [Mon, 20 Dec 2021 09:16:51 +0000 (09:16 +0000)]
Merge branch 'remove-useless-exporting-of-symbols-in-gvc-def-file' into 'main'

Remove useless exporting of symbols in gvc.def file

See merge request graphviz/graphviz!2348

3 years agoMerge branch 'smattr/9e8bb9bf-1a04-485d-ae0f-4920031a6a55' into 'main'
Matthew Fernandez [Mon, 20 Dec 2021 02:50:18 +0000 (02:50 +0000)]
Merge branch 'smattr/9e8bb9bf-1a04-485d-ae0f-4920031a6a55' into 'main'

more boolean → bool modernization

See merge request graphviz/graphviz!2350

3 years agoendpath: [nfc] take a C99 bool parameter instead of a boolean
Matthew Fernandez [Sun, 19 Dec 2021 20:42:56 +0000 (12:42 -0800)]
endpath: [nfc] take a C99 bool parameter instead of a boolean

3 years agoremove lib/pack/ptest.c
Matthew Fernandez [Sun, 19 Dec 2021 20:36:42 +0000 (12:36 -0800)]
remove lib/pack/ptest.c

This code has clearly bitrotted some time ago. E.g. it calls `graph_init` with
one parameter, but this function takes two parameters.

3 years agograph_init: [nfc] take a C99 bool parameter instead of a boolean
Matthew Fernandez [Sun, 19 Dec 2021 20:34:37 +0000 (12:34 -0800)]
graph_init: [nfc] take a C99 bool parameter instead of a boolean

3 years agoshape_clip0: [nfc] take a C99 bool parameter instead of a boolean
Matthew Fernandez [Sun, 19 Dec 2021 20:28:48 +0000 (12:28 -0800)]
shape_clip0: [nfc] take a C99 bool parameter instead of a boolean

3 years agobezier_clip: [nfc] take a C99 bool parameter instead of a boolean
Matthew Fernandez [Sun, 19 Dec 2021 20:26:36 +0000 (12:26 -0800)]
bezier_clip: [nfc] take a C99 bool parameter instead of a boolean

3 years agobeginpath: [nfc] use a C99 bool for a parameter instead of a boolean
Matthew Fernandez [Sun, 19 Dec 2021 20:20:58 +0000 (12:20 -0800)]
beginpath: [nfc] use a C99 bool for a parameter instead of a boolean