Graphviz Issue Tracker
Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0002411graphvizBuild/Installpublic2014-01-22 19:572015-01-19 08:55
ReporterMike M 
Assigned Toellson 
PrioritynormalSeveritycosmeticReproducibilityalways
StatusassignedResolutionopen 
PlatformmingwOSWindowsOS Version7
Summary0002411: Changes against graphviz 2.34 to get the libs compiled with mingw/gcc
DescriptionThe title says it all, in the diff are a view changes to get graphviz libs compiled with mingw on Windows. However looking at the different preprocessor defines, the build on mingw Windows feels like a hack. I just worked my way around it, I didn't clean it up completely.
TagsNo tags attached.
AUXILLARY-FILES
DATE-FIXED
FIX-COMMENT
FORMER-ID
INPUT-FILE
OUTPUT-FILE
STATUS-COMMENT
VERSION
Attached Filesdiff file icon graphviz_2.34.diff [^] (11,685 bytes) 2014-01-22 19:57 [Show Content]

- Relationships

-  Notes
User avatar (0000671)
Mike M (reporter)
2014-01-22 20:29

Hm, few not view...
User avatar (0000672)
ellson (administrator)
2014-01-22 20:43

Mike, I can quite believe that Mingw make support need maintenance, and I encourage your efforts, but I can't use this patch as is...

- I'd prefer a patch against the development tree in github.com/ellson/github

- there should be no changes against Makefile.in as these are generated from Makefile.am by automake during ./autogen.sh

- I don't think there should be changes against Makefile.old since only Emden uses these, and not on mingw as far as i know.

- All changes should almost-certainly be conditional on MINGW, which needs to be detected by configure.ac

John
User avatar (0000673)
Mike M (reporter)
2014-01-23 05:51

Yes, I know it's not clean, that's what I meant by "I just worked my way around it". Maybe it can be a starting point.
User avatar (0000674)
ellson (administrator)
2014-01-23 11:40

Mike, I need your help to make progress on this .. I don't have access to a ming platform .. and I've injured my hand which is making it difficult for me to do anything ..

Before worrying about the patches ... can you tell me if you are able to clone from git and do a build on your ming host starting from ./autogen.sh ?
User avatar (0000675)
Mike M (reporter)
2014-01-24 08:15

Yes, I can.

I set the flag: GVDLL=1.

Autogen/configure output:
graphviz-2.37.0 will be compiled with the following:

options:
  cgraph:
  digcola: Yes
  expat: Yes
  fontconfig: Yes
  freetype: Yes
  glut: No (missing GL/glut.h)
  ann: No (ANN library not available)
  gts: Yes
  ipsepcola: No (disabled by default - C++ portability issues)
  ltdl: Yes
  ortho: Yes
  sfdp: Yes
  shared: Yes
  static: Yes
  qt: No (qmake not found)
  x: No (disabled or unavailable)

commands:
  dot: Yes (always enabled)
  neato: Yes (always enabled)
  fdp: Yes (always enabled)
  circo: Yes (always enabled)
  twopi: Yes (always enabled)
  gvpr: Yes (always enabled)
  gvmap: Yes (always enabled)
  lefty: No (missing Xaw headers)
  smyrna: No (disabled by default - experimental)
  gvedit: No (qmake not found)

plugin libraries:
  dot_layout: Yes (always enabled)
  neato_layout: Yes (always enabled)
  core: Yes (always enabled)
  devil: No (missing library)
  gd: No (gd headers not found)
  gdiplus: No (disabled by default - Windows only)
  gdk:
  gdk_pixbuf: No (gdk_pixbuf library not available)
  ghostscript: No (missing Xrender)
  glitz: No (disabled by default - incomplete)
  gtk: No (gtk library not available)
  lasi: No (missing pangocairo support)
  ming: No (disabled by default - incomplete)
  pangocairo: No (pangocairo library not available)
  poppler: No (poppler library not available)
  quartz: No (disabled by default - Mac only)
  rsvg: No (rsvg library not available)
  visio: No (disabled by default - experimental)
  webp: No (disabled by default - experimental)
  xlib: No (disabled or unavailable)

