| Paul Pluzhnikov 2006-07-20, 1:23 pm |
| gazelle@xmission.xmission.com (Kenny McCormack) writes:
> Note, incidentally, given that other posters have mentioned Windows and
> made comparisons thereto, that the actual origin of this problem is:
> I have an application which ships in both Windows and Solaris flavors
> and I am able to do this thing in the Windows version (it is supported
> there).
It is probably time to re-think your design.
> And, therefore, I'd like to be able to do the same in the Solaris version.
It is possible to do this on Solaris, but it will require so much
effort that you are unlikely to succeed on that path. And the effort
would have to be repeated on every other UNIX you'll want to port to.
All you have to do is "pretend" that your executable is the dynamic
linker (/lib/ld.so.1) and load (mmap) the executable yourself. Then
load all its direct dependencies, relocate, arrange for lazy symbol
resolution, etc. etc.
Cheers,
--
In order to understand recursion you must first understand recursion.
Remove /-nsp/ for email.
|