From: Jarkko Hietaniemi Date: Mon, 5 Jul 1999 10:31:43 +0000 (+0000) Subject: Make perl_exp.SH smarter about what to include and what to exclude. X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=049fc1c86dccf1e1a1afcb2acb4ac5e1259cf74b;p=p5sagit%2Fp5-mst-13.2.git Make perl_exp.SH smarter about what to include and what to exclude. p4raw-id: //depot/cfgperl@3587 --- diff --git a/perl_exp.SH b/perl_exp.SH index ffacdac..436bfd1 100644 --- a/perl_exp.SH +++ b/perl_exp.SH @@ -52,9 +52,8 @@ echo "#!" > perl.exp # No interp.sym since 5.005_03. # perlio.sym will added later if needed. -syms="global.sym pp.sym" - -cat $syms >> perl.exp +grep '^Perl_' global.sym >> perl.exp +grep '^Perl_' pp.sym >> perl.exp sed -n '/^[A-Za-z]/ s/^/PL_/p' globvar.sym >> perl.exp sed -n 's/^PERLVAR.*(G\([^[,]*\).*/PL_\1/p' perlvars.h >> perl.exp @@ -78,6 +77,48 @@ fi #cat >>perl.exp < perl.exp$$ + mv -f perl.exp$$ perl.exp + case "$ccflags" in + *DEBUGGING*) ;; + *) + egrep -v '^(Perl_dump_mstats)$' < perl.exp > perl.exp$$ + mv -f perl.exp$$ perl.exp + ;; + esac + ;; +esac + +# Remove unneeded utility functions. +egrep -v '^(Perl_my_(bcopy|bzero|chsize|htonl|memcmp|memset|ntohl|swap))$' < perl.exp > perl.exp$$ +mv -f perl.exp$$ perl.exp + +# Remove thread symbols if needed. +case "$usethreads" in +y) ;; +*) + egrep -v '^(Perl_(condpair_magic|find_threadsv|magic_mutexfree|new_struct_thread|unlock_condpair)|^PL_((eval|nthreads)_cond|curthr|eval_owner|(cred|eval|strtab|sv|svref|threads|malloc|vtbl)_mutex|nthreads|threadnum|threadsv_names|thr_key|thrsv))$' < perl.exp > perl.exp$$ + mv -f perl.exp$$ perl.exp + ;; +esac + +# Remove debugging symbols if needed. +case "$ccflags" in +*DEBUGGING*) ;; +*) + egrep -v '^(PL_(block_type|watchaddr|watchok))$' < perl.exp > perl.exp$$ + mv -f perl.exp$$ perl.exp + ;; +esac + +# Remove unneeded globals. +egrep -v '^(Perl_(ErrorNo|GetVars|same_dirent|unlnk)|PL_(cryptseen|statusvalue_vms))' < perl.exp > perl.exp$$ +mv -f perl.exp$$ perl.exp + # The shebang line nicely sorts as the first one. sort -o perl.exp -u perl.exp