language extensions:
  gv_sharp: No (swig not available)
  gv_go: No (disabled by default - experimental)
  gv_guile: No (swig not available)
  gv_io: No (disabled by default - no swig support yet)
  gv_java: No (swig not available)
  gv_lua: No (swig not available)
  gv_ocaml: No (swig not available)
  gv_perl: No (swig not available)
  gv_php: No (swig not available)
  gv_python: No (swig not available)
  gv_python23: No (disabled by default - for multiversion installs)
  gv_python24: No (disabled by default - for multiversion installs)
  gv_python25: No (disabled by default - for multiversion installs)
  gv_python26: No (disabled by default - for multiversion installs)
  gv_python27: No (disabled by default - for multiversion installs)
  gv_R: No (swig not available)
  gv_ruby: No (swig not available)
  gv_tcl: No (tcl not available)

  tcldot: No (tcl not available)
  tclpathplan: No (tcl not available)
  gdtclft: No (tcl not available)
  tkspline: No (tk not available)


Make failure:
/bin/sh ../../libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I../.. -I../../lib/common -I../.. -I../../
lib/cdt -I/my/include -I/my/include/freetype2 -I/qt/include -I/my/include -DGVDLL=1 -I/my/include -I/my/include/freety
pe2 -I/qt/include -Wno-unknown-pragmas -Wstrict-prototypes -Wpointer-arith -Wall -ffast-math -MT graph.lo -MD -MP -MF .d
eps/graph.Tpo -c -o graph.lo graph.c
libtool: compile: gcc -DHAVE_CONFIG_H -I. -I../.. -I../../lib/common -I../.. -I../../lib/cdt -I/my/include -I/my/includ
e/freetype2 -I/qt/include -I/my/include -DGVDLL=1 -I/my/include -I/my/include/freetype2 -I/qt/include -Wno-unknown-pragm
as -Wstrict-prototypes -Wpointer-arith -Wall -ffast-math -MT graph.lo -MD -MP -MF .deps/graph.Tpo -c graph.c -DDLL_EXPO
RT -DPIC -o .libs/graph.o
graph.c:276:10: warning: 'Agdirected' redeclared without dllimport attribute: previous dllimport ignored [-Wattributes]
 Agdesc_t Agdirected = { 1, 0, 0, 1 };
          ^
graph.c:277:10: warning: 'Agstrictdirected' redeclared without dllimport attribute: previous dllimport ignored [-Wattrib
utes]
 Agdesc_t Agstrictdirected = { 1, 1, 0, 1 };
          ^
graph.c:278:10: warning: 'Agundirected' redeclared without dllimport attribute: previous dllimport ignored [-Wattributes
]
 Agdesc_t Agundirected = { 0, 0, 0, 1 };
          ^
graph.c:279:10: warning: 'Agstrictundirected' redeclared without dllimport attribute: previous dllimport ignored [-Wattr
ibutes]
 Agdesc_t Agstrictundirected = { 0, 1, 0, 1 };
          ^
graph.c:281:10: warning: 'AgDefaultDisc' redeclared without dllimport attribute: previous dllimport ignored [-Wattribute
s]
 Agdisc_t AgDefaultDisc = { &AgMemDisc, &AgIdDisc, &AgIoDisc };
          ^
graph.c:281:1: error: initializer element is not constant
 Agdisc_t AgDefaultDisc = { &AgMemDisc, &AgIdDisc, &AgIoDisc };
 ^
