flex on win64 - workaround for "flex: fatal internal error, exec failed" - Mailing list pgsql-hackers

From Craig Ringer
Subject flex on win64 - workaround for "flex: fatal internal error, exec failed"
Date
Msg-id 4E10F770.5020406@postnewspapers.com.au
Whole thread Raw
Responses Re: flex on win64 - workaround for "flex: fatal internal error, exec failed"
List pgsql-hackers
Hi all

On my win64 build machine I've been suffering from hard to track down 
errors from flex like:
  "flex: fatal internal error, exec failed"

... even though I have m4 properly installed and whether or not the M4 
environment variable is set to point to my M4 executable. It all works 
fine under 32-bit windows using the same flex-2.5.35 obtained from Pg 
ftp. Under win64 it works ... sometimes.

I haven't managed to figure out exactly what's broken. For the benefit 
of anyone else having problems like this or who might find this via a 
search later, though: just install msys and use the current flex from 
msys. It works perfectly in Pg's build environment and it's easy to 
install, so you don't need to stuff around trying to get flex to work.

Grab mingw-get-inst from 
http://sourceforge.net/projects/mingw/files/Automated%20MinGW%20Installer/mingw-get-inst/ 
and use it to install msys and the minimalist mingw. You won't be using 
mingw, but it won't hurt you, and it's easier than installing msys 
standalone.

Edit src\tools\msvc\buildenv.pl (or create it if necessary) and use it 
to add C:\MinGW\msys\1.0\bin to your PATH. Adjust as appropriate if your 
MinGW install dir was different.  Eg:

$ENV{PATH}='C:\MinGW\msys\1.0\bin;' .  $ENV{PATH};

(As usual you'll probably need to add GnuWin32 and the paths to the 
directories containing zlib1.dll, the openssl dlls, etc too).

--
Craig Ringer


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: plpgsql extension install nitpick
Next
From: Shigeru Hanada
Date:
Subject: Re: per-column generic option