1*e0680481Safresh1# vim: syntax=pod 2*e0680481Safresh1 355745691SmillertIf you read this file _as_is_, just ignore the funny characters you 455745691Smillertsee. It is written in the POD format (see pod/perlpod.pod) which is 555745691Smillertspecifically designed to be readable as is. 655745691Smillert 755745691Smillert=head1 NAME 855745691Smillert 9898184e3Ssthenperlfreebsd - Perl version 5 on FreeBSD systems 1055745691Smillert 1155745691Smillert=head1 DESCRIPTION 1255745691Smillert 1355745691SmillertThis document describes various features of FreeBSD that will affect how Perl 1455745691Smillertversion 5 (hereafter just Perl) is compiled and/or runs. 1555745691Smillert 1655745691Smillert=head2 FreeBSD core dumps from readdir_r with ithreads 1755745691Smillert 1855745691SmillertWhen perl is configured to use ithreads, it will use re-entrant library calls 1955745691Smillertin preference to non-re-entrant versions. There is a bug in FreeBSD's 2055745691SmillertC<readdir_r> function in versions 4.5 and earlier that can cause a SEGV when 2155745691Smillertreading large directories. A patch for FreeBSD libc is available 22*e0680481Safresh1(see L<https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=30631>) 2355745691Smillertwhich has been integrated into FreeBSD 4.6. 2455745691Smillert 255759b3d2Safresh1=head2 C<$^X> doesn't always contain a full path in FreeBSD 2655745691Smillert 27898184e3Ssthenperl sets C<$^X> where possible to a full path by asking the operating 28898184e3Ssthensystem. On FreeBSD the full path of the perl interpreter is found by using 29898184e3SsthenC<sysctl> with C<KERN_PROC_PATHNAME> if that is supported, else by reading 30898184e3Ssthenthe symlink F</proc/curproc/file>. FreeBSD 7 and earlier has a bug where 31898184e3Sstheneither approach sometimes returns an incorrect value 32*e0680481Safresh1(see L<https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=35703>). 3355745691SmillertIn these cases perl will fall back to the old behaviour of using C's 345759b3d2Safresh1C<argv[0]> value for C<$^X>. 3555745691Smillert 3655745691Smillert=head1 AUTHOR 3755745691Smillert 3855745691SmillertNicholas Clark <nick@ccl4.org>, collating wisdom supplied by Slaven Rezic 3955745691Smillertand Tim Bunce. 4055745691Smillert 4198dafc01Safresh1Please report any errors, updates, or suggestions to 4298dafc01Safresh1L<https://github.com/Perl/perl5/issues>. 4355745691Smillert 44