Replacement for GMP as Bignum: ARPREC? Haskell?; OS-X and OpenSSL

Esa Ilari Vuokko eivuokko at gmail.com
Sun Jul 30 08:44:55 EDT 2006


Hi Brian,

On 7/30/06, Brian Hulley <brianh at metamilk.com> wrote:
> Still, a slight problem is that since there is one object file per source
> file, the names of the object files give quite a lot of information away
> about the structure of the program especially when they are arranged in a
> module hierarchy, so I'll be glad when GMP is replaced by something without
> such a burdensome licence. (Although perhaps I can bundle my object files
> into a single library file but I don't know how to do this yet, or if it
> would really help in the goal to make the code completely obfuscated,
> impenetrable, and unavailable to any rival company... ;-) )

Assuming gnu toolchain, you can use ld to link object
files together in a form that is definitely harder to break apart.
(incremental linking to incomplete executable, iirc via switch -x).
That should allow you to produce one big object file (of atleast
haskell bits and c bits) that gets simply passed to ghc.

Using strip to remove debug info/symbol tables also helps somewhat.
(strip.exe is not part of ghc distribution, but you can find it in mingw
bintools.)

Using ar to create archives does not help at all - you can extract the
original files using ar itself.

HTH,
--Esa


More information about the Glasgow-haskell-users mailing list