In perl.git, the branch blead has been updated <http://perl5.git.perl.org/perl.git/commitdiff/9aa972151378d3fdced94dbae99981c495d749f5?hp=c1e7a0a2cac6d665e90d28a4b81db40e72276749>
- Log ----------------------------------------------------------------- commit 9aa972151378d3fdced94dbae99981c495d749f5 Author: Jarkko Hietaniemi <[email protected]> Date: Tue Jul 22 08:13:24 2014 -0400 Mention libperl.t, and explain nm output some more. ----------------------------------------------------------------------- Summary of changes: pod/perlguts.pod | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/pod/perlguts.pod b/pod/perlguts.pod index 4fe0798..bcd2672 100644 --- a/pod/perlguts.pod +++ b/pod/perlguts.pod @@ -2237,11 +2237,18 @@ please see F<miniperlmain.c> for usage details. You may also need to use C<dVAR> in your coding to "declare the global variables" when you are using them. dTHX does this for you automatically. -To see whether you have non-const data you can use a BSD-compatible C<nm>: +To see whether you have non-const data you can use a BSD (or GNU) +compatible C<nm>: nm libperl.a | grep -v ' [TURtr] ' -If this displays any C<D> or C<d> symbols, you have non-const data. +If this displays any C<D> or C<d> symbols (or possibly C<C> or C<c>), +you have non-const data. The symbols the C<grep> removed are as follows: +C<Tt> are I<text>, or code, the C<Rr> are I<read-only> (const) data, +and the C<U> is <undefined>, external symbols referred to. + +The test F<t/porting/libperl.t> does this kind of symbol sanity +checking on C<libperl.a>. For backward compatibility reasons defining just PERL_GLOBAL_STRUCT doesn't actually hide all symbols inside a big global struct: some -- Perl5 Master Repository
