You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@perl.apache.org by Nikolay Ananiev <an...@thegdb.com> on 2005/09/02 15:40:29 UTC

auto-image-base flag for cygwin

On cygwin some dlls might happen to be with identical
base addresses and if you try to load both of them you'll
get an error and you'll have to use the rebase utility to fix them.
The following patch should prevent this.

Index: lib/Apache2/Build.pm
===================================================================
--- lib/Apache2/Build.pm (revision 264972)
+++ lib/Apache2/Build.pm (working copy)
@@ -320,6 +320,7 @@

         $ldopts = join ' ',
             '--export-all-symbols',
+            '--enable-auto-image-base',
             "$self->{cwd}/src/modules/perl/$mplib",
             $ldopts;

@@ -1590,7 +1591,8 @@
  $(MODPERL_RM_F) $@
  $(MODPERL_CC) -shared -o $@ \
  -Wl,--out-implib=$(MODPERL_LIBNAME).dll.a \
- -Wl,--export-all-symbols -Wl,--enable-auto-import -Wl,--stack,8388608 \
+ -Wl,--export-all-symbols -Wl,--enable-auto-import \
+ -Wl,--enable-auto-image-base -Wl,--stack,8388608 \
  $(MODPERL_PIC_OBJS) \
  $(MODPERL_LDDLFLAGS) $(MODPERL_LDOPTS) \
  $(MODPERL_AP_LIBS)




---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: auto-image-base flag for cygwin

Posted by Stas Bekman <st...@stason.org>.
Nikolay Ananiev wrote:
> "Stas Bekman" <st...@stason.org> wrote in message
> news:43188F80.6080104@stason.org...
> 
>>Nikolay Ananiev wrote:
>>
>>>On cygwin some dlls might happen to be with identical
>>>base addresses and if you try to load both of them you'll
>>>get an error and you'll have to use the rebase utility to fix them.
>>>The following patch should prevent this.
>>
>>Thanks Nikolay. Nick is our cygwin guy. (none of us has cygwin to test).
>>Nick, do you approve this patch?
> 
> 
> Stas, I'm Nick. I just changed my e-mail some time ago and that's my full
> name. :)

Heh! Committed! Thanks Nick.

-- 
__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://mailchannels.com

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: auto-image-base flag for cygwin

Posted by Nikolay Ananiev <an...@thegdb.com>.
"Stas Bekman" <st...@stason.org> wrote in message
news:43188F80.6080104@stason.org...
> Nikolay Ananiev wrote:
> > On cygwin some dlls might happen to be with identical
> > base addresses and if you try to load both of them you'll
> > get an error and you'll have to use the rebase utility to fix them.
> > The following patch should prevent this.
>
> Thanks Nikolay. Nick is our cygwin guy. (none of us has cygwin to test).
> Nick, do you approve this patch?

Stas, I'm Nick. I just changed my e-mail some time ago and that's my full
name. :)

>
> >[...]




---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: auto-image-base flag for cygwin

Posted by Stas Bekman <st...@stason.org>.
Nikolay Ananiev wrote:
> On cygwin some dlls might happen to be with identical
> base addresses and if you try to load both of them you'll
> get an error and you'll have to use the rebase utility to fix them.
> The following patch should prevent this.

Thanks Nikolay. Nick is our cygwin guy. (none of us has cygwin to test). 
Nick, do you approve this patch?

> Index: lib/Apache2/Build.pm
> ===================================================================
> --- lib/Apache2/Build.pm (revision 264972)
> +++ lib/Apache2/Build.pm (working copy)
> @@ -320,6 +320,7 @@
> 
>          $ldopts = join ' ',
>              '--export-all-symbols',
> +            '--enable-auto-image-base',
>              "$self->{cwd}/src/modules/perl/$mplib",
>              $ldopts;
> 
> @@ -1590,7 +1591,8 @@
>   $(MODPERL_RM_F) $@
>   $(MODPERL_CC) -shared -o $@ \
>   -Wl,--out-implib=$(MODPERL_LIBNAME).dll.a \
> - -Wl,--export-all-symbols -Wl,--enable-auto-import -Wl,--stack,8388608 \
> + -Wl,--export-all-symbols -Wl,--enable-auto-import \
> + -Wl,--enable-auto-image-base -Wl,--stack,8388608 \
>   $(MODPERL_PIC_OBJS) \
>   $(MODPERL_LDDLFLAGS) $(MODPERL_LDOPTS) \
>   $(MODPERL_AP_LIBS)
> 
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
> For additional commands, e-mail: dev-help@perl.apache.org


-- 
__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://mailchannels.com

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org