[Haskell-cafe] libffi mystery

Conor McBride conor at strictlypositive.org
Fri Oct 29 04:03:40 EDT 2010


Hi

Thanks for the help! I've made some progress, but I'm not there yet.

On 28 Oct 2010, at 20:08, Ketil Malde wrote:

> "Sittampalam, Ganesh" <ganesh.sittampalam at credit-suisse.com> writes:
>
>> Have you tried passing -optl-static to ghc (which causes -static to  
>> be
>> passed to ld)?

This was new to me. I gave it a whirl. I got lots of linker
errors about missing pthread this, missing pthread that, so...

>
> It used to be: -optl-static -optl-pthread

...seemed like a good plan. I got lots of scary warnings like

(.text+0x51d8): warning: Using 'setprotoent' in statically linked  
applications requires at runtime the shared libraries from the glibc  
version used for linking
/usr/lib/haskell-packages/ghc6/lib/network-2.2.1.7/ghc-6.12.1/ 
libHSnetwork-2.2.1.7.a(BSD.o): In function `suy9_info':
(.text+0x12f6): warning: Using 'endprotoent' in statically linked  
applications requires at runtime the shared libraries from the glibc  
version used for linking
/usr/lib/haskell-packages/ghc6/lib/network-2.2.1.7/ghc-6.12.1/ 
libHSnetwork-2.2.1.7.a(BSD.o): In function `svAk_info':

but an executable emerges. If I run the executable from the prompt,
it dumps some html, but it still 500s on the web server.

So there are at least options and ways to control what's going on.
I haven't figured out how to achieve the 6.8.2-alike linking, but
oughtn't it to be possible?

Many thanks

Conor



More information about the Haskell-Cafe mailing list