On Mon, Dec 05, 2011 at 04:47:08PM +, Richard Sandiford wrote:
> Richard Sandiford writes:
> > Dave Martin writes:
> >> Another way of doing a similar thing is to mark __mylib_constructor
> >> as undefined in all the objects that make up the library.
> >>
> >> Unfortunately, there seems to be
Richard Sandiford writes:
> Dave Martin writes:
>> Another way of doing a similar thing is to mark __mylib_constructor
>> as undefined in all the objects that make up the library.
>>
>> Unfortunately, there seems to be no obvious way of doing that: the
>> assembler generates undefined symbol refe
Dave Martin writes:
> Another way of doing a similar thing is to mark __mylib_constructor
> as undefined in all the objects that make up the library.
>
> Unfortunately, there seems to be no obvious way of doing that: the
> assembler generates undefined symbol references automatically for
> unresol
Tom Gall wrote:
> For shared libs one can define and use something like:
>
> void __attribute__ ((constructor)) my_init(void);
> void __attribute__ ((destructor)) my_fini(void);
>
> Which of course allows your lib to run code just after the library is
> loaded and just before the library is going
> On Mon, Dec 5, 2011 at 1:40 AM, Tom Gall wrote:
> > I probably know the answer to this already but ...
> >
> > For shared libs one can define and use something like:
> >
> > void __attribute__ ((constructor)) my_init(void);
> > void __attribute__ ((destructor)) my_fini(void);
> >
> > Which of co
On 4 December 2011 17:40, Tom Gall wrote:
> I probably know the answer to this already but ...
>
> For shared libs one can define and use something like:
>
> void __attribute__ ((constructor)) my_init(void);
> void __attribute__ ((destructor)) my_fini(void);
>
> Which of course allows your lib to
Here is some triky way for this problem, you can put the constructor
and destructor to the source file which contain necessary function
call in your libraries to enforce the linker to archive your
constructor and destructor.
However if this solution is not work for your situation, you can apply
th
I probably know the answer to this already but ...
For shared libs one can define and use something like:
void __attribute__ ((constructor)) my_init(void);
void __attribute__ ((destructor)) my_fini(void);
Which of course allows your lib to run code just after the library is
loaded and just befor