[erlang-questions] Erlang crypto_drv in R13B02/03 fails to load on amd64-Solaris2.10

Wallentin Dahlberg <>
Fri Nov 20 23:25:28 CET 2009


We haven't had time to investigate this problem yet. (Lots of release stuff
going on today).

However, it seems like similar problems exists on opensolaris + AMD64.
For instance:
http://bugs.opensolaris.org/bugdatabase/view_bug.do;jsessionid=a68c8de187c30929fb79755edd017?bug_id=5102797

This would be kind of bad.

I don't have your build log in front of me so I can't see if this is the
case but similar problems has been solved with -fPIC and -shared and not -G
when using gcc on solaris.

LDFLAGS += -shared
CFLAGS += -fPIC

// Björn-Egil



2009/11/20 Per Hedeland <>

> Peter-Henry Mander <> wrote:
> >
> >A useful point, but no. I've been careful to ensure that the build is 64
> bit:
>
> OK, it was just a first guess.:-)
>
> >Björn-Egil Dahlberg and Sverker Eriksson suggested that linker flags
> >"-Wl,-Bsymbolic" applied to crypto_drv.so build might offer respite,
> >but this was unsuccessful. I may have stuck in the wrong place, mind
> >you.
>
> Hm, they should of course know more about the Erlang/OTP build than I
> do, but the few words that are recognizable from the error message, like
> "relocation error" and "does not fit", don't really suggest that it is
> an issue with symbol resolution I think.
>
> My next guess would be a -fpic vs -fPIC problem when compiling
> crypto_drv - in many cases / architectures you can "get away" with using
> -fpic which is supposedly slightly more efficient, but my understanding
> is that -fPIC should always work and is sometimes required. Of course if
> your build actually used -fPIC (likely), this is moot.
>
> But then I recognized one more word from the message: "main". This kind
> of contradicts what I wrote above, but surely there shouldn't be a
> "main" symbol in crypto_drv. What does 'nm' say?
>
> --Per
>
> ________________________________________________________________
> erlang-questions mailing list. See http://www.erlang.org/faq.html
> erlang-questions (at) erlang.org
>
>


More information about the erlang-questions mailing list