|
From: Petr M. <mi...@ph...> - 2008-09-04 16:08:17
|
> Yes, wxt does work for Windows. "Official" windows binaries that are > distributed on our SourceForge page are not built with it though. With > those, you have to use the default "win" terminal. To use wxt on Windows, > you can either build gnuplot by yourself with MinGW or MSVC (MinGW should > work with the untouched code base). > Additionally, Michael Goffioul has built a Windows package for Octave, > that also contains gnuplot with wxt ! I tried to compile gnuplot with wxt on Windows by MingW, but it failed. How can I do it? I did the following: I have downloaded the files below from http://www.gtk.org/download-windows.html and unzipped them into the MingW32 directory: cairo-dev-1.6.4-2.zip cairo-1.6.4-2.zip glib-dev_2.18.0-1_win32.zip glib_2.18.0-1_win32.zip pango-dev-1.20.5.zip pango-1.20.5.zip >From the wx homepage I've got and unzipped into D:/wxMSW-2.8.8 wxMSW-2.8.8.zip These are source code. Unfortunately I couldn't compile it, the make always failed in some part of its makefile.gcc. I couldn't repair it. Any idea what to do? Anyway, I proceeded further. In gnuplot's makefile.mgw, I had to change: ifdef WXT CFLAGS += -DWXWIDGETS -ID:/wxMSW-2.8.8/include CFLAGS += -ID:/Apps/MingW32/MingW344/include/cairo CFLAGS += -ID:/Apps/MingW32/MingW344/include/glib-2.0 WX_OBJS = wxt_gui.o gp_cairo.o endif because there is nothing like "wx-config" and "pkg-config" on my PATH as shell'ed from makefile.mgw. In gnuplot/src/wxterminal/wx_gui.cpp, I had to uncomment this code: #ifdef __WXMSW__ /* the following is done in wxEntry() with wxMSW only */ wxSetInstance(GetModuleHandle(NULL)); wxApp::m_nCmdShow = SW_SHOW; #endif because wxSetInstance() was not known. Then the compilation make -f makefile.mgw worked. But linking does not work, it complains about many undefined references. It seems wgnuplot.exe wants to be linked against the wx library. But it was not available as I couldn't compile it. I though the library may not be needed and some dll's could be used instead -- Michael's wgnuplot has dependencies to many dll's. Could somebody describe a procedure how to compile wxt under MingW? How to have it static or with dll's? Thanks. --- PM |