From: erg Date: Mon, 12 Mar 2007 22:48:19 +0000 (+0000) Subject: Modify makefiles and common.h to support Windows build X-Git-Tag: LAST_LIBGRAPH~32^2~5642 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=927fd45cdb85a2af91c2a2737a85329167aad1a2;p=graphviz Modify makefiles and common.h to support Windows build --- diff --git a/cmd/lefty/Makefile.am b/cmd/lefty/Makefile.am index bbbaeb954..6935c4dbb 100644 --- a/cmd/lefty/Makefile.am +++ b/cmd/lefty/Makefile.am @@ -45,6 +45,11 @@ man_MANS = $(man) pdf_DATA = $(pdf) endif endif +if WITH_WIN32 +bin_PROGRAMS = lefty +man_MANS = $(man) +pdf_DATA = $(pdf) +endif lefty_DATA = lefty.psp @@ -55,12 +60,19 @@ lefty_SOURCES = code.c common.c display.c exec.c g.c gfxview.c internal.c \ # NB. -lXaw must be before -lXt or strange inability-to-get-mouse-focus # problems can occur on some systems. # +if WITH_WIN32 +lefty_LDADD = $(top_builddir)/cmd/lefty/dot2l/libdot2l.la \ + $(top_builddir)/cmd/lefty/ws/mswin32/libws.la \ + $(top_builddir)/cmd/lefty/os/mswin32/libos.la \ + -luser32 -lgdi32 -lwinspool -lcomdlg32 -ladvapi32 -lshell32 @MATH_LIBS@ +else lefty_LDADD = $(top_builddir)/cmd/lefty/dot2l/libdot2l.la \ $(top_builddir)/cmd/lefty/ws/x11/libws.la \ $(top_builddir)/cmd/lefty/ws/x11/libfilereq/libfilereq.la \ $(top_builddir)/cmd/lefty/os/unix/libos.la \ @X_LIBS@ @XAW_LIBS@ @X_PRE_LIBS@ @XPM_LIBS@ \ -lXt -lXmu -lXext -lX11 @SOCKET_LIBS@ @MATH_LIBS@ +endif .1.pdf: -groff -Tps -man $< | ps2pdf - - >$@ diff --git a/cmd/lefty/common.h b/cmd/lefty/common.h index 4e9129992..5cc3d2223 100644 --- a/cmd/lefty/common.h +++ b/cmd/lefty/common.h @@ -32,7 +32,14 @@ extern "C" { */ #define FEATURE_MINTSIZE 1 #define FEATURE_DOT 1 -#ifndef MSWIN32 +#ifdef MSWIN32 +#ifndef FEATURE_WIN32 +#define FEATURE_WIN32 1 +#endif +#ifndef FEATURE_MS +#define FEATURE_MS 1 +#endif +#else #define FEATURE_X11 1 #endif #endif