On Tue, 8 May 2007 18:26:05 +0100
"MacArthur, Ian \(SELEX\) \(UK\)" <[EMAIL PROTECTED]> wrote:
>
> > export CC=/usr/ppc/arm-wince-mingw32ce/bin/gcc
> > export CXX=/usr/ppc/arm-wince-mingw32ce/bin/g++
> > ./configure --enable-cygwin
> >
> > # make install
>
> I'm not sure that the fltk configure will honour the cross-compilation
> like this... The few times I have built fltk to cross-compile (and never
> for wince) I have done it by creating my own config.h and makeinclude
> file by hand (by editing a "known good" version for another target.)
> Perhaps you will have to do the same.
It was done before I wrote this mail :-)
Plus, minor modifications to let fltk tree compile, nothing's weird
actually.
>
>
> > then compilation test like this
> >
> > [EMAIL PROTECTED]:~/src/fltk-2.0.x-r5528>
> > /usr/ppc/arm-wince-mingw32ce/bin/gcc -I/usr/local/include
> > -I/usr/X11/include -Wno-non-virtual-dtor -o arc test/arc.cxx
> > -L/usr/local/lib /usr/local/lib/libfltk2.a -L/usr/X11/lib -lsupc++
>
>
> Hmm, don't like the look of that compile command much at all.
> The include paths look all wrong for a cross-compile target, as do the
> library paths.
Because this string is constructed by '/usr/local/bin/fltk2-config
--compile test/arc.cxx'
I've expanded it, to show full libraries list (includes and libs).
FYI, running like mentioned below, gives the same effect, i.e.
/usr/local/lib/libfltk2.a(Window.o):Window.cxx:(.text+0x33c): undefined
reference to `OpenIcon'
/usr/local/lib/libfltk2.a(Window.o):Window.cxx:(.text+0x108c): undefined
reference to `IsIconic'
/usr/local/lib/libfltk2.a(run.o):run.cxx:(.text+0x6fc): undefined reference to
`GetTextMetricsA'
/usr/local/lib/libfltk2.a(run.o):run.cxx:(.text+0x8f4): undefined reference to
`CreateFontIndirectA'
/usr/local/lib/libfltk2.a(run.o):run.cxx:(.text+0xa44): undefined reference to
`IsIconic'
[EMAIL PROTECTED]:~/src/fltk-2.0.x-r5528> /usr/ppc/arm-wince-mingw32ce/bin/g++
-I/usr/local/include -o arc test/radio.cxx -L/usr/local/lib
-L/usr/ppc/arm-wince-mingw32ce/lib/ /usr/local/lib/libfltk2.a -lsupc++
> That can't be right, I think.
> Looks like you will need to edit makeinclude to set the paths up
> correctly, and to make sure the correct (i.e. the cross-compiler, not
> the local host) versions of the tools and binutils get called.
> Also, in general, I would call g++ rather than gcc for a C++ target, and
> drop the -lsupc++ from my command line.
makeinclude has different lines for CC and CXX.
I have no clue, why gcc is used instead of g++ (or vice-versa),
but object files are good at this point.
I tend to think, that --enable-cygwin isn't better place to escape from
unix environment.
And it is worth to try cegcc tools from windows environment.
_______________________________________________
fltk-dev mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk-dev