Re: Loading a shared library directly from inside of a ZIP file
Re: Loading a shared library directly from inside of a ZIP file
- Subject: Re: Loading a shared library directly from inside of a ZIP file
- From: John Davidorff Pell <email@hidden>
- Date: Sat, 21 Jan 2006 23:21:54 -0800
How would you decompress the library? Is it in the ZIP file
uncompressed? the dlopen() family of calls are *extremely* simple, so
"hacking" them would not be a bad idea since they are "hacks" to
begin with. They're just wrappers around native calls anyway. Check
out the dlcompat library (which Tiger includes).
JP
On 20 Jan 2006, at 07:45, Martin Knapp-Cordes wrote:
Hi,
Is there a 'public' interface (with a different name) that will
replace the interface:
void *dlopen(const char *filename, int flag);
by say:
void *dlopen_new(int fd, void *start, size_t length, int flag);
This is motivated by the mmap interface:
void * mmap(void *start, size_t length, int prot , int flags,
int fd,
off_t offset);
The idea is that you are given a triplet:
(name,offset,length)
where name is file descriptor for the ZIP file (int fd), and
the offset (void *start) is the start of the shared library in the
ZIP file, and length (size_t length) is the length of the shared
library.
Note that dlopen() under the hood does a mmap.
If there isn't, is the only recourse, to 'hack' the source or are
there some other ideas or published solutions.
The solution of making a copy into the filesystem first and using
the old interface is NOT acceptable.
Sincerely,
Martin Knapp-Cordes
---------------------------------------------------------------
| Martin Knapp-Cordes email@hidden |
| The MathWorks, Inc. http://www.mathworks.com |
| 3 Apple Hill Drive Natick, MA 01760 |
| Tel: (508) 647-7321 Fax: (508) 647-7015 |
---------------------------------------------------------------
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
40mac.com
This email sent to email@hidden
--
John Davidorff Pell
email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden