[TRE-general] cygwin problem

Ville Laurikari ville at laurikari.net
Thu May 11 09:26:24 EEST 2006


On Thu, May 11, 2006 at 12:09:51PM +1000, skaller wrote:
> Can I just say
> CC=gcc -mnocygwin ./configure
> 
> Or on linux
> CC=/usr/something/i686-mingw/bin/gcc ./configure
> 
> and expect a windows DLL to be generated??
> So what option do I use? There has to be a way to
> identify the target environment.

Ah, I thought you were aware of the --host option for configure (it's
explained in the INSTALL file).

Here's an excerpt:

  If you want to _use_ a cross compiler, that generates code for a
  platform different from the build platform, you should specify the
  "host" platform (i.e., that on which the generated programs will
  eventually be run) with `--host=TYPE'.

Cross compiling on Cygwin for MinGC works like this:
  ./configure CC="gcc -mno-cygwin" --host=i686-pc-mingw32

and cross compiling on Linux for MinGW probably something like
  ./configure CC=/usr/something/i686-mingw/bin/gcc --host=i686-pc-mingw32


> BTW: I'm using the darcs head on Linux. I'm not sure exactly
> how to do the familiar CVS like operations, eg update,
> generate a patch, etc, or package it up so I can move the
> sources to my other boxes for testing.

I suggest you read the documentation:
http://www.abridgegame.org/darcs/manual/bigpage.html#SECTION00220000000000000000

A checked out source tree is also a repository (and a branch, if you
will).  A darcs repository can be simply copied from one machine to
another, or you can push and pull patches to/from remote repos via ssh
using
  darcs pull user at host:path/to/repo
and
  darcs push user at host:path/to/repo


> Curious how you're running the regression tests.
> You cannot run tests when cross compiling, without switching
> to the target machine.

I was cross compiling on Cygwin, and the test programs built for MinGW
also seem to run under Cygwin.

> I have some questions on whether some more 'inner' parts of
> TRE can be exposed to provide a saner API. For example, 
> a combinator form for regexps instead of a string

Yes, I've been thinking about this.  Probably some sort of combinator
API to build regexps would be good.

> String regexps are evil but they're convenient for micky mouse
> applications.

Agreed.

> But visual Studio has a superb debugger :)

Yeah.  It crashed when I tried to debug the TRE regression test
program :)

-- 
http://www.iki.fi/vl/


More information about the TRE-general mailing list