graph.c:281:1: error: (near initialization for 'AgDefaultDisc.mem')
graph.c:281:1: error: initializer element is not constant
graph.c:281:1: error: (near initialization for 'AgDefaultDisc.id')
graph.c:281:1: error: initializer element is not constant
graph.c:281:1: error: (near initialization for 'AgDefaultDisc.io')
Makefile:699: recipe for target `graph.lo' failed
make[3]: *** [graph.lo] Error 1
make[3]: Leaving directory `/my/src/graphviz/lib/cgraph'
Makefile:535: recipe for target `all-recursive' failed
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/my/src/graphviz/lib'
Makefile:774: recipe for target `all-recursive' failed
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/my/src/graphviz'
Makefile:583: recipe for target `all' failed
make: *** [all] Error 2
User avatar (0000679)
ellson (administrator)
2014-01-24 10:34

Great.

It looks like there is already a test in configure.ac for MINGW32.
Do we also need MINGW64

Can you rework your patch so that all *.[ch] changes are wrapped in:
  #ifdef MINGW32
  #endif

I don't understand your changes to SUBDIRS in Makefile.am(s) I suspect those aren't needed. ./configure is supposed to work out what can be built.
User avatar (0000860)
lwan (reporter)
2015-01-13 06:22
edited on: 2015-01-13 07:27

Hello,

I am facing the same problem on Windows 7 with mingw64 x86_64 toolchain.

libtool: compile: gcc -DHAVE_CONFIG_H -I. -I../.. -I../../lib/common -I../.. -I../../lib/cdt -D_FORTIFY_SOURCE=2 -D__USE_MINGW_ANSI_STDIO=1 -march=xic -O2 -pipe -Wno-unknown-pragmas -Wstrict-prototypes -Wpointer-arith -Wall -ffast-math -MT agerror.lo -MD -MP -MF .deps/agerror.Tpo -c agerror.c -Do .libs/agerror.o
libtool: compile: gcc -DHAVE_CONFIG_H -I. -I../.. -I../../lib/common -I../.. -I../../lib/cdt -D_FORTIFY_SOURCE=2 -D__USE_MINGW_ANSI_STDIO=1 -march=xic -O2 -pipe -Wno-unknown-pragmas -Wstrict-prototypes -Wpointer-arith -Wall -ffast-math -MT apply.lo -MD -MP -MF .deps/apply.Tpo -c apply.c -DDLL_EXs/apply.o
libtool: compile: gcc -DHAVE_CONFIG_H -I. -I../.. -I../../lib/common -I../.. -I../../lib/cdt -D_FORTIFY_SOURCE=2 -D__USE_MINGW_ANSI_STDIO=1 -march=xic -O2 -pipe -Wno-unknown-pragmas -Wstrict-prototypes -Wpointer-arith -Wall -ffast-math -MT graph.lo -MD -MP -MF .deps/graph.Tpo -c graph.c -DDLL_EXs/graph.o
libtool: compile: gcc -DHAVE_CONFIG_H -I. -I../.. -I../../lib/common -I../.. -I../../lib/cdt -D_FORTIFY_SOURCE=2 -D__USE_MINGW_ANSI_STDIO=1 -march=xic -O2 -pipe -Wno-unknown-pragmas -Wstrict-prototypes -Wpointer-arith -Wall -ffast-math -MT edge.lo -MD -MP -MF .deps/edge.Tpo -c edge.c -DDLL_EXPORdge.o
libtool: compile: gcc -DHAVE_CONFIG_H -I. -I../.. -I../../lib/common -I../.. -I../../lib/cdt -D_FORTIFY_SOURCE=2 -D__USE_MINGW_ANSI_STDIO=1 -march=xic -O2 -pipe -Wno-unknown-pragmas -Wstrict-prototypes -Wpointer-arith -Wall -ffast-math -MT flatten.lo -MD -MP -MF .deps/flatten.Tpo -c flatten.c -Do .libs/flatten.o
libtool: compile: gcc -DHAVE_CONFIG_H -I. -I../.. -I../../lib/common -I../.. -I../../lib/cdt -D_FORTIFY_SOURCE=2 -D__USE_MINGW_ANSI_STDIO=1 -march=xic -O2 -pipe -Wno-unknown-pragmas -Wstrict-prototypes -Wpointer-arith -Wall -ffast-math -MT grammar.lo -MD -MP -MF .deps/grammar.Tpo -c grammar.c -Do .libs/grammar.o
attr.c: In function 'setattr':
attr.c:257:19: warning: variable 'dd' set but not used [-Wunused-but-set-variable]
     Agdatadict_t *dd;
                   ^
edge.c: In function 'del':
edge.c:178:11: warning: variable 'x' set but not used [-Wunused-but-set-variable]
     void *x;
           ^
graph.c:276:10: warning: 'Agdirected' redeclared without dllimport attribute: previous dllimport ignored [-Wattributes]
 Agdesc_t Agdirected = { 1, 0, 0, 1 };
          ^
graph.c:277:10: warning: 'Agstrictdirected' redeclared without dllimport attribute: previous dllimport ignored [-Wattributes]
 Agdesc_t Agstrictdirected = { 1, 1, 0, 1 };
          ^
graph.c:278:10: warning: 'Agundirected' redeclared without dllimport attribute: previous dllimport ignored [-Wattributes]
 Agdesc_t Agundirected = { 0, 0, 0, 1 };
          ^
graph.c:279:10: warning: 'Agstrictundirected' redeclared without dllimport attribute: previous dllimport ignored [-Wattributes]
 Agdesc_t Agstrictundirected = { 0, 1, 0, 1 };
          ^
graph.c:281:10: warning: 'AgDefaultDisc' redeclared without dllimport attribute: previous dllimport ignored [-Wattributes]
 Agdisc_t AgDefaultDisc = { &AgMemDisc, &AgIdDisc, &AgIoDisc };
          ^
graph.c:281:1: error: initializer element is not constant
 Agdisc_t AgDefaultDisc = { &AgMemDisc, &AgIdDisc, &AgIoDisc };
 ^
graph.c:281:1: error: (near initialization for 'AgDefaultDisc.mem')
graph.c:281:1: error: initializer element is not constant
graph.c:281:1: error: (near initialization for 'AgDefaultDisc.id')
graph.c:281:1: error: initializer element is not constant
graph.c:281:1: error: (near initialization for 'AgDefaultDisc.io')

i am using graphviz-2.39.20150112.0545 source package.

i use a configuration as follows:

graphviz-2.39.20150112.0545 will be compiled with the following:

options:
  cgraph:
  digcola: Yes
  expat: Yes
  fontconfig: Yes
  freetype: Yes
  glut: No (missing GL/glut.h)
  ann: No (ANN library not available)
  gts: No (disabled)
  ipsepcola: No (disabled by default - C++ portability issues)
  ltdl: Yes
  ortho: Yes
  sfdp: Yes
  shared: Yes
  static: No (disabled by default)
  qt: No (disabled)
  x: No (disabled or unavailable)

commands:
  dot: Yes (always enabled)
  neato: Yes (always enabled)
  fdp: Yes (always enabled)
  circo: Yes (always enabled)
  twopi: Yes (always enabled)
  gvpr: Yes (always enabled)
  gvmap: Yes (always enabled)
  lefty: No (missing Xaw headers)
  smyrna: No (disabled by default - experimental)
  gvedit: No (disabled)

plugin libraries:
  dot_layout: Yes (always enabled)
  neato_layout: Yes (always enabled)
  core: Yes (always enabled)
  devil: No (missing library)
  gd: No (disabled)
  gdiplus: No (disabled by default - Windows only)
  gdk: Yes
  gdk_pixbuf: Yes
  ghostscript: No (disabled)
  glitz: No (disabled by default - incomplete)
  gtk: No (disabled)
  lasi: No (disabled)
  ming: No (disabled by default - incomplete)
  pangocairo: No (disabled)
  poppler: No (poppler library not available)
  quartz: No (disabled by default - Mac only)
  rsvg: No (disabled)
  visio: No (disabled by default - experimental)
  webp: No (disabled by default - experimental)
  xlib: No (disabled or unavailable)

language extensions:
  gv_sharp: No (disabled)
  gv_go: No (disabled by default - experimental)
  gv_guile: No (swig not available)
  gv_io: No (disabled by default - no swig support yet)
  gv_java: No (disabled)
  gv_lua: No (disabled)
  gv_ocaml: No (disabled)
  gv_perl: No (swig not available)
  gv_php: No (disabled)
  gv_python: No (swig not available)
  gv_python23: No (disabled by default - for multiversion installs)
  gv_python24: No (disabled by default - for multiversion installs)
  gv_python25: No (disabled by default - for multiversion installs)
  gv_python26: No (disabled by default - for multiversion installs)
  gv_python27: No (disabled by default - for multiversion installs)
  gv_R: No (disabled)
  gv_ruby: No (disabled)
  gv_tcl: No (tcl not available)
  tcldot: No (tcl not available)
  tclpathplan: No (tcl not available)
  gdtclft: No (tcl not available)

no change on configure or Makefile.am made.

i am interested for graphviz to run on windows 7 for work, so i can spend some time on this. can someone give me some pointers on the MINGW32 macro stuff ?

regards,


- Issue History
Date Modified Username Field Change
2014-01-22 19:57 Mike M New Issue
2014-01-22 19:57 Mike M File Added: graphviz_2.34.diff
2014-01-22 20:29 Mike M Note Added: 0000671
2014-01-22 20:43 ellson Note Added: 0000672
2014-01-23 05:51 Mike M Note Added: 0000673
2014-01-23 09:00 erg Assigned To => ellson
2014-01-23 09:00 erg Status new => assigned
2014-01-23 11:40 ellson Note Added: 0000674
2014-01-24 08:15 Mike M Note Added: 0000675
2014-01-24 10:34 ellson Note Added: 0000679
2015-01-13 06:22 lwan Note Added: 0000860
2015-01-13 07:27 lwan Note Edited: 0000860 View Revisions


MantisBT 1.2.5[^]
Copyright © 2000 - 2011 MantisBT Group
Powered by Mantis Bugtracker