Erwin Janssen [Wed, 8 Feb 2017 20:38:41 +0000 (21:38 +0100)]
Add all header checks from configure.ac to CMake
The CMake build now checks for the same headers as the Autotools build.
The following headers checks were added:
- crt_externs.h
- fcntl.h
- memory.h
- search.h
- sys/inotify.h
- sys/ioctl.h
- sys/mman.h
- sys/select.h
- sys/time.h
- sys/vfork.h
- termios.h
- vfork.h
- X11/Intrinsic.h
- X11/Xaw/Text.h
Erwin Janssen [Tue, 7 Feb 2017 07:02:19 +0000 (08:02 +0100)]
Add lib/gvc to CMake build
The dynamic library `gvc` is the core library of Graphviz. It has various
dependencies, of which some are third party libraries. The DLLs of these
libraries will be included in the package on Windows.
Now also generating `builddate.h` on all platforms. The Windows Visual
Studio build didn't generate this file.
Now also defines GVPLUGIN_CONFIG_FILE, set to confg6, just like the
Autotools build.
Support the "enable-ltdl" option, default value is ON.
Now passing the "-fPIC" to all compilers, except MSVC.
The following checks have been added:
- FindLTDL
- FindRxSpencer (on Windows only)
Erwin Janssen [Fri, 3 Feb 2017 16:50:02 +0000 (17:50 +0100)]
Add lib/common to CMake build
The static library 'common' has no dependencies.
The following checks have been added:
- FindAWK (custom CMake module added)
- FindPerl
- FindEXPAT
- FindZLIB
- HAVE_SINCOS
- HAVE_STRINGS_H
- HAVE_SYS_TYPES_H
- HAVE_STRNCASECMP_H
The steps to generate `colortbl.h` and `ps_font_equiv.h` are the same as
in the Autotools build. DEFAULT_DPI is now set in the config.h generated
by CMake.
Erwin Janssen [Sun, 29 Jan 2017 09:51:42 +0000 (10:51 +0100)]
Disable warning C4996 on Windows CMake build
MSVC warning C4996 mostly fires on completely valid code. The changes
proposed in the warning text often seriously compromise the code
portability, while they never substantially improve the code quality.
Thus we suppress this warning.
gmlparse.y: Each identifier in dedicated statement
It is good practice to define each identifier in a dedicated statement,
various standard and style guides recommend this. Because where multiple
declarators appear in the same declaration, the type of an identifier
may not meet a developer's expectations.
It is good practice to define each identifier in a dedicated statement,
various standard and style guides recommend this. Because where multiple
declarators appear in the same declaration, the type of an identifier
may not meet a developer's expectations.
It is good practice to define each identifier in a dedicated statement,
various standard and style guides recommend this. Because where multiple
declarators appear in the same declaration, the type of an identifier
may not meet a developer's expectations.
Erwin Janssen [Fri, 31 Mar 2017 11:06:41 +0000 (13:06 +0200)]
Remove HAVE_LIBGD check from plugin/gd
This check should exist only in the build configuration, if plugin/gd gets
build, then libgd should _always_ be available. Otherwise, mistakenly
building plugin/gd without defining HAVE_LIBGD, will lead to believe that
the build is succesfull, while in truth nothing gets build.
Erwin Janssen [Fri, 31 Mar 2017 07:06:41 +0000 (09:06 +0200)]
Remove declared, not defined, function from cdt.h
Remove `dttreeset` function declaration from cdt.h. The function
definition was removed some time ago because it was not used in the
codebase, but the declaration wasn't removed properly.
On Windows, the plugin gvplugin_neato_layout exported a lot of function,
also from other libraries that are not being exported, such as ortho and
neatogen. This has been reduced to only the varaible
`gvplugin_neato_layout_LTX_library`.
A minor link change was needed on Windows as a result.
Erwin Janssen [Mon, 27 Mar 2017 20:53:07 +0000 (22:53 +0200)]
Use dllimport to link gd fonts on Windows
Using extern to link the gd fonts on Windows doesn't work, they should be
imported from the DLL using __declspec(dllimport).
Also update the libgd DLL to the most recent version.
Erwin Janssen [Mon, 27 Mar 2017 09:12:12 +0000 (11:12 +0200)]
Restructure appveyor.yml
Split the script into three parts, instead of one large block. Because
of the block structure, errors didn't show up because only the last
command was evaluated when determining whether the build was successful.
These errors should now be visible.
Erwin Janssen [Mon, 27 Mar 2017 08:40:45 +0000 (10:40 +0200)]
Remove disabled Autotools build from appveyor.yml
There was an attempt to include the Autotools build on Appveyor, but
with the current Visual Studio build and the future CMake build, this is
no longer relevant.
Erwin Janssen [Sun, 26 Mar 2017 13:52:11 +0000 (15:52 +0200)]
*_API to specify linkage for lib/cgraph on Windows
Instead of overloading the `extern` keyword with __dllspec(dllexport) or
__dllspec(dllimport) to specify the linkage, and use a function definition
file to specify the exported functions, this commit adds a seperate define
for each header file to do both. It also makes it more explicit which
function are exported.
Erwin Janssen [Sat, 25 Mar 2017 17:11:13 +0000 (18:11 +0100)]
CDT_API to specify linkage for lib/cdt on Windows
Instead of overloading the `extern` keyword with __dllspec(dllexport) or
__dllspec(dllimport) to specify the linkage, and use a function definition
file to specify the exported functions, this commit adds a seperate define
to do both.
Erwin Janssen [Sat, 18 Mar 2017 23:05:33 +0000 (00:05 +0100)]
Improve __dllspec specification in plugin/
The plugin projects that are included in the Visual Studio build,
contained __dllspec specification for the `gvplugin_*_LTX_library`
definition. This commit improves this specification by making it more
consistant. The `.def` files in `pluging` are now no longer required.
Erwin Janssen [Thu, 16 Mar 2017 10:36:08 +0000 (11:36 +0100)]
Replace WIN32_DLL with _WIN32 in vplugin_core.c
This define check should only be triggerd on Windows. Using the compiler
set `_WIN32` to check if Windows is the platform is better than using a
user set define.
Emden R. Gansner [Tue, 14 Mar 2017 21:39:47 +0000 (17:39 -0400)]
Remove duplicate declaration of gd fonts; re-add extern. Without extern, thesewill be defined locally and uninitialized. We want these to bind to gdFontPtrs
defined in libgd.
Erwin Janssen [Sun, 5 Mar 2017 12:26:36 +0000 (13:26 +0100)]
Enable JSON on Windows build
The JSON module was not included in the Windows build because of some
errors. These errors were caused by two function from gvc not being added
to the Windows definition file. This is now resolved and JSON is added.
Erwin Janssen [Fri, 10 Feb 2017 09:57:03 +0000 (10:57 +0100)]
Use <type>_MAX instead of <type>_SIZE, rectangle.c
Instead of using the custom defined <type>_SIZE defines in
lib/label/rectangle.c function RectAra, we now use the defines
<type>_MAX from the standard library. The meaning is the same, but it is
more portable and requires less checks.
Erwin Janssen [Thu, 9 Feb 2017 06:57:08 +0000 (07:57 +0100)]
Remove `#ifdef _UWIN` block with hard path include
The header globals.h had an `#ifdef _UWIN` block at the top. This block
had an include with a hard path, which is a bad idea. Since it has
been 12 years since this block has been modified an UWIN isn't used in
the current build, we remove this block.
Erwin Janssen [Wed, 8 Feb 2017 19:36:35 +0000 (20:36 +0100)]
Remove `AC_HEADER_DIRENT` from configure.ac
The check `AC_HEADER_DIRENT` is no longer needed, as all current UNIX
systems have the correct version of this header. The checks and
corresponding define can be removed.
Erwin Janssen [Mon, 6 Feb 2017 17:12:22 +0000 (18:12 +0100)]
Remove HAVE_STDBOOL_H check from common/logic.h
This header check was removed earlier, but this one was missed. The C++
check can also be removed, because the stdbool.h header files includes is
check by itself.
Erwin Janssen [Sat, 4 Feb 2017 10:21:18 +0000 (11:21 +0100)]
Don't use path as variable name in colortbl.awk
Instead of using `argv[1]` to name the variable, we now always call it
`color_lib` in awk/colortbl.awk. The reason for this, is in some build
configurations, like the Visual Studio and CMake build, the full path to
the color_lib file is used. This resulted in the variable conaining
slashes, etc. Since the rest of the code already assumes this variable is
called `color_lib`, there is no problem with hard coding it in
colortbl.awk
Erwin Janssen [Tue, 31 Jan 2017 15:57:32 +0000 (16:57 +0100)]
Remove email address from .travis.yml
Notifications about the build were now always send to John, even when
someone else, in their own fork, was using Travis. This should send the
emails to the one that issued the build.
Erwin Janssen [Tue, 31 Jan 2017 13:29:46 +0000 (14:29 +0100)]
Made libgvpr a dynamic library on Windows
libgvpr is a dynamic library with the Autotools build, but was for some
reason a static library on Windows. Since Autotools is considered the
default, this commit makes libgvpr a dynamic library on Windows as well.
The added define "GVPR_API", is used for linking, so a seperate gvpr.def
file is not needed. On non-Windows platforms, this define is set to
"extern", so nothing changes there.
Emden Gansner [Wed, 1 Mar 2017 19:54:27 +0000 (14:54 -0500)]
Fix rtest.sh to use test data based on system running the tests;
add test data for Ubuntu;
remove absolute paths containing dperry-make relative to the rtest directory.
Erwin Janssen [Sat, 11 Feb 2017 10:33:37 +0000 (11:33 +0100)]
Update test reference files after indent change
The recent change in the indentation of the dot output, caused tests
regarding gv and xdot output to fail. A minor difference in indentation
was the cause (a single space), but the indentation is now better aligned.
We update the rest reference files to reflect this update.
Erwin Janssen [Thu, 26 Jan 2017 12:56:15 +0000 (13:56 +0100)]
Use awk to generate colortbl.h on Windows
Instead of using the pregenerated colortbl.h in windows/include, we now
include awk in windows/dependencies/graphviz-build-utilities and use this
to generate colortbl.h
Erwin Janssen [Fri, 20 Jan 2017 18:02:04 +0000 (19:02 +0100)]
Add lib/sfdpgen to CMake build
The static library 'sfdpgen' has no dependencies, but the `WITH_SFDP`
option had to be added, for this is also done in the Autotools build.
If WITH_SFDP is set, the define SFDP is also added (also added this for
ORTHO, this was missing).
Erwin Janssen [Fri, 20 Jan 2017 16:55:41 +0000 (17:55 +0100)]
Add lib/vpsc to CMake build
The static library 'vpsc' has no dependencies, but the `WITH_IPSEPCOLA`
option had to be added, for this is also done in the Autotools build. This
library is disabled by default due to C++ portability issues.
Erwin Janssen [Thu, 5 Jan 2017 09:07:48 +0000 (10:07 +0100)]
Replace "." with "${CMAKE_CURRENT_SOURCE_DIR}"
When specifying the current source directory as an include directory, both
"." and "${CMAKE_CURRENT_SOURCE_DIR}" mean the same, but the latter is
more descriptive.
Erwin Janssen [Tue, 3 Jan 2017 12:35:12 +0000 (13:35 +0100)]
Modify files generated by Bison and Flex, to match the Autotools build.
- Replace "yy" with "aag" in all three files
- Replace "unsigned long int" with "uint64_t" in grammar.h and grammar.c
- Replace "unsigned long" with "uint64_t" in grammar.h and grammar.c
- Remove declaration of the "isatty()" function from scan.c