tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: crunchgen and c++



On Mon, Jul 14, 2014 at 11:54:35AM -0500, Frank Zerangue wrote:
> Is crunchgen compatible with c++ executables?

I thik you answer yourself...

> I was able to build the c++ tool into a crunched binary but get an
> illegal instruction trap when trying to execute the tool.

Clearly not :-)

> And static variables in the c++ tool are initialized when any
> of the binaries crunched are executed.

To stop that happening the linker section names for the initialiers
(and destructors) in each tool would need renaming, and then the
constructors run (in the correct order) before calling the tool's main().
(and even that might not work).

> Thanks for any ideas on this matter.

I'd try a minimal crunched binary and see why it fails.
All crunchgen really does is rename the program's symbols so that
the ones from each 'tool' are separate.

        David

-- 
David Laight: david%l8s.co.uk@localhost


Home | Main Index | Thread Index | Old Index