This commit was generated by cvs2svn to compensate for changes in r92442,
which included commits to RCS files with non-trunk default branches.
This commit is contained in:
commit
535b847ca7
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=92443
@ -1,120 +1,557 @@
|
||||
# Two sections: the real one and the virtual one.
|
||||
# The real section has three \t+ fields: alias, name, email.
|
||||
# The sections are separated by one or more empty lines.
|
||||
# The virtual section (each record two \t+ separated fields) builds
|
||||
# meta-aliases based on the real section.
|
||||
|
||||
alan.burlison Alan Burlison Alan.Burlison@UK.Sun.com
|
||||
allen Norton T. Allen allen@huarp.harvard.edu
|
||||
bradapp Brad Appleton bradapp@enteract.com
|
||||
cbail Charles Bailey bailey@newman.upenn.edu
|
||||
dgris Daniel Grisinger dgris@dimensional.com
|
||||
dmulholl Daniel Yacob dmulholl@cs.indiana.edu
|
||||
dogcow Tom Spindler dogcow@merit.edu
|
||||
domo Dominic Dunlop domo@slipper.ip.lu
|
||||
doug Doug MacEachern dougm@pobox.com
|
||||
doughera Andy Dougherty doughera@lafcol.lafayette.edu
|
||||
gbarr Graham Barr gbarr@ti.com
|
||||
gerti Gerd Knops gerti@BITart.com
|
||||
gibreel Stephen Zander gibreel@pobox.com
|
||||
gnat Nathan Torkington gnat@frii.com
|
||||
gsar Gurusamy Sarathy gsar@activestate.com
|
||||
hansmu Hans Mulder hansmu@xs4all.nl
|
||||
ilya Ilya Zakharevich ilya@math.ohio-state.edu
|
||||
jbuehler Joe Buehler jbuehler@hekimian.com
|
||||
jfs John Stoffel jfs@fluent.com
|
||||
jhi Jarkko Hietaniemi jhi@iki.fi
|
||||
jon Jon Orwant orwant@media.mit.edu
|
||||
jvromans Johan Vromans jvromans@squirrel.nl
|
||||
k Andreas Koenig andreas.koenig@franz.ww.tu-berlin.de
|
||||
kjahds Kenneth Albanowski kjahds@kjahds.com
|
||||
krishna Krishna Sethuraman krishna@sgi.com
|
||||
kstar Kurt D. Starsinic kstar@isinet.com
|
||||
lstein Lincoln D. Stein lstein@genome.wi.mit.edu
|
||||
lutherh Luther Huffman lutherh@stratcom.com
|
||||
lutz Mark P. Lutz mark.p.lutz@boeing.com
|
||||
lwall Larry Wall larry@wall.org
|
||||
makemaker MakeMaker list makemaker@franz.ww.tu-berlin.de
|
||||
mbiggar Mark A Biggar mab@wdl.loral.com
|
||||
mbligh Martin J. Bligh mbligh@sequent.com
|
||||
mike Mike Stok mike@stok.co.uk
|
||||
millert Todd Miller millert@openbsd.org
|
||||
laszlo.molnar Laszlo Molnar Laszlo.Molnar@eth.ericsson.se
|
||||
mpeix Mark Bixby markb@cccd.edu
|
||||
muir David Muir Sharnoff muir@idiom.com
|
||||
neale Neale Ferguson neale@VMA.TABNSW.COM.AU
|
||||
nik Nick Ing-Simmons nik@tiuk.ti.com
|
||||
okamoto Jeff Okamoto okamoto@corp.hp.com
|
||||
paul_green Paul Green Paul_Green@stratus.com
|
||||
pmarquess Paul Marquess Paul.Marquess@btinternet.com
|
||||
pomeranz Hal Pomeranz pomeranz@netcom.com
|
||||
pudge Chris Nandor pudge@pobox.com
|
||||
pueschel Norbert Pueschel pueschel@imsdd.meb.uni-bonn.de
|
||||
pvhp Peter Prymmer pvhp@forte.com
|
||||
raphael Raphael Manfredi Raphael_Manfredi@pobox.com
|
||||
rdieter Rex Dieter rdieter@math.unl.edu
|
||||
rsanders Robert Sanders Robert.Sanders@linux.org
|
||||
roberto Ollivier Robert roberto@keltia.freenix.fr
|
||||
roderick Roderick Schertler roderick@argon.org
|
||||
roehrich Dean Roehrich roehrich@cray.com
|
||||
tsanders Tony Sanders sanders@bsdi.com
|
||||
schinder Paul Schinder schinder@pobox.com
|
||||
scotth Scott Henry scotth@sgi.com
|
||||
seibert Greg Seibert seibert@Lynx.COM
|
||||
spider Spider Boardman spider@Orb.Nashua.NH.US
|
||||
smccam Stephen McCamant smccam@uclink4.berkeley.edu
|
||||
sugalskd Dan Sugalski sugalskd@osshe.edu
|
||||
sundstrom David Sundstrom sunds@asictest.sc.ti.com
|
||||
tchrist Tom Christiansen tchrist@perl.com
|
||||
thomas.dorner Dorner Thomas Thomas.Dorner@start.de
|
||||
timb Tim Bunce Tim.Bunce@ig.co.uk
|
||||
tom.horsley Tom Horsley Tom.Horsley@mail.ccur.com
|
||||
tye Tye McQueen tye@metronet.com
|
||||
wayne.thompson Wayne Thompson Wayne.Thompson@Ebay.sun.com
|
||||
|
||||
PUMPKING gsar
|
||||
aix jhi
|
||||
amiga pueschel
|
||||
beos dogcow
|
||||
bsdos tsanders
|
||||
cfg jhi
|
||||
cgi lstein
|
||||
complex jhi,raphael
|
||||
cpan k
|
||||
cxux tom.horsley
|
||||
cygwin win32
|
||||
dec_osf jhi,spider
|
||||
dgux roderick
|
||||
doc tchrist
|
||||
dos laszlo.molnar
|
||||
dynix/ptx mbligh
|
||||
ebcdic vms,vmesa,posixbc
|
||||
filespec kjahds
|
||||
freebsd roberto
|
||||
hpux okamoto,jhi
|
||||
irix scotth,krishna,jfs,kstar
|
||||
jpl gibreel
|
||||
linux kjahds,kstar
|
||||
locale jhi,domo
|
||||
lynxos lynxos
|
||||
machten domo
|
||||
mm makemaker
|
||||
mvs pvhp
|
||||
netbsd jhi
|
||||
openbsd millert
|
||||
os2 ilya
|
||||
plan9 lutherl
|
||||
posix-bc thomas.dorner
|
||||
powerux tom.horsley
|
||||
qnx allen
|
||||
solaris doughera,alan.burlison
|
||||
step gerti,hansmu,rdieter
|
||||
sunos4 doughera
|
||||
svr4 tye
|
||||
unicos jhi,lutz
|
||||
uwin jbuehler
|
||||
vmesa neale
|
||||
vms sugalskd,cbail
|
||||
vos paul_green
|
||||
warn pmarquess
|
||||
win32 gsar
|
||||
# To give due honor to those who have made Perl 5 what is is today,
|
||||
# here are easily-from-changelogs-extractable people and their
|
||||
# (hopefully) current and preferred email addresses (as of late 2000
|
||||
# if known) from the Changes files. These people have either submitted
|
||||
# patches or suggestions, or their bug reports or comments have inspired
|
||||
# the appropriate patches. Corrections, additions, deletions welcome.
|
||||
#
|
||||
--
|
||||
Aaron B. Dossett <aaron@iglou.com>
|
||||
Abigail <abigail@foad.org>
|
||||
Achim Bohnet <ach@mpe.mpg.de>
|
||||
Adam Krolnik <adamk@gypsy.cyrix.com>
|
||||
Akim Demaille <akim@epita.fr>
|
||||
Alan Burlison <Alan.Burlison@uk.sun.com>
|
||||
Alan Champion <achampio@lehman.com>
|
||||
Alan Harder <Alan.Harder@Ebay.Sun.COM>
|
||||
Alan Modra
|
||||
Albert Chin-A-Young <china@thewrittenword.com>
|
||||
Albert Dvornik <bert@genscan.com>
|
||||
Alexander Smishlajev <als@turnhere.com>
|
||||
Allen Smith <easmith@beatrice.rutgers.edu>
|
||||
Ambrose Kofi Laing
|
||||
Andreas Klussmann <andreas@infosys.heitec.de>
|
||||
Andreas König <a.koenig@mind.de>
|
||||
Andreas Schwab <schwab@suse.de>
|
||||
Andrew Bettison <andrewb@zip.com.au>
|
||||
Andrew Cohen <cohen@andy.bu.edu>
|
||||
Andrew M. Langmead <aml@world.std.com>
|
||||
Andrew Pimlott <pimlott@abel.math.harvard.edu>
|
||||
Andrew Vignaux <ajv@nz.sangacorp.com>
|
||||
Andrew Wilcox <awilcox@maine.com>
|
||||
Andy Dougherty <doughera@lafayette.edu>
|
||||
Anno Siegel <anno4000@lublin.zrz.tu-berlin.de>
|
||||
Anthony David <adavid@netinfo.com.au>
|
||||
Anton Berezin <tobez@tobez.org>
|
||||
Art Green <Art_Green@mercmarine.com>
|
||||
Artur <artur@vogon-solutions.com>
|
||||
Barrie Slaymaker <barries@slaysys.com>
|
||||
Barry Friedman
|
||||
Ben Tilly <ben_tilly@hotmail.com>
|
||||
Benjamin Low <b.d.low@unsw.edu.au>
|
||||
Benjamin Stuhl <sho_pi@hotmail.com>
|
||||
Benjamin Sugars <bsugars@canoe.ca>
|
||||
Bernard Quatermass <bernard@quatermass.co.uk>
|
||||
Bill Campbell <bill@celestial.com>
|
||||
Bill Glicker <billg@burrelles.com>
|
||||
Billy Constantine <wdconsta@cs.adelaide.edu.au>
|
||||
Blair Zajac <bzajac@geostaff.com>
|
||||
Boyd Gerber <gerberb@zenez.com>
|
||||
Brad Appleton <bradapp@enteract.com>
|
||||
Brad Howerter <bhower@wgc.woodward.com>
|
||||
Brad Hughes <brad@tgsmc.com>
|
||||
Brad Lanam <bll@gentoo.com>
|
||||
Brent B. Powers <powers@ml.com>
|
||||
Brian Callaghan <callagh@itginc.com>
|
||||
Brian Clarke <clarke@appliedmeta.com>
|
||||
Brian Grossman
|
||||
Brian Harrison <brie@corp.home.net>
|
||||
Brian Jepson <bjepson@home.com>
|
||||
Brian Katzung
|
||||
Brian Reichert <reichert@internet.com>
|
||||
Brian S. Cashman <bsc@umich.edu>
|
||||
Bruce Barnett <barnett@grymoire.crd.ge.com>
|
||||
Bruce J. Keeler <bkeelerx@iwa.dp.intel.com>
|
||||
Bruce P. Schuck <bruce@aps.org>
|
||||
Bud Huff <BAHUFF@us.oracle.com>
|
||||
Byron Brummer <byron@omix.com>
|
||||
Calle Dybedahl <calle@lysator.liu.se>
|
||||
Carl M. Fongheiser <cmf@ins.infonet.net>
|
||||
Carl Witty <cwitty@newtonlabs.com>
|
||||
Cary D. Renzema <caryr@mxim.com>
|
||||
Casey R. Tweten <crt@kiski.net>
|
||||
Castor Fu
|
||||
Chaim Frenkel <chaimf@pobox.com>
|
||||
Charles Bailey <bailey@newman.upenn.edu>
|
||||
Charles F. Randall <crandall@free.click-n-call.com>
|
||||
Charles Lane <lane@DUPHY4.Physics.Drexel.Edu>
|
||||
Charles Wilson <cwilson@ece.gatech.edu>
|
||||
Chip Salzenberg <chip@pobox.com>
|
||||
Chris Faylor <cgf@bbc.com>
|
||||
Chris Nandor <pudge@pobox.com>
|
||||
Chris Wick <cwick@lmc.com>
|
||||
Christian Kirsch <ck@held.mind.de>
|
||||
Christopher Chan-Nui <channui@austin.ibm.com>
|
||||
Christopher Davis <ckd@loiosh.kei.com>
|
||||
Chuck D. Phillips <cdp@hpescdp.fc.hp.com>
|
||||
Chuck Phillips <cdp@fc.hp.com>
|
||||
Chunhui Teng <cteng@nortel.ca>
|
||||
Clark Cooper <coopercc@netheaven.com>
|
||||
Clinton Pierce <cpierce1@ford.com>
|
||||
Colin Kuskie <ckuskie@cadence.com>
|
||||
Conrad Augustin
|
||||
Conrad E. Kimball <cek@tblv021.ca.boeing.com>
|
||||
Craig A. Berry <craig.berry@psinetcs.com>
|
||||
Craig Milo Rogers <Rogers@ISI.EDU>
|
||||
Dale Amon <amon@vnl.com>
|
||||
Damian Conway <damian@cs.monash.edu.au>
|
||||
Damon Atkins <Damon.Atkins@nabaus.com.au>
|
||||
Dan Boorstein <dan_boo@bellsouth.net>
|
||||
Dan Carson <dbc@tc.fluke.COM>
|
||||
Dan Schmidt <dfan@harmonixmusic.com>
|
||||
Dan Sugalski <dan@sidhe.org>
|
||||
Daniel Chetlin <daniel@chetlin.com>
|
||||
Daniel Grisinger <dgris@dimensional.com>
|
||||
Daniel Muiño <dmuino@afip.gov.ar>
|
||||
Daniel S. Lewart <lewart@vadds.cvm.uiuc.edu>
|
||||
Daniel Yacob <dmulholl@cs.indiana.edu>
|
||||
Danny R. Faught <faught@mailhost.rsn.hp.com>
|
||||
Danny Sadinoff <sadinoff@olf.com>
|
||||
Darrell Kindred <dkindred+@cmu.edu>
|
||||
Darrell Schiebel <drs@nrao.edu>
|
||||
Darren/Torin/Who Ever... <torin@daft.com>
|
||||
Dave Bianchi
|
||||
Dave Hartnoll <Dave_Hartnoll@3b2.com>
|
||||
Dave Nelson <David.Nelson@bellcow.com>
|
||||
Dave Schweisguth <dcs@neutron.chem.yale.edu>
|
||||
David Billinghurst <David.Billinghurst@riotinto.com.au>
|
||||
David Campbell
|
||||
David Couture
|
||||
David Denholm <denholm@conmat.phys.soton.ac.uk>
|
||||
David Dyck <dcd@tc.fluke.com>
|
||||
David F. Haertig <dfh@dwroll.lucent.com>
|
||||
David Filo
|
||||
David Glasser <me@davidglasser.net>
|
||||
David Hammen <hammen@gothamcity.jsc.nasa.gov>
|
||||
David J. Fiander <davidf@mks.com>
|
||||
David Kerry <davidk@tor.securecomputing.com>
|
||||
David Muir Sharnoff <muir@idiom.com>
|
||||
David R. Favor <dfavor@austin.ibm.com>
|
||||
David Sparks <daves@ActiveState.com>
|
||||
David Starks-Browning <dstarks@rc.tudelft.nl>
|
||||
David Sundstrom <sunds@asictest.sc.ti.com>
|
||||
Davin Milun <milun@cs.Buffalo.EDU>
|
||||
Dean Roehrich <roehrich@cray.com>
|
||||
Dennis Marsa <dennism@cyrix.com>
|
||||
dive <dive@ender.com>
|
||||
Dominic Dunlop <domo@computer.org>
|
||||
Dominique Dumont <Dominique_Dumont@grenoble.hp.com>
|
||||
Doug Campbell <soup@ampersand.com>
|
||||
Doug MacEachern <dougm@covalent.net>
|
||||
Douglas E. Wegscheid <wegscd@whirlpool.com>
|
||||
Douglas Lankshear <dougl@activestate.com>
|
||||
Dov Grobgeld <dov@Orbotech.Co.IL>
|
||||
Drago Goricanec <drago@raptor.otsd.ts.fujitsu.co.jp>
|
||||
Ed Mooring <mooring@Lynx.COM>
|
||||
Ed Peschko <epeschko@den-mdev1>
|
||||
Elaine -HFB- Ashton <elaine@chaos.wustl.edu>
|
||||
Eric Arnold <eric.arnold@sun.com>
|
||||
Eric Bartley <bartley@icd.cc.purdue.edu>
|
||||
Eric E. Coe <Eric.Coe@oracle.com>
|
||||
Eric Fifer <egf7@columbia.edu>
|
||||
Erich Rickheit
|
||||
Eryq <eryq@zeegee.com>
|
||||
Etienne Grossman <etienne@isr.isr.ist.utl.pt>
|
||||
Eugene Alterman <Eugene.Alterman@bremer-inc.com>
|
||||
Fabien Tassin <tassin@eerie.fr>
|
||||
Felix Gallo <fgallo@etoys.com>
|
||||
Florent Guillaume
|
||||
Frank Crawford
|
||||
Frank Ridderbusch <Frank.Ridderbusch@pdb.siemens.de>
|
||||
Frank Tobin <ftobin@uiuc.edu>
|
||||
François Désarménien <desar@club-internet.fr>
|
||||
Fréderic Chauveau <fmc@pasteur.fr>
|
||||
G. Del Merritt <del@intranetics.com>
|
||||
Gabe Schaffer
|
||||
Gary Clark <GaryC@mail.jeld-wen.com>
|
||||
Gary Ng <71564.1743@compuserve.com>
|
||||
Gerben Wierda <G.C.Th.Wierda@AWT.nl>
|
||||
Gerd Knops <gerti@BITart.com>
|
||||
Giles Lean <giles@nemeton.com.au>
|
||||
Gisle Aas <gisle@aas.no>
|
||||
Gordon J. Miller <gjm@cray.com>
|
||||
Grace Lee <grace@hal.com>
|
||||
Graham Barr <gbarr@pobox.com>
|
||||
Graham TerMarsch <grahamt@ActiveState.com>
|
||||
Greg Bacon <gbacon@itsc.uah.edu>
|
||||
Greg Chapman <glc@well.com>
|
||||
Greg Earle
|
||||
Greg Kuperberg
|
||||
Greg Seibert <seibert@Lynx.COM>
|
||||
Greg Ward <gward@ase.com>
|
||||
Gregory Martin Pfeil <pfeilgm@technomadic.org>
|
||||
Guenter Schmidt <gsc@bruker.de>
|
||||
Guido Flohr <gufl0000@stud.uni-sb.de>
|
||||
Gurusamy Sarathy <gsar@activestate.com>
|
||||
Gustaf Neumann
|
||||
Guy Decoux <decoux@moulon.inra.fr>
|
||||
H.J. Lu <hjl@nynexst.com>
|
||||
H.Merijn Brand <h.m.brand@hccnet.nl>
|
||||
Hal Pomeranz <pomeranz@netcom.com>
|
||||
Hallvard B Furuseth <h.b.furuseth@usit.uio.no>
|
||||
Hannu Napari <Hannu.Napari@hut.fi>
|
||||
Hans Mulder <hansmu@xs4all.nl>
|
||||
Hans de Graaff <J.J.deGraaff@twi.tudelft.nl>
|
||||
Harold O Morris <hom00@utsglobal.com>
|
||||
Harry Edmon <harry@atmos.washington.edu>
|
||||
Helmut Jarausch <jarausch@numa1.igpm.rwth-aachen.de>
|
||||
Henrik Tougaard <ht.000@foa.dk>
|
||||
Hershel Walters <walters@smd4d.wes.army.mil>
|
||||
Holger Bechtold
|
||||
Horst von Brand <vonbrand@sleipnir.valparaiso.cl>
|
||||
Hubert Feyrer <hubert.feyrer@informatik.fh-regensburg.de>
|
||||
Hugo van der Sanden <hv@crypt0.demon.co.uk>
|
||||
Hunter Kelly <retnuh@zule.pixar.com>
|
||||
Huw Rogers <count0@gremlin.straylight.co.jp>
|
||||
Ian Maloney <ian.malonet@ubs.com>
|
||||
Ian Phillipps <ian@dial.pipex.com>
|
||||
Ignasi Roca <ignasi.roca@fujitsu.siemens.es>
|
||||
Ilya Sandler <Ilya.Sandler@etak.com>
|
||||
Ilya Zakharevich <ilya@math.ohio-state.edu>
|
||||
Inaba Hiroto <inaba@st.rim.or.jp>
|
||||
Irving Reid <irving@tor.securecomputing.com>
|
||||
J. David Blackstone <jdb@dfwnet.sbms.sbc.com>
|
||||
J. van Krieken <John.van.Krieken@ATComputing.nl>
|
||||
JD Laub <jdl@access-health.com>
|
||||
JT McDuffie <jt@kpc.com>
|
||||
Jack Shirazi <JackS@GemStone.com>
|
||||
Jacqui Caren <Jacqui.Caren@ig.co.uk>
|
||||
Jake Hamby <jehamby@lightside.com>
|
||||
James FitzGibbon <james@ican.net>
|
||||
Jamshid Afshar
|
||||
Jan D. <jan.djarv@mbox200.swipnet.se>
|
||||
Jan Dubois <jand@activestate.com>
|
||||
Jan Pazdziora <adelton@fi.muni.cz>
|
||||
Jan-Erik Karlsson <trg@privat.utfors.se>
|
||||
Jan-Pieter Cornet <johnpc@xs4all.nl>
|
||||
Jared Rhine <jared@organic.com>
|
||||
Jarkko Hietaniemi <jhi@iki.fi>
|
||||
Jason A. Smith <smithj4@rpi.edu>
|
||||
Jason Shirk
|
||||
Jason Stewart <jasons@cs.unm.edu>
|
||||
Jason Varsoke <jjv@caesun10.msd.ray.com>
|
||||
Jay Rogers <jay@rgrs.com>
|
||||
Jeff Bouis
|
||||
Jeff McDougal <jmcdo@cris.com>
|
||||
Jeff Okamoto <okamoto@corp.hp.com>
|
||||
Jeff Pinyan <japhy@pobox.com>
|
||||
Jeff Urlwin <jurlwin@access.digex.net>
|
||||
Jeffrey Friedl <jfriedl@yahoo-inc.com>
|
||||
Jeffrey S. Haemer <jsh@woodcock.boulder.qms.com>
|
||||
Jens Hamisch <jens@Strawberry.COM>
|
||||
Jens T. Berger Thielemann <jensthi@ifi.uio.no>
|
||||
Jens Thomsen <jens@fiend.cis.com>
|
||||
Jens-Uwe Mager <jum@helios.de>
|
||||
Jeremy D. Zawodny <jzawodn@wcnet.org>
|
||||
Jerome Abela <abela@hsc.fr>
|
||||
Jim Anderson <jander@ml.com>
|
||||
Jim Avera <avera@hal.com>
|
||||
Jim Balter
|
||||
Jim Meyering <meyering@asic.sc.ti.com>
|
||||
Jim Miner <jfm@winternet.com>
|
||||
Jim Richardson
|
||||
Joachim Huober
|
||||
Jochen Wiedmann <joe@ispsoft.de>
|
||||
Joe Buehler <jbuehler@hekimian.com>
|
||||
Joe Smith <jsmith@inwap.com>
|
||||
Joel Rosi-Schwartz <j.schwartz@agonet.it>
|
||||
Joerg Porath <Joerg.Porath@informatik.tu-chemnitz.de>
|
||||
Joergen Haegg
|
||||
Johan Holtman
|
||||
Johan Vromans <jvromans@squirrel.nl>
|
||||
Johann Klasek <jk@auto.tuwien.ac.at>
|
||||
John Bley <jbb6@acpub.duke.edu>
|
||||
John Borwick <jhborwic@unity.ncsu.edu>
|
||||
John Cerney <j-cerney1@ti.com>
|
||||
John D Groenveld <groenvel@cse.psu.edu>
|
||||
John Hasstedt <John.Hasstedt@sunysb.edu>
|
||||
John Hughes <john@AtlanTech.COM>
|
||||
John L. Allen <allen@grumman.com>
|
||||
John Macdonald <jmm@revenge.elegant.com>
|
||||
John Nolan <jpnolan@Op.Net>
|
||||
John Peacock <jpeacock@rowman.com>
|
||||
John Pfuntner <pfuntner@vnet.ibm.com>
|
||||
John Rowe
|
||||
John Salinas <jsalinas@cray.com>
|
||||
John Stoffel <jfs@fluent.com>
|
||||
John Tobey <jtobey@john-edwin-tobey.org>
|
||||
Jon Orwant <orwant@oreilly.com>
|
||||
Jonathan Biggar <jon@sems.com>
|
||||
Jonathan D Johnston <jdjohnston2@juno.com>
|
||||
Jonathan Fine <jfine@borders.com>
|
||||
Jonathan I. Kamens <jik@kamens.brookline.ma.us>
|
||||
Jonathan Roy <roy@idle.com>
|
||||
Joseph N. Hall <joseph@cscaper.com>
|
||||
Joseph S. Myers <jsm28@hermes.cam.ac.uk>
|
||||
Joshua Pritikin <joshua.pritikin@db.com>
|
||||
Juan Gallego <Little.Boss@physics.mcgill.ca>
|
||||
Julian Yip <julian@imoney.com>
|
||||
Justin Banks <justinb@cray.com>
|
||||
Ka-Ping Yee <kpyee@aw.sgi.com>
|
||||
Karl Glazebrook <kgb@aaossz.aao.GOV.AU>
|
||||
Karl Heuer <kwzh@gnu.org>
|
||||
Karl Simon Berg <karl@it.kth.se>
|
||||
Karsten Sperling <spiff@phreax.net>
|
||||
Kaveh Ghazi <ghazi@caip.rutgers.edu>
|
||||
Keith Neufeld <neufeld@fast.pvi.org>
|
||||
Keith Thompson <kst@cts.com>
|
||||
Ken Estes <estes@ms.com>
|
||||
Ken Fox <kfox@ford.com>
|
||||
Ken MacLeod <ken@bitsko.slc.ut.us>
|
||||
Ken Shan <ken@digitas.harvard.edu>
|
||||
Kenneth Albanowski <kjahds@kjahds.com>
|
||||
Kenneth Duda <kjd@cisco.com>
|
||||
Keong Lim <Keong.Lim@sr.com.au>
|
||||
Kevin O'Gorman <kevin.kosman@nrc.com>
|
||||
Kevin White <klwhite@magnus.acs.ohio-state.edu>
|
||||
Kim Frutiger
|
||||
Kragen Sitaker <kragen@dnaco.net>
|
||||
Krishna Sethuraman <krishna@sgi.com>
|
||||
Kurt D. Starsinic <kstar@smithrenaud.com>
|
||||
Kyriakos Georgiou
|
||||
Larry Parmelee <parmelee@CS.Cornell.EDU>
|
||||
Larry Schuler
|
||||
Larry Schwimmer <rosebud@cyclone.Stanford.EDU>
|
||||
Larry W. Virden <lvirden@cas.org>
|
||||
Larry Wall <larry@wall.org>
|
||||
Lars Hecking <lhecking@nmrc.ucc.ie>
|
||||
Laszlo Molnar <laszlo.molnar@eth.ericsson.se>
|
||||
Len Johnson <lenjay@ibm.net>
|
||||
Les Peters <lpeters@aol.net>
|
||||
Lincoln D. Stein <lstein@cshl.org>
|
||||
Lionel Cons <lionel.cons@cern.ch>
|
||||
Luca Fini
|
||||
Lupe Christoph <lupe@lupe-christoph.de>
|
||||
Luther Huffman <lutherh@stratcom.com>
|
||||
M. J. T. Guy <mjtg@cam.ac.uk>
|
||||
Major Sébastien <sebastien.major@crdp.ac-caen.fr>
|
||||
Makoto MATSUSHITA <matusita@ics.es.osaka-u.ac.jp>
|
||||
Malcolm Beattie <mbeattie@sable.ox.ac.uk>
|
||||
Marc Lehmann <pcg@goof.com>
|
||||
Marc Paquette <Marc.Paquette@Softimage.COM>
|
||||
Marcel Grunauer <marcel@codewerk.com>
|
||||
Mark A Biggar <mab@wdl.loral.com>
|
||||
Mark Bixby <mark@bixby.org>
|
||||
Mark Dickinson <dickins3@fas.harvard.edu>
|
||||
Mark Hanson
|
||||
Mark K Trettin <mkt@lucent.com>
|
||||
Mark Kaehny <kaehny@execpc.com>
|
||||
Mark Kettenis <kettenis@wins.uva.nl>
|
||||
Mark Klein <mklein@dis.com>
|
||||
Mark Knutsen <knutsen@pilot.njin.net>
|
||||
Mark Kvale <kvale@phy.ucsf.edu>
|
||||
Mark Leighton Fisher <fisherm@tce.com>
|
||||
Mark Murray <mark@grondar.za>
|
||||
Mark P. Lutz <mark.p.lutz@boeing.com>
|
||||
Mark Pease <peasem@primenet.com>
|
||||
Mark Pizzolato <mark@infocomm.com>
|
||||
Mark R. Levinson <mrl@isc.upenn.edu>
|
||||
Mark-Jason Dominus <mjd@plover.com>
|
||||
Martijn Koster <mak@excitecorp.com>
|
||||
Martin J. Bligh <mbligh@sequent.com>
|
||||
Martin Jost <Martin.Jost@icn.siemens.de>
|
||||
Martin Lichtin <lichtin@bivio.com>
|
||||
Martin Plechsmid <plechsmi@karlin.mff.cuni.cz>
|
||||
Marty Lucich <marty@netcom.com>
|
||||
Martyn Pearce <martyn@inpharmatica.co.uk>
|
||||
Masahiro KAJIURA <masahiro.kajiura@toshiba.co.jp>
|
||||
Mathias Koerber <mathias@dnssec1.singnet.com.sg>
|
||||
Matt Kimball
|
||||
Matthew Black <black@csulb.edu>
|
||||
Matthew Green <mrg@splode.eterna.com.au>
|
||||
Matthew T Harden <mthard@mthard1.monsanto.com>
|
||||
Matthias Ulrich Neeracher <neeri@iis.ee.ethz.ch>
|
||||
Matthias Urlichs <smurf@noris.net>
|
||||
Maurizio Loreti <maurizio.loreti@pd.infn.it>
|
||||
Michael Cook <mcook@cognex.com>
|
||||
Michael De La Rue <mikedlr@tardis.ed.ac.uk>
|
||||
Michael Engel <engel@nms1.cc.huji.ac.il>
|
||||
Michael G Schwern <schwern@pobox.com>
|
||||
Michael H. Moran <mhm@austin.ibm.com>
|
||||
Michael Mahan <mahanm@nextwork.rose-hulman.edu>
|
||||
Michael Stevens <mstevens@globnix.org>
|
||||
Michele Sardo
|
||||
Mik Firestone <fireston@lexmark.com>
|
||||
Mike Fletcher <fletch@phydeaux.org>
|
||||
Mike Hopkirk <hops@sco.com>
|
||||
Mike Rogers
|
||||
Mike Stok <mike@stok.co.uk>
|
||||
Mike W Ellwood <mwe@rl.ac.uk>
|
||||
Milton Hankins <webtools@uewrhp03.msd.ray.com>
|
||||
Milton L. Hankins <mlh@swl.msd.ray.com>
|
||||
Molnar Laszlo <molnarl@cdata.tvnet.hu>
|
||||
Murray Nesbitt <mjn@pathcom.com>
|
||||
Nathan Kurz <nate@valleytel.net>
|
||||
Nathan Torkington <gnat@frii.com>
|
||||
Neale Ferguson <neale@VMA.TABNSW.COM.AU>
|
||||
Neil Bowers <neilb@cre.canon.co.uk>
|
||||
Nicholas Clark <nick@ccl4.org>
|
||||
Nick Duffek
|
||||
Nick Gianniotis
|
||||
Nick Ing-Simmons <nick@ing-simmons.net>
|
||||
Norbert Pueschel <pueschel@imsdd.meb.uni-bonn.de>
|
||||
Norton T. Allen <allen@huarp.harvard.edu>
|
||||
Olaf Flebbe <o.flebbe@science-computing.de>
|
||||
Olaf Titz <olaf@bigred.inka.de>
|
||||
Ollivier Robert <roberto@keltia.freenix.fr>
|
||||
Owen Taylor <owt1@cornell.edu>
|
||||
Patrick Hayes <Patrick.Hayes.CAP_SESA@renault.fr>
|
||||
Patrick O'Brien <pdo@cs.umd.edu>
|
||||
Paul A Sand <pas@unh.edu>
|
||||
Paul David Fardy <pdf@morgan.ucs.mun.ca>
|
||||
Paul Green <Paul_Green@stratus.com>
|
||||
Paul Hoffman <phoffman@proper.com>
|
||||
Paul Holser <Paul.Holser.pholser@nortelnetworks.com>
|
||||
Paul Johnson <paul@pjcj.net>
|
||||
Paul Marquess <Paul.Marquess@btinternet.com>
|
||||
Paul Moore <Paul.Moore@uk.origin-it.com>
|
||||
Paul Rogers <Paul.Rogers@Central.Sun.COM>
|
||||
Paul Saab <ps@yahoo-inc.com>
|
||||
Paul Schinder <schinder@pobox.com>
|
||||
Pete Peterson <petersonp@genrad.com>
|
||||
Peter Chines <pchines@nhgri.nih.gov>
|
||||
Peter Gordon <peter@valor.com>
|
||||
Peter Haworth <pmh@edison.ioppublishing.com>
|
||||
Peter J. Farley III <pjfarley@banet.net>
|
||||
Peter Jaspers-Fayer
|
||||
Peter Prymmer <pvhp@forte.com>
|
||||
Peter Scott <Peter@PSDT.com>
|
||||
Peter Wolfe <wolfe@teloseng.com>
|
||||
Peter van Heusden <pvh@junior.uwc.ac.za>
|
||||
Petter Reinholdtsen <pere@hungry.com>
|
||||
Phil Lobbes <phil@finchcomputer.com>
|
||||
Philip Hazel <ph10@cus.cam.ac.uk>
|
||||
Philip Newton <pne@cpan.org>
|
||||
Piers Cawley <pdcawley@bofh.org.uk>
|
||||
Piotr Klaban <makler@oryl.man.torun.pl>
|
||||
Prymmer/Kahn <pvhp@best.com>
|
||||
Quentin Fennessy <quentin@arrakeen.amd.com>
|
||||
Radu Greab <radu@netsoft.ro>
|
||||
Ralf S. Engelschall <rse@engelschall.com>
|
||||
Randal L. Schwartz <merlyn@stonehenge.com>
|
||||
Randy J. Ray <rjray@redhat.com>
|
||||
Raphael Manfredi <Raphael.Manfredi@pobox.com>
|
||||
Raymund Will <ray@caldera.de>
|
||||
Rex Dieter <rdieter@math.unl.edu>
|
||||
Rich Morin <rdm@cfcl.com>
|
||||
Rich Salz <rsalz@bbn.com>
|
||||
Richard A. Wells <Rwells@uhs.harvard.edu>
|
||||
Richard Foley <Richard.Foley@m.dasa.de>
|
||||
Richard L. England <richard_england@mentorg.com>
|
||||
Richard L. Maus, Jr. <rmaus@monmouth.com>
|
||||
Richard Soderberg <rs@crystalflame.net>
|
||||
Richard Yeh <rcyeh@cco.caltech.edu>
|
||||
Rick Delaney <rick@consumercontact.com>
|
||||
Rick Pluta
|
||||
Rickard Westman
|
||||
Rob Henderson <robh@cs.indiana.edu>
|
||||
Robert Partington <rjp@riffraff.plig.net>
|
||||
Robert Sanders <Robert.Sanders@linux.org>
|
||||
Robert Spier <rspier@pobox.com>
|
||||
Robin Barker <rmb1@cise.npl.co.uk>
|
||||
Robin Houston <robin@kitsite.com>
|
||||
Rocco Caputo <troc@netrus.net>
|
||||
Roderick Schertler <roderick@argon.org>
|
||||
Rodger Anderson <rodger@boi.hp.com>
|
||||
Ronald F. Guilmette <rfg@monkeys.com>
|
||||
Ronald J. Kimball <rjk@linguist.dartmouth.edu>
|
||||
Ruben Schattevoy <schattev@imb-jena.de>
|
||||
Rujith S. de Silva <desilva@netbox.com>
|
||||
Russ Allbery <rra@stanford.edu>
|
||||
Russell Fulton <russell@ccu1.auckland.ac.nz>
|
||||
Russell Mosemann
|
||||
Ryan Herbert <rherbert@sycamorehq.com>
|
||||
SAKAI Kiyotaka <ksakai@netwk.ntt-at.co.jp>
|
||||
Samuli Kärkkäinen <skarkkai@woods.iki.fi>
|
||||
Scott Gifford <sgifford@tir.com>
|
||||
Scott Henry <scotth@sgi.com>
|
||||
Sean Robinson <robinson_s@sc.maricopa.edu>
|
||||
Sean Sheedy <seans@ncube.com>
|
||||
Sebastien Barre <Sebastien.Barre@utc.fr>
|
||||
Shigeya Suzuki <shigeya@foretune.co.jp>
|
||||
Shimpei Yamashita <shimpei@socrates.patnet.caltech.edu>
|
||||
Shishir Gundavaram <shishir@ruby.ora.com>
|
||||
Simon Cozens <simon@cozens.net>
|
||||
Simon Leinen
|
||||
Simon Parsons <S.Parsons@ftel.co.uk>
|
||||
Slaven Rezic <eserte@cs.tu-berlin.de>
|
||||
Spider Boardman <spider@orb.nashua.nh.us>
|
||||
Stephane Payrard <stef@francenet.fr>
|
||||
Stephanie Beals <bealzy@us.ibm.com>
|
||||
Stephen McCamant <alias@mcs.com>
|
||||
Stephen O. Lidie <lusol@turkey.cc.Lehigh.EDU>
|
||||
Stephen P. Potter <spp@ds.net>
|
||||
Stephen Zander <gibreel@pobox.com>
|
||||
Steve A Fink <sfink@cs.berkeley.edu>
|
||||
Steve Kelem <steve.kelem@xilinx.com>
|
||||
Steve McDougall <swmcd@world.std.com>
|
||||
Steve Nielsen <spn@enteract.com>
|
||||
Steve Pearlmutter
|
||||
Steve Vinoski
|
||||
Steven Hirsch <hirschs@btv.ibm.com>
|
||||
Steven Knight <knight@theopera.baldmt.citilink.com>
|
||||
Steven Morlock <newspost@morlock.net>
|
||||
Steven N. Hirsch <hirschs@stargate.btv.ibm.com>
|
||||
Steven Parkes <parkes@sierravista.com>
|
||||
Sven Verdoolaege <skimo@breughel.ufsia.ac.be>
|
||||
SynaptiCAD, Inc. <sales@syncad.com>
|
||||
Taro KAWAGISHI
|
||||
Ted Ashton <ashted@southern.edu>
|
||||
Ted Law <tedlaw@cibcwg.com>
|
||||
Teun Burgers <burgers@ecn.nl>
|
||||
Thad Floryan <thad@thadlabs.com>
|
||||
Thomas Bowditch <bowditch@inmet.com>
|
||||
Thomas Conté <tom@fr.uu.net>
|
||||
Thomas Dorner <Thomas.Dorner@start.de>
|
||||
Thomas Kofler
|
||||
Thomas König
|
||||
Tim Adye <T.J.Adye@rl.ac.uk>
|
||||
Tim Ayers <tayers@bridge.com>
|
||||
Tim Bunce <Tim.Bunce@ig.co.uk>
|
||||
Tim Conrow <tim@spindrift.srl.caltech.edu>
|
||||
Tim Freeman <tfreeman@infoseek.com>
|
||||
Tim Jenness <t.jenness@jach.hawaii.edu>
|
||||
Tim Mooney <mooney@dogbert.cc.ndsu.NoDak.edu>
|
||||
Tim Witham <twitham@pcocd2.intel.com>
|
||||
Timur I. Bakeyev <bsdi@listserv.bat.ru>
|
||||
Tkil <tkil@reptile.scrye.com>
|
||||
Todd C. Miller <Todd.Miller@courtesan.com>
|
||||
Tom Bates <tom_bates@att.net>
|
||||
Tom Christiansen <tchrist@perl.com>
|
||||
Tom Horsley <Tom.Horsley@mail.ccur.com>
|
||||
Tom Hughes <tom@compton.nu>
|
||||
Tom Phoenix <rootbeer@teleport.com>
|
||||
Tom Spindler <dogcow@isi.net>
|
||||
Tony Camas
|
||||
Tony Cook <tony@develop-help.com>
|
||||
Tony Sanders <sanders@bsdi.com>
|
||||
Tor Lillqvist <tml@hemuli.tte.vtt.fi>
|
||||
Trevor Blackwell <tlb@viaweb.com>
|
||||
Tuomas J. Lukka <tjl@lukka.student.harvard.edu>
|
||||
Tye McQueen <tye@metronet.com>
|
||||
Ulrich Kunitz <kunitz@mai-koeln.com>
|
||||
Ulrich Pfeifer <pfeifer@wait.de>
|
||||
Vadim Konovalov <vkonovalov@lucent.com>
|
||||
Valeriy E. Ushakov <uwe@ptc.spbu.ru>
|
||||
Vishal Bhatia <vishal@deja.com>
|
||||
Vlad Harchev <hvv@hippo.ru>
|
||||
Vladimir Alexiev <vladimir@cs.ualberta.ca>
|
||||
W. Phillip Moore <wpm@ms.com>
|
||||
Warren Hyde <whyde@pezz.sps.mot.com>
|
||||
Warren Jones <wjones@tc.fluke.com>
|
||||
Wayne Berke <berke@panix.com>
|
||||
Wayne Scott <wscott@ichips.intel.com>
|
||||
Wayne Thompson <Wayne.Thompson@Ebay.sun.com>
|
||||
Wilfredo Sánchez <wsanchez@apple.com>
|
||||
William J. Middleton <William.Middleton@oslo.mobil.telenor.no>
|
||||
William Mann <wmann@avici.com>
|
||||
William R Ward <hermit@BayView.COM>
|
||||
William Setzer <William_Setzer@ncsu.edu>
|
||||
Winfried König <win@in.rhein-main.de>
|
||||
Wolfgang Laun <Wolfgang.Laun@alcatel.at>
|
||||
Yary Hluchan
|
||||
Yasushi Nakajima <sey@jkc.co.jp>
|
||||
Yitzchak Scott-Thoennes <sthoenna@efn.org>
|
||||
Yutaka OIWA <oiwa@is.s.u-tokyo.ac.jp>
|
||||
Yutao Feng
|
||||
Zachary Miller <zcmiller@simon.er.usgs.gov>
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -8031,7 +8031,7 @@ This release is beta candidate #5: Our last, best hope for a beta.
|
||||
From: Chip Salzenberg
|
||||
Files: pp_hot.c
|
||||
|
||||
Title: "Fix grep() with refs in array context"
|
||||
Title: "Fix grep() with refs in list context"
|
||||
From: Chip Salzenberg
|
||||
Files: pp.c
|
||||
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -1,6 +1,6 @@
|
||||
/* EXTERN.h
|
||||
*
|
||||
* Copyright (c) 1991-2000, Larry Wall
|
||||
* Copyright (c) 1991-2001, Larry Wall
|
||||
*
|
||||
* You may distribute under the terms of either the GNU General Public
|
||||
* License or the Artistic License, as specified in the README file.
|
||||
|
@ -6,7 +6,7 @@ Install - Build and Installation guide for perl5.
|
||||
|
||||
First, make sure you are installing an up-to-date version of Perl. If
|
||||
you didn't get your Perl source from CPAN, check the latest version at
|
||||
<URL:http://www.perl.com/CPAN/src/>.
|
||||
<URL:http://www.cpan.org/src/>.
|
||||
|
||||
The basic steps to build and install perl5 on a Unix system
|
||||
with all the defaults are:
|
||||
@ -24,6 +24,15 @@ with all the defaults are:
|
||||
|
||||
Each of these is explained in further detail below.
|
||||
|
||||
B<NOTE>: starting from the release 5.6.0 Perl will use a version
|
||||
scheme where even-numbered subreleases (like 5.6) are stable
|
||||
maintenance releases and odd-numbered subreleases (like 5.7) are
|
||||
unstable development releases. Development releases should not be
|
||||
used in production environments. Fixes and new features are first
|
||||
carefully tested in development releases and only if they prove
|
||||
themselves to be worthy will they be migrated to the maintenance
|
||||
releases.
|
||||
|
||||
The above commands will install Perl to /usr/local or /opt, depending
|
||||
on the platform. If that's not okay with you, use
|
||||
|
||||
@ -76,7 +85,7 @@ extensions that have not been updated for the new naming convention
|
||||
with:
|
||||
|
||||
perl Makefile.PL POLLUTE=1
|
||||
|
||||
|
||||
Alternatively, you can enable CPP symbol pollution wholesale by
|
||||
building perl itself with:
|
||||
|
||||
@ -113,8 +122,42 @@ currently installed modules.
|
||||
|
||||
=head1 WARNING: This version requires a compiler that supports ANSI C.
|
||||
|
||||
If you find that your C compiler is not ANSI-capable, try obtaining
|
||||
GCC, available from GNU mirrors worldwide (e.g. ftp://ftp.gnu.org/pub/gnu).
|
||||
Most C compilers are now ANSI-compliant. However, a few current
|
||||
computers are delivered with an older C compiler expressly for
|
||||
rebuilding the system kernel, or for some other historical reason.
|
||||
Alternatively, you may have an old machine which was shipped before
|
||||
ANSI compliance became widespread. Such compilers are not suitable
|
||||
for building Perl.
|
||||
|
||||
If you find that your default C compiler is not ANSI-capable, but you
|
||||
know that an ANSI-capable compiler is installed on your system, you
|
||||
can tell F<Configure> to use the correct compiler by means of the
|
||||
C<-Dcc=> command-line option -- see L<"gcc">.
|
||||
|
||||
If do not have an ANSI-capable compiler there are several avenues open
|
||||
to you:
|
||||
|
||||
=over 4
|
||||
|
||||
=item *
|
||||
|
||||
You may try obtaining GCC, available from GNU mirrors worldwide,
|
||||
listed at <URL:http://www.gnu.org/order/ftp.html>. If, rather than
|
||||
building gcc from source code, you locate a binary version configured
|
||||
for your platform, be sure that it is compiled for the version of the
|
||||
operating system that you are using.
|
||||
|
||||
=item *
|
||||
|
||||
You may purchase a commercial ANSI C compiler from your system
|
||||
supplier or elsewhere. (Or your organization may already have
|
||||
licensed such software -- ask your colleagues to find out how to
|
||||
access it.) If there is a README file for your system in the Perl
|
||||
distribution (for example, F<README.hpux>), it may contain advice on
|
||||
suitable compilers.
|
||||
|
||||
=item *
|
||||
|
||||
Another alternative may be to use a tool like ansi2knr to convert the
|
||||
sources back to K&R style, but there is no guarantee this route will get
|
||||
you anywhere, since the prototypes are not the only ANSI features used
|
||||
@ -125,9 +168,11 @@ run, you may have to run it on a platform where GCC is available, and move
|
||||
the sources back to the platform without GCC.
|
||||
|
||||
If you succeed in automatically converting the sources to a K&R compatible
|
||||
form, be sure to email perlbug@perl.com to let us know the steps you
|
||||
form, be sure to email perlbug@perl.org to let us know the steps you
|
||||
followed. This will enable us to officially support this option.
|
||||
|
||||
=back
|
||||
|
||||
Although Perl can be compiled using a C++ compiler, the Configure script
|
||||
does not work with some C++ compilers.
|
||||
|
||||
@ -219,6 +264,28 @@ For more help on Configure switches, run:
|
||||
|
||||
sh Configure -h
|
||||
|
||||
=head2 Building Perl outside of the source directory
|
||||
|
||||
Sometimes it is desirable to build Perl in a directory different from
|
||||
where the sources are, for example if you want to keep your sources
|
||||
read-only, or if you want to share the sources between different binary
|
||||
architectures.
|
||||
|
||||
Starting from Perl 5.6.1 you can do this (if your file system supports
|
||||
symbolic links) by
|
||||
|
||||
mkdir /tmp/perl/build/directory
|
||||
cd /tmp/perl/build/directory
|
||||
sh /path/to/perl/source/Configure -Dmksymlinks ...
|
||||
|
||||
This will create in /tmp/perl/build/directory a tree of symbolic links
|
||||
pointing to files in /path/to/perl/source. The original files are left
|
||||
unaffected. After Configure has finished you can just say
|
||||
|
||||
make all test
|
||||
|
||||
and Perl will be built and tested, all in /tmp/perl/build/directory.
|
||||
|
||||
=head2 Common Configure options
|
||||
|
||||
Configure supports a number of useful options. Run B<Configure -h> to
|
||||
@ -291,7 +358,14 @@ output, you can run
|
||||
|
||||
sh Configure -des
|
||||
|
||||
For my Solaris system, I usually use
|
||||
Note: for development releases (odd subreleases, like 5.7, as opposed
|
||||
to maintenance releases which have even subreleases, like 5.6)
|
||||
if you want to use Configure -d, you will also need to supply -Dusedevel
|
||||
to Configure, because the default answer to the question "do you really
|
||||
want to Configure a development version?" is "no". The -Dusedevel
|
||||
skips that sanity check.
|
||||
|
||||
For example for my Solaris system, I usually use
|
||||
|
||||
sh Configure -Dprefix=/opt/perl -Doptimize='-xpentium -xO4' -des
|
||||
|
||||
@ -461,9 +535,26 @@ network. One way to do that would be something like
|
||||
|
||||
As a final catch-all, Configure also offers an $otherlibdirs
|
||||
variable. This variable contains a colon-separated list of additional
|
||||
directories to add to @INC. By default, it will be set to
|
||||
$prefix/site_perl if Configure detects that you have 5.004-era modules
|
||||
installed there. However, you can set it to anything you like.
|
||||
directories to add to @INC. By default, it will be empty.
|
||||
Perl will search these directories (including architecture and
|
||||
version-specific subdirectories) for add-on modules and extensions.
|
||||
|
||||
=item APPLLIB_EXP
|
||||
|
||||
There is one other way of adding paths to @INC at perl build time, and
|
||||
that is by setting the APPLLIB_EXP C pre-processor token to a colon-
|
||||
separated list of directories, like this
|
||||
|
||||
sh Configure -Accflags='-DAPPLLIB_EXP=\"/usr/libperl\"'
|
||||
|
||||
The directories defined by APPLLIB_EXP get added to @INC I<first>,
|
||||
ahead of any others, and so provide a way to override the standard perl
|
||||
modules should you, for example, want to distribute fixes without
|
||||
touching the perl distribution proper. And, like otherlib dirs,
|
||||
version and architecture specific subdirectories are also searched, if
|
||||
present, at run time. Of course, you can still search other @INC
|
||||
directories ahead of those in APPLLIB_EXP by using any of the standard
|
||||
run-time methods: $PERLLIB, $PERL5LIB, -I, use lib, etc.
|
||||
|
||||
=item Man Pages
|
||||
|
||||
@ -634,6 +725,52 @@ or by
|
||||
Eventually (by perl v5.6.0) this internal confusion ought to disappear,
|
||||
and these options may disappear as well.
|
||||
|
||||
=head2 64 bit support.
|
||||
|
||||
If your platform does not have 64 bits natively, but can simulate them with
|
||||
compiler flags and/or C<long long> or C<int64_t>, you can build a perl that
|
||||
uses 64 bits.
|
||||
|
||||
There are actually two modes of 64-bitness: the first one is achieved
|
||||
using Configure -Duse64bitint and the second one using Configure
|
||||
-Duse64bitall. The difference is that the first one is minimal and
|
||||
the second one maximal. The first works in more places than the second.
|
||||
|
||||
The C<use64bitint> does only as much as is required to get 64-bit
|
||||
integers into Perl (this may mean, for example, using "long longs")
|
||||
while your memory may still be limited to 2 gigabytes (because your
|
||||
pointers could still be 32-bit). Note that the name C<64bitint> does
|
||||
not imply that your C compiler will be using 64-bit C<int>s (it might,
|
||||
but it doesn't have to): the C<use64bitint> means that you will be
|
||||
able to have 64 bits wide scalar values.
|
||||
|
||||
The C<use64bitall> goes all the way by attempting to switch also
|
||||
integers (if it can), longs (and pointers) to being 64-bit. This may
|
||||
create an even more binary incompatible Perl than -Duse64bitint: the
|
||||
resulting executable may not run at all in a 32-bit box, or you may
|
||||
have to reboot/reconfigure/rebuild your operating system to be 64-bit
|
||||
aware.
|
||||
|
||||
Natively 64-bit systems like Alpha and Cray need neither -Duse64bitint
|
||||
nor -Duse64bitall.
|
||||
|
||||
NOTE: 64-bit support is still experimental on most platforms.
|
||||
Existing support only covers the LP64 data model. In particular, the
|
||||
LLP64 data model is not yet supported. 64-bit libraries and system
|
||||
APIs on many platforms have not stabilized--your mileage may vary.
|
||||
|
||||
=head2 Long doubles
|
||||
|
||||
In some systems you may be able to use long doubles to enhance the
|
||||
range and precision of your double precision floating point numbers
|
||||
(that is, Perl's numbers). Use Configure -Duselongdouble to enable
|
||||
this support (if it is available).
|
||||
|
||||
=head2 "more bits"
|
||||
|
||||
You can "Configure -Dusemorebits" to turn on both the 64-bit support
|
||||
and the long double support.
|
||||
|
||||
=head2 Selecting File IO mechanisms
|
||||
|
||||
Previous versions of perl used the standard IO mechanisms as defined in
|
||||
@ -665,7 +802,7 @@ extension modules or external libraries may not work. This
|
||||
configuration exists to allow these issues to be worked on.
|
||||
|
||||
This option requires the 'sfio' package to have been built and installed.
|
||||
A (fairly old) version of sfio is in CPAN.
|
||||
The latest sfio is available from http://www.research.att.com/sw/tools/sfio/
|
||||
|
||||
You select this option by
|
||||
|
||||
@ -682,9 +819,6 @@ Configure should detect this problem and warn you about problems with
|
||||
_exit vs. exit. If you have this problem, the fix is to go back to
|
||||
your sfio sources and correct iffe's guess about atexit.
|
||||
|
||||
There also might be a more recent release of Sfio that fixes your
|
||||
problem.
|
||||
|
||||
=item 2.
|
||||
|
||||
Normal stdio IO, but with all IO going through calls to the PerlIO
|
||||
@ -703,6 +837,13 @@ detect sfio, then this will be the default suggested by Configure.
|
||||
|
||||
=back
|
||||
|
||||
=head2 SOCKS
|
||||
|
||||
Perl can be configured to be 'socksified', that is, to use the SOCKS
|
||||
TCP/IP proxy protocol library. SOCKS is used to give applications
|
||||
access to transport layer network proxies. Perl supports only SOCKS
|
||||
Version 5. You can find more about SOCKS from http://www.socks.nec.com/
|
||||
|
||||
=head2 Dynamic Loading
|
||||
|
||||
By default, Configure will compile perl to use dynamic loading if
|
||||
@ -1029,6 +1170,39 @@ you have some libraries under /usr/local/ and others under
|
||||
|
||||
=back
|
||||
|
||||
=head2 Building DB, NDBM, and ODBM interfaces with Berkeley DB 3
|
||||
|
||||
Perl interface for DB3 is part of Berkeley DB, but if you want to
|
||||
compile standard Perl DB/ODBM/NDBM interfaces, you must follow
|
||||
following instructions.
|
||||
|
||||
Berkeley DB3 from Sleepycat Software is by default installed without
|
||||
DB1 compatibility code (needed for DB_File interface) and without
|
||||
links to compatibility files. So if you want to use packages written
|
||||
for DB/ODBM/NDBM interfaces, you need to configure DB3 with
|
||||
--enable-compat185 (and optionally with --enable-dump185) and create
|
||||
additional references (suppose you are installing DB3 with
|
||||
--prefix=/usr):
|
||||
|
||||
ln -s libdb-3.so /usr/lib/libdbm.so
|
||||
ln -s libdb-3.so /usr/lib/libndbm.so
|
||||
echo '#define DB_DBM_HSEARCH 1' >dbm.h
|
||||
echo '#include <db.h>' >>dbm.h
|
||||
install -m 0644 dbm.h /usr/include/dbm.h
|
||||
install -m 0644 dbm.h /usr/include/ndbm.h
|
||||
|
||||
Optionally, if you have compiled with --enable-compat185 (not needed
|
||||
for ODBM/NDBM):
|
||||
|
||||
ln -s libdb-3.so /usr/lib/libdb1.so
|
||||
ln -s libdb-3.so /usr/lib/libdb.so
|
||||
|
||||
ODBM emulation seems not to be perfect, but is quite usable,
|
||||
using DB 3.1.17:
|
||||
|
||||
lib/odbm.............FAILED at test 9
|
||||
Failed 1/64 tests, 98.44% okay
|
||||
|
||||
=head2 What if it doesn't work?
|
||||
|
||||
If you run into problems, try some of the following ideas.
|
||||
@ -1295,36 +1469,6 @@ numbers and function name may vary in different versions of perl):
|
||||
it might well be a symptom of the gcc "varargs problem". See the
|
||||
previous L<"varargs"> item.
|
||||
|
||||
=item Solaris and SunOS dynamic loading
|
||||
|
||||
If you have problems with dynamic loading using gcc on SunOS or
|
||||
Solaris, and you are using GNU as and GNU ld, you may need to add
|
||||
-B/bin/ (for SunOS) or -B/usr/ccs/bin/ (for Solaris) to your
|
||||
$ccflags, $ldflags, and $lddlflags so that the system's versions of as
|
||||
and ld are used. Note that the trailing '/' is required.
|
||||
Alternatively, you can use the GCC_EXEC_PREFIX
|
||||
environment variable to ensure that Sun's as and ld are used. Consult
|
||||
your gcc documentation for further information on the -B option and
|
||||
the GCC_EXEC_PREFIX variable.
|
||||
|
||||
One convenient way to ensure you are not using GNU as and ld is to
|
||||
invoke Configure with
|
||||
|
||||
sh Configure -Dcc='gcc -B/usr/ccs/bin/'
|
||||
|
||||
for Solaris systems. For a SunOS system, you must use -B/bin/
|
||||
instead.
|
||||
|
||||
Alternatively, recent versions of GNU ld reportedly work if you
|
||||
include C<-Wl,-export-dynamic> in the ccdlflags variable in
|
||||
config.sh.
|
||||
|
||||
=item ld.so.1: ./perl: fatal: relocation error:
|
||||
|
||||
If you get this message on SunOS or Solaris, and you're using gcc,
|
||||
it's probably the GNU as or GNU ld problem in the previous item
|
||||
L<"Solaris and SunOS dynamic loading">.
|
||||
|
||||
=item LD_LIBRARY_PATH
|
||||
|
||||
If you run into dynamic loading problems, check your setting of
|
||||
@ -1333,18 +1477,6 @@ Perl library (libperl.a rather than libperl.so) it should build
|
||||
fine with LD_LIBRARY_PATH unset, though that may depend on details
|
||||
of your local set-up.
|
||||
|
||||
=item dlopen: stub interception failed
|
||||
|
||||
The primary cause of the 'dlopen: stub interception failed' message is
|
||||
that the LD_LIBRARY_PATH environment variable includes a directory
|
||||
which is a symlink to /usr/lib (such as /lib).
|
||||
|
||||
The reason this causes a problem is quite subtle. The file libdl.so.1.0
|
||||
actually *only* contains functions which generate 'stub interception
|
||||
failed' errors! The runtime linker intercepts links to
|
||||
"/usr/lib/libdl.so.1.0" and links in internal implementation of those
|
||||
functions instead. [Thanks to Tim Bunce for this explanation.]
|
||||
|
||||
=item nm extraction
|
||||
|
||||
If Configure seems to be having trouble finding library functions,
|
||||
@ -1518,6 +1650,23 @@ to include the GNU utils before running Configure, or specify the
|
||||
vendor-supplied utilities explicitly to Configure, for example by
|
||||
Configure -Dar=/bin/ar.
|
||||
|
||||
=item THIS PACKAGE SEEMS TO BE INCOMPLETE
|
||||
|
||||
The F<Configure> program has not been able to find all the files which
|
||||
make up the complete Perl distribution. You may have a damaged source
|
||||
archive file (in which case you may also have seen messages such as
|
||||
C<gzip: stdin: unexpected end of file> and C<tar: Unexpected EOF on
|
||||
archive file>), or you may have obtained a structurally-sound but
|
||||
incomplete archive. In either case, try downloading again from the
|
||||
official site named at the start of this document. If you do find
|
||||
that any site is carrying a corrupted or incomplete source code
|
||||
archive, please report it to the site's maintainer.
|
||||
|
||||
=item invalid token: ##
|
||||
|
||||
You are using a non-ANSI-compliant C compiler. See L<WARNING: This
|
||||
version requires a compiler that supports ANSI C>.
|
||||
|
||||
=item Miscellaneous
|
||||
|
||||
Some additional things that have been reported for either perl4 or perl5:
|
||||
@ -1616,6 +1765,51 @@ test, it does not necessarily mean you have a broken perl. This test
|
||||
tries to exercise the regular expression subsystem quite thoroughly,
|
||||
and may well be far more demanding than your normal usage.
|
||||
|
||||
=item Test failures from lib/ftmp-security saying "system possibly insecure"
|
||||
|
||||
Firstly, test failures from the ftmp-security are not necessarily
|
||||
serious or indicative of a real security threat. That being said,
|
||||
they bear investigating.
|
||||
|
||||
The tests may fail for the following reasons. Note that each of the
|
||||
tests is run both in the building directory and the temporary
|
||||
directory, as returned by File::Spec->tmpdir().
|
||||
|
||||
(1) If the directory the tests are being run is owned by somebody else
|
||||
than the user running the tests, or root (uid 0). This failure can
|
||||
happen if the Perl source code distribution is unpacked in a way that
|
||||
the user ids in the distribution package are used as-is. Some tar
|
||||
programs do this.
|
||||
|
||||
(2) If the directory the test are being run in is writable by group
|
||||
or by other (remember: with UNIX/POSIX semantics, write access to
|
||||
a directory means the right to add/remove files in that directory),
|
||||
and there is no sticky bit set in the directory. 'Sticky bit' is
|
||||
a feature used in some UNIXes to give extra protection to files: if
|
||||
the bit is on a directory, no one but the owner (or the root) can remove
|
||||
that file even if the permissions of the directory would allow file
|
||||
removal by others. This failure can happen if the permissions in the
|
||||
directory simply are a bit too liberal for the tests' liking. This
|
||||
may or may not be a real problem: it depends on the permissions policy
|
||||
used on this particular directory/project/system/site. This failure
|
||||
can also happen if the system either doesn't support the sticky bit
|
||||
(this is the case with many non-UNIX platforms: in principle the
|
||||
File::Temp should know about these platforms and skip the tests), or
|
||||
if the system supports the sticky bit but for some reason or reasons
|
||||
it is not being used. This is for example the case with HP-UX: as of
|
||||
HP-UX release 11.00, the sticky bit is very much supported, but HP-UX
|
||||
doesn't use it on its /tmp directory as shipped. Also as with the
|
||||
permissions, some local policy might dictate that the stickiness is
|
||||
not used.
|
||||
|
||||
(3) If the system supports the POSIX 'chown giveaway' feature and if
|
||||
any of the parent directories of the temporary file back to the root
|
||||
directory are 'unsafe', using the definitions given above in (1) and
|
||||
(2).
|
||||
|
||||
See the documentation for the File::Temp module for more information
|
||||
about the various security aspects.
|
||||
|
||||
=back
|
||||
|
||||
=head1 make install
|
||||
@ -1654,12 +1848,17 @@ anything, you can run
|
||||
|
||||
make install will install the following:
|
||||
|
||||
binaries
|
||||
|
||||
perl,
|
||||
perl5.nnn where nnn is the current release number. This
|
||||
will be a link to perl.
|
||||
suidperl,
|
||||
sperl5.nnn If you requested setuid emulation.
|
||||
a2p awk-to-perl translator
|
||||
|
||||
scripts
|
||||
|
||||
cppstdin This is used by perl -P, if your cc -E can't
|
||||
read from stdin.
|
||||
c2ph, pstruct Scripts for handling C structures in header files.
|
||||
@ -1672,13 +1871,21 @@ make install will install the following:
|
||||
pl2pm Convert Perl 4 .pl files to Perl 5 .pm modules
|
||||
pod2html, Converters from perl's pod documentation format
|
||||
pod2latex, to other useful formats.
|
||||
pod2man, and
|
||||
pod2text
|
||||
pod2man,
|
||||
pod2text,
|
||||
pod2checker,
|
||||
pod2select,
|
||||
pod2usage
|
||||
splain Describe Perl warnings and errors
|
||||
dprofpp Perl code profile post-processor
|
||||
|
||||
library files in $privlib and $archlib specified to
|
||||
library files
|
||||
|
||||
in $privlib and $archlib specified to
|
||||
Configure, usually under /usr/local/lib/perl5/.
|
||||
|
||||
documentation
|
||||
|
||||
man pages in $man1dir, usually /usr/local/man/man1.
|
||||
module man
|
||||
pages in $man3dir, usually /usr/local/man/man3.
|
||||
@ -1687,11 +1894,28 @@ make install will install the following:
|
||||
Installperl will also create the directories listed above
|
||||
in L<"Installation Directories">.
|
||||
|
||||
Perl's *.h header files and the libperl.a library are also installed
|
||||
Perl's *.h header files and the libperl library are also installed
|
||||
under $archlib so that any user may later build new modules, run the
|
||||
optional Perl compiler, or embed the perl interpreter into another
|
||||
program even if the Perl source is no longer available.
|
||||
|
||||
Sometimes you only want to install the version-specific parts of the perl
|
||||
installation. For example, you may wish to install a newer version of
|
||||
perl alongside an already installed production version of perl without
|
||||
disabling installation of new modules for the production version.
|
||||
To only install the version-specific parts of the perl installation, run
|
||||
|
||||
Configure -Dversiononly
|
||||
|
||||
or answer 'y' to the appropriate Configure prompt. Alternatively,
|
||||
you can just manually run
|
||||
|
||||
./perl installperl -v
|
||||
|
||||
and skip installman altogether.
|
||||
See also L<"Maintaining completely separate versions"> for another
|
||||
approach.
|
||||
|
||||
=head1 Coexistence with earlier versions of perl5
|
||||
|
||||
In general, you can usually safely upgrade from one version of Perl (e.g.
|
||||
@ -1878,7 +2102,7 @@ available in TeX format. Type
|
||||
If you have difficulty building perl, and none of the advice in this file
|
||||
helps, and careful reading of the error message and the relevant manual
|
||||
pages on your system doesn't help either, then you should send a message
|
||||
to either the comp.lang.perl.misc newsgroup or to perlbug@perl.com with
|
||||
to either the comp.lang.perl.misc newsgroup or to perlbug@perl.org with
|
||||
an accurate description of your problem.
|
||||
|
||||
Please include the output of the ./myconfig shell script that comes with
|
||||
|
@ -1,6 +1,6 @@
|
||||
/* INTERN.h
|
||||
*
|
||||
* Copyright (c) 1991-2000, Larry Wall
|
||||
* Copyright (c) 1991-2001, Larry Wall
|
||||
*
|
||||
* You may distribute under the terms of either the GNU General Public
|
||||
* License or the Artistic License, as specified in the README file.
|
||||
|
@ -12,7 +12,6 @@ Copying The GNU General Public License
|
||||
EXTERN.h Included before foreign .h files
|
||||
INSTALL Detailed installation instructions
|
||||
INTERN.h Included before domestic .h files
|
||||
MAINTAIN Who maintains which files
|
||||
MANIFEST This list of files
|
||||
Makefile.SH A script that generates Makefile
|
||||
Policy_sh.SH Hold site-wide preferences between Configure runs.
|
||||
@ -30,24 +29,28 @@ Porting/p4desc Smarter 'p4 describe', outputs diffs for new files
|
||||
Porting/patching.pod How to report changes made to Perl
|
||||
Porting/patchls Flexible patch file listing utility
|
||||
Porting/pumpkin.pod Guidelines and hints for Perl maintainers
|
||||
Porting/repository.pod How to use the Perl repository
|
||||
README The Instructions
|
||||
README.Y2K Notes about Year 2000 concerns
|
||||
README.aix Notes about AIX port
|
||||
README.amiga Notes about AmigaOS port
|
||||
README.apollo Notes about Apollo DomainOS port
|
||||
README.beos Notes about BeOS port
|
||||
README.bs2000 Notes about BS2000 POSIX port
|
||||
README.cygwin Notes about Cygwin port
|
||||
README.dos Notes about dos/djgpp port
|
||||
README.epoc Notes about EPOC port
|
||||
README.hpux Notes about HP-UX port
|
||||
README.hurd Notes about GNU/Hurd port
|
||||
README.machten Notes about Power MachTen port
|
||||
README.macos Notes about Mac OS (Classic)
|
||||
README.mint Notes about Atari MiNT port
|
||||
README.mpeix Notes about MPE/iX port
|
||||
README.os2 Notes about OS/2 port
|
||||
README.os390 Notes about OS/390 (nee MVS) port
|
||||
README.plan9 Notes about Plan9 port
|
||||
README.posix-bc Notes about BS2000 POSIX port
|
||||
README.qnx Notes about QNX port
|
||||
README.solaris Notes about Solaris port
|
||||
README.threads Notes about multithreading
|
||||
README.vmesa Notes about VM/ESA port
|
||||
README.vms Notes about installing the VMS port
|
||||
@ -69,8 +72,8 @@ configure.com Configure-equivalent for VMS
|
||||
configure.gnu Crude emulation of GNU configure
|
||||
cop.h Control operator header
|
||||
cv.h Code value header
|
||||
cygwin/cygwin.c Additional code for Cygwin port
|
||||
cygwin/Makefile.SHs Shared library generation for Cygwin port
|
||||
cygwin/cygwin.c Additional code for Cygwin port
|
||||
cygwin/ld2.in ld wrapper template for Cygwin port
|
||||
cygwin/perlld.in dll generator template for Cygwin port
|
||||
deb.c Debugging routines
|
||||
@ -83,7 +86,6 @@ doio.c I/O operations
|
||||
doop.c Support code for various operations
|
||||
dosish.h Some defines for MS/DOSish machines
|
||||
dump.c Debugging output
|
||||
ebcdic.c EBCDIC support routines
|
||||
eg/ADB An adb wrapper to put in your crash dir
|
||||
eg/README Intro to example perl scripts
|
||||
eg/cgi/RunMeFirst Setup script for CGI examples
|
||||
@ -170,6 +172,7 @@ ext/B/B/Bblock.pm Compiler basic block analysis support
|
||||
ext/B/B/Bytecode.pm Compiler Bytecode backend
|
||||
ext/B/B/C.pm Compiler C backend
|
||||
ext/B/B/CC.pm Compiler CC backend
|
||||
ext/B/B/Concise.pm Compiler Concise backend
|
||||
ext/B/B/Debug.pm Compiler Debug backend
|
||||
ext/B/B/Deparse.pm Compiler Deparse backend
|
||||
ext/B/B/Disassembler.pm Compiler Disassembler backend
|
||||
@ -235,9 +238,11 @@ ext/DynaLoader/XSLoader_pm.PL Simple XS Loader perl module
|
||||
ext/DynaLoader/dl_aix.xs AIX implementation
|
||||
ext/DynaLoader/dl_beos.xs BeOS implementation
|
||||
ext/DynaLoader/dl_dld.xs GNU dld style implementation
|
||||
ext/DynaLoader/dl_dllload.xs S/390 dllload() style implementation
|
||||
ext/DynaLoader/dl_dlopen.xs BSD/SunOS4&5 dlopen() style implementation
|
||||
ext/DynaLoader/dl_dyld.xs NeXT/Apple dyld implementation
|
||||
ext/DynaLoader/dl_hpux.xs HP-UX implementation
|
||||
ext/DynaLoader/dl_mac.xs MacOS implementation
|
||||
ext/DynaLoader/dl_mpeix.xs MPE/iX implementation
|
||||
ext/DynaLoader/dl_next.xs NeXT implementation
|
||||
ext/DynaLoader/dl_none.xs Stub implementation
|
||||
@ -246,6 +251,7 @@ ext/DynaLoader/dl_vms.xs VMS implementation
|
||||
ext/DynaLoader/dlutils.c Dynamic loader utilities for dl_*.xs files
|
||||
ext/DynaLoader/hints/aix.pl Hint for DynaLoader for named architecture
|
||||
ext/DynaLoader/hints/linux.pl Hint for DynaLoader for named architecture
|
||||
ext/DynaLoader/hints/netbsd.pl Hint for DynaLoader for named architecture
|
||||
ext/DynaLoader/hints/openbsd.pl Hint for DynaLoader for named architecture
|
||||
ext/Errno/ChangeLog Errno perl module change log
|
||||
ext/Errno/Errno_pm.PL Errno perl module create script
|
||||
@ -300,8 +306,8 @@ ext/NDBM_File/NDBM_File.xs NDBM extension external subroutines
|
||||
ext/NDBM_File/hints/cygwin.pl Hint for NDBM_File for named architecture
|
||||
ext/NDBM_File/hints/dec_osf.pl Hint for NDBM_File for named architecture
|
||||
ext/NDBM_File/hints/dynixptx.pl Hint for NDBM_File for named architecture
|
||||
ext/NDBM_File/hints/solaris.pl Hint for NDBM_File for named architecture
|
||||
ext/NDBM_File/hints/sco.pl Hint for NDBM_File for named architecture
|
||||
ext/NDBM_File/hints/solaris.pl Hint for NDBM_File for named architecture
|
||||
ext/NDBM_File/hints/svr4.pl Hint for NDBM_File for named architecture
|
||||
ext/NDBM_File/typemap NDBM extension interface types
|
||||
ext/ODBM_File/Makefile.PL ODBM extension makefile writer
|
||||
@ -333,6 +339,7 @@ ext/POSIX/hints/netbsd.pl Hint for POSIX for named architecture
|
||||
ext/POSIX/hints/next_3.pl Hint for POSIX for named architecture
|
||||
ext/POSIX/hints/openbsd.pl Hint for POSIX for named architecture
|
||||
ext/POSIX/hints/sunos_4.pl Hint for POSIX for named architecture
|
||||
ext/POSIX/hints/svr4.pl Hint for POSIX for named architecture
|
||||
ext/POSIX/typemap POSIX extension interface types
|
||||
ext/SDBM_File/Makefile.PL SDBM extension makefile writer
|
||||
ext/SDBM_File/SDBM_File.pm SDBM extension Perl module
|
||||
@ -366,9 +373,9 @@ ext/SDBM_File/typemap SDBM extension interface types
|
||||
ext/Socket/Makefile.PL Socket extension makefile writer
|
||||
ext/Socket/Socket.pm Socket extension Perl module
|
||||
ext/Socket/Socket.xs Socket extension external subroutines
|
||||
ext/Sys/Hostname/Makefile.PL Sys::Hostname extension makefile writer
|
||||
ext/Sys/Hostname/Hostname.pm Sys::Hostname extension Perl module
|
||||
ext/Sys/Hostname/Hostname.xs Sys::Hostname extension external subroutines
|
||||
ext/Sys/Hostname/Makefile.PL Sys::Hostname extension makefile writer
|
||||
ext/Sys/Syslog/Makefile.PL Sys::Syslog extension makefile writer
|
||||
ext/Sys/Syslog/Syslog.pm Sys::Syslog extension Perl module
|
||||
ext/Sys/Syslog/Syslog.xs Sys::Syslog extension external subroutines
|
||||
@ -402,6 +409,7 @@ ext/attrs/Makefile.PL attrs extension makefile writer
|
||||
ext/attrs/attrs.pm attrs extension Perl module
|
||||
ext/attrs/attrs.xs attrs extension external subroutines
|
||||
ext/re/Makefile.PL re extension makefile writer
|
||||
ext/re/hints/aix.pl Hints for re for named architecture
|
||||
ext/re/hints/mpeix.pl Hints for re for named architecture
|
||||
ext/re/re.pm re extension Perl module
|
||||
ext/re/re.xs re extension external subroutines
|
||||
@ -478,6 +486,7 @@ hints/newsos4.sh Hints for named architecture
|
||||
hints/next_3.sh Hints for named architecture
|
||||
hints/next_3_0.sh Hints for named architecture
|
||||
hints/next_4.sh Hints for named architecture
|
||||
hints/nonstopux.sh Hints for named architecture
|
||||
hints/openbsd.sh Hints for named architecture
|
||||
hints/opus.sh Hints for named architecture
|
||||
hints/os2.sh Hints for named architecture
|
||||
@ -516,6 +525,7 @@ installman Perl script to install man pages for pods
|
||||
installperl Perl script to do "make install" dirty work
|
||||
intrpvar.h Variables held in each interpreter instance
|
||||
iperlsys.h Perl's interface to the system
|
||||
jpl/ChangeLog Java/Perl Lingo change log
|
||||
jpl/JNI/Changes Java Native Interface changes
|
||||
jpl/JNI/Closer.java Java Native Interface example
|
||||
jpl/JNI/JNI.pm Java Native Interface module
|
||||
@ -543,12 +553,14 @@ jpl/PerlInterpreter/PerlInterpreter.c Perl interpreter abstraction
|
||||
jpl/PerlInterpreter/PerlInterpreter.h Perl interpreter abstraction
|
||||
jpl/PerlInterpreter/PerlInterpreter.java Perl interpreter abstraction
|
||||
jpl/README JPL instructions
|
||||
jpl/README.JUST-JNI JPL instructions
|
||||
jpl/SETVARS.PL JPL setup
|
||||
jpl/Sample/Makefile.PL JPL sample makefile generator
|
||||
jpl/Sample/Sample.jpl JPL sample
|
||||
jpl/Test/Makefile.PL JPL tests makefile generator
|
||||
jpl/Test/Test.jpl JPL tests
|
||||
jpl/bin/jpl JPL compiler
|
||||
jpl/docs/Tutorial.pod Perl and Java Tutorial
|
||||
jpl/get_jdk/README Instructions for using get_jdk.pl
|
||||
jpl/get_jdk/get_jdk.pl JDK download tool
|
||||
jpl/get_jdk/jdk_hosts JDK availability list
|
||||
@ -567,6 +579,7 @@ lib/CGI/Fast.pm Support for FastCGI (persistent server process)
|
||||
lib/CGI/Pretty.pm Output nicely formatted HTML
|
||||
lib/CGI/Push.pm Support for server push
|
||||
lib/CGI/Switch.pm Simple interface for multiple server types
|
||||
lib/CGI/Util.pm Utility functions
|
||||
lib/CPAN.pm Interface to Comprehensive Perl Archive Network
|
||||
lib/CPAN/FirstTime.pm Utility for creating CPAN config files
|
||||
lib/CPAN/Nox.pm Runs CPAN while avoiding compiled extensions
|
||||
@ -610,12 +623,14 @@ lib/File/DosGlob.pm Win32 DOS-globbing module
|
||||
lib/File/Find.pm Routines to do a find
|
||||
lib/File/Path.pm Do things like `mkdir -p' and `rm -r'
|
||||
lib/File/Spec.pm portable operations on file names
|
||||
lib/File/Spec/Epoc.pm portable operations on EPOC file names
|
||||
lib/File/Spec/Functions.pm Function interface to File::Spec object methods
|
||||
lib/File/Spec/Mac.pm portable operations on Mac file names
|
||||
lib/File/Spec/OS2.pm portable operations on OS2 file names
|
||||
lib/File/Spec/Unix.pm portable operations on Unix file names
|
||||
lib/File/Spec/VMS.pm portable operations on VMS file names
|
||||
lib/File/Spec/Win32.pm portable operations on Win32 file names
|
||||
lib/File/Temp.pm create safe temporary files and file handles
|
||||
lib/File/stat.pm By-name interface to Perl's builtin stat
|
||||
lib/FileCache.pm Keep more files open than the system permits
|
||||
lib/FileHandle.pm Backward-compatible front end to IO extension
|
||||
@ -639,6 +654,7 @@ lib/Pod/Find.pm used by pod/splitpod
|
||||
lib/Pod/Functions.pm used by pod/splitpod
|
||||
lib/Pod/Html.pm Convert POD data to HTML
|
||||
lib/Pod/InputObjects.pm Pod-Parser - define objects for input streams
|
||||
lib/Pod/LaTeX.pm Convert POD data to LaTeX
|
||||
lib/Pod/Man.pm Convert POD data to *roff
|
||||
lib/Pod/ParseUtils.pm Pod-Parser - pod utility functions
|
||||
lib/Pod/Parser.pm Pod-Parser - define base class for parsing POD
|
||||
@ -646,6 +662,7 @@ lib/Pod/Plainer.pm Pod migration utility module
|
||||
lib/Pod/Select.pm Pod-Parser - select portions of POD docs
|
||||
lib/Pod/Text.pm Pod-Parser - convert POD data to formatted ASCII text
|
||||
lib/Pod/Text/Color.pm Convert POD data to color ASCII text
|
||||
lib/Pod/Text/Overstrike.pm Convert POD data to formatted overstrike text
|
||||
lib/Pod/Text/Termcap.pm Convert POD data to ASCII text with format escapes
|
||||
lib/Pod/Usage.pm Pod-Parser - print usage messages
|
||||
lib/Search/Dict.pm Perform binary search on dictionaries
|
||||
@ -677,6 +694,7 @@ lib/Time/tm.pm Internal object for Time::{gm,local}time
|
||||
lib/UNIVERSAL.pm Base class for ALL classes
|
||||
lib/User/grent.pm By-name interface to Perl's builtin getgr*
|
||||
lib/User/pwent.pm By-name interface to Perl's builtin getpw*
|
||||
lib/Win32.pod Documentation for Win32 extras
|
||||
lib/abbrev.pl An abbreviation table builder
|
||||
lib/assert.pl assertion and panic with stack trace
|
||||
lib/attributes.pm For "sub foo : attrlist"
|
||||
@ -734,9 +752,11 @@ lib/timelocal.pl Perl library supporting inverse of localtime, gmtime
|
||||
lib/unicode/ArabLink.pl Unicode character database
|
||||
lib/unicode/ArabLnkGrp.pl Unicode character database
|
||||
lib/unicode/ArabShap.txt Unicode character database
|
||||
lib/unicode/BidiMirr.txt Unicode character database
|
||||
lib/unicode/Bidirectional.pl Unicode character database
|
||||
lib/unicode/Block.pl Unicode character database
|
||||
lib/unicode/Blocks.txt Unicode character database
|
||||
lib/unicode/CaseFold.txt Unicode character database
|
||||
lib/unicode/Category.pl Unicode character database
|
||||
lib/unicode/CombiningClass.pl Unicode character database
|
||||
lib/unicode/CompExcl.txt Unicode character database
|
||||
@ -833,29 +853,41 @@ lib/unicode/Index.txt Unicode character database
|
||||
lib/unicode/Is/ASCII.pl Unicode character database
|
||||
lib/unicode/Is/Alnum.pl Unicode character database
|
||||
lib/unicode/Is/Alpha.pl Unicode character database
|
||||
lib/unicode/Is/BidiAL.pl Unicode character database
|
||||
lib/unicode/Is/BidiAN.pl Unicode character database
|
||||
lib/unicode/Is/BidiB.pl Unicode character database
|
||||
lib/unicode/Is/BidiBN.pl Unicode character database
|
||||
lib/unicode/Is/BidiCS.pl Unicode character database
|
||||
lib/unicode/Is/BidiEN.pl Unicode character database
|
||||
lib/unicode/Is/BidiES.pl Unicode character database
|
||||
lib/unicode/Is/BidiET.pl Unicode character database
|
||||
lib/unicode/Is/BidiL.pl Unicode character database
|
||||
lib/unicode/Is/BidiLRE.pl Unicode character database
|
||||
lib/unicode/Is/BidiLRO.pl Unicode character database
|
||||
lib/unicode/Is/BidiNSM.pl Unicode character database
|
||||
lib/unicode/Is/BidiON.pl Unicode character database
|
||||
lib/unicode/Is/BidiPDF.pl Unicode character database
|
||||
lib/unicode/Is/BidiR.pl Unicode character database
|
||||
lib/unicode/Is/BidiRLE.pl Unicode character database
|
||||
lib/unicode/Is/BidiRLO.pl Unicode character database
|
||||
lib/unicode/Is/BidiS.pl Unicode character database
|
||||
lib/unicode/Is/BidiWS.pl Unicode character database
|
||||
lib/unicode/Is/Blank.pl Unicode character database
|
||||
lib/unicode/Is/C.pl Unicode character database
|
||||
lib/unicode/Is/Cc.pl Unicode character database
|
||||
lib/unicode/Is/Cf.pl Unicode character database
|
||||
lib/unicode/Is/Cn.pl Unicode character database
|
||||
lib/unicode/Is/Cntrl.pl Unicode character database
|
||||
lib/unicode/Is/Co.pl Unicode character database
|
||||
lib/unicode/Is/Cs.pl Unicode character database
|
||||
lib/unicode/Is/DCcircle.pl Unicode character database
|
||||
lib/unicode/Is/DCcompat.pl Unicode character database
|
||||
lib/unicode/Is/DCfinal.pl Unicode character database
|
||||
lib/unicode/Is/DCfont.pl Unicode character database
|
||||
lib/unicode/Is/DCinital.pl Unicode character database
|
||||
lib/unicode/Is/DCfraction.pl Unicode character database
|
||||
lib/unicode/Is/DCinitial.pl Unicode character database
|
||||
lib/unicode/Is/DCisolated.pl Unicode character database
|
||||
lib/unicode/Is/DCmedial.pl Unicode character database
|
||||
lib/unicode/Is/DCnarrow.pl Unicode character database
|
||||
lib/unicode/Is/DCnoBreak.pl Unicode character database
|
||||
lib/unicode/Is/DCsmall.pl Unicode character database
|
||||
@ -869,6 +901,35 @@ lib/unicode/Is/DecoCompat.pl Unicode character database
|
||||
lib/unicode/Is/Digit.pl Unicode character database
|
||||
lib/unicode/Is/Graph.pl Unicode character database
|
||||
lib/unicode/Is/L.pl Unicode character database
|
||||
lib/unicode/Is/LbrkAI.pl Unicode character database
|
||||
lib/unicode/Is/LbrkAL.pl Unicode character database
|
||||
lib/unicode/Is/LbrkB2.pl Unicode character database
|
||||
lib/unicode/Is/LbrkBA.pl Unicode character database
|
||||
lib/unicode/Is/LbrkBB.pl Unicode character database
|
||||
lib/unicode/Is/LbrkBK.pl Unicode character database
|
||||
lib/unicode/Is/LbrkCB.pl Unicode character database
|
||||
lib/unicode/Is/LbrkCL.pl Unicode character database
|
||||
lib/unicode/Is/LbrkCM.pl Unicode character database
|
||||
lib/unicode/Is/LbrkCR.pl Unicode character database
|
||||
lib/unicode/Is/LbrkEX.pl Unicode character database
|
||||
lib/unicode/Is/LbrkGL.pl Unicode character database
|
||||
lib/unicode/Is/LbrkHY.pl Unicode character database
|
||||
lib/unicode/Is/LbrkID.pl Unicode character database
|
||||
lib/unicode/Is/LbrkIN.pl Unicode character database
|
||||
lib/unicode/Is/LbrkIS.pl Unicode character database
|
||||
lib/unicode/Is/LbrkLF.pl Unicode character database
|
||||
lib/unicode/Is/LbrkNS.pl Unicode character database
|
||||
lib/unicode/Is/LbrkNU.pl Unicode character database
|
||||
lib/unicode/Is/LbrkOP.pl Unicode character database
|
||||
lib/unicode/Is/LbrkPO.pl Unicode character database
|
||||
lib/unicode/Is/LbrkPR.pl Unicode character database
|
||||
lib/unicode/Is/LbrkQU.pl Unicode character database
|
||||
lib/unicode/Is/LbrkSA.pl Unicode character database
|
||||
lib/unicode/Is/LbrkSG.pl Unicode character database
|
||||
lib/unicode/Is/LbrkSP.pl Unicode character database
|
||||
lib/unicode/Is/LbrkSY.pl Unicode character database
|
||||
lib/unicode/Is/LbrkXX.pl Unicode character database
|
||||
lib/unicode/Is/LbrkZW.pl Unicode character database
|
||||
lib/unicode/Is/Ll.pl Unicode character database
|
||||
lib/unicode/Is/Lm.pl Unicode character database
|
||||
lib/unicode/Is/Lo.pl Unicode character database
|
||||
@ -877,34 +938,54 @@ lib/unicode/Is/Lt.pl Unicode character database
|
||||
lib/unicode/Is/Lu.pl Unicode character database
|
||||
lib/unicode/Is/M.pl Unicode character database
|
||||
lib/unicode/Is/Mc.pl Unicode character database
|
||||
lib/unicode/Is/Me.pl Unicode character database
|
||||
lib/unicode/Is/Mirrored.pl Unicode character database
|
||||
lib/unicode/Is/Mn.pl Unicode character database
|
||||
lib/unicode/Is/N.pl Unicode character database
|
||||
lib/unicode/Is/Nd.pl Unicode character database
|
||||
lib/unicode/Is/Nl.pl Unicode character database
|
||||
lib/unicode/Is/No.pl Unicode character database
|
||||
lib/unicode/Is/P.pl Unicode character database
|
||||
lib/unicode/Is/Pc.pl Unicode character database
|
||||
lib/unicode/Is/Pd.pl Unicode character database
|
||||
lib/unicode/Is/Pe.pl Unicode character database
|
||||
lib/unicode/Is/Pf.pl Unicode character database
|
||||
lib/unicode/Is/Pi.pl Unicode character database
|
||||
lib/unicode/Is/Po.pl Unicode character database
|
||||
lib/unicode/Is/Print.pl Unicode character database
|
||||
lib/unicode/Is/Ps.pl Unicode character database
|
||||
lib/unicode/Is/Punct.pl Unicode character database
|
||||
lib/unicode/Is/S.pl Unicode character database
|
||||
lib/unicode/Is/Sc.pl Unicode character database
|
||||
lib/unicode/Is/Sk.pl Unicode character database
|
||||
lib/unicode/Is/Sm.pl Unicode character database
|
||||
lib/unicode/Is/So.pl Unicode character database
|
||||
lib/unicode/Is/Space.pl Unicode character database
|
||||
lib/unicode/Is/SpacePerl.pl Unicode character database
|
||||
lib/unicode/Is/SylA.pl Unicode character database
|
||||
lib/unicode/Is/SylAA.pl Unicode character database
|
||||
lib/unicode/Is/SylAAI.pl Unicode character database
|
||||
lib/unicode/Is/SylAI.pl Unicode character database
|
||||
lib/unicode/Is/SylC.pl Unicode character database
|
||||
lib/unicode/Is/SylE.pl Unicode character database
|
||||
lib/unicode/Is/SylEE.pl Unicode character database
|
||||
lib/unicode/Is/SylI.pl Unicode character database
|
||||
lib/unicode/Is/SylII.pl Unicode character database
|
||||
lib/unicode/Is/SylN.pl Unicode character database
|
||||
lib/unicode/Is/SylO.pl Unicode character database
|
||||
lib/unicode/Is/SylOO.pl Unicode character database
|
||||
lib/unicode/Is/SylU.pl Unicode character database
|
||||
lib/unicode/Is/SylV.pl Unicode character database
|
||||
lib/unicode/Is/SylWA.pl Unicode character database
|
||||
lib/unicode/Is/SylWAA.pl Unicode character database
|
||||
lib/unicode/Is/SylWC.pl Unicode character database
|
||||
lib/unicode/Is/SylWE.pl Unicode character database
|
||||
lib/unicode/Is/SylWEE.pl Unicode character database
|
||||
lib/unicode/Is/SylWI.pl Unicode character database
|
||||
lib/unicode/Is/SylWII.pl Unicode character database
|
||||
lib/unicode/Is/SylWO.pl Unicode character database
|
||||
lib/unicode/Is/SylWOO.pl Unicode character database
|
||||
lib/unicode/Is/SylWU.pl Unicode character database
|
||||
lib/unicode/Is/SylWV.pl Unicode character database
|
||||
lib/unicode/Is/Syllable.pl Unicode character database
|
||||
lib/unicode/Is/Upper.pl Unicode character database
|
||||
@ -922,17 +1003,18 @@ lib/unicode/Name.pl Unicode character database
|
||||
lib/unicode/Names.txt Unicode character database
|
||||
lib/unicode/NamesList.html Unicode character database
|
||||
lib/unicode/Number.pl Unicode character database
|
||||
lib/unicode/Props.txt Unicode character database
|
||||
lib/unicode/PropList.txt Unicode character database
|
||||
lib/unicode/README.Ethiopic Unicode character database
|
||||
lib/unicode/README.perl Unicode character database
|
||||
lib/unicode/ReadMe.txt Unicode character database info
|
||||
lib/unicode/SpecCase.txt Unicode character database
|
||||
lib/unicode/To/Digit.pl Unicode character database
|
||||
lib/unicode/To/Lower.pl Unicode character database
|
||||
lib/unicode/To/Title.pl Unicode character database
|
||||
lib/unicode/To/Upper.pl Unicode character database
|
||||
lib/unicode/UCD300.html Unicode character database
|
||||
lib/unicode/Unicode.300 Unicode character database
|
||||
lib/unicode/Unicode3.html Unicode character database
|
||||
lib/unicode/UCD301.html Unicode character database
|
||||
lib/unicode/UCDFF301.html Unicode character database
|
||||
lib/unicode/Unicode.301 Unicode character database
|
||||
lib/unicode/mktables.PL Unicode character database generator
|
||||
lib/unicode/syllables.txt Unicode character database
|
||||
lib/utf8.pm Pragma to control Unicode support
|
||||
@ -991,12 +1073,12 @@ os2/OS2/Process/Makefile.PL system() constants in a module
|
||||
os2/OS2/Process/Process.pm system() constants in a module
|
||||
os2/OS2/Process/Process.xs system() constants in a module
|
||||
os2/OS2/REXX/Changes DLL access module
|
||||
os2/OS2/REXX/MANIFEST DLL access module
|
||||
os2/OS2/REXX/DLL/Changes DLL access module
|
||||
os2/OS2/REXX/DLL/DLL.pm DLL access module
|
||||
os2/OS2/REXX/DLL/DLL.xs DLL access module
|
||||
os2/OS2/REXX/DLL/MANIFEST DLL access module
|
||||
os2/OS2/REXX/DLL/Makefile.PL DLL access module
|
||||
os2/OS2/REXX/MANIFEST DLL access module
|
||||
os2/OS2/REXX/Makefile.PL DLL access module
|
||||
os2/OS2/REXX/REXX.pm DLL access module
|
||||
os2/OS2/REXX/REXX.xs DLL access module
|
||||
@ -1015,6 +1097,7 @@ os2/dl_os2.c Addon for dl_open
|
||||
os2/dlfcn.h Addon for dl_open
|
||||
os2/os2.c Additional code for OS/2
|
||||
os2/os2.sym Additional symbols to export
|
||||
os2/os2add.sym Overriding symbols to export
|
||||
os2/os2ish.h Header for OS/2
|
||||
os2/os2thread.h pthread-like typedefs
|
||||
os2/perl2cmd.pl Corrects installed binaries under OS/2
|
||||
@ -1050,27 +1133,29 @@ plan9/plan9.c Plan9 port: Plan9-specific C routines
|
||||
plan9/plan9ish.h Plan9 port: Plan9-specific C header file
|
||||
plan9/setup.rc Plan9 port: script for easy build+install
|
||||
plan9/versnum Plan9 port: script to print version number
|
||||
pod/Makefile Make pods into something else
|
||||
pod/Win32.pod Documentation for Win32 extras
|
||||
pod/buildtoc generate perltoc.pod
|
||||
pod/Makefile.SH generate Makefile whichs makes pods into something else
|
||||
pod/buildtoc.PL generate buildtoc which generates perltoc.pod
|
||||
pod/checkpods.PL Tool to check for common errors in pods
|
||||
pod/perl.pod Top level perl man page
|
||||
pod/perl.pod Top level perl documentation
|
||||
pod/perl5004delta.pod Changes from 5.003 to 5.004
|
||||
pod/perl5005delta.pod Changes from 5.004 to 5.005
|
||||
pod/perlapi.pod Perl API documentation (autogenerated)
|
||||
pod/perlapio.pod IO API info
|
||||
pod/perlbook.pod Book info
|
||||
pod/perlbook.pod Perl book information
|
||||
pod/perlboot.pod Beginner's Object-oriented Tutorial
|
||||
pod/perlbot.pod Object-oriented Bag o' Tricks
|
||||
pod/perlcall.pod Callback info
|
||||
pod/perlclib.pod Internal replacements for standard C library functions
|
||||
pod/perlcompile.pod Info on using the Compiler suite
|
||||
pod/perldata.pod Data structure info
|
||||
pod/perldbmfilter.pod Info about DBM Filters
|
||||
pod/perldebguts.pod Debugger guts info
|
||||
pod/perldebtut.pod Perl debugging tutorial
|
||||
pod/perldebug.pod Debugger info
|
||||
pod/perldelta.pod Changes since last version
|
||||
pod/perldiag.pod Diagnostic info
|
||||
pod/perldsc.pod Data Structures Cookbook
|
||||
pod/perlebcdic.pod Considerations for running Perl on EBCDIC platforms
|
||||
pod/perlembed.pod Embedding info
|
||||
pod/perlfaq.pod Frequently Asked Questions, Top Level
|
||||
pod/perlfaq1.pod Frequently Asked Questions, Part 1
|
||||
@ -1096,7 +1181,9 @@ pod/perllocale.pod Locale support info
|
||||
pod/perllol.pod How to use lists of lists
|
||||
pod/perlmod.pod Module mechanism info
|
||||
pod/perlmodinstall.pod Installing CPAN Modules
|
||||
pod/perlmodlib.PL Generate pod/perlmodlib.pod
|
||||
pod/perlmodlib.pod Module policy info
|
||||
pod/perlnewmod.pod Preparing a new module for distribution
|
||||
pod/perlnumber.pod Semantics of numbers and numeric operations
|
||||
pod/perlobj.pod Object info
|
||||
pod/perlop.pod Operator info
|
||||
@ -1106,6 +1193,8 @@ pod/perlport.pod Portability guide
|
||||
pod/perlre.pod Regular expression info
|
||||
pod/perlref.pod References info
|
||||
pod/perlreftut.pod Mark's references tutorial
|
||||
pod/perlrequick.pod Quick start guide for Perl regular expressions
|
||||
pod/perlretut.pod Tutorial for Perl regular expressions
|
||||
pod/perlrun.pod Execution info
|
||||
pod/perlsec.pod Security info
|
||||
pod/perlstyle.pod Style info
|
||||
@ -1119,6 +1208,7 @@ pod/perltoot.pod Tom's object-oriented tutorial
|
||||
pod/perltootc.pod Tom's object-oriented tutorial (more on class data)
|
||||
pod/perltrap.pod Trap info
|
||||
pod/perlunicode.pod Unicode support info
|
||||
pod/perlutil.pod Accompanying utilities explained
|
||||
pod/perlvar.pod Variable info
|
||||
pod/perlxs.pod XS api info
|
||||
pod/perlxstut.pod XS tutorial
|
||||
@ -1202,17 +1292,21 @@ t/lib/ansicolor.t See if Term::ANSIColor works
|
||||
t/lib/anydbm.t See if AnyDBM_File works
|
||||
t/lib/attrs.t See if attrs works with C<sub : attrs>
|
||||
t/lib/autoloader.t See if AutoLoader works
|
||||
t/lib/b.t See if B backends work
|
||||
t/lib/basename.t See if File::Basename works
|
||||
t/lib/bigfloat.t See if bigfloat.pl works
|
||||
t/lib/bigfltpm.t See if BigFloat.pm works
|
||||
t/lib/bigint.t See if bigint.pl works
|
||||
t/lib/bigintpm.t See if BigInt.pm works
|
||||
t/lib/cgi-esc.t See if CGI.pm works
|
||||
t/lib/cgi-form.t See if CGI.pm works
|
||||
t/lib/cgi-function.t See if CGI.pm works
|
||||
t/lib/cgi-html.t See if CGI.pm works
|
||||
t/lib/cgi-pretty.t See if CGI.pm works
|
||||
t/lib/cgi-request.t See if CGI.pm works
|
||||
t/lib/charnames.t See if character names work
|
||||
t/lib/checktree.t See if File::CheckTree works
|
||||
t/lib/class-struct.t See if Class::Struct works
|
||||
t/lib/complex.t See if Math::Complex works
|
||||
t/lib/db-btree.t See if DB_File works
|
||||
t/lib/db-hash.t See if DB_File works
|
||||
@ -1236,8 +1330,8 @@ t/lib/dprof/test6_v Perl code profiler tests
|
||||
t/lib/dumper-ovl.t See if Data::Dumper works for overloaded data
|
||||
t/lib/dumper.t See if Data::Dumper works
|
||||
t/lib/english.t See if English works
|
||||
t/lib/env.t See if Env works
|
||||
t/lib/env-array.t See if Env works for arrays
|
||||
t/lib/env.t See if Env works
|
||||
t/lib/errno.t See if Errno works
|
||||
t/lib/fatal.t See if Fatal works
|
||||
t/lib/fields.t See if base/fields works
|
||||
@ -1249,6 +1343,10 @@ t/lib/filehand.t See if FileHandle works
|
||||
t/lib/filepath.t See if File::Path works
|
||||
t/lib/filespec.t See if File::Spec works
|
||||
t/lib/findbin.t See if FindBin works
|
||||
t/lib/ftmp-mktemp.t See if File::Temp works
|
||||
t/lib/ftmp-posix.t See if File::Temp works
|
||||
t/lib/ftmp-security.t See if File::Temp works
|
||||
t/lib/ftmp-tempfile.t See if File::Temp works
|
||||
t/lib/gdbm.t See if GDBM_File works
|
||||
t/lib/getopt.t See if Getopt::Std and Getopt::Long work
|
||||
t/lib/glob-basic.t See if File::Glob works
|
||||
@ -1258,6 +1356,7 @@ t/lib/glob-taint.t See if File::Glob works
|
||||
t/lib/gol-basic.t See if Getopt::Long works
|
||||
t/lib/gol-compat.t See if Getopt::Long works
|
||||
t/lib/gol-linkage.t See if Getopt::Long works
|
||||
t/lib/gol-oo.t See if Getopt::Long works
|
||||
t/lib/h2ph.h Test header file for h2ph
|
||||
t/lib/h2ph.pht Generated output from h2ph.h by h2ph, for comparison
|
||||
t/lib/h2ph.t See if h2ph works like it should
|
||||
@ -1284,6 +1383,7 @@ t/lib/open2.t See if IPC::Open2 works
|
||||
t/lib/open3.t See if IPC::Open3 works
|
||||
t/lib/ops.t See if Opcode works
|
||||
t/lib/parsewords.t See if Text::ParseWords works
|
||||
t/lib/peek.t See if Devel::Peek works
|
||||
t/lib/ph.t See if h2ph works
|
||||
t/lib/posix.t See if POSIX works
|
||||
t/lib/safe1.t See if Safe works
|
||||
@ -1291,21 +1391,27 @@ t/lib/safe2.t See if Safe works
|
||||
t/lib/sdbm.t See if SDBM_File works
|
||||
t/lib/searchdict.t See if Search::Dict works
|
||||
t/lib/selectsaver.t See if SelectSaver works
|
||||
t/lib/selfloader.t See if SelfLoader works
|
||||
t/lib/socket.t See if Socket works
|
||||
t/lib/soundex.t See if Soundex works
|
||||
t/lib/symbol.t See if Symbol works
|
||||
t/lib/syslfs.t See if large files work for sysio
|
||||
t/lib/syslog.t See if Sys::Syslog works
|
||||
t/lib/textfill.t See if Text::Wrap::fill works
|
||||
t/lib/texttabs.t See if Text::Tabs works
|
||||
t/lib/textwrap.t See if Text::Wrap::wrap works
|
||||
t/lib/thr5005.t Test 5.005-style threading (skipped if no use5005threads)
|
||||
t/lib/tie-push.t Test for Tie::Array
|
||||
t/lib/tie-refhash.t Test for Tie::RefHash and Tie::RefHash::Nestable
|
||||
t/lib/tie-splice.t Test for Tie::Array::SPLICE
|
||||
t/lib/tie-stdarray.t Test for Tie::StdArray
|
||||
t/lib/tie-stdhandle.t Test for Tie::StdHandle
|
||||
t/lib/tie-stdpush.t Test for Tie::StdArray
|
||||
t/lib/tie-substrhash.t Test for Tie::SubstrHash
|
||||
t/lib/timelocal.t See if Time::Local works
|
||||
t/lib/trig.t See if Math::Trig works
|
||||
t/op/64bitint.t See if 64 bit integers work
|
||||
t/op/anonsub.t See if anonymous subroutines work
|
||||
t/op/append.t See if . works
|
||||
t/op/args.t See if operations on @_ work
|
||||
t/op/arith.t See if arithmetic works
|
||||
@ -1319,6 +1425,7 @@ t/op/chars.t See if character escapes work
|
||||
t/op/chop.t See if chop works
|
||||
t/op/closure.t See if closures work
|
||||
t/op/cmp.t See if the various string and numeric compare work
|
||||
t/op/concat.t See if string concatenation works
|
||||
t/op/cond.t See if conditional expressions work
|
||||
t/op/context.t See if context propagation works
|
||||
t/op/defins.t See if auto-insert of defined() works
|
||||
@ -1347,6 +1454,7 @@ t/op/inc.t See if inc/dec of integers near 32 bit limit work
|
||||
t/op/index.t See if index works
|
||||
t/op/int.t See if int works
|
||||
t/op/join.t See if join works
|
||||
t/op/length.t See if length works
|
||||
t/op/lex_assign.t See if ops involving lexicals or pad temps work
|
||||
t/op/lfs.t See if large files work for perlio
|
||||
t/op/list.t See if array lists work
|
||||
@ -1357,6 +1465,7 @@ t/op/method.t See if method calls work
|
||||
t/op/misc.t See if miscellaneous bugs have been fixed
|
||||
t/op/mkdir.t See if mkdir works
|
||||
t/op/my.t See if lexical scoping works
|
||||
t/op/my_stash.t See if my Package works
|
||||
t/op/nothr5005.t local @_ test which does not work under use5005threads
|
||||
t/op/numconvert.t See if accessing fields does not change numeric values
|
||||
t/op/oct.t See if oct and hex work
|
||||
@ -1376,7 +1485,9 @@ t/op/recurse.t See if deep recursion works
|
||||
t/op/ref.t See if refs and objects work
|
||||
t/op/regexp.t See if regular expressions work
|
||||
t/op/regexp_noamp.t See if regular expressions work with optimizations
|
||||
t/op/regmesg.t See if one can get regular expression errors
|
||||
t/op/repeat.t See if x operator works
|
||||
t/op/reverse.t See if reverse operator works
|
||||
t/op/runlevel.t See if die() works from perl_call_*()
|
||||
t/op/sleep.t See if sleep works
|
||||
t/op/sort.t See if sort works
|
||||
@ -1399,12 +1510,14 @@ t/op/tr.t See if tr works
|
||||
t/op/undef.t See if undef works
|
||||
t/op/universal.t See if UNIVERSAL class works
|
||||
t/op/unshift.t See if unshift works
|
||||
t/op/utf8decode.t See if UTF-8 decoding works
|
||||
t/op/vec.t See if vectors work
|
||||
t/op/ver.t See if v-strings and the %v format flag work
|
||||
t/op/wantarray.t See if wantarray works
|
||||
t/op/write.t See if write works
|
||||
t/pod/emptycmd.t Test empty pod directives
|
||||
t/pod/emptycmd.xr Expected results for emptycmd.t
|
||||
t/pod/find.t See if Pod::Find works
|
||||
t/pod/for.t Test =for directive
|
||||
t/pod/for.xr Expected results for for.t
|
||||
t/pod/headings.t Test =head directives
|
||||
@ -1432,7 +1545,7 @@ t/pod/podselect.xr Expected results for podselect.t
|
||||
t/pod/special_seqs.t Test "special" interior sequences
|
||||
t/pod/special_seqs.xr Expected results for emptycmd.t
|
||||
t/pod/testcmp.pl Module to compare output against expected results
|
||||
t/pod/testp2pt.pl Module to test Pod::PlainText for a given file
|
||||
t/pod/testp2pt.pl Module to test Pod::Text for a given file
|
||||
t/pod/testpchk.pl Module to test Pod::Checker for a given file
|
||||
t/pragma/constant.t See if compile-time constants work
|
||||
t/pragma/diagnostics.t See if diagnostics.pm works
|
||||
@ -1444,8 +1557,8 @@ t/pragma/strict-refs Tests of "use strict 'refs'" for strict.t
|
||||
t/pragma/strict-subs Tests of "use strict 'subs'" for strict.t
|
||||
t/pragma/strict-vars Tests of "use strict 'vars'" for strict.t
|
||||
t/pragma/strict.t See if strictures work
|
||||
t/pragma/subs.t See if subroutine pseudo-importation works
|
||||
t/pragma/sub_lval.t See if lvalue subroutines work
|
||||
t/pragma/subs.t See if subroutine pseudo-importation works
|
||||
t/pragma/utf8.t See if utf8 operations work
|
||||
t/pragma/warn/1global Tests of global warnings for warnings.t
|
||||
t/pragma/warn/2use Tests for "use warnings" for warnings.t
|
||||
@ -1481,6 +1594,7 @@ t/pragma/warn/universal Tests for universal.c for warnings.t
|
||||
t/pragma/warn/utf8 Tests for utf8.c for warnings.t
|
||||
t/pragma/warn/util Tests for util.c for warnings.t
|
||||
t/pragma/warnings.t See if warning controls work
|
||||
t/run/runenv.t Test if perl honors its environment variables.
|
||||
taint.c Tainting code
|
||||
thrdvar.h Per-thread variables
|
||||
thread.h Threading header
|
||||
@ -1496,7 +1610,6 @@ utils/c2ph.PL program to translate dbx stabs to perl
|
||||
utils/dprofpp.PL Perl code profile post-processor
|
||||
utils/h2ph.PL A thing to turn C .h files into perl .ph files
|
||||
utils/h2xs.PL Program to make .xs files from C header files
|
||||
utils/perlbc.PL Front-end for byte compiler
|
||||
utils/perlbug.PL A simple tool to submit a bug report
|
||||
utils/perlcc.PL Front-end for compiler
|
||||
utils/perldoc.PL A simple tool to find & display perl's documentation
|
||||
@ -1533,19 +1646,22 @@ vms/perly_c.vms perly.c with fixed declarations for global syms
|
||||
vms/perly_h.vms perly.h with fixed declarations for global syms
|
||||
vms/sockadapt.c glue for SockshShr socket support
|
||||
vms/sockadapt.h glue for SockshShr socket support
|
||||
vms/subconfigure.com performs compiler checks and writes config.sh, config.h, and descrip.mms
|
||||
vms/test.com DCL driver for regression tests
|
||||
vms/vms.c VMS-specific C code for Perl core
|
||||
vms/vms_yfix.pl convert Unix perly.[ch] to VMS perly_[ch].vms
|
||||
vms/vmsish.h VMS-specific C header for Perl core
|
||||
vms/vmspipe.com VMS-specific piped command helper script
|
||||
vms/writemain.pl Generate perlmain.c from miniperlmain.c+extensions
|
||||
vos/Changes Changes made to port Perl to the VOS operating system
|
||||
vos/build.cm VOS command macro to build Perl
|
||||
vos/compile_perl.cm VOS command macro to build multiple version of Perl
|
||||
vos/config.def input for config.pl
|
||||
vos/config.h config.h for VOS
|
||||
vos/config.alpha.def definitions used by config.pl
|
||||
vos/config.alpha.h config.h for use with alpha VOS POSIX.1 support
|
||||
vos/config.ga.def definitions used by config.pl
|
||||
vos/config.ga.h config.h for use with generally-available VOS POSIX.1 support
|
||||
vos/config.pl script to convert a config_h.SH to a config.h
|
||||
vos/config_h.SH_orig config_h.SH at the time config.h was created
|
||||
vos/configure_perl.cm VOS command macro to configure perl before building
|
||||
vos/install_perl.cm VOS command macro to install perl after building
|
||||
vos/perl.bind VOS bind control file
|
||||
vos/test_vos_dummies.c Test program for "vos_dummies.c"
|
||||
vos/vos_dummies.c Wrappers to soak up undefined functions
|
||||
@ -1579,6 +1695,7 @@ win32/perlhost.h Perl "host" implementation
|
||||
win32/perllib.c Win32 port
|
||||
win32/pod.mak Win32 port
|
||||
win32/runperl.c Win32 port
|
||||
win32/sncfnmcs.pl Win32 port
|
||||
win32/splittree.pl Win32 port
|
||||
win32/vdir.h Perl "host" virtual directory manager
|
||||
win32/vmem.h Perl "host" memory manager
|
||||
|
@ -26,6 +26,7 @@ esac
|
||||
linklibperl='$(LIBPERL)'
|
||||
shrpldflags='$(LDDLFLAGS)'
|
||||
ldlibpth=''
|
||||
DPERL_EXTERNAL_GLOB='-DPERL_EXTERNAL_GLOB'
|
||||
case "$useshrplib" in
|
||||
true)
|
||||
# Prefix all runs of 'miniperl' and 'perl' with
|
||||
@ -70,12 +71,17 @@ true)
|
||||
*) shrpldflags="$shrpldflags -b noentry"
|
||||
;;
|
||||
esac
|
||||
shrpldflags="$shrpldflags $ldflags $libs $cryptlib"
|
||||
shrpldflags="$shrpldflags $ldflags $perllibs $cryptlib"
|
||||
linklibperl="-L $archlibexp/CORE -L `pwd | sed 's/\/UU$//'` -lperl"
|
||||
;;
|
||||
hpux*)
|
||||
linklibperl="-L `pwd | sed 's/\/UU$//'` -Wl,+s -Wl,+b$archlibexp/CORE -lperl"
|
||||
;;
|
||||
os390*)
|
||||
shrpldflags='-W l,dll'
|
||||
linklibperl='libperl.x'
|
||||
DPERL_EXTERNAL_GLOB=''
|
||||
;;
|
||||
esac
|
||||
case "$ldlibpthname" in
|
||||
'') ;;
|
||||
@ -117,6 +123,24 @@ for f in $nonxs_ext; do
|
||||
nonxs_list="$nonxs_list ext/$f/pm_to_blib"
|
||||
done
|
||||
|
||||
# Handle the usage of different yaccs in posix-bc (During Configure we
|
||||
# us yacc for perly.y and byacc for a2p.y. The makefiles must use the
|
||||
# same configuration for run_byacc!):
|
||||
case "$osname" in
|
||||
posix-bc)
|
||||
byacc=$yacc
|
||||
;;
|
||||
esac
|
||||
|
||||
# Handle the usage of different yaccs in posix-bc (During Configure we
|
||||
# us yacc for perly.y and byacc for a2p.y. The makefiles must use the
|
||||
# same configuration for run_byacc!):
|
||||
case "$osname" in
|
||||
posix-bc)
|
||||
byacc=$yacc
|
||||
;;
|
||||
esac
|
||||
|
||||
echo "Extracting Makefile (with variable substitutions)"
|
||||
$spitshell >Makefile <<!GROK!THIS!
|
||||
# Makefile.SH
|
||||
@ -134,11 +158,11 @@ LD = $ld
|
||||
LDFLAGS = $ldflags
|
||||
CLDFLAGS = $ldflags
|
||||
|
||||
SMALL = $small
|
||||
LARGE = $large $split
|
||||
mallocsrc = $mallocsrc
|
||||
mallocobj = $mallocobj
|
||||
LNS = $lns
|
||||
# NOTE: some systems don't grok "cp -f". XXX Configure test needed?
|
||||
CPS = $cp
|
||||
RMS = rm -f
|
||||
ranlib = $ranlib
|
||||
|
||||
@ -176,7 +200,7 @@ nonxs_ext = $nonxs_list
|
||||
ext = \$(dynamic_ext) \$(static_ext) \$(nonxs_ext)
|
||||
DYNALOADER = lib/auto/DynaLoader/DynaLoader\$(LIB_EXT)
|
||||
|
||||
libs = $libs $cryptlib
|
||||
libs = $perllibs $cryptlib
|
||||
|
||||
public = perl $suidperl utilities translators
|
||||
|
||||
@ -206,11 +230,12 @@ SHELL = $sh
|
||||
# how to tr(anslate) newlines
|
||||
TRNL = '$trnl'
|
||||
|
||||
# not used by Makefile but by installperl;
|
||||
# mentioned here so that metaconfig picks it up
|
||||
INSTALL_USR_BIN_PERL = $installusrbinperl
|
||||
|
||||
!GROK!THIS!
|
||||
# not used by Makefile but by installperl;
|
||||
# mentioned here so that metaconfig picks these up
|
||||
# $installusrbinperl
|
||||
# $versiononly
|
||||
|
||||
|
||||
## In the following dollars and backticks do not need the extra backslash.
|
||||
$spitshell >>Makefile <<'!NO!SUBS!'
|
||||
@ -222,19 +247,21 @@ private = preplibrary lib/ExtUtils/Miniperl.pm lib/Config.pm
|
||||
# Files to be built with variable substitution before miniperl
|
||||
# is available.
|
||||
sh = Makefile.SH cflags.SH config_h.SH makeaperl.SH makedepend.SH \
|
||||
makedir.SH myconfig.SH writemain.SH
|
||||
makedir.SH myconfig.SH writemain.SH pod/Makefile.SH
|
||||
|
||||
shextract = Makefile cflags config.h makeaperl makedepend \
|
||||
makedir myconfig writemain
|
||||
makedir myconfig writemain pod/Makefile
|
||||
|
||||
# Files to be built with variable substitution after miniperl is
|
||||
# available. Dependencies handled manually below (for now).
|
||||
|
||||
pl = pod/pod2html.PL pod/pod2latex.PL pod/pod2man.PL pod/pod2text.PL \
|
||||
pod/pod2usage.PL pod/podchecker.PL pod/podselect.PL
|
||||
pod/pod2usage.PL pod/podchecker.PL pod/podselect.PL \
|
||||
pod/buildtoc.PL
|
||||
|
||||
plextract = pod/pod2html pod/pod2latex pod/pod2man pod/pod2text \
|
||||
pod/pod2usage pod/podchecker pod/podselect
|
||||
pod/pod2usage pod/podchecker pod/podselect \
|
||||
pod/buildtoc
|
||||
|
||||
addedbyconf = UU $(shextract) $(plextract) pstruct
|
||||
|
||||
@ -297,14 +324,18 @@ utilities: miniperl lib/Config.pm $(plextract) FORCE
|
||||
# Apparently some makes require an action for the FORCE target.
|
||||
FORCE:
|
||||
@sh -c true
|
||||
!NO!SUBS!
|
||||
|
||||
opmini$(OBJ_EXT): op.c
|
||||
$(RMS) opmini.c
|
||||
$(LNS) op.c opmini.c
|
||||
$(CCCMD) $(PLDLFLAGS) -DPERL_EXTERNAL_GLOB opmini.c
|
||||
$(RMS) opmini.c
|
||||
$spitshell >>Makefile <<!GROK!THIS!
|
||||
opmini\$(OBJ_EXT): op.c config.h
|
||||
\$(RMS) opmini.c
|
||||
\$(CPS) op.c opmini.c
|
||||
\$(CCCMD) \$(PLDLFLAGS) $DPERL_EXTERNAL_GLOB opmini.c
|
||||
\$(RMS) opmini.c
|
||||
|
||||
miniperlmain$(OBJ_EXT): miniperlmain.c
|
||||
!GROK!THIS!
|
||||
$spitshell >>Makefile <<'!NO!SUBS!'
|
||||
miniperlmain$(OBJ_EXT): miniperlmain.c patchlevel.h
|
||||
$(CCCMD) $(PLDLFLAGS) $*.c
|
||||
|
||||
perlmain.c: miniperlmain.c config.sh $(FIRSTMAKEFILE)
|
||||
@ -333,7 +364,7 @@ esac
|
||||
case "$osname" in
|
||||
aix)
|
||||
$spitshell >>Makefile <<!GROK!THIS!
|
||||
LIBS = $libs
|
||||
LIBS = $perllibs
|
||||
# In AIX we need to change this for building Perl itself from
|
||||
# its earlier definition (which is for building external
|
||||
# extensions *after* Perl has been built and installed)
|
||||
@ -403,7 +434,7 @@ $(LIBPERL): $& perl$(OBJ_EXT) $(obj) $(LIBPERLEXPORT)
|
||||
case "$useshrplib" in
|
||||
true)
|
||||
$spitshell >>Makefile <<'!NO!SUBS!'
|
||||
$(LD) $(SHRPLDFLAGS) -o $@ perl$(OBJ_EXT) $(obj)
|
||||
$(LD) -o $@ $(SHRPLDFLAGS) perl$(OBJ_EXT) $(obj)
|
||||
!NO!SUBS!
|
||||
case "$osname" in
|
||||
aix)
|
||||
@ -458,7 +489,7 @@ miniperl: $& miniperlmain$(OBJ_EXT) $(LIBPERL) opmini$(OBJ_EXT)
|
||||
*)
|
||||
$spitshell >>Makefile <<'!NO!SUBS!'
|
||||
miniperl: $& miniperlmain$(OBJ_EXT) $(LIBPERL) opmini$(OBJ_EXT)
|
||||
$(LDLIBPTH) $(CC) $(LARGE) $(CLDFLAGS) -o miniperl \
|
||||
$(LDLIBPTH) $(CC) $(CLDFLAGS) -o miniperl \
|
||||
miniperlmain$(OBJ_EXT) opmini$(OBJ_EXT) $(LLIBPERL) $(libs)
|
||||
$(LDLIBPTH) ./miniperl -w -Ilib -MExporter -e '<?>' || $(MAKE) minitest
|
||||
!NO!SUBS!
|
||||
@ -468,16 +499,16 @@ miniperl: $& miniperlmain$(OBJ_EXT) $(LIBPERL) opmini$(OBJ_EXT)
|
||||
$spitshell >>Makefile <<'!NO!SUBS!'
|
||||
|
||||
perl: $& perlmain$(OBJ_EXT) $(LIBPERL) $(DYNALOADER) $(static_ext) ext.libs $(PERLEXPORT)
|
||||
$(SHRPENV) $(LDLIBPTH) $(CC) $(LARGE) $(CLDFLAGS) $(CCDLFLAGS) -o perl perlmain$(OBJ_EXT) $(DYNALOADER) $(static_ext) $(LLIBPERL) `cat ext.libs` $(libs)
|
||||
$(SHRPENV) $(LDLIBPTH) $(CC) -o perl $(CLDFLAGS) $(CCDLFLAGS) perlmain$(OBJ_EXT) $(DYNALOADER) $(static_ext) $(LLIBPERL) `cat ext.libs` $(libs)
|
||||
|
||||
pureperl: $& perlmain$(OBJ_EXT) $(LIBPERL) $(DYNALOADER) $(static_ext) ext.libs $(PERLEXPORT)
|
||||
$(SHRPENV) $(LDLIBPTH) purify $(CC) $(LARGE) $(CLDFLAGS) $(CCDLFLAGS) -o pureperl perlmain$(OBJ_EXT) $(DYNALOADER) $(static_ext) $(LLIBPERL) `cat ext.libs` $(libs)
|
||||
$(SHRPENV) $(LDLIBPTH) purify $(CC) -o pureperl $(CLDFLAGS) $(CCDLFLAGS) perlmain$(OBJ_EXT) $(DYNALOADER) $(static_ext) $(LLIBPERL) `cat ext.libs` $(libs)
|
||||
|
||||
purecovperl: $& perlmain$(OBJ_EXT) $(LIBPERL) $(DYNALOADER) $(static_ext) ext.libs $(PERLEXPORT)
|
||||
$(SHRPENV) $(LDLIBPTH) purecov $(CC) $(LARGE) $(CLDFLAGS) $(CCDLFLAGS) -o purecovperl perlmain$(OBJ_EXT) $(DYNALOADER) $(static_ext) $(LLIBPERL) `cat ext.libs` $(libs)
|
||||
$(SHRPENV) $(LDLIBPTH) purecov $(CC) -o purecovperl $(CLDFLAGS) $(CCDLFLAGS) perlmain$(OBJ_EXT) $(DYNALOADER) $(static_ext) $(LLIBPERL) `cat ext.libs` $(libs)
|
||||
|
||||
quantperl: $& perlmain$(OBJ_EXT) $(LIBPERL) $(DYNALOADER) $(static_ext) ext.libs $(PERLEXPORT)
|
||||
$(SHRPENV) $(LDLIBPTH) quantify $(CC) $(LARGE) $(CLDFLAGS) $(CCDLFLAGS) -o quantperl perlmain$(OBJ_EXT) $(DYNALOADER) $(static_ext) $(LLIBPERL) `cat ext.libs` $(libs)
|
||||
$(SHRPENV) $(LDLIBPTH) quantify $(CC) -o quantperl $(CLDFLAGS) $(CCDLFLAGS) perlmain$(OBJ_EXT) $(DYNALOADER) $(static_ext) $(LLIBPERL) `cat ext.libs` $(libs)
|
||||
|
||||
# This version, if specified in Configure, does ONLY those scripts which need
|
||||
# set-id emulation. Suidperl must be setuid root. It contains the "taint"
|
||||
@ -485,7 +516,7 @@ quantperl: $& perlmain$(OBJ_EXT) $(LIBPERL) $(DYNALOADER) $(static_ext) ext.libs
|
||||
# has been invoked correctly.
|
||||
|
||||
suidperl: $& sperl$(OBJ_EXT) perlmain$(OBJ_EXT) $(LIBPERL) $(DYNALOADER) $(static_ext) ext.libs $(PERLEXPORT)
|
||||
$(SHRPENV) $(LDLIBPTH) $(CC) $(LARGE) $(CLDFLAGS) $(CCDLFLAGS) -o suidperl perlmain$(OBJ_EXT) sperl$(OBJ_EXT) $(DYNALOADER) $(static_ext) $(LLIBPERL) `cat ext.libs` $(libs)
|
||||
$(SHRPENV) $(LDLIBPTH) $(CC) -o suidperl $(CLDFLAGS) $(CCDLFLAGS) perlmain$(OBJ_EXT) sperl$(OBJ_EXT) $(DYNALOADER) $(static_ext) $(LLIBPERL) `cat ext.libs` $(libs)
|
||||
|
||||
!NO!SUBS!
|
||||
|
||||
@ -493,7 +524,7 @@ fi
|
||||
|
||||
$spitshell >>Makefile <<'!NO!SUBS!'
|
||||
|
||||
sperl$(OBJ_EXT): perl.c perly.h patchlevel.h $(h)
|
||||
sperl$(OBJ_EXT): perl.c $(h)
|
||||
$(RMS) sperl.c
|
||||
$(LNS) perl.c sperl.c
|
||||
$(CCCMD) -DIAMSUID sperl.c
|
||||
@ -531,15 +562,25 @@ extra.pods: miniperl
|
||||
-@rm -f extra.pods
|
||||
-@for x in `grep -l '^=[a-z]' README.* | grep -v README.vms` ; do \
|
||||
nx=`echo $$x | sed -e "s/README\.//"`; \
|
||||
$(LNS) ../$$x "pod/perl"$$nx".pod" ; \
|
||||
cd pod ; $(LNS) ../$$x "perl"$$nx".pod" ; cd .. ; \
|
||||
echo "pod/perl"$$nx".pod" >> extra.pods ; \
|
||||
done
|
||||
-@test -f vms/perlvms.pod && $(LNS) ../vms/perlvms.pod pod/perlvms.pod && echo "pod/perlvms.pod" >> extra.pods
|
||||
-@test -f vms/perlvms.pod && cd pod && $(LNS) ../vms/perlvms.pod perlvms.pod && cd .. && echo "pod/perlvms.pod" >> extra.pods
|
||||
|
||||
install-strip:
|
||||
$(MAKE) STRIPFLAGS=-s install
|
||||
|
||||
install: all install.perl install.man
|
||||
install:
|
||||
$(MAKE) install.perl install.man STRIPFLAGS=$(STRIPFLAGS)
|
||||
|
||||
install-verbose:
|
||||
$(MAKE) install.perl install.man STRIPFLAGS=$(STRIPFLAGS) INSTALLFLAGS=-V
|
||||
|
||||
install-silent:
|
||||
$(MAKE) install.perl install.man STRIPFLAGS=$(STRIPFLAGS) INSTALLFLAGS=-S
|
||||
|
||||
no-install:
|
||||
$(MAKE) install.perl install.man STRIPFLAGS=$(STRIPFLAGS) INSTALLFLAGS=-n
|
||||
|
||||
install.perl: all installperl
|
||||
if [ -n "$(COMPILE)" ]; \
|
||||
@ -549,15 +590,15 @@ install.perl: all installperl
|
||||
cd ../pod; $(MAKE) compile; \
|
||||
else :; \
|
||||
fi
|
||||
$(LDLIBPTH) ./perl installperl $(STRIPFLAGS)
|
||||
$(LDLIBPTH) ./perl installperl $(INSTALLFLAGS) $(STRIPFLAGS)
|
||||
|
||||
install.man: all installman
|
||||
$(LDLIBPTH) ./perl installman
|
||||
$(LDLIBPTH) ./perl installman $(INSTALLFLAGS)
|
||||
|
||||
# XXX Experimental. Hardwired values, but useful for testing.
|
||||
# Eventually Configure could ask for some of these values.
|
||||
install.html: all installhtml
|
||||
-@test -f README.vms && $(LNS) ../README.vms vms/README_vms.pod
|
||||
-@test -f README.vms && cd vms && $(LNS) ../README.vms README_vms.pod && cd ..
|
||||
$(LDLIBPTH) ./perl installhtml \
|
||||
--podroot=. --podpath=. --recurse \
|
||||
--htmldir=$(privlib)/html \
|
||||
@ -577,7 +618,7 @@ install.html: all installhtml
|
||||
|
||||
run_byacc: FORCE
|
||||
$(BYACC) -d perly.y
|
||||
-chmod 664 perly.c
|
||||
-chmod 664 perly.c perly.h
|
||||
sh $(shellflags) ./perly.fixer y.tab.c perly.c
|
||||
sed -e 's/fprintf *( *stderr *,/PerlIO_printf(Perl_debug_log,/g' \
|
||||
-e 's/y\.tab/perly/g' perly.c >perly.tmp && mv perly.tmp perly.c
|
||||
@ -624,7 +665,8 @@ AUTOGEN_FILES = keywords.h opcode.h opnames.h pp_proto.h pp.sym proto.h \
|
||||
pod/perlintern.pod pod/perlapi.pod \
|
||||
objXSUB.h perlapi.h perlapi.c ext/ByteLoader/byterun.h \
|
||||
ext/ByteLoader/byterun.c ext/B/B/Asmdata.pm regnodes.h \
|
||||
warnings.h lib/warnings.pm
|
||||
warnings.h lib/warnings.pm \
|
||||
vms/perly_c.vms vms/perly_h.vms
|
||||
|
||||
regen_headers: FORCE
|
||||
-$(CHMOD_W) $(AUTOGEN_FILES)
|
||||
@ -635,6 +677,14 @@ regen_headers: FORCE
|
||||
-perl regcomp.pl
|
||||
-perl warnings.pl
|
||||
|
||||
regen_pods: FORCE
|
||||
-cd pod; $(LDLIBPTH) make regen_pods
|
||||
|
||||
regen_vms: FORCE
|
||||
-perl vms/vms_yfix.pl perly.c perly.h vms/perly_c.vms vms/perly_h.vms
|
||||
|
||||
regen_all: regen_headers regen_pods regen_vms
|
||||
|
||||
# Extensions:
|
||||
# Names added to $(dynamic_ext) or $(static_ext) or $(nonxs_ext) will
|
||||
# automatically get built. There should ordinarily be no need to change
|
||||
@ -659,23 +709,29 @@ n_dummy $(nonxs_ext): miniperl preplibrary $(DYNALOADER) FORCE
|
||||
|
||||
clean: _tidy _mopup
|
||||
|
||||
realclean: _cleaner _mopup
|
||||
realclean: _realcleaner _mopup
|
||||
@echo "Note that make realclean does not delete config.sh or Policy.sh"
|
||||
|
||||
clobber: _cleaner _mopup
|
||||
_clobber:
|
||||
rm -f config.sh cppstdin Policy.sh
|
||||
|
||||
clobber: _realcleaner _mopup _clobber
|
||||
|
||||
distclean: clobber
|
||||
|
||||
# Like distclean but also removes emacs backups and *.orig.
|
||||
veryclean: _verycleaner _mopup _clobber
|
||||
-@rm -f Obsolete Wanted
|
||||
|
||||
# Do not 'make _mopup' directly.
|
||||
_mopup:
|
||||
rm -f *$(OBJ_EXT) *$(LIB_EXT) all perlmain.c
|
||||
-@test -f extra.pods && rm -f `cat extra.pods`
|
||||
-@test -f vms/README_vms.pod && rm -f vms/README_vms.pod
|
||||
-rm -f perl.exp ext.libs extra.pods
|
||||
-rm -f perl.exp ext.libs extra.pods opmini.o
|
||||
-rm -f perl.export perl.dll perl.libexp perl.map perl.def
|
||||
-rm -f perl.loadmap miniperl.loadmap perl.prelmap miniperl.prelmap
|
||||
rm -f perl suidperl miniperl $(LIBPERL)
|
||||
rm -f perl suidperl miniperl $(LIBPERL) libperl.* microperl
|
||||
|
||||
# Do not 'make _tidy' directly.
|
||||
_tidy:
|
||||
@ -687,16 +743,17 @@ _tidy:
|
||||
done
|
||||
rm -f testcompile compilelog
|
||||
|
||||
# Do not 'make _cleaner' directly.
|
||||
_cleaner:
|
||||
_cleaner1:
|
||||
-cd os2; rm -f Makefile
|
||||
-cd pod; $(LDLIBPTH) $(MAKE) realclean
|
||||
-cd utils; $(LDLIBPTH) $(MAKE) realclean
|
||||
-cd x2p; $(LDLIBPTH) $(MAKE) realclean
|
||||
-cd pod; $(LDLIBPTH) $(MAKE) $(CLEAN)
|
||||
-cd utils; $(LDLIBPTH) $(MAKE) $(CLEAN)
|
||||
-cd x2p; $(LDLIBPTH) $(MAKE) $(CLEAN)
|
||||
-@for x in $(DYNALOADER) $(dynamic_ext) $(static_ext) $(nonxs_ext) ; do \
|
||||
$(LDLIBPTH) sh ext/util/make_ext realclean $$x MAKE=$(MAKE) ; \
|
||||
$(LDLIBPTH) sh ext/util/make_ext $(CLEAN) $$x MAKE=$(MAKE) ; \
|
||||
done
|
||||
rm -f *.orig */*.orig *~ */*~ core core.*perl.*.? *perl.core t/core t/core.perl.*.? t/*perl.core t/misctmp* t/tmp* t/c t/perl .?*.c so_locations $(LIBPERL_NONSHR) $(MINIPERL_NONSHR)
|
||||
|
||||
_cleaner2:
|
||||
rm -f core core.*perl.*.? *perl.core t/core t/core.perl.*.? t/*perl.core t/misctmp* t/forktmp* t/tmp* t/c t/perl t/rantests .?*.c so_locations $(LIBPERL_NONSHR) $(MINIPERL_NONSHR)
|
||||
rm -rf $(addedbyconf)
|
||||
rm -f $(FIRSTMAKEFILE) $(FIRSTMAKEFILE).old
|
||||
rm -f $(private)
|
||||
@ -705,14 +762,23 @@ _cleaner:
|
||||
rm -f h2ph.man pstruct
|
||||
rm -rf .config
|
||||
rm -f testcompile compilelog
|
||||
-rmdir lib/B lib/Data lib/IO/Socket lib/IO
|
||||
-rmdir lib/B lib/Data lib/IO/Socket lib/IO lib/Sys lib/Thread
|
||||
|
||||
_realcleaner:
|
||||
@$(LDLIBPTH) $(MAKE) _cleaner1 CLEAN=realclean
|
||||
@$(LDLIBPTH) $(MAKE) _cleaner2
|
||||
|
||||
_verycleaner:
|
||||
@$(LDLIBPTH) $(MAKE) _cleaner1 CLEAN=veryclean
|
||||
@$(LDLIBPTH) $(MAKE) _cleaner2
|
||||
-rm -f *~ *.orig */*~ */*.orig */*/*~ */*/*.orig
|
||||
|
||||
# The following lint has practically everything turned on. Unfortunately,
|
||||
# you have to wade through a lot of mumbo jumbo that can't be suppressed.
|
||||
# If the source file has a /*NOSTRICT*/ somewhere, ignore the lint message
|
||||
# for that spot.
|
||||
|
||||
lint: perly.c $(c)
|
||||
lint: $(c)
|
||||
lint $(lintflags) $(defs) perly.c $(c) > perl.fuzz
|
||||
|
||||
# Need to unset during recursion to go out of loop.
|
||||
@ -750,6 +816,7 @@ test check: test-prep
|
||||
else \
|
||||
cd t && PERL_SKIP_TTY_TEST=1 $(LDLIBPTH) ./perl TEST; \
|
||||
fi
|
||||
@echo "Ran tests" > t/rantests
|
||||
|
||||
utest ucheck: test-prep
|
||||
if (true </dev/tty) >/dev/null 2>&1; then \
|
||||
@ -768,7 +835,7 @@ minitest: miniperl lib/re.pm
|
||||
@echo "You may see some irrelevant test failures if you have been unable"
|
||||
@echo "to build lib/Config.pm."
|
||||
- cd t && (rm -f perl$(EXE_EXT); $(LNS) ../miniperl$(EXE_EXT) perl$(EXE_EXT)) \
|
||||
&& $(LDLIBPTH) ./perl TEST base/*.t comp/*.t cmd/*.t io/*.t op/*.t pragma/*.t </dev/tty
|
||||
&& $(LDLIBPTH) ./perl TEST base/*.t comp/*.t cmd/*.t run/*.t io/*.t op/*.t pragma/*.t </dev/tty
|
||||
|
||||
# Handy way to run perlbug -ok without having to install and run the
|
||||
# installed perlbug. We don't re-run the tests here - we trust the user.
|
||||
@ -780,12 +847,24 @@ ok: utilities
|
||||
okfile: utilities
|
||||
$(LDLIBPTH) ./perl -Ilib utils/perlbug -ok -s '(UNINSTALLED)' -F perl.ok
|
||||
|
||||
oknack: utilities
|
||||
$(LDLIBPTH) ./perl -Ilib utils/perlbug -ok -s '(UNINSTALLED)' -A
|
||||
|
||||
okfilenack: utilities
|
||||
$(LDLIBPTH) ./perl -Ilib utils/perlbug -ok -s '(UNINSTALLED)' -F perl.ok -A
|
||||
|
||||
nok: utilities
|
||||
$(LDLIBPTH) ./perl -Ilib utils/perlbug -nok -s '(UNINSTALLED)'
|
||||
|
||||
nokfile: utilities
|
||||
$(LDLIBPTH) ./perl -Ilib utils/perlbug -nok -s '(UNINSTALLED)' -F perl.nok
|
||||
|
||||
noknack: utilities
|
||||
$(LDLIBPTH) ./perl -Ilib utils/perlbug -nok -s '(UNINSTALLED)' -A
|
||||
|
||||
nokfilenack: utilities
|
||||
$(LDLIBPTH) ./perl -Ilib utils/perlbug -nok -s '(UNINSTALLED)' -F perl.nok -A
|
||||
|
||||
clist: $(c)
|
||||
echo $(c) | tr ' ' $(TRNL) >.clist
|
||||
|
||||
@ -896,6 +975,7 @@ os390|posix-bc)
|
||||
mv -f y.tab.c a2p.c
|
||||
chmod u+w a2p.c
|
||||
sed -e 's/fprintf *( *stderr *,/PerlIO_printf(Perl_debug_log,/g' \
|
||||
-e 's|^static void __YY_YACC_MAIN.*BS2000.*|/*static main deleted*/|' \
|
||||
-e 's/y\.tab/a2p/g' a2p.c >a2p.tmp && mv a2p.tmp a2p.c
|
||||
xxx="$xxx a2p.c"
|
||||
fi
|
||||
|
@ -7,18 +7,33 @@ $startsh
|
||||
#
|
||||
# This file was produced by running the Policy_sh.SH script, which
|
||||
# gets its values from config.sh, which is generally produced by
|
||||
# running Configure. The Policy.sh file gets overwritten each time
|
||||
# Configure is run. Any variables you add to Policy.sh will be lost
|
||||
# unless you copy Policy.sh somewhere else before running Configure.
|
||||
# running Configure.
|
||||
#
|
||||
# The idea here is to distill in one place the common site-wide
|
||||
# "policy" answers (such as installation directories) that are
|
||||
# to be "sticky". If you keep the file Policy.sh around in
|
||||
# the same directory as you are building Perl, then Configure will
|
||||
# (by default) load up the Policy.sh file just before the
|
||||
# platform-specific hints file.
|
||||
# platform-specific hints file and rewrite it at the end.
|
||||
#
|
||||
# The sequence of events is as follows:
|
||||
# A: If you are NOT re-using an old config.sh:
|
||||
# 1. At start-up, Configure loads up the defaults from the
|
||||
# os-specific hints/osname_osvers.sh file and any previous
|
||||
# Policy.sh file.
|
||||
# 2. At the end, Configure runs Policy_sh.SH, which creates
|
||||
# Policy.sh, overwriting a previous Policy.sh if necessary.
|
||||
#
|
||||
# B: If you are re-using an old config.sh:
|
||||
# 1. At start-up, Configure loads up the defaults from config.sh,
|
||||
# ignoring any previous Policy.sh file.
|
||||
# 2. At the end, Configure runs Policy_sh.SH, which creates
|
||||
# Policy.sh, overwriting a previous Policy.sh if necessary.
|
||||
#
|
||||
# Thus the Policy.sh file gets overwritten each time
|
||||
# Configure is run. Any variables you add to Policy.sh will be lost
|
||||
# unless you copy Policy.sh somewhere else before running Configure.
|
||||
#
|
||||
|
||||
# Allow Configure command-line overrides; usually these won't be
|
||||
# needed, but something like -Dprefix=/test/location can be quite
|
||||
# useful for testing out new versions.
|
||||
@ -37,16 +52,37 @@ esac
|
||||
case "\$prefix" in
|
||||
'') prefix='$prefix' ;;
|
||||
esac
|
||||
|
||||
# By default, the next three are the same as \$prefix.
|
||||
# If the user changes \$prefix, and previously \$siteprefix was the
|
||||
# same as \$prefix, then change \$siteprefix as well.
|
||||
# Use similar logic for \$vendorprefix and \$installprefix.
|
||||
|
||||
case "\$siteprefix" in
|
||||
'') siteprefix='$siteprefix' ;;
|
||||
'') if test "$siteprefix" = "$prefix"; then
|
||||
siteprefix="\$prefix"
|
||||
else
|
||||
siteprefix='$siteprefix'
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
case "\$vendorprefix" in
|
||||
'') vendorprefix='$vendorprefix' ;;
|
||||
'') if test "$vendorprefix" = "$prefix"; then
|
||||
vendorprefix="\$prefix"
|
||||
else
|
||||
vendorprefix='$vendorprefix'
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
# Where installperl puts things.
|
||||
case "\$installprefix" in
|
||||
'') installprefix='$installprefix' ;;
|
||||
'') if test "$installprefix" = "$prefix"; then
|
||||
installprefix="\$prefix"
|
||||
else
|
||||
installprefix='$installprefix'
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
# Installation directives. Note that each one comes in three flavors.
|
||||
|
@ -19,7 +19,7 @@ community, mutual respect, trust, and good-faith cooperation.
|
||||
|
||||
We recognize that the Perl core, defined as the software distributed with
|
||||
the heart of Perl itself, is a joint project on the part of all of us.
|
||||
>From time to time, a script, module, or set of modules (hereafter referred
|
||||
From time to time, a script, module, or set of modules (hereafter referred
|
||||
to simply as a "module") will prove so widely useful and/or so integral to
|
||||
the correct functioning of Perl itself that it should be distributed with
|
||||
Perl core. This should never be done without the author's explicit
|
||||
|
@ -174,7 +174,8 @@ cat (Loc.U):
|
||||
cc (cc.U):
|
||||
This variable holds the name of a command to execute a C compiler which
|
||||
can resolve multiple global references that happen to have the same
|
||||
name. Usual values are 'cc', 'Mcc', 'cc -M', and 'gcc'.
|
||||
name. Usual values are 'cc' and 'gcc'.
|
||||
Fervent ANSI compilers may be called 'c89'. AIX has xlc.
|
||||
|
||||
cccdlflags (dlsrc.U):
|
||||
This variable contains any special flags that might need to be
|
||||
@ -192,12 +193,28 @@ ccflags (ccflags.U):
|
||||
This variable contains any additional C compiler flags desired by
|
||||
the user. It is up to the Makefile to use this.
|
||||
|
||||
ccflags_uselargefiles (uselfs.U):
|
||||
This variable contains the compiler flags needed by large file builds
|
||||
and added to ccflags by hints files.
|
||||
|
||||
ccname (Checkcc.U):
|
||||
This can set either by hints files or by Configure. If using
|
||||
gcc, this is gcc, and if not, usually equal to cc, unimpressive, no?
|
||||
Some platforms, however, make good use of this by storing the
|
||||
flavor of the C compiler being used here. For example if using
|
||||
the Sun WorkShop suite, ccname will be 'workshop'.
|
||||
|
||||
ccsymbols (Cppsym.U):
|
||||
The variable contains the symbols defined by the C compiler alone.
|
||||
The symbols defined by cpp or by cc when it calls cpp are not in
|
||||
this list, see cppsymbols and cppccsymbols.
|
||||
The list is a space-separated list of symbol=value tokens.
|
||||
|
||||
ccversion (Checkcc.U):
|
||||
This can set either by hints files or by Configure. If using
|
||||
a (non-gcc) vendor cc, this variable may contain a version for
|
||||
the compiler.
|
||||
|
||||
cf_by (cf_who.U):
|
||||
Login name of the person who ran the Configure script and answered the
|
||||
questions. This is used to tag both config.sh and config_h.SH.
|
||||
@ -323,6 +340,10 @@ csh (Loc.U):
|
||||
full pathname (if any) of the csh program. After Configure runs,
|
||||
the value is reset to a plain "csh" and is not useful.
|
||||
|
||||
d__fwalk (d__fwalk.U):
|
||||
This variable conditionally defines HAS__FWALK if _fwalk() is
|
||||
available to apply a function to all the file handles.
|
||||
|
||||
d_access (d_access.U):
|
||||
This variable conditionally defines HAS_ACCESS if the access() system
|
||||
call is available to check for access permissions using real IDs.
|
||||
@ -506,10 +527,6 @@ d_endsent (d_endsent.U):
|
||||
This variable conditionally defines HAS_ENDSERVENT if endservent() is
|
||||
available to close whatever was being used for service queries.
|
||||
|
||||
d_endspent (d_endspent.U):
|
||||
This variable conditionally defines HAS_ENDSPENT if endspent() is
|
||||
available to finalize the scan of SysV shadow password entries.
|
||||
|
||||
d_eofnblk (nblock_io.U):
|
||||
This variable conditionally defines EOF_NONBLOCK if EOF can be seen
|
||||
when reading from a non-blocking I/O source.
|
||||
@ -532,6 +549,10 @@ d_fcntl (d_fcntl.U):
|
||||
This variable conditionally defines the HAS_FCNTL symbol, and indicates
|
||||
whether the fcntl() function exists
|
||||
|
||||
d_fcntl_can_lock (d_fcntl_can_lock.U):
|
||||
This variable conditionally defines the FCNTL_CAN_LOCK symbol
|
||||
and indicates whether file locking with fcntl() works.
|
||||
|
||||
d_fd_macros (d_fd_set.U):
|
||||
This variable contains the eventual value of the HAS_FD_MACROS symbol,
|
||||
which indicates if your C compiler knows about the macros which
|
||||
@ -573,6 +594,10 @@ d_fpathconf (d_pathconf.U):
|
||||
d_fpos64_t (d_fpos64_t.U):
|
||||
This symbol will be defined if the C compiler supports fpos64_t.
|
||||
|
||||
d_frexpl (d_frexpl.U):
|
||||
This variable conditionally defines the HAS_FREXPL symbol, which
|
||||
indicates to the C program that the frexpl() routine is available.
|
||||
|
||||
d_fs_data_s (d_fs_data_s.U):
|
||||
This variable conditionally defines the HAS_STRUCT_FS_DATA symbol,
|
||||
which indicates that the struct fs_data is supported.
|
||||
@ -593,6 +618,10 @@ d_fstatvfs (d_statvfs.U):
|
||||
This variable conditionally defines the HAS_FSTATVFS symbol, which
|
||||
indicates to the C program that the fstatvfs() routine is available.
|
||||
|
||||
d_fsync (d_fsync.U):
|
||||
This variable conditionally defines the HAS_FSYNC symbol, which
|
||||
indicates to the C program that the fsync() routine is available.
|
||||
|
||||
d_ftello (d_ftello.U):
|
||||
This variable conditionally defines the HAS_FTELLO symbol, which
|
||||
indicates to the C program that the ftello() routine is available.
|
||||
@ -616,6 +645,10 @@ d_getcwd (d_getcwd.U):
|
||||
indicates to the C program that the getcwd() routine is available
|
||||
to get the current working directory.
|
||||
|
||||
d_getespwnam (d_getespwnam.U):
|
||||
This variable conditionally defines HAS_GETESPWNAM if getespwnam() is
|
||||
available to retrieve enchanced (shadow) password entries by name.
|
||||
|
||||
d_getfsstat (d_getfsstat.U):
|
||||
This variable conditionally defines the HAS_GETFSSTAT symbol, which
|
||||
indicates to the C program that the getfsstat() routine is available.
|
||||
@ -690,6 +723,10 @@ d_getnetprotos (d_getnetprotos.U):
|
||||
prototypes for the various getnet*() functions.
|
||||
See also netdbtype.U for probing for various netdb types.
|
||||
|
||||
d_getpagsz (d_getpagsz.U):
|
||||
This variable conditionally defines HAS_GETPAGESIZE if getpagesize()
|
||||
is available to get the system page size.
|
||||
|
||||
d_getpbyname (d_getprotby.U):
|
||||
This variable conditionally defines the HAS_GETPROTOBYNAME
|
||||
symbol, which indicates to the C program that the
|
||||
@ -735,6 +772,10 @@ d_getprotoprotos (d_getprotoprotos.U):
|
||||
prototypes for the various getproto*() functions.
|
||||
See also netdbtype.U for probing for various netdb types.
|
||||
|
||||
d_getprpwnam (d_getprpwnam.U):
|
||||
This variable conditionally defines HAS_GETPRPWNAM if getprpwnam() is
|
||||
available to retrieve protected (shadow) password entries by name.
|
||||
|
||||
d_getpwent (d_getpwent.U):
|
||||
This variable conditionally defines the HAS_GETPWENT symbol, which
|
||||
indicates to the C program that the getpwent() routine is available
|
||||
@ -762,10 +803,6 @@ d_getservprotos (d_getservprotos.U):
|
||||
prototypes for the various getserv*() functions.
|
||||
See also netdbtype.U for probing for various netdb types.
|
||||
|
||||
d_getspent (d_getspent.U):
|
||||
This variable conditionally defines HAS_GETSPENT if getspent() is
|
||||
available to retrieve SysV shadow password entries sequentially.
|
||||
|
||||
d_getspnam (d_getspnam.U):
|
||||
This variable conditionally defines HAS_GETSPNAM if getspnam() is
|
||||
available to retrieve SysV shadow password entries by name.
|
||||
@ -811,6 +848,14 @@ d_isascii (d_isascii.U):
|
||||
This variable conditionally defines the HAS_ISASCII constant,
|
||||
which indicates to the C program that isascii() is available.
|
||||
|
||||
d_isnan (d_isnan.U):
|
||||
This variable conditionally defines the HAS_ISNAN symbol, which
|
||||
indicates to the C program that the isnan() routine is available.
|
||||
|
||||
d_isnanl (d_isnanl.U):
|
||||
This variable conditionally defines the HAS_ISNANL symbol, which
|
||||
indicates to the C program that the isnanl() routine is available.
|
||||
|
||||
d_killpg (d_killpg.U):
|
||||
This variable conditionally defines the HAS_KILLPG symbol, which
|
||||
indicates to the C program that the killpg() routine is available
|
||||
@ -933,6 +978,10 @@ d_mmap (d_mmap.U):
|
||||
This variable conditionally defines HAS_MMAP if mmap() is
|
||||
available to map a file into memory.
|
||||
|
||||
d_modfl (d_modfl.U):
|
||||
This variable conditionally defines the HAS_MODFL symbol, which
|
||||
indicates to the C program that the modfl() routine is available.
|
||||
|
||||
d_mprotect (d_mprotect.U):
|
||||
This variable conditionally defines HAS_MPROTECT if mprotect() is
|
||||
available to modify the access protection of a memory mapped file.
|
||||
@ -1003,6 +1052,10 @@ d_nv_preserves_uv (perlxv.U):
|
||||
This variable indicates whether a variable of type nvtype
|
||||
can preserve all the bits a variable of type uvtype.
|
||||
|
||||
d_nv_preserves_uv_bits (perlxv.U):
|
||||
This variable indicates how many of bits type uvtype
|
||||
a variable nvtype can preserve.
|
||||
|
||||
d_off64_t (d_off64_t.U):
|
||||
This symbol will be defined if the C compiler supports off64_t.
|
||||
|
||||
@ -1036,6 +1089,11 @@ d_pause (d_pause.U):
|
||||
indicates to the C program that the pause() routine is available
|
||||
to suspend a process until a signal is received.
|
||||
|
||||
d_perl_otherlibdirs (otherlibdirs.U):
|
||||
This variable conditionally defines PERL_OTHERLIBDIRS, which
|
||||
contains a colon-separated set of paths for the perl binary to
|
||||
include in @INC. See also otherlibdirs.
|
||||
|
||||
d_phostname (d_gethname.U):
|
||||
This variable conditionally defines the HAS_PHOSTNAME symbol, which
|
||||
contains the shell command which, when fed to popen(), may be
|
||||
@ -1061,28 +1119,34 @@ d_PRId64 (quadfio.U):
|
||||
indiciates that stdio has a symbol to print 64-bit decimal numbers.
|
||||
|
||||
d_PRIeldbl (longdblfio.U):
|
||||
This variable conditionally defines the PERL_PRIfldlbl symbol, which
|
||||
This variable conditionally defines the PERL_PRIfldbl symbol, which
|
||||
indiciates that stdio has a symbol to print long doubles.
|
||||
|
||||
d_PRIEldbl (longdblfio.U):
|
||||
This variable conditionally defines the PERL_PRIfldlbl symbol, which
|
||||
d_PRIEUldbl (longdblfio.U):
|
||||
This variable conditionally defines the PERL_PRIfldbl symbol, which
|
||||
indiciates that stdio has a symbol to print long doubles.
|
||||
The 'U' in the name is to separate this from d_PRIeldbl so that even
|
||||
case-blind systems can see the difference.
|
||||
|
||||
d_PRIfldbl (longdblfio.U):
|
||||
This variable conditionally defines the PERL_PRIfldlbl symbol, which
|
||||
This variable conditionally defines the PERL_PRIfldbl symbol, which
|
||||
indiciates that stdio has a symbol to print long doubles.
|
||||
|
||||
d_PRIFldbl (longdblfio.U):
|
||||
This variable conditionally defines the PERL_PRIfldlbl symbol, which
|
||||
d_PRIFUldbl (longdblfio.U):
|
||||
This variable conditionally defines the PERL_PRIfldbl symbol, which
|
||||
indiciates that stdio has a symbol to print long doubles.
|
||||
The 'U' in the name is to separate this from d_PRIfldbl so that even
|
||||
case-blind systems can see the difference.
|
||||
|
||||
d_PRIgldbl (longdblfio.U):
|
||||
This variable conditionally defines the PERL_PRIfldlbl symbol, which
|
||||
This variable conditionally defines the PERL_PRIfldbl symbol, which
|
||||
indiciates that stdio has a symbol to print long doubles.
|
||||
|
||||
d_PRIGldbl (longdblfio.U):
|
||||
This variable conditionally defines the PERL_PRIfldlbl symbol, which
|
||||
d_PRIGUldbl (longdblfio.U):
|
||||
This variable conditionally defines the PERL_PRIfldbl symbol, which
|
||||
indiciates that stdio has a symbol to print long doubles.
|
||||
The 'U' in the name is to separate this from d_PRIgldbl so that even
|
||||
case-blind systems can see the difference.
|
||||
|
||||
d_PRIi64 (quadfio.U):
|
||||
This variable conditionally defines the PERL_PRIi64 symbol, which
|
||||
@ -1101,9 +1165,11 @@ d_PRIx64 (quadfio.U):
|
||||
This variable conditionally defines the PERL_PRIx64 symbol, which
|
||||
indiciates that stdio has a symbol to print 64-bit hexadecimal numbers.
|
||||
|
||||
d_PRIX64 (quadfio.U):
|
||||
This variable conditionally defines the PERL_PRIX64 symbol, which
|
||||
d_PRIXU64 (quadfio.U):
|
||||
This variable conditionally defines the PERL_PRIXU64 symbol, which
|
||||
indiciates that stdio has a symbol to print 64-bit hExADECimAl numbers.
|
||||
The 'U' in the name is to separate this from d_PRIx64 so that even
|
||||
case-blind systems can see the difference.
|
||||
|
||||
d_pthread_yield (d_pthread_y.U):
|
||||
This variable conditionally defines the HAS_PTHREAD_YIELD
|
||||
@ -1185,6 +1251,12 @@ d_sanemcmp (d_sanemcmp.U):
|
||||
the memcpy() routine is available and can be used to compare relative
|
||||
magnitudes of chars with their high bits set.
|
||||
|
||||
d_sbrkproto (d_sbrkproto.U):
|
||||
This variable conditionally defines the HAS_SBRK_PROTO symbol,
|
||||
which indicates to the C program that the system provides
|
||||
a prototype for the sbrk() function. Otherwise, it is
|
||||
up to the program to supply one.
|
||||
|
||||
d_sched_yield (d_pthread_y.U):
|
||||
This variable conditionally defines the HAS_SCHED_YIELD
|
||||
symbol if the sched_yield routine is available to yield
|
||||
@ -1195,6 +1267,10 @@ d_scm_rights (d_socket.U):
|
||||
which indicates that the SCM_RIGHTS is available. #ifdef is
|
||||
not enough because it may be an enum, glibc has been known to do this.
|
||||
|
||||
d_SCNfldbl (longdblfio.U):
|
||||
This variable conditionally defines the PERL_PRIfldbl symbol, which
|
||||
indiciates that stdio has a symbol to scan long doubles.
|
||||
|
||||
d_seekdir (d_readdir.U):
|
||||
This variable conditionally defines HAS_SEEKDIR if seekdir() is
|
||||
available.
|
||||
@ -1287,6 +1363,11 @@ d_setprior (d_setprior.U):
|
||||
This variable conditionally defines HAS_SETPRIORITY if setpriority()
|
||||
is available to set a process's priority.
|
||||
|
||||
d_setproctitle (d_setproctitle.U):
|
||||
This variable conditionally defines the HAS_SETPROCTITLE symbol,
|
||||
which indicates to the C program that the setproctitle() routine
|
||||
is available.
|
||||
|
||||
d_setpwent (d_setpwent.U):
|
||||
This variable conditionally defines the HAS_SETPWENT symbol, which
|
||||
indicates to the C program that the setpwent() routine is available
|
||||
@ -1330,10 +1411,6 @@ d_setsid (d_setsid.U):
|
||||
This variable conditionally defines HAS_SETSID if setsid() is
|
||||
available to set the process group ID.
|
||||
|
||||
d_setspent (d_setspent.U):
|
||||
This variable conditionally defines HAS_SETSPENT if setspent() is
|
||||
available to initialize the scan of SysV shadow password entries.
|
||||
|
||||
d_setvbuf (d_setvbuf.U):
|
||||
This variable conditionally defines the HAS_SETVBUF symbol, which
|
||||
indicates to the C program that the setvbuf() routine is available
|
||||
@ -1372,6 +1449,11 @@ d_sigaction (d_sigaction.U):
|
||||
This variable conditionally defines the HAS_SIGACTION symbol, which
|
||||
indicates that the Vr4 sigaction() routine is available.
|
||||
|
||||
d_sigprocmask (d_sigprocmask.U):
|
||||
This variable conditionally defines HAS_SIGPROCMASK
|
||||
if sigprocmask() is available to examine or change the signal mask
|
||||
of the calling process.
|
||||
|
||||
d_sigsetjmp (d_sigsetjmp.U):
|
||||
This variable conditionally defines the HAS_SIGSETJMP symbol,
|
||||
which indicates that the sigsetjmp() routine is available to
|
||||
@ -1388,6 +1470,10 @@ d_sockpair (d_socket.U):
|
||||
This variable conditionally defines the HAS_SOCKETPAIR symbol, which
|
||||
indicates that the BSD socketpair() is supported.
|
||||
|
||||
d_socks5_init (d_socks5_init.U):
|
||||
This variable conditionally defines the HAS_SOCKS5_INIT symbol, which
|
||||
indicates to the C program that the socks5_init() routine is available.
|
||||
|
||||
d_sqrtl (d_sqrtl.U):
|
||||
This variable conditionally defines the HAS_SQRTL symbol, which
|
||||
indicates to the C program that the sqrtl() routine is available.
|
||||
@ -1419,6 +1505,15 @@ d_stdio_ptr_lval (d_stdstdio.U):
|
||||
This variable conditionally defines STDIO_PTR_LVALUE if the
|
||||
FILE_ptr macro can be used as an lvalue.
|
||||
|
||||
d_stdio_ptr_lval_nochange_cnt (d_stdstdio.U):
|
||||
This symbol is defined if using the FILE_ptr macro as an lvalue
|
||||
to increase the pointer by n leaves File_cnt(fp) unchanged.
|
||||
|
||||
d_stdio_ptr_lval_sets_cnt (d_stdstdio.U):
|
||||
This symbol is defined if using the FILE_ptr macro as an lvalue
|
||||
to increase the pointer by n has the side effect of decreasing the
|
||||
value of File_cnt(fp) by n.
|
||||
|
||||
d_stdio_stream_array (stdio_streams.U):
|
||||
This variable tells whether there is an array holding
|
||||
the stdio streams.
|
||||
@ -1474,6 +1569,10 @@ d_strtoll (d_strtoll.U):
|
||||
This variable conditionally defines the HAS_STRTOLL symbol, which
|
||||
indicates to the C program that the strtoll() routine is available.
|
||||
|
||||
d_strtoq (d_strtoq.U):
|
||||
This variable conditionally defines the HAS_STRTOQ symbol, which
|
||||
indicates to the C program that the strtoq() routine is available.
|
||||
|
||||
d_strtoul (d_strtoul.U):
|
||||
This variable conditionally defines the HAS_STRTOUL symbol, which
|
||||
indicates to the C program that the strtoul() routine is available
|
||||
@ -1782,7 +1881,12 @@ full_sed (Loc_sed.U):
|
||||
can share this executable will have the same full pathname to
|
||||
'sed.'
|
||||
|
||||
gccversion (cc.U):
|
||||
gccosandvers (gccvers.U):
|
||||
If GNU cc (gcc) is used, this variable the operating system and
|
||||
version used to compile the gcc. It is set to '' if not gcc,
|
||||
or if nothing useful can be parsed as the os version.
|
||||
|
||||
gccversion (gccvers.U):
|
||||
If GNU cc (gcc) is used, this variable holds '1' or '2' to
|
||||
indicate whether the compiler is version 1 or 2. This is used in
|
||||
setting some of the default cflags. It is set to '' if not gcc.
|
||||
@ -1849,12 +1953,6 @@ hostcat (nis.U):
|
||||
On some systems, such as os390, there may be no equivalent
|
||||
command, in which case this variable is unset.
|
||||
|
||||
huge (models.U):
|
||||
This variable contains a flag which will tell the C compiler and loader
|
||||
to produce a program running with a huge memory model. If the
|
||||
huge model is not supported, contains the flag to produce large
|
||||
model programs. It is up to the Makefile to use this.
|
||||
|
||||
i16size (perlxv.U):
|
||||
This variable is the size of an I16 in bytes.
|
||||
|
||||
@ -1941,6 +2039,10 @@ i_inttypes (i_inttypes.U):
|
||||
This variable conditionally defines the I_INTTYPES symbol,
|
||||
and indicates whether a C program should include <inttypes.h>.
|
||||
|
||||
i_libutil (i_libutil.U):
|
||||
This variable conditionally defines the I_LIBUTIL symbol, and indicates
|
||||
whether a C program should include <libutil.h>.
|
||||
|
||||
i_limits (i_limits.U):
|
||||
This variable conditionally defines the I_LIMITS symbol, and indicates
|
||||
whether a C program may include <limits.h> to get symbols like WORD_BIT
|
||||
@ -1997,6 +2099,10 @@ i_poll (i_poll.U):
|
||||
This variable conditionally defines the I_POLL symbol, and indicates
|
||||
whether a C program should include <poll.h>.
|
||||
|
||||
i_prot (i_prot.U):
|
||||
This variable conditionally defines the I_PROT symbol, and indicates
|
||||
whether a C program should include <prot.h>.
|
||||
|
||||
i_pthread (i_pthread.U):
|
||||
This variable conditionally defines the I_PTHREAD symbol,
|
||||
and indicates whether a C program should include <pthread.h>.
|
||||
@ -2342,6 +2448,11 @@ intsize (intsize.U):
|
||||
This variable contains the value of the INTSIZE symbol, which
|
||||
indicates to the C program how many bytes there are in an int.
|
||||
|
||||
issymlink (issymlink.U):
|
||||
This variable holds the test command to test for a symbolic link
|
||||
(if they are supported). Typical values include 'test -h' and
|
||||
'test -L'.
|
||||
|
||||
ivdformat (perlxvf.U):
|
||||
This variable contains the format string used for printing
|
||||
a Perl IV as a signed decimal integer.
|
||||
@ -2360,11 +2471,6 @@ ksh (Loc.U):
|
||||
This variable is defined but not used by Configure.
|
||||
The value is a plain '' and is not useful.
|
||||
|
||||
large (models.U):
|
||||
This variable contains a flag which will tell the C compiler and loader
|
||||
to produce a program running with a large memory model. It is up to
|
||||
the Makefile to use this.
|
||||
|
||||
ld (dlsrc.U):
|
||||
This variable indicates the program to be used to link
|
||||
libraries for dynamic loading. On some systems, it is 'ld'.
|
||||
@ -2381,6 +2487,10 @@ ldflags (ccflags.U):
|
||||
This variable contains any additional C loader flags desired by
|
||||
the user. It is up to the Makefile to use this.
|
||||
|
||||
ldflags_uselargefiles (uselfs.U):
|
||||
This variable contains the loader flags needed by large file builds
|
||||
and added to ldflags by hints files.
|
||||
|
||||
ldlibpthname (libperl.U):
|
||||
This variable holds the name of the shared library
|
||||
search path, often LD_LIBRARY_PATH. To get an empty
|
||||
@ -2433,6 +2543,12 @@ libswanted (Myinit.U):
|
||||
search. The order is chosen to pick up the c library
|
||||
ahead of ucb or bsd libraries for SVR4.
|
||||
|
||||
libswanted_uselargefiles (uselfs.U):
|
||||
This variable contains the libraries needed by large file builds
|
||||
and added to ldflags by hints files. It is a space separated list
|
||||
of the library names without the "lib" prefix or any suffix, just
|
||||
like libswanted..
|
||||
|
||||
line (Loc.U):
|
||||
This variable is defined but not used by Configure.
|
||||
The value is a plain '' and is not useful.
|
||||
@ -2578,12 +2694,6 @@ Mcc (Loc.U):
|
||||
full pathname (if any) of the Mcc program. After Configure runs,
|
||||
the value is reset to a plain "Mcc" and is not useful.
|
||||
|
||||
medium (models.U):
|
||||
This variable contains a flag which will tell the C compiler and loader
|
||||
to produce a program running with a medium memory model. If the
|
||||
medium model is not supported, contains the flag to produce large
|
||||
model programs. It is up to the Makefile to use this.
|
||||
|
||||
mips_type (usrinc.U):
|
||||
This variable holds the environment type for the mips system.
|
||||
Possible values are "BSD 4.3" and "System V".
|
||||
@ -2598,11 +2708,6 @@ mmaptype (d_mmap.U):
|
||||
(and simultaneously the type of the first argument).
|
||||
It can be 'void *' or 'caddr_t'.
|
||||
|
||||
models (models.U):
|
||||
This variable contains the list of memory models supported by this
|
||||
system. Possible component values are none, split, unsplit, small,
|
||||
medium, large, and huge. The component values are space separated.
|
||||
|
||||
modetype (modetype.U):
|
||||
This variable defines modetype to be something like mode_t,
|
||||
int, unsigned short, or whatever type is used to declare file
|
||||
@ -2649,6 +2754,15 @@ n (n.U):
|
||||
command to suppress newline. Otherwise it is null. Correct usage is
|
||||
$echo $n "prompt for a question: $c".
|
||||
|
||||
need_va_copy (need_va_copy.U):
|
||||
This symbol, if defined, indicates that the system stores
|
||||
the variable argument list datatype, va_list, in a format
|
||||
that cannot be copied by simple assignment, so that some
|
||||
other means must be used when copying is required.
|
||||
As such systems vary in their provision (or non-provision)
|
||||
of copying mechanisms, handy.h defines a platform-
|
||||
independent macro, Perl_va_copy(src, dst), to do the job.
|
||||
|
||||
netdb_hlen_type (netdbtype.U):
|
||||
This variable holds the type used for the 2nd argument to
|
||||
gethostbyaddr(). Usually, this is int or size_t or unsigned.
|
||||
@ -2695,6 +2809,30 @@ nroff (Loc.U):
|
||||
full pathname (if any) of the nroff program. After Configure runs,
|
||||
the value is reset to a plain "nroff" and is not useful.
|
||||
|
||||
nveformat (perlxvf.U):
|
||||
This variable contains the format string used for printing
|
||||
a Perl NV using %e-ish floating point format.
|
||||
|
||||
nvEUformat (perlxvf.U):
|
||||
This variable contains the format string used for printing
|
||||
a Perl NV using %E-ish floating point format.
|
||||
|
||||
nvfformat (perlxvf.U):
|
||||
This variable confains the format string used for printing
|
||||
a Perl NV using %f-ish floating point format.
|
||||
|
||||
nvFUformat (perlxvf.U):
|
||||
This variable confains the format string used for printing
|
||||
a Perl NV using %F-ish floating point format.
|
||||
|
||||
nvgformat (perlxvf.U):
|
||||
This variable contains the format string used for printing
|
||||
a Perl NV using %g-ish floating point format.
|
||||
|
||||
nvGUformat (perlxvf.U):
|
||||
This variable contains the format string used for printing
|
||||
a Perl NV using %G-ish floating point format.
|
||||
|
||||
nvsize (perlxv.U):
|
||||
This variable is the size of an NV in bytes.
|
||||
|
||||
@ -2741,6 +2879,16 @@ osvers (Oldconfig.U):
|
||||
same for this package, hints files might just be os_4.0 or
|
||||
os_4.1, etc., not keeping separate files for each little release.
|
||||
|
||||
otherlibdirs (otherlibdirs.U):
|
||||
This variable contains a colon-separated set of paths for the perl
|
||||
binary to search for additional library files or modules.
|
||||
These directories will be tacked to the end of @INC.
|
||||
Perl will automatically search below each path for version-
|
||||
and architecture-specific directories. See inc_version_list
|
||||
for more details.
|
||||
A value of ' ' means 'none' and is used to preserve this value
|
||||
for the next run through Configure.
|
||||
|
||||
package (package.U):
|
||||
This variable contains the name of the package being constructed.
|
||||
It is primarily intended for the use of later Configure units.
|
||||
@ -2792,6 +2940,10 @@ PERL_VERSION (Oldsyms.U):
|
||||
perladmin (perladmin.U):
|
||||
Electronic mail address of the perl5 administrator.
|
||||
|
||||
perllibs (End.U):
|
||||
The list of libraries needed by Perl only (any libraries needed
|
||||
by extensions only will by dropped, if using dynamic loading).
|
||||
|
||||
perlpath (perlpath.U):
|
||||
This variable contains the eventual value of the PERLPATH symbol,
|
||||
which contains the name of the perl interpreter to be used in
|
||||
@ -3036,6 +3188,10 @@ sig_num_init (sig_name.U):
|
||||
below. A "ZERO" is prepended to the list, and the list is
|
||||
terminated with a plain 0.
|
||||
|
||||
sig_size (sig_name.U):
|
||||
This variable contains the number of elements of the sig_name
|
||||
and sig_num arrays, excluding the final NULL entry.
|
||||
|
||||
signal_t (d_voidsig.U):
|
||||
This variable holds the type of the signal handler (void or int).
|
||||
|
||||
@ -3114,11 +3270,6 @@ smail (Loc.U):
|
||||
This variable is defined but not used by Configure.
|
||||
The value is a plain '' and is not useful.
|
||||
|
||||
small (models.U):
|
||||
This variable contains a flag which will tell the C compiler and loader
|
||||
to produce a program running with a small memory model. It is up to
|
||||
the Makefile to use this.
|
||||
|
||||
so (so.U):
|
||||
This variable holds the extension used to identify shared libraries
|
||||
(also known as shared objects) on the system. Usually set to 'so'.
|
||||
@ -3148,12 +3299,6 @@ spitshell (spitshell.U):
|
||||
This variable contains the command necessary to spit out a runnable
|
||||
shell on this system. It is either cat or a grep '-v' for # comments.
|
||||
|
||||
split (models.U):
|
||||
This variable contains a flag which will tell the C compiler and loader
|
||||
to produce a program that will run in separate I and D space, for those
|
||||
machines that support separation of instruction and data space. It is
|
||||
up to the Makefile to use this.
|
||||
|
||||
sPRId64 (quadfio.U):
|
||||
This variable, if defined, contains the string used by stdio to
|
||||
format 64-bit decimal numbers (format 'd') for output.
|
||||
@ -3162,25 +3307,31 @@ sPRIeldbl (longdblfio.U):
|
||||
This variable, if defined, contains the string used by stdio to
|
||||
format long doubles (format 'e') for output.
|
||||
|
||||
sPRIEldbl (longdblfio.U):
|
||||
sPRIEUldbl (longdblfio.U):
|
||||
This variable, if defined, contains the string used by stdio to
|
||||
format long doubles (format 'E') for output.
|
||||
The 'U' in the name is to separate this from sPRIeldbl so that even
|
||||
case-blind systems can see the difference.
|
||||
|
||||
sPRIfldbl (longdblfio.U):
|
||||
This variable, if defined, contains the string used by stdio to
|
||||
format long doubles (format 'f') for output.
|
||||
|
||||
sPRIFldbl (longdblfio.U):
|
||||
sPRIFUldbl (longdblfio.U):
|
||||
This variable, if defined, contains the string used by stdio to
|
||||
format long doubles (format 'F') for output.
|
||||
The 'U' in the name is to separate this from sPRIfldbl so that even
|
||||
case-blind systems can see the difference.
|
||||
|
||||
sPRIgldbl (longdblfio.U):
|
||||
This variable, if defined, contains the string used by stdio to
|
||||
format long doubles (format 'g') for output.
|
||||
|
||||
sPRIGldbl (longdblfio.U):
|
||||
sPRIGUldbl (longdblfio.U):
|
||||
This variable, if defined, contains the string used by stdio to
|
||||
format long doubles (format 'G') for output.
|
||||
The 'U' in the name is to separate this from sPRIgldbl so that even
|
||||
case-blind systems can see the difference.
|
||||
|
||||
sPRIi64 (quadfio.U):
|
||||
This variable, if defined, contains the string used by stdio to
|
||||
@ -3198,15 +3349,21 @@ sPRIx64 (quadfio.U):
|
||||
This variable, if defined, contains the string used by stdio to
|
||||
format 64-bit hexadecimal numbers (format 'x') for output.
|
||||
|
||||
sPRIX64 (quadfio.U):
|
||||
sPRIXU64 (quadfio.U):
|
||||
This variable, if defined, contains the string used by stdio to
|
||||
format 64-bit hExADECimAl numbers (format 'X') for output.
|
||||
The 'U' in the name is to separate this from sPRIx64 so that even
|
||||
case-blind systems can see the difference.
|
||||
|
||||
src (src.U):
|
||||
This variable holds the path to the package source. It is up to
|
||||
the Makefile to use this variable and set VPATH accordingly to
|
||||
find the sources remotely.
|
||||
|
||||
sSCNfldbl (longdblfio.U):
|
||||
This variable, if defined, contains the string used by stdio to
|
||||
format long doubles (format 'f') for input.
|
||||
|
||||
ssizetype (ssizetype.U):
|
||||
This variable defines ssizetype to be something like ssize_t,
|
||||
long or int. It is used by functions that return a count
|
||||
@ -3521,7 +3678,11 @@ uvuformat (perlxvf.U):
|
||||
|
||||
uvxformat (perlxvf.U):
|
||||
This variable contains the format string used for printing
|
||||
a Perl UV as an unsigned hexadecimal integer.
|
||||
a Perl UV as an unsigned hexadecimal integer in lowercase abcdef.
|
||||
|
||||
uvXUformat (perlxvf.U):
|
||||
This variable contains the format string used for printing
|
||||
a Perl UV as an unsigned hexadecimal integer in uppercase ABCDEF.
|
||||
|
||||
vendorarch (vendorarch.U):
|
||||
This variable contains the value of the PERL_VENDORARCH symbol.
|
||||
@ -3583,6 +3744,18 @@ version (patchlevel.U):
|
||||
This is suitable for use as a directory name, and hence is
|
||||
filesystem dependent.
|
||||
|
||||
versiononly (versiononly.U):
|
||||
If set, this symbol indicates that only the version-specific
|
||||
components of a perl installation should be installed.
|
||||
This may be useful for making a test installation of a new
|
||||
version without disturbing the existing installation.
|
||||
Setting versiononly is equivalent to setting installperl's -v option.
|
||||
In particular, the non-versioned scripts and programs such as
|
||||
a2p, c2ph, h2xs, pod2*, and perldoc are not installed
|
||||
(see INSTALL for a more complete list). Nor are the man
|
||||
pages installed.
|
||||
Usually, this is undef.
|
||||
|
||||
vi (Loc.U):
|
||||
This variable is defined but not used by Configure.
|
||||
The value is a plain '' and is not useful.
|
||||
|
@ -8,7 +8,7 @@
|
||||
|
||||
# Package name : perl5
|
||||
# Source directory : .
|
||||
# Configuration time: Tue Mar 21 23:22:20 EET 2000
|
||||
# Configuration time: Sat Mar 3 01:13:55 EET 2001
|
||||
# Configured by : jhi
|
||||
# Target system : osf1 alpha.hut.fi v4.0 878 alpha
|
||||
|
||||
@ -35,10 +35,10 @@ api_subversion='0'
|
||||
api_version='5'
|
||||
api_versionstring='5.005'
|
||||
ar='ar'
|
||||
archlib='/opt/perl/lib/5.6.0/alpha-dec_osf-thread-multi'
|
||||
archlibexp='/opt/perl/lib/5.6.0/alpha-dec_osf-thread-multi'
|
||||
archlib='/opt/perl/lib/5.6.1/alpha-dec_osf-thread'
|
||||
archlibexp='/opt/perl/lib/5.6.1/alpha-dec_osf-thread'
|
||||
archname64=''
|
||||
archname='alpha-dec_osf-thread-multi'
|
||||
archname='alpha-dec_osf-thread'
|
||||
archobjs=''
|
||||
awk='awk'
|
||||
baserev='5.0'
|
||||
@ -46,7 +46,7 @@ bash=''
|
||||
bin='/opt/perl/bin'
|
||||
bincompat5005='undef'
|
||||
binexp='/opt/perl/bin'
|
||||
bison=''
|
||||
bison='bison'
|
||||
byacc='byacc'
|
||||
byteorder='12345678'
|
||||
c='\c'
|
||||
@ -54,12 +54,15 @@ castflags='0'
|
||||
cat='cat'
|
||||
cc='cc'
|
||||
cccdlflags=' '
|
||||
ccdlflags=' -Wl,-rpath,/opt/perl/lib/5.6.0/alpha-dec_osf-thread-multi/CORE'
|
||||
ccdlflags=' -Wl,-rpath,/opt/perl/lib/5.6.1/alpha-dec_osf-thread/CORE'
|
||||
ccflags='-pthread -std -DLANGUAGE_C'
|
||||
ccflags_uselargefiles=''
|
||||
ccname='cc'
|
||||
ccsymbols='__alpha=1 __LANGUAGE_C__=1 __osf__=1 __unix__=1 _LONGLONG=1 _SYSTYPE_BSD=1 SYSTYPE_BSD=1 unix=1'
|
||||
ccversion='V5.6-082'
|
||||
cf_by='jhi'
|
||||
cf_email='yourname@yourhost.yourplace.com'
|
||||
cf_time='Tue Mar 21 23:22:20 EET 2000'
|
||||
cf_time='Sat Mar 3 01:13:55 EET 2001'
|
||||
charsize='1'
|
||||
chgrp=''
|
||||
chmod=''
|
||||
@ -83,10 +86,10 @@ crosscompile='undef'
|
||||
cryptlib=''
|
||||
csh='csh'
|
||||
d_Gconvert='gcvt((x),(n),(b))'
|
||||
d_PRIEldbl='define'
|
||||
d_PRIFldbl='define'
|
||||
d_PRIGldbl='define'
|
||||
d_PRIX64='define'
|
||||
d_PRIEUldbl='define'
|
||||
d_PRIFUldbl='define'
|
||||
d_PRIGUldbl='define'
|
||||
d_PRIXU64='define'
|
||||
d_PRId64='define'
|
||||
d_PRIeldbl='define'
|
||||
d_PRIfldbl='define'
|
||||
@ -95,6 +98,8 @@ d_PRIi64='define'
|
||||
d_PRIo64='define'
|
||||
d_PRIu64='define'
|
||||
d_PRIx64='define'
|
||||
d_SCNfldbl='define'
|
||||
d__fwalk='undef'
|
||||
d_access='define'
|
||||
d_accessx='undef'
|
||||
d_alarm='define'
|
||||
@ -136,12 +141,12 @@ d_endnent='define'
|
||||
d_endpent='define'
|
||||
d_endpwent='define'
|
||||
d_endsent='define'
|
||||
d_endspent='undef'
|
||||
d_eofnblk='define'
|
||||
d_eunice='undef'
|
||||
d_fchmod='define'
|
||||
d_fchown='define'
|
||||
d_fcntl='define'
|
||||
d_fcntl_can_lock='define'
|
||||
d_fd_macros='define'
|
||||
d_fd_set='define'
|
||||
d_fds_bits='define'
|
||||
@ -151,14 +156,17 @@ d_flock='define'
|
||||
d_fork='define'
|
||||
d_fpathconf='define'
|
||||
d_fpos64_t='undef'
|
||||
d_frexpl='define'
|
||||
d_fs_data_s='undef'
|
||||
d_fseeko='undef'
|
||||
d_fsetpos='define'
|
||||
d_fstatfs='define'
|
||||
d_fstatvfs='define'
|
||||
d_fsync='define'
|
||||
d_ftello='undef'
|
||||
d_ftime='undef'
|
||||
d_getcwd='define'
|
||||
d_getespwnam='undef'
|
||||
d_getfsstat='define'
|
||||
d_getgrent='define'
|
||||
d_getgrps='define'
|
||||
@ -174,6 +182,7 @@ d_getnbyaddr='define'
|
||||
d_getnbyname='define'
|
||||
d_getnent='define'
|
||||
d_getnetprotos='define'
|
||||
d_getpagsz='define'
|
||||
d_getpbyname='define'
|
||||
d_getpbynumber='define'
|
||||
d_getpent='define'
|
||||
@ -183,12 +192,12 @@ d_getpgrp='define'
|
||||
d_getppid='define'
|
||||
d_getprior='define'
|
||||
d_getprotoprotos='define'
|
||||
d_getprpwnam='undef'
|
||||
d_getpwent='define'
|
||||
d_getsbyname='define'
|
||||
d_getsbyport='define'
|
||||
d_getsent='define'
|
||||
d_getservprotos='define'
|
||||
d_getspent='undef'
|
||||
d_getspnam='undef'
|
||||
d_gettimeod='define'
|
||||
d_gnulibc='undef'
|
||||
@ -200,6 +209,8 @@ d_index='undef'
|
||||
d_inetaton='define'
|
||||
d_int64_t='undef'
|
||||
d_isascii='define'
|
||||
d_isnan='define'
|
||||
d_isnanl='define'
|
||||
d_killpg='define'
|
||||
d_lchown='define'
|
||||
d_ldbl_dig='define'
|
||||
@ -226,6 +237,7 @@ d_mkstemp='define'
|
||||
d_mkstemps='undef'
|
||||
d_mktime='define'
|
||||
d_mmap='define'
|
||||
d_modfl='define'
|
||||
d_mprotect='define'
|
||||
d_msg='define'
|
||||
d_msg_ctrunc='define'
|
||||
@ -242,6 +254,7 @@ d_munmap='define'
|
||||
d_mymalloc='undef'
|
||||
d_nice='define'
|
||||
d_nv_preserves_uv='undef'
|
||||
d_nv_preserves_uv_bits='53'
|
||||
d_off64_t='undef'
|
||||
d_old_pthread_create_joinable='undef'
|
||||
d_oldpthreads='undef'
|
||||
@ -249,6 +262,7 @@ d_oldsock='undef'
|
||||
d_open3='define'
|
||||
d_pathconf='define'
|
||||
d_pause='define'
|
||||
d_perl_otherlibdirs='undef'
|
||||
d_phostname='undef'
|
||||
d_pipe='define'
|
||||
d_poll='define'
|
||||
@ -272,6 +286,7 @@ d_rmdir='define'
|
||||
d_safebcpy='define'
|
||||
d_safemcpy='undef'
|
||||
d_sanemcmp='define'
|
||||
d_sbrkproto='define'
|
||||
d_sched_yield='define'
|
||||
d_scm_rights='define'
|
||||
d_seekdir='define'
|
||||
@ -295,6 +310,7 @@ d_setpgid='define'
|
||||
d_setpgrp2='undef'
|
||||
d_setpgrp='define'
|
||||
d_setprior='define'
|
||||
d_setproctitle='undef'
|
||||
d_setpwent='define'
|
||||
d_setregid='define'
|
||||
d_setresgid='undef'
|
||||
@ -304,7 +320,6 @@ d_setrgid='define'
|
||||
d_setruid='define'
|
||||
d_setsent='define'
|
||||
d_setsid='define'
|
||||
d_setspent='undef'
|
||||
d_setvbuf='define'
|
||||
d_sfio='undef'
|
||||
d_shm='define'
|
||||
@ -318,6 +333,7 @@ d_sigsetjmp='define'
|
||||
d_socket='define'
|
||||
d_socklen_t='undef'
|
||||
d_sockpair='define'
|
||||
d_socks5_init='undef'
|
||||
d_sqrtl='define'
|
||||
d_statblks='define'
|
||||
d_statfs_f_flags='define'
|
||||
@ -325,6 +341,8 @@ d_statfs_s='define'
|
||||
d_statvfs='define'
|
||||
d_stdio_cnt_lval='define'
|
||||
d_stdio_ptr_lval='define'
|
||||
d_stdio_ptr_lval_nochange_cnt='define'
|
||||
d_stdio_ptr_lval_sets_cnt='undef'
|
||||
d_stdio_stream_array='define'
|
||||
d_stdiobase='define'
|
||||
d_stdstdio='define'
|
||||
@ -404,6 +422,7 @@ freetype='void'
|
||||
full_ar='/usr/bin/ar'
|
||||
full_csh='/usr/bin/csh'
|
||||
full_sed='/usr/bin/sed'
|
||||
gccosandvers=''
|
||||
gccversion=''
|
||||
gidformat='"u"'
|
||||
gidsign='1'
|
||||
@ -418,7 +437,6 @@ h_fcntl='false'
|
||||
h_sysfile='true'
|
||||
hint='recommended'
|
||||
hostcat='cat /etc/hosts'
|
||||
huge=''
|
||||
i16size='2'
|
||||
i16type='short'
|
||||
i32size='4'
|
||||
@ -441,6 +459,7 @@ i_grp='define'
|
||||
i_iconv='define'
|
||||
i_ieeefp='undef'
|
||||
i_inttypes='undef'
|
||||
i_libutil='undef'
|
||||
i_limits='define'
|
||||
i_locale='define'
|
||||
i_machcthr='undef'
|
||||
@ -454,6 +473,7 @@ i_neterrno='undef'
|
||||
i_netinettcp='define'
|
||||
i_niin='define'
|
||||
i_poll='define'
|
||||
i_prot='define'
|
||||
i_pthread='define'
|
||||
i_pwd='define'
|
||||
i_rpcsvcdbm='undef'
|
||||
@ -509,44 +529,46 @@ inc_version_list=' '
|
||||
inc_version_list_init='0'
|
||||
incpath=''
|
||||
inews=''
|
||||
installarchlib='/opt/perl/lib/5.6.0/alpha-dec_osf-thread-multi'
|
||||
installarchlib='/opt/perl/lib/5.6.1/alpha-dec_osf-thread'
|
||||
installbin='/opt/perl/bin'
|
||||
installman1dir='/opt/perl/man/man1'
|
||||
installman3dir='/opt/perl/man/man3'
|
||||
installprefix='/opt/perl'
|
||||
installprefixexp='/opt/perl'
|
||||
installprivlib='/opt/perl/lib/5.6.0'
|
||||
installprivlib='/opt/perl/lib/5.6.1'
|
||||
installscript='/opt/perl/bin'
|
||||
installsitearch='/opt/perl/lib/site_perl/5.6.0/alpha-dec_osf-thread-multi'
|
||||
installsitearch='/opt/perl/lib/site_perl/5.6.1/alpha-dec_osf-thread'
|
||||
installsitebin='/opt/perl/bin'
|
||||
installsitelib='/opt/perl/lib/site_perl/5.6.0'
|
||||
installsitelib='/opt/perl/lib/site_perl/5.6.1'
|
||||
installstyle='lib'
|
||||
installusrbinperl='define'
|
||||
installvendorarch=''
|
||||
installvendorbin=''
|
||||
installvendorlib=''
|
||||
intsize='4'
|
||||
issymlink='-h'
|
||||
ivdformat='"ld"'
|
||||
ivsize='8'
|
||||
ivtype='long'
|
||||
known_extensions='B ByteLoader DB_File Data/Dumper Devel/DProf Devel/Peek Fcntl File/Glob GDBM_File IO IPC/SysV NDBM_File ODBM_File Opcode POSIX SDBM_File Socket Sys/Hostname Sys/Syslog Thread attrs re'
|
||||
ksh=''
|
||||
large=''
|
||||
ld='ld'
|
||||
lddlflags='-shared -expect_unresolved "*" -msym -std -s'
|
||||
ldflags=''
|
||||
ldflags_uselargefiles=''
|
||||
ldlibpthname='LD_LIBRARY_PATH'
|
||||
less='less'
|
||||
lib_ext='.a'
|
||||
libc='/usr/shlib/libc.so'
|
||||
libperl='libperl.so'
|
||||
libpth='/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /var/shlib'
|
||||
libs='-lgdbm -ldbm -ldb -lm -liconv -lpthread -lexc'
|
||||
libs='-lgdbm -ldbm -ldb -lm -liconv -lutil -lpthread -lexc'
|
||||
libsdirs=' /usr/shlib /usr/ccs/lib'
|
||||
libsfiles=' libgdbm.so libdbm.a libdb.so libm.so libiconv.so libpthread.so libexc.so'
|
||||
libsfound=' /usr/shlib/libgdbm.so /usr/ccs/lib/libdbm.a /usr/shlib/libdb.so /usr/shlib/libm.so /usr/shlib/libiconv.so /usr/shlib/libpthread.so /usr/shlib/libexc.so'
|
||||
libsfiles=' libgdbm.so libdbm.a libdb.so libm.so libiconv.so libutil.a libpthread.so libexc.so'
|
||||
libsfound=' /usr/shlib/libgdbm.so /usr/ccs/lib/libdbm.a /usr/shlib/libdb.so /usr/shlib/libm.so /usr/shlib/libiconv.so /usr/ccs/lib/libutil.a /usr/shlib/libpthread.so /usr/shlib/libexc.so'
|
||||
libspath=' /usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /var/shlib'
|
||||
libswanted='sfio socket bind inet nsl nm gdbm dbm db malloc dld ld sun m cposix posix ndir dir crypt sec ucb BSD x iconv pthread exc'
|
||||
libswanted='sfio socket bind inet nsl nm gdbm dbm db malloc dld ld sun m cposix posix ndir dir crypt sec ucb BSD x iconv util pthread exc'
|
||||
libswanted_uselargefiles=''
|
||||
line=''
|
||||
lint=''
|
||||
lkflags=''
|
||||
@ -575,11 +597,9 @@ man1ext='1'
|
||||
man3dir='/opt/perl/man/man3'
|
||||
man3direxp='/opt/perl/man/man3'
|
||||
man3ext='3'
|
||||
medium=''
|
||||
mips_type=''
|
||||
mkdir='mkdir'
|
||||
mmaptype='void *'
|
||||
models='none'
|
||||
modetype='mode_t'
|
||||
more='more'
|
||||
multiarch='undef'
|
||||
@ -598,6 +618,12 @@ nm_opt='-p'
|
||||
nm_so_opt=''
|
||||
nonxs_ext='Errno'
|
||||
nroff='nroff'
|
||||
nvEUformat='"E"'
|
||||
nvFUformat='"F"'
|
||||
nvGUformat='"G"'
|
||||
nveformat='"e"'
|
||||
nvfformat='"f"'
|
||||
nvgformat='"g"'
|
||||
nvsize='8'
|
||||
nvtype='double'
|
||||
o_nonblock='O_NONBLOCK'
|
||||
@ -607,6 +633,7 @@ optimize='-O'
|
||||
orderlib='false'
|
||||
osname='dec_osf'
|
||||
osvers='4.0'
|
||||
otherlibdirs=' '
|
||||
package='perl5'
|
||||
pager='/c/bin/less'
|
||||
passcat='cat /etc/passwd'
|
||||
@ -615,6 +642,7 @@ path_sep=':'
|
||||
perl5='/u/vieraat/vieraat/jhi/Perl/bin/perl'
|
||||
perl=''
|
||||
perladmin='yourname@yourhost.yourplace.com'
|
||||
perllibs='-lm -liconv -lutil -lpthread -lexc'
|
||||
perlpath='/opt/perl/bin/perl'
|
||||
pg='pg'
|
||||
phostname=''
|
||||
@ -625,8 +653,8 @@ pmake=''
|
||||
pr=''
|
||||
prefix='/opt/perl'
|
||||
prefixexp='/opt/perl'
|
||||
privlib='/opt/perl/lib/5.6.0'
|
||||
privlibexp='/opt/perl/lib/5.6.0'
|
||||
privlib='/opt/perl/lib/5.6.1'
|
||||
privlibexp='/opt/perl/lib/5.6.1'
|
||||
prototype='define'
|
||||
ptrsize='8'
|
||||
quadkind='2'
|
||||
@ -640,10 +668,10 @@ revision='5'
|
||||
rm='rm'
|
||||
rmail=''
|
||||
runnm='true'
|
||||
sPRIEldbl='"E"'
|
||||
sPRIFldbl='"F"'
|
||||
sPRIGldbl='"G"'
|
||||
sPRIX64='"lX"'
|
||||
sPRIEUldbl='"E"'
|
||||
sPRIFUldbl='"F"'
|
||||
sPRIGUldbl='"G"'
|
||||
sPRIXU64='"lX"'
|
||||
sPRId64='"ld"'
|
||||
sPRIeldbl='"e"'
|
||||
sPRIfldbl='"f"'
|
||||
@ -652,6 +680,7 @@ sPRIi64='"li"'
|
||||
sPRIo64='"lo"'
|
||||
sPRIu64='"lu"'
|
||||
sPRIx64='"lx"'
|
||||
sSCNfldbl='"f"'
|
||||
sched_yield='sched_yield()'
|
||||
scriptdir='/opt/perl/bin'
|
||||
scriptdirexp='/opt/perl/bin'
|
||||
@ -673,20 +702,19 @@ sig_name_init='"ZERO", "HUP", "INT", "QUIT", "ILL", "TRAP", "ABRT", "EMT", "FPE"
|
||||
sig_num='0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 6 6 16 20 23 23 23 29 48 '
|
||||
sig_num_init='0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 6, 6, 16, 20, 23, 23, 23, 29, 48, 0'
|
||||
signal_t='void'
|
||||
sitearch='/opt/perl/lib/site_perl/5.6.0/alpha-dec_osf-thread-multi'
|
||||
sitearchexp='/opt/perl/lib/site_perl/5.6.0/alpha-dec_osf-thread-multi'
|
||||
sitearch='/opt/perl/lib/site_perl/5.6.1/alpha-dec_osf-thread'
|
||||
sitearchexp='/opt/perl/lib/site_perl/5.6.1/alpha-dec_osf-thread'
|
||||
sitebin='/opt/perl/bin'
|
||||
sitebinexp='/opt/perl/bin'
|
||||
sitelib='/opt/perl/lib/site_perl/5.6.0'
|
||||
sitelib='/opt/perl/lib/site_perl/5.6.1'
|
||||
sitelib_stem='/opt/perl/lib/site_perl'
|
||||
sitelibexp='/opt/perl/lib/site_perl/5.6.0'
|
||||
sitelibexp='/opt/perl/lib/site_perl/5.6.1'
|
||||
siteprefix='/opt/perl'
|
||||
siteprefixexp='/opt/perl'
|
||||
sizesize='8'
|
||||
sizetype='size_t'
|
||||
sleep=''
|
||||
smail=''
|
||||
small=''
|
||||
so='so'
|
||||
sockethdr=''
|
||||
socketlib=''
|
||||
@ -694,8 +722,7 @@ socksizetype='int'
|
||||
sort='sort'
|
||||
spackage='Perl5'
|
||||
spitshell='cat'
|
||||
split=''
|
||||
src='.'
|
||||
src='/m/fs/work/work/permanent/perl/pp4/maint-5.6/perl'
|
||||
ssizetype='ssize_t'
|
||||
startperl='#!/opt/perl/bin/perl'
|
||||
startsh='#!/bin/sh'
|
||||
@ -709,7 +736,7 @@ stdio_ptr='((fp)->_ptr)'
|
||||
stdio_stream_array='_iob'
|
||||
strings='/usr/include/string.h'
|
||||
submit=''
|
||||
subversion='0'
|
||||
subversion='1'
|
||||
sysman='/usr/man/man1'
|
||||
tail=''
|
||||
tar=''
|
||||
@ -737,15 +764,15 @@ uidtype='uid_t'
|
||||
uname='uname'
|
||||
uniq='uniq'
|
||||
uquadtype='unsigned long'
|
||||
use5005threads='undef'
|
||||
use5005threads='define'
|
||||
use64bitall='define'
|
||||
use64bitint='define'
|
||||
usedl='define'
|
||||
useithreads='define'
|
||||
useithreads='undef'
|
||||
uselargefiles='define'
|
||||
uselongdouble='undef'
|
||||
usemorebits='undef'
|
||||
usemultiplicity='define'
|
||||
usemultiplicity='undef'
|
||||
usemymalloc='n'
|
||||
usenm='true'
|
||||
useopcode='true'
|
||||
@ -759,6 +786,7 @@ usevendorprefix='undef'
|
||||
usevfork='false'
|
||||
usrinc='/usr/include'
|
||||
uuname=''
|
||||
uvXUformat='"lX"'
|
||||
uvoformat='"lo"'
|
||||
uvsize='8'
|
||||
uvtype='unsigned long'
|
||||
@ -773,31 +801,36 @@ vendorlib_stem=''
|
||||
vendorlibexp=''
|
||||
vendorprefix=''
|
||||
vendorprefixexp=''
|
||||
version='5.6.0'
|
||||
version='5.6.1'
|
||||
versiononly='undef'
|
||||
vi=''
|
||||
voidflags='15'
|
||||
xlibpth='/usr/lib/386 /lib/386'
|
||||
xs_apiversion='5.6.0'
|
||||
xs_apiversion='5.6.1'
|
||||
yacc='/u/vieraat/vieraat/jhi/Perl/bin/byacc'
|
||||
yaccflags=''
|
||||
zcat=''
|
||||
zip='zip'
|
||||
# Configure command line arguments.
|
||||
config_arg0='Configure'
|
||||
config_args='-Dprefix=/opt/perl -Doptimize=-O -Dusethreads -Duse64bitint -Duselargefiles -Dcf_by=yourname -Dcf_email=yourname@yourhost.yourplace.com -Dperladmin=yourname@yourhost.yourplace.com -Dmydomain=.yourplace.com -Dmyhostname=yourhost -dE'
|
||||
config_argc=11
|
||||
config_arg0='./Configure'
|
||||
config_args='-Dprefix=/opt/perl -Doptimize=-O -Dusethreads -Duse5005threads -Duse64bitint -Duselargefiles -Dcf_by=yourname -Dcf_email=yourname@yourhost.yourplace.com -Dperladmin=yourname@yourhost.yourplace.com -Dmydomain=.yourplace.com -Dmyhostname=yourhost -dE -Dusedevel'
|
||||
config_argc=13
|
||||
config_arg1='-Dprefix=/opt/perl'
|
||||
config_arg2='-Doptimize=-O'
|
||||
config_arg3='-Dusethreads'
|
||||
config_arg4='-Duse64bitint'
|
||||
config_arg5='-Duselargefiles'
|
||||
config_arg6='-Dcf_by=yourname'
|
||||
config_arg7='-Dcf_email=yourname@yourhost.yourplace.com'
|
||||
config_arg8='-Dperladmin=yourname@yourhost.yourplace.com'
|
||||
config_arg9='-Dmydomain=.yourplace.com'
|
||||
config_arg10='-Dmyhostname=yourhost'
|
||||
config_arg11='-dE'
|
||||
config_arg4='-Duse5005threads'
|
||||
config_arg5='-Duse64bitint'
|
||||
config_arg6='-Duselargefiles'
|
||||
config_arg7='-Dcf_by=yourname'
|
||||
config_arg8='-Dcf_email=yourname@yourhost.yourplace.com'
|
||||
config_arg9='-Dperladmin=yourname@yourhost.yourplace.com'
|
||||
config_arg10='-Dmydomain=.yourplace.com'
|
||||
config_arg11='-Dmyhostname=yourhost'
|
||||
config_arg12='-dE'
|
||||
config_arg13='-Dusedevel'
|
||||
PERL_REVISION=5
|
||||
PERL_VERSION=6
|
||||
PERL_SUBVERSION=0
|
||||
PERL_SUBVERSION=1
|
||||
PERL_API_REVISION=5
|
||||
PERL_API_VERSION=5
|
||||
PERL_API_SUBVERSION=0
|
||||
|
@ -17,7 +17,7 @@
|
||||
/*
|
||||
* Package name : perl5
|
||||
* Source directory : .
|
||||
* Configuration time: Tue Mar 21 23:22:20 EET 2000
|
||||
* Configuration time: Sat Mar 3 01:13:55 EET 2001
|
||||
* Configured by : jhi
|
||||
* Target system : osf1 alpha.hut.fi v4.0 878 alpha
|
||||
*/
|
||||
@ -224,17 +224,6 @@
|
||||
*/
|
||||
#define HAS_GETPGID /**/
|
||||
|
||||
/* HAS_GETPGRP:
|
||||
* This symbol, if defined, indicates that the getpgrp routine is
|
||||
* available to get the current process group.
|
||||
*/
|
||||
/* USE_BSD_GETPGRP:
|
||||
* This symbol, if defined, indicates that getpgrp needs one
|
||||
* arguments whereas USG one needs none.
|
||||
*/
|
||||
#define HAS_GETPGRP /**/
|
||||
/*#define USE_BSD_GETPGRP / **/
|
||||
|
||||
/* HAS_GETPGRP2:
|
||||
* This symbol, if defined, indicates that the getpgrp2() (as in DG/UX)
|
||||
* routine is available to get the current process group.
|
||||
@ -489,18 +478,6 @@
|
||||
*/
|
||||
#define HAS_SETPGID /**/
|
||||
|
||||
/* HAS_SETPGRP:
|
||||
* This symbol, if defined, indicates that the setpgrp routine is
|
||||
* available to set the current process group.
|
||||
*/
|
||||
/* USE_BSD_SETPGRP:
|
||||
* This symbol, if defined, indicates that setpgrp needs two
|
||||
* arguments whereas USG one needs none. See also HAS_SETPGID
|
||||
* for a POSIX interface.
|
||||
*/
|
||||
#define HAS_SETPGRP /**/
|
||||
#define USE_BSD_SETPGRP /**/
|
||||
|
||||
/* HAS_SETPGRP2:
|
||||
* This symbol, if defined, indicates that the setpgrp2() (as in DG/UX)
|
||||
* routine is available to set the current process group.
|
||||
@ -984,12 +961,6 @@
|
||||
*/
|
||||
#define SH_PATH "/bin/sh" /**/
|
||||
|
||||
/* STDCHAR:
|
||||
* This symbol is defined to be the type of char used in stdio.h.
|
||||
* It has the values "unsigned char" or "char".
|
||||
*/
|
||||
#define STDCHAR unsigned char /**/
|
||||
|
||||
/* CROSSCOMPILE:
|
||||
* This symbol, if defined, signifies that we our
|
||||
* build process is a cross-compilation.
|
||||
@ -1092,8 +1063,8 @@
|
||||
* This symbol contains the ~name expanded version of ARCHLIB, to be used
|
||||
* in programs that are not prepared to deal with ~ expansion at run-time.
|
||||
*/
|
||||
#define ARCHLIB "/opt/perl/lib/5.6.0/alpha-dec_osf-thread-multi" /**/
|
||||
#define ARCHLIB_EXP "/opt/perl/lib/5.6.0/alpha-dec_osf-thread-multi" /**/
|
||||
#define ARCHLIB "/opt/perl/lib/5.6.1/alpha-dec_osf-thread" /**/
|
||||
#define ARCHLIB_EXP "/opt/perl/lib/5.6.1/alpha-dec_osf-thread" /**/
|
||||
|
||||
/* ARCHNAME:
|
||||
* This symbol holds a string representing the architecture name.
|
||||
@ -1101,7 +1072,7 @@
|
||||
* where library files may be held under a private library, for
|
||||
* instance.
|
||||
*/
|
||||
#define ARCHNAME "alpha-dec_osf-thread-multi" /**/
|
||||
#define ARCHNAME "alpha-dec_osf-thread" /**/
|
||||
|
||||
/* HAS_ATOLF:
|
||||
* This symbol, if defined, indicates that the atolf routine is
|
||||
@ -1184,21 +1155,21 @@
|
||||
* This macro surrounds its token with double quotes.
|
||||
*/
|
||||
#if 42 == 1
|
||||
# define CAT2(a,b) a/**/b
|
||||
# define STRINGIFY(a) "a"
|
||||
#define CAT2(a,b) a/**/b
|
||||
#define STRINGIFY(a) "a"
|
||||
/* If you can get stringification with catify, tell me how! */
|
||||
#endif
|
||||
#if 42 == 42
|
||||
# define PeRl_CaTiFy(a, b) a ## b
|
||||
# define PeRl_StGiFy(a) #a
|
||||
#define PeRl_CaTiFy(a, b) a ## b
|
||||
#define PeRl_StGiFy(a) #a
|
||||
/* the additional level of indirection enables these macros to be
|
||||
* used as arguments to other macros. See K&R 2nd ed., page 231. */
|
||||
# define CAT2(a,b) PeRl_CaTiFy(a,b)
|
||||
# define StGiFy(a) PeRl_StGiFy(a)
|
||||
# define STRINGIFY(a) PeRl_StGiFy(a)
|
||||
#define CAT2(a,b) PeRl_CaTiFy(a,b)
|
||||
#define StGiFy(a) PeRl_StGiFy(a)
|
||||
#define STRINGIFY(a) PeRl_StGiFy(a)
|
||||
#endif
|
||||
#if 42 != 1 && 42 != 42
|
||||
#include "Bletch: How does this C preprocessor catenate tokens?"
|
||||
# include "Bletch: How does this C preprocessor catenate tokens?"
|
||||
#endif
|
||||
|
||||
/* CPPSTDIN:
|
||||
@ -1328,23 +1299,30 @@
|
||||
*/
|
||||
#define HAS_ENDSERVENT /**/
|
||||
|
||||
/* HAS_ENDSPENT:
|
||||
* This symbol, if defined, indicates that the endspent system call is
|
||||
* available to finalize the scan of SysV shadow password entries.
|
||||
*/
|
||||
/*#define HAS_ENDSPENT / **/
|
||||
|
||||
/* HAS_FD_SET:
|
||||
* This symbol, when defined, indicates presence of the fd_set typedef
|
||||
* in <sys/types.h>
|
||||
*/
|
||||
#define HAS_FD_SET /**/
|
||||
|
||||
/* FLEXFILENAMES:
|
||||
* This symbol, if defined, indicates that the system supports filenames
|
||||
* longer than 14 characters.
|
||||
*/
|
||||
#define FLEXFILENAMES /**/
|
||||
|
||||
/* HAS_FPOS64_T:
|
||||
* This symbol will be defined if the C compiler supports fpos64_t.
|
||||
*/
|
||||
/*#define HAS_FPOS64_T / **/
|
||||
|
||||
/* HAS_FREXPL:
|
||||
* This symbol, if defined, indicates that the frexpl routine is
|
||||
* available to break a long double floating-point number into
|
||||
* a normalized fraction and an integral power of 2.
|
||||
*/
|
||||
#define HAS_FREXPL /**/
|
||||
|
||||
/* HAS_STRUCT_FS_DATA:
|
||||
* This symbol, if defined, indicates that the struct fs_data
|
||||
* to do statfs() is supported.
|
||||
@ -1392,6 +1370,12 @@
|
||||
*/
|
||||
#define HAS_GETCWD /**/
|
||||
|
||||
/* HAS_GETESPWNAM:
|
||||
* This symbol, if defined, indicates that the getespwnam system call is
|
||||
* available to retrieve enchanced (shadow) password entries by name.
|
||||
*/
|
||||
/*#define HAS_GETESPWNAM / **/
|
||||
|
||||
/* HAS_GETFSSTAT:
|
||||
* This symbol, if defined, indicates that the getfsstat routine is
|
||||
* available to stat filesystems in bulk.
|
||||
@ -1497,6 +1481,13 @@
|
||||
*/
|
||||
#define HAS_GETNET_PROTOS /**/
|
||||
|
||||
/* HAS_GETPAGESIZE:
|
||||
* This symbol, if defined, indicates that the getpagesize system call
|
||||
* is available to get system page size, which is the granularity of
|
||||
* many memory management calls.
|
||||
*/
|
||||
#define HAS_GETPAGESIZE /**/
|
||||
|
||||
/* HAS_GETPROTOENT:
|
||||
* This symbol, if defined, indicates that the getprotoent() routine is
|
||||
* available to look up protocols in some data base or another.
|
||||
@ -1522,6 +1513,12 @@
|
||||
*/
|
||||
#define HAS_GETPROTO_PROTOS /**/
|
||||
|
||||
/* HAS_GETPRPWNAM:
|
||||
* This symbol, if defined, indicates that the getprpwnam system call is
|
||||
* available to retrieve protected (shadow) password entries by name.
|
||||
*/
|
||||
/*#define HAS_GETPRPWNAM / **/
|
||||
|
||||
/* HAS_GETPWENT:
|
||||
* This symbol, if defined, indicates that the getpwent routine is
|
||||
* available for sequential access of the passwd database.
|
||||
@ -1543,12 +1540,6 @@
|
||||
*/
|
||||
#define HAS_GETSERV_PROTOS /**/
|
||||
|
||||
/* HAS_GETSPENT:
|
||||
* This symbol, if defined, indicates that the getspent system call is
|
||||
* available to retrieve SysV shadow password entries sequentially.
|
||||
*/
|
||||
/*#define HAS_GETSPENT / **/
|
||||
|
||||
/* HAS_GETSPNAM:
|
||||
* This symbol, if defined, indicates that the getspnam system call is
|
||||
* available to retrieve SysV shadow password entries by name.
|
||||
@ -1624,6 +1615,25 @@
|
||||
*/
|
||||
#define HAS_ISASCII /**/
|
||||
|
||||
/* HAS_ISNAN:
|
||||
* This symbol, if defined, indicates that the isnan routine is
|
||||
* available to check whether a double is a NaN.
|
||||
*/
|
||||
#define HAS_ISNAN /**/
|
||||
|
||||
/* HAS_ISNANL:
|
||||
* This symbol, if defined, indicates that the isnanl routine is
|
||||
* available to check whether a long double is a NaN.
|
||||
*/
|
||||
#define HAS_ISNANL /**/
|
||||
|
||||
/* HAS_LCHOWN:
|
||||
* This symbol, if defined, indicates that the lchown routine is
|
||||
* available to operate on a symbolic link (instead of following the
|
||||
* link).
|
||||
*/
|
||||
#define HAS_LCHOWN /**/
|
||||
|
||||
/* HAS_LDBL_DIG:
|
||||
* This symbol, if defined, indicates that this system's <float.h>
|
||||
* or <limits.h> defines the symbol LDBL_DIG, which is the number
|
||||
@ -1711,6 +1721,13 @@
|
||||
#define HAS_MMAP /**/
|
||||
#define Mmap_t void * /**/
|
||||
|
||||
/* HAS_MODFL:
|
||||
* This symbol, if defined, indicates that the modfl routine is
|
||||
* available to split a long double x into a fractional part f and
|
||||
* an integer part i such that |f| < 1.0 and (f + i) = x.
|
||||
*/
|
||||
#define HAS_MODFL /**/
|
||||
|
||||
/* HAS_MPROTECT:
|
||||
* This symbol, if defined, indicates that the mprotect system call is
|
||||
* available to modify the access protection of a memory mapped file.
|
||||
@ -1823,6 +1840,12 @@
|
||||
*/
|
||||
#define HAS_SETPROTOENT /**/
|
||||
|
||||
/* HAS_SETPROCTITLE:
|
||||
* This symbol, if defined, indicates that the setproctitle routine is
|
||||
* available to set process title.
|
||||
*/
|
||||
/*#define HAS_SETPROCTITLE / **/
|
||||
|
||||
/* HAS_SETPWENT:
|
||||
* This symbol, if defined, indicates that the setpwent routine is
|
||||
* available for initializing sequential access of the passwd database.
|
||||
@ -1835,12 +1858,6 @@
|
||||
*/
|
||||
#define HAS_SETSERVENT /**/
|
||||
|
||||
/* HAS_SETSPENT:
|
||||
* This symbol, if defined, indicates that the setspent system call is
|
||||
* available to initialize the scan of SysV shadow password entries.
|
||||
*/
|
||||
/*#define HAS_SETSPENT / **/
|
||||
|
||||
/* HAS_SETVBUF:
|
||||
* This symbol, if defined, indicates that the setvbuf routine is
|
||||
* available to change buffering on an open stdio stream.
|
||||
@ -1944,6 +1961,12 @@
|
||||
/*#define HAS_MSG_PROXY / **/
|
||||
#define HAS_SCM_RIGHTS /**/
|
||||
|
||||
/* HAS_SOCKS5_INIT:
|
||||
* This symbol, if defined, indicates that the socks5_init routine is
|
||||
* available to initialize SOCKS 5.
|
||||
*/
|
||||
/*#define HAS_SOCKS5_INIT / **/
|
||||
|
||||
/* HAS_SQRTL:
|
||||
* This symbol, if defined, indicates that the sqrtl routine is
|
||||
* available to do long double square roots.
|
||||
@ -2006,12 +2029,23 @@
|
||||
* This symbol is defined if the FILE_cnt macro can be used as an
|
||||
* lvalue.
|
||||
*/
|
||||
/* STDIO_PTR_LVAL_SETS_CNT:
|
||||
* This symbol is defined if using the FILE_ptr macro as an lvalue
|
||||
* to increase the pointer by n has the side effect of decreasing the
|
||||
* value of File_cnt(fp) by n.
|
||||
*/
|
||||
/* STDIO_PTR_LVAL_NOCHANGE_CNT:
|
||||
* This symbol is defined if using the FILE_ptr macro as an lvalue
|
||||
* to increase the pointer by n leaves File_cnt(fp) unchanged.
|
||||
*/
|
||||
#define USE_STDIO_PTR /**/
|
||||
#ifdef USE_STDIO_PTR
|
||||
#define FILE_ptr(fp) ((fp)->_ptr)
|
||||
#define STDIO_PTR_LVALUE /**/
|
||||
#define FILE_cnt(fp) ((fp)->_cnt)
|
||||
#define STDIO_CNT_LVALUE /**/
|
||||
/*#define STDIO_PTR_LVAL_SETS_CNT / **/
|
||||
#define STDIO_PTR_LVAL_NOCHANGE_CNT /**/
|
||||
#endif
|
||||
|
||||
/* USE_STDIO_BASE:
|
||||
@ -2279,6 +2313,12 @@
|
||||
*/
|
||||
/*#define I_INTTYPES / **/
|
||||
|
||||
/* I_LIBUTIL:
|
||||
* This symbol, if defined, indicates that <libutil.h> exists and
|
||||
* should be included.
|
||||
*/
|
||||
/*#define I_LIBUTIL / **/
|
||||
|
||||
/* I_MACH_CTHREADS:
|
||||
* This symbol, if defined, indicates to the C program that it should
|
||||
* include <mach/cthreads.h>.
|
||||
@ -2309,6 +2349,12 @@
|
||||
*/
|
||||
#define I_POLL /**/
|
||||
|
||||
/* I_PROT:
|
||||
* This symbol, if defined, indicates that <prot.h> exists and
|
||||
* should be included.
|
||||
*/
|
||||
#define I_PROT /**/
|
||||
|
||||
/* I_PTHREAD:
|
||||
* This symbol, if defined, indicates to the C program that it should
|
||||
* include <pthread.h>.
|
||||
@ -2471,8 +2517,18 @@
|
||||
* This symbol, if defined, contains the string used by stdio to
|
||||
* format long doubles (format 'g') for output.
|
||||
*/
|
||||
/* PERL_PRIeldbl:
|
||||
* This symbol, if defined, contains the string used by stdio to
|
||||
* format long doubles (format 'e') for output.
|
||||
*/
|
||||
/* PERL_SCNfldbl:
|
||||
* This symbol, if defined, contains the string used by stdio to
|
||||
* format long doubles (format 'f') for input.
|
||||
*/
|
||||
#define PERL_PRIfldbl "f" /**/
|
||||
#define PERL_PRIgldbl "g" /**/
|
||||
#define PERL_PRIeldbl "e" /**/
|
||||
#define PERL_SCNfldbl "f" /**/
|
||||
|
||||
/* Off_t:
|
||||
* This symbol holds the type used to declare offsets in the kernel.
|
||||
@ -2560,6 +2616,16 @@
|
||||
#define Netdb_name_t const char * /**/
|
||||
#define Netdb_net_t int /**/
|
||||
|
||||
/* PERL_OTHERLIBDIRS:
|
||||
* This variable contains a colon-separated set of paths for the perl
|
||||
* binary to search for additional library files or modules.
|
||||
* These directories will be tacked to the end of @INC.
|
||||
* Perl will automatically search below each path for version-
|
||||
* and architecture-specific directories. See PERL_INC_VERSION_LIST
|
||||
* for more details.
|
||||
*/
|
||||
/*#define PERL_OTHERLIBDIRS " " / **/
|
||||
|
||||
/* IVTYPE:
|
||||
* This symbol defines the C type used for Perl's IV.
|
||||
*/
|
||||
@ -2623,9 +2689,16 @@
|
||||
/* U64SIZE:
|
||||
* This symbol contains the sizeof(U64).
|
||||
*/
|
||||
/* NVSIZE:
|
||||
* This symbol contains the sizeof(NV).
|
||||
*/
|
||||
/* NV_PRESERVES_UV:
|
||||
* This symbol, if defined, indicates that a variable of type NVTYPE
|
||||
* can preserve all the bit of a variable of type UVSIZE.
|
||||
* can preserve all the bits of a variable of type UVTYPE.
|
||||
*/
|
||||
/* NV_PRESERVES_UV_BITS:
|
||||
* This symbol contains the number of bits a variable of type NVTYPE
|
||||
* can preserve of a variable of type UVTYPE.
|
||||
*/
|
||||
#define IVTYPE long /**/
|
||||
#define UVTYPE unsigned long /**/
|
||||
@ -2652,7 +2725,9 @@
|
||||
#define I64SIZE 8 /**/
|
||||
#define U64SIZE 8 /**/
|
||||
#endif
|
||||
#define NVSIZE 8 /**/
|
||||
#undef NV_PRESERVES_UV
|
||||
#define NV_PRESERVES_UV_BITS 53
|
||||
|
||||
/* IVdf:
|
||||
* This symbol defines the format string used for printing a Perl IV
|
||||
@ -2668,12 +2743,27 @@
|
||||
*/
|
||||
/* UVxf:
|
||||
* This symbol defines the format string used for printing a Perl UV
|
||||
* as an unsigned hexadecimal integer.
|
||||
* as an unsigned hexadecimal integer in lowercase abcdef.
|
||||
*/
|
||||
/* NVef:
|
||||
* This symbol defines the format string used for printing a Perl NV
|
||||
* using %e-ish floating point format.
|
||||
*/
|
||||
/* NVff:
|
||||
* This symbol defines the format string used for printing a Perl NV
|
||||
* using %f-ish floating point format.
|
||||
*/
|
||||
/* NVgf:
|
||||
* This symbol defines the format string used for printing a Perl NV
|
||||
* using %g-ish floating point format.
|
||||
*/
|
||||
#define IVdf "ld" /**/
|
||||
#define UVuf "lu" /**/
|
||||
#define UVof "lo" /**/
|
||||
#define UVxf "lx" /**/
|
||||
#define NVef "e" /**/
|
||||
#define NVff "f" /**/
|
||||
#define NVgf "g" /**/
|
||||
|
||||
/* Pid_t:
|
||||
* This symbol holds the type used to declare process ids in the kernel.
|
||||
@ -2692,8 +2782,8 @@
|
||||
* This symbol contains the ~name expanded version of PRIVLIB, to be used
|
||||
* in programs that are not prepared to deal with ~ expansion at run-time.
|
||||
*/
|
||||
#define PRIVLIB "/opt/perl/lib/5.6.0" /**/
|
||||
#define PRIVLIB_EXP "/opt/perl/lib/5.6.0" /**/
|
||||
#define PRIVLIB "/opt/perl/lib/5.6.1" /**/
|
||||
#define PRIVLIB_EXP "/opt/perl/lib/5.6.1" /**/
|
||||
|
||||
/* PTRSIZE:
|
||||
* This symbol contains the size of a pointer, so that the C preprocessor
|
||||
@ -2791,8 +2881,8 @@
|
||||
* This symbol contains the ~name expanded version of SITEARCH, to be used
|
||||
* in programs that are not prepared to deal with ~ expansion at run-time.
|
||||
*/
|
||||
#define SITEARCH "/opt/perl/lib/site_perl/5.6.0/alpha-dec_osf-thread-multi" /**/
|
||||
#define SITEARCH_EXP "/opt/perl/lib/site_perl/5.6.0/alpha-dec_osf-thread-multi" /**/
|
||||
#define SITEARCH "/opt/perl/lib/site_perl/5.6.1/alpha-dec_osf-thread" /**/
|
||||
#define SITEARCH_EXP "/opt/perl/lib/site_perl/5.6.1/alpha-dec_osf-thread" /**/
|
||||
|
||||
/* SITELIB:
|
||||
* This symbol contains the name of the private library for this package.
|
||||
@ -2814,8 +2904,8 @@
|
||||
* removed. The elements in inc_version_list (inc_version_list.U) can
|
||||
* be tacked onto this variable to generate a list of directories to search.
|
||||
*/
|
||||
#define SITELIB "/opt/perl/lib/site_perl/5.6.0" /**/
|
||||
#define SITELIB_EXP "/opt/perl/lib/site_perl/5.6.0" /**/
|
||||
#define SITELIB "/opt/perl/lib/site_perl/5.6.1" /**/
|
||||
#define SITELIB_EXP "/opt/perl/lib/site_perl/5.6.1" /**/
|
||||
#define SITELIB_STEM "/opt/perl/lib/site_perl" /**/
|
||||
|
||||
/* Size_t_size:
|
||||
@ -2943,7 +3033,7 @@
|
||||
* be built to use multiplicity.
|
||||
*/
|
||||
#ifndef MULTIPLICITY
|
||||
#define MULTIPLICITY /**/
|
||||
/*#define MULTIPLICITY / **/
|
||||
#endif
|
||||
|
||||
/* USE_PERLIO:
|
||||
@ -2975,8 +3065,8 @@
|
||||
* This symbol, if defined, indicates that Perl should
|
||||
* be built to use the old draft POSIX threads API.
|
||||
*/
|
||||
/*#define USE_5005THREADS / **/
|
||||
#define USE_ITHREADS /**/
|
||||
#define USE_5005THREADS /**/
|
||||
/*#define USE_ITHREADS / **/
|
||||
#if defined(USE_5005THREADS) && !defined(USE_ITHREADS)
|
||||
#define USE_THREADS /* until src is revised*/
|
||||
#endif
|
||||
@ -3040,7 +3130,7 @@
|
||||
/* PERL_XS_APIVERSION:
|
||||
* This variable contains the version of the oldest perl binary
|
||||
* compatible with the present perl. perl.c:incpush() and
|
||||
* lib/lib.pm will automatically search in /opt/perl/lib/site_perl/5.6.0/alpha-dec_osf-thread-multi for older
|
||||
* lib/lib.pm will automatically search in /opt/perl/lib/site_perl/5.6.1/alpha-dec_osf-thread for older
|
||||
* directories across major versions back to xs_apiversion.
|
||||
* This is only useful if you have a perl library directory tree
|
||||
* structured like the default one.
|
||||
@ -3059,7 +3149,7 @@
|
||||
* compatible with the present perl. (That is, pure perl modules
|
||||
* written for pm_apiversion will still work for the current
|
||||
* version). perl.c:incpush() and lib/lib.pm will automatically
|
||||
* search in /opt/perl/lib/site_perl/5.6.0 for older directories across major versions
|
||||
* search in /opt/perl/lib/site_perl/5.6.1 for older directories across major versions
|
||||
* back to pm_apiversion. This is only useful if you have a perl
|
||||
* library directory tree structured like the default one. The
|
||||
* versioned site_perl library was introduced in 5.005, so that's
|
||||
@ -3069,20 +3159,65 @@
|
||||
* (presumably) be similar.
|
||||
* See the INSTALL file for how this works.
|
||||
*/
|
||||
#define PERL_XS_APIVERSION "5.6.0"
|
||||
#define PERL_XS_APIVERSION "5.6.1"
|
||||
#define PERL_PM_APIVERSION "5.005"
|
||||
|
||||
/* HAS_LCHOWN:
|
||||
* This symbol, if defined, indicates that the lchown routine is
|
||||
* available to operate on a symbolic link (instead of following the
|
||||
* link).
|
||||
/* HAS_GETPGRP:
|
||||
* This symbol, if defined, indicates that the getpgrp routine is
|
||||
* available to get the current process group.
|
||||
*/
|
||||
#define HAS_LCHOWN /**/
|
||||
/* USE_BSD_GETPGRP:
|
||||
* This symbol, if defined, indicates that getpgrp needs one
|
||||
* arguments whereas USG one needs none.
|
||||
*/
|
||||
#define HAS_GETPGRP /**/
|
||||
/*#define USE_BSD_GETPGRP / **/
|
||||
|
||||
/* FLEXFILENAMES:
|
||||
* This symbol, if defined, indicates that the system supports filenames
|
||||
* longer than 14 characters.
|
||||
/* HAS_SETPGRP:
|
||||
* This symbol, if defined, indicates that the setpgrp routine is
|
||||
* available to set the current process group.
|
||||
*/
|
||||
#define FLEXFILENAMES /**/
|
||||
/* USE_BSD_SETPGRP:
|
||||
* This symbol, if defined, indicates that setpgrp needs two
|
||||
* arguments whereas USG one needs none. See also HAS_SETPGID
|
||||
* for a POSIX interface.
|
||||
*/
|
||||
#define HAS_SETPGRP /**/
|
||||
#define USE_BSD_SETPGRP /**/
|
||||
|
||||
/* STDCHAR:
|
||||
* This symbol is defined to be the type of char used in stdio.h.
|
||||
* It has the values "unsigned char" or "char".
|
||||
*/
|
||||
#define STDCHAR unsigned char /**/
|
||||
|
||||
/* HAS__FWALK:
|
||||
* This symbol, if defined, indicates that the _fwalk system call is
|
||||
* available to apply a function to all the file handles.
|
||||
*/
|
||||
/*#define HAS__FWALK / **/
|
||||
|
||||
/* FCNTL_CAN_LOCK:
|
||||
* This symbol, if defined, indicates that fcntl() can be used
|
||||
* for file locking. Normally on Unix systems this is defined.
|
||||
* It may be undefined on VMS.
|
||||
*/
|
||||
#define FCNTL_CAN_LOCK /**/
|
||||
|
||||
/* HAS_FSYNC:
|
||||
* This symbol, if defined, indicates that the fsync routine is
|
||||
* available to write a file's modified data and attributes to
|
||||
* permanent storage.
|
||||
*/
|
||||
#define HAS_FSYNC /**/
|
||||
|
||||
/* HAS_SBRK_PROTO:
|
||||
* This symbol, if defined, indicates that the system provides
|
||||
* a prototype for the sbrk() function. Otherwise, it is up
|
||||
* to the program to supply one. Good guesses are
|
||||
* extern void* sbrk _((int));
|
||||
* extern void* sbrk _((size_t));
|
||||
*/
|
||||
#define HAS_SBRK_PROTO /**/
|
||||
|
||||
#endif
|
||||
|
@ -20,7 +20,7 @@ use Text::Wrap;
|
||||
$0 =~ s|^.*/||;
|
||||
unless (@ARGV) {
|
||||
die <<USAGE;
|
||||
$0 [-p \$P4PORT] <change numbers or from..to>
|
||||
$0 [-p \$P4PORT] [-bi branch_include] [-be branch_exclude] <change numbers or from..to>
|
||||
USAGE
|
||||
}
|
||||
|
||||
@ -32,6 +32,11 @@ my %editkind;
|
||||
|
||||
my $p4port = $ENV{P4PORT} || 'localhost:1666';
|
||||
|
||||
my @branch_include;
|
||||
my @branch_exclude;
|
||||
my %branch_include;
|
||||
my %branch_exclude;
|
||||
|
||||
while (@ARGV) {
|
||||
$_ = shift;
|
||||
if (/^(\d+)\.\.(\d+)$/) {
|
||||
@ -43,6 +48,12 @@ while (@ARGV) {
|
||||
elsif (/^-p(.*)$/) {
|
||||
$p4port = $1 || shift;
|
||||
}
|
||||
elsif (/^-bi(.*)$/) {
|
||||
push @branch_include, $1 || shift;
|
||||
}
|
||||
elsif (/^-be(.*)$/) {
|
||||
push @branch_exclude, $1 || shift;
|
||||
}
|
||||
else {
|
||||
warn "Arguments must be change numbers, ignoring `$_'\n";
|
||||
}
|
||||
@ -50,6 +61,9 @@ while (@ARGV) {
|
||||
|
||||
@changes = sort { $b <=> $a } @changes;
|
||||
|
||||
@branch_include{@branch_include} = @branch_include if @branch_include;
|
||||
@branch_exclude{@branch_exclude} = @branch_exclude if @branch_exclude;
|
||||
|
||||
my @desc = `p4 -p $p4port describe -s @changes`;
|
||||
if ($?) {
|
||||
die "$0: `p4 -p $p4port describe -s @changes` failed, status[$?]\n";
|
||||
@ -58,6 +72,8 @@ else {
|
||||
chomp @desc;
|
||||
while (@desc) {
|
||||
my ($change,$who,$date,$time,@log,$branch,$file,$type,%files);
|
||||
my $skip = 0;
|
||||
my $nbranch = 0;
|
||||
$_ = shift @desc;
|
||||
if (/^Change (\d+) by (\w+)\@.+ on (\S+) (\S+)\s*$/) {
|
||||
($change, $who, $date, $time) = ($1,$2,$3,$4);
|
||||
@ -73,6 +89,12 @@ else {
|
||||
last unless /^\.\.\./;
|
||||
if (m{^\.\.\. //depot/(.*?perl|[^/]*)/([^#]+)#\d+ (\w+)\s*$}) {
|
||||
($branch,$file,$type) = ($1,$2,$3);
|
||||
$nbranch++;
|
||||
if (exists $branch_exclude{$branch} or
|
||||
@branch_include and
|
||||
not exists $branch_include{$branch}) {
|
||||
$skip++;
|
||||
}
|
||||
$files{$branch} = {} unless exists $files{$branch};
|
||||
$files{$branch}{$type} = [] unless exists $files{$branch}{$type};
|
||||
push @{$files{$branch}{$type}}, $file;
|
||||
@ -83,7 +105,7 @@ else {
|
||||
}
|
||||
}
|
||||
}
|
||||
next unless $change;
|
||||
next if not $change or $skip == $nbranch;
|
||||
print "_" x 76, "\n";
|
||||
printf <<EOT, $change, $who, $date, $time;
|
||||
[%6s] By: %-25s on %9s %9s
|
||||
|
@ -78,23 +78,29 @@ print "\n";
|
||||
chdir "$relroot/$reldir" or die $!;
|
||||
|
||||
print "Setting file permissions...\n";
|
||||
system("find . -type f -print | xargs chmod -w");
|
||||
system("find . -type d -print | xargs chmod g-s");
|
||||
system("find t -name '*.t' -print | xargs chmod +x");
|
||||
system("find . -type f -print | xargs chmod a-w");
|
||||
system("find . -type d -print | xargs chmod 0755");
|
||||
|
||||
# the right files should already have the execute bit set
|
||||
# in the repository, but this is just insurance
|
||||
system("find t -name '*.t' -print | xargs chmod a+x");
|
||||
my @exe = qw(
|
||||
Configure
|
||||
configure.gnu
|
||||
configpm
|
||||
embed.pl
|
||||
installperl
|
||||
installhtml
|
||||
installman
|
||||
embed.pl
|
||||
keywords.pl
|
||||
opcode.pl
|
||||
warnings.pl
|
||||
perly.fixer
|
||||
t/TEST
|
||||
t/*/*.t
|
||||
*.SH
|
||||
vms/ext/Stdio/test.pl
|
||||
vms/ext/filespec.t
|
||||
vms/ext/*.t
|
||||
x2p/*.SH
|
||||
Porting/patchls
|
||||
Porting/makerel
|
||||
@ -102,20 +108,31 @@ my @exe = qw(
|
||||
system("chmod +x @exe");
|
||||
|
||||
my @writables = qw(
|
||||
keywords.h
|
||||
opcode.h
|
||||
opnames.h
|
||||
pp_proto.h
|
||||
pp.sym
|
||||
proto.h
|
||||
embed.h
|
||||
embedvar.h
|
||||
ext/B/B/Asmdata.pm
|
||||
ext/ByteLoader/byterun.c
|
||||
ext/ByteLoader/byterun.h
|
||||
global.sym
|
||||
keywords.h
|
||||
lib/warnings.pm
|
||||
pod/perlintern.pod
|
||||
pod/perlapi.pod
|
||||
objXSUB.h
|
||||
opcode.h
|
||||
pp.sym
|
||||
pp_proto.h
|
||||
perlapi.h
|
||||
perlapi.c
|
||||
ext/ByteLoader/byterun.h
|
||||
ext/ByteLoader/byterun.c
|
||||
ext/B/B/Asmdata.pm
|
||||
regnodes.h
|
||||
warnings.h
|
||||
lib/warnings.pm
|
||||
vms/perly_c.vms
|
||||
vms/perly_h.vms
|
||||
win32/Makefile
|
||||
win32/makefile.mk
|
||||
win32/config_H.bc
|
||||
win32/config_H.bc
|
||||
win32/config_H.gc
|
||||
win32/config_H.vc
|
||||
|
@ -6,7 +6,8 @@
|
||||
# Gurusamy Sarathy <gsar@activestate.com>
|
||||
#
|
||||
|
||||
use vars qw($thisfile $change $file $fnum $h $v $p4port @addfiles);
|
||||
use vars qw($thisfile $change $file $fnum $h $v $p4port @addfiles
|
||||
$branches $skip);
|
||||
|
||||
BEGIN {
|
||||
$0 =~ s|^.*/||;
|
||||
@ -18,6 +19,9 @@ BEGIN {
|
||||
elsif (/^-p(.*)$/) {
|
||||
$p4port = $1 || ' ';
|
||||
}
|
||||
elsif (/^-b(.*)$/) {
|
||||
$branches = $1;
|
||||
}
|
||||
elsif (/^-v$/) {
|
||||
$v++;
|
||||
}
|
||||
@ -30,20 +34,28 @@ BEGIN {
|
||||
}
|
||||
unless (@files) { @files = '-'; undef $^I; }
|
||||
@ARGV = @files;
|
||||
$branches = '//depot/perl/' unless defined $branches;
|
||||
if ($h) {
|
||||
print STDERR <<USAGE;
|
||||
Usage: $0 [-p \$P4PORT] [-v] [-h] [files]
|
||||
|
||||
-p host:port p4 port (e.g. myhost:1666)
|
||||
-phost:port p4 port (e.g. myhost:1666)
|
||||
-h print this help
|
||||
-v output progress messages
|
||||
-bbranch(es) which branches to include (regex)
|
||||
(default: //depot/perl/)
|
||||
-h show this help
|
||||
|
||||
A smart 'cat'. When fed the spew from "p4 describe ..." on STDIN,
|
||||
spits it right out on STDOUT, followed by patches for any new files
|
||||
detected in the spew. Can also be used to edit insitu a bunch of
|
||||
files containing said spew.
|
||||
|
||||
WARNING: Currently only emits unified diffs.
|
||||
WARNING 1: Currently only emits unified diffs (diff -u).
|
||||
|
||||
WARNING 2: By default only the changes in the //depot/perl branch
|
||||
are shown. To include all the branches, supply "-b." arguments
|
||||
to $0.
|
||||
|
||||
Examples:
|
||||
p4 describe -du 123 | $0 > change-123.desc
|
||||
@ -65,14 +77,28 @@ my $cur = m|^Affected files| ... m|^Differences|;
|
||||
|
||||
# while we are within range
|
||||
if ($cur) {
|
||||
if (m{^\.\.\. (//depot/.+?#\d+) (add|branch)$}) {
|
||||
my $newfile = $1;
|
||||
push @addfiles, $newfile;
|
||||
warn "$newfile add, revision != 1!\n" unless $newfile =~ /#1$/;
|
||||
if (m|^\.\.\. |) {
|
||||
if (m|$branches|) {
|
||||
if (m{^\.\.\. (//depot/.+?\#\d+) (add|branch)$}) {
|
||||
my $newfile = $1;
|
||||
push @addfiles, $newfile;
|
||||
warn "$newfile add, revision != 1!\n" unless $newfile =~ /#1$/;
|
||||
}
|
||||
} else {
|
||||
push @skipped, "# $_";
|
||||
$_ = '';
|
||||
}
|
||||
}
|
||||
warn "file [$file] line [$cur] file# [$fnum]\n" if $v;
|
||||
}
|
||||
|
||||
if (m|^==== //depot/|) {
|
||||
$skip = !m|$branches|;
|
||||
print "# Skipped because not under branches: $branches\n" if $skip;
|
||||
}
|
||||
|
||||
$_ = "# $_" if $skip;
|
||||
|
||||
if (/^Change (\d+) by/) {
|
||||
$_ = "\n\n" . $_ if $change; # start of a new change list
|
||||
$change = $1;
|
||||
@ -84,6 +110,9 @@ if (/^Change (\d+) by/) {
|
||||
|
||||
if (eof) {
|
||||
$_ .= newfiles();
|
||||
$_ .= join('', "\n",
|
||||
"# Skipped because not under branches: $branches\n",
|
||||
@skipped, "\n") if @skipped;
|
||||
}
|
||||
|
||||
sub newfiles {
|
||||
|
@ -94,12 +94,7 @@ diffs. Some examples using GNU diff:
|
||||
# show function name in every hunk (safer, more informative)
|
||||
% diff -u -F '^[_a-zA-Z0-9]+ *(' old/file new/file
|
||||
|
||||
|
||||
=item Directories
|
||||
|
||||
IMPORTANT: Patches should be generated from the source root directory, not
|
||||
from the directory that the patched file resides in. This ensures that the
|
||||
maintainer patches the proper file.
|
||||
=item Derived Files
|
||||
|
||||
Many files in the distribution are derivative--avoid patching them.
|
||||
Patch the originals instead. Most utilities (like perldoc) are in
|
||||
@ -120,6 +115,31 @@ If you are submitting patches that affect multiple files then you should
|
||||
backup the entire directory tree (to $source_root.old/ for example). This
|
||||
will allow C<diff -ruN old-dir new-dir> to create all the patches at once.
|
||||
|
||||
=item Directories
|
||||
|
||||
IMPORTANT: Patches should be generated from the source root directory, not
|
||||
from the directory that the patched file resides in. This ensures that the
|
||||
maintainer patches the proper file.
|
||||
|
||||
For larger patches that are dealing with multiple files or
|
||||
directories, Johan Vromans has written a powerful utility: makepatch.
|
||||
See the JV directory on CPAN for the current version. If you have this
|
||||
program available, it is recommended to create a duplicate of the perl
|
||||
directory tree against which you are intending to provide a patch and
|
||||
let makepatch figure out all the changes you made to your copy of the
|
||||
sources. As perl comes with a MANIFEST file, you need not delete
|
||||
object files and other derivative files from the two directory trees,
|
||||
makepatch is smart about them.
|
||||
|
||||
Say, you have created a directory perl-5.7.1@8685/ for the perl you
|
||||
are taking as the base and a directory perl-5.7.1@8685-withfoo/ where
|
||||
you have your changes, you would run makepatch as follows:
|
||||
|
||||
makepatch -oldman perl-5.7.1@8685/MANIFEST \
|
||||
-newman perl-5.7.1@8685-withfoo/MANIFEST \
|
||||
-diff "diff -u" \
|
||||
perl-5.7.1@8685 perl-5.7.1@8685-withfoo
|
||||
|
||||
=item Try it yourself
|
||||
|
||||
Just to make sure your patch "works", be sure to apply it to the Perl
|
||||
|
@ -58,7 +58,7 @@ and 1 is the subversion.
|
||||
|
||||
For compatibility with the older numbering scheme the composite floating
|
||||
point version number continues to be available as the magic variable $],
|
||||
and amounts to C<$revision + $version/1000 + $subversion/1000000>. This
|
||||
and amounts to C<$revision + $version/1000 + $subversion/100000>. This
|
||||
can still be used in comparisons.
|
||||
|
||||
print "You've got an old perl\n" if $] < 5.005_03;
|
||||
@ -210,7 +210,7 @@ unset appropriate Configure variables, based on the Configure command
|
||||
line options and possibly existing config.sh and Policy.sh files from
|
||||
previous Configure runs.
|
||||
|
||||
The extension hints are written Perl (by the time they are used
|
||||
The extension hints are written in Perl (by the time they are used
|
||||
miniperl has been built) and control the building of their respective
|
||||
extensions. They can be used to for example manipulate compilation
|
||||
and linking flags.
|
||||
@ -252,7 +252,8 @@ the first B<not> to have a system call also update the list of
|
||||
A file called F<README.youros> at the top level that explains things
|
||||
like how to install perl at this platform, where to get any possibly
|
||||
required additional software, and for example what test suite errors
|
||||
to expect, is nice too.
|
||||
to expect, is nice too. Such files are in the process of being written
|
||||
in pod format and will eventually be renamed F<INSTALL.youros>.
|
||||
|
||||
You may also want to write a separate F<.pod> file for your operating
|
||||
system to tell about existing mailing lists, os-specific modules,
|
||||
@ -449,7 +450,9 @@ safely be sorted, so it's easy to track (typically very small) changes
|
||||
to config.sh and then propoagate them to a canned 'config.h' by any
|
||||
number of means, including a perl script in win32/ or carrying
|
||||
config.sh and config_h.SH to a Unix system and running sh
|
||||
config_h.SH.)
|
||||
config_h.SH.) Vms uses configure.com to generate its own config.sh
|
||||
and config.h. If you want to add a new variable to config.sh check
|
||||
with vms folk how to add it to configure.com too.
|
||||
XXX]
|
||||
|
||||
The Porting/config.sh and Porting/config_H files are provided to
|
||||
@ -460,7 +463,7 @@ distinguish the file from config.h even on case-insensitive file systems.)
|
||||
Simply edit the existing config_H file; keep the first few explanatory
|
||||
lines and then copy your new config.h below.
|
||||
|
||||
It may also be necessary to update win32/config.?c, vms/config.vms and
|
||||
It may also be necessary to update win32/config.?c, and
|
||||
plan9/config.plan9, though you should be quite careful in doing so if
|
||||
you are not familiar with those systems. You might want to issue your
|
||||
patch with a promise to quickly issue a follow-up that handles those
|
||||
@ -481,8 +484,10 @@ output statements mean the patch won't apply cleanly. Long ago I
|
||||
started to fix F<perly.fixer> to detect this, but I never completed the
|
||||
task.
|
||||
|
||||
If C<perly.c> changes, make sure you run C<perl vms/vms_yfix.pl> to
|
||||
update the corresponding VMS files. See L<VMS-specific updates>.
|
||||
If C<perly.c> or C<perly.h> changes, make sure you run C<perl vms/vms_yfix.pl>
|
||||
to update the corresponding VMS files. This could be taken care of by
|
||||
the regen_all target in the Unix Makefile. See also
|
||||
L<VMS-specific updates>.
|
||||
|
||||
Some additional notes from Larry on this:
|
||||
|
||||
@ -507,6 +512,11 @@ could be automated, but it doesn't happen very often nowadays.
|
||||
|
||||
Larry
|
||||
|
||||
=head2 make regen_all
|
||||
|
||||
This target takes care of the PERLYVMS, regen_headers, and regen_pods
|
||||
targets.
|
||||
|
||||
=head2 make regen_headers
|
||||
|
||||
The F<embed.h>, F<keywords.h>, and F<opcode.h> files are all automatically
|
||||
@ -532,6 +542,10 @@ and effort by manually running C<make regen_headers> myself rather
|
||||
than answering all the questions and complaints about the failing
|
||||
command.
|
||||
|
||||
=head2 make regen_pods
|
||||
|
||||
Will run `make regen_pods` in the pod directory for indexing.
|
||||
|
||||
=head2 global.sym, interp.sym and perlio.sym
|
||||
|
||||
Make sure these files are up-to-date. Read the comments in these
|
||||
@ -541,7 +555,7 @@ files and in perl_exp.SH to see what to do.
|
||||
|
||||
If you do change F<global.sym> or F<interp.sym>, think carefully about
|
||||
what you are doing. To the extent reasonable, we'd like to maintain
|
||||
souce and binary compatibility with older releases of perl. That way,
|
||||
source and binary compatibility with older releases of perl. That way,
|
||||
extensions built under one version of perl will continue to work with
|
||||
new versions of perl.
|
||||
|
||||
@ -594,11 +608,11 @@ things that need to be fixed in Configure.
|
||||
=head2 VMS-specific updates
|
||||
|
||||
If you have changed F<perly.y> or F<perly.c>, then you most probably want
|
||||
to update F<vms/perly_{h,c}.vms> by running C<perl vms/vms_yfix.pl>.
|
||||
to update F<vms/perly_{h,c}.vms> by running C<perl vms/vms_yfix.pl>, or
|
||||
by running `make regen_all` which will run that script for you.
|
||||
|
||||
The Perl version number appears in several places under F<vms>.
|
||||
It is courteous to update these versions. For example, if you are
|
||||
making 5.004_42, replace "5.00441" with "5.00442".
|
||||
The Perl revision number appears as "perl5" in configure.com.
|
||||
It is courteous to update that if necessary.
|
||||
|
||||
=head2 Making the new distribution
|
||||
|
||||
@ -701,6 +715,34 @@ supports dynamic loading, you can also test static loading with
|
||||
You can also hand-tweak your config.h to try out different #ifdef
|
||||
branches.
|
||||
|
||||
=head2 Other tests
|
||||
|
||||
=over 4
|
||||
|
||||
=item CHECK_FORMAT
|
||||
|
||||
To test the correct use of printf-style arguments, C<Configure> with
|
||||
S<-Dccflags='-DCHECK_FORMAT -Wformat'> and run C<make>. The compiler
|
||||
will produce warning of incorrect use of format arguments. CHECK_FORMAT
|
||||
changes perl-defined formats to common formats, so DO NOT USE the executable
|
||||
produced by this process.
|
||||
|
||||
A more accurate approach is the following commands:
|
||||
|
||||
sh Configure -des -Dccflags=-Wformat ...
|
||||
make miniperl # without -DCHECK_FORMAT
|
||||
perl -i.orig -pwe 's/-Wformat/-DCHECK_FORMAT $&/' config.sh
|
||||
sh Configure -S
|
||||
make >& make.log # build from correct miniperl
|
||||
make clean
|
||||
make miniperl >& mini.log # build miniperl with -DCHECK_FORMAT
|
||||
perl -nwe 'print if /^\S+:/ and not /^make\b/' mini.log make.log
|
||||
make clean
|
||||
|
||||
(-Wformat support by Robin Barker.)
|
||||
|
||||
=back
|
||||
|
||||
=head1 Running Purify
|
||||
|
||||
Purify is a commercial tool that is helpful in identifying memory
|
||||
@ -1325,7 +1367,8 @@ have good reason to do otherwise, I see no reason not to support them.
|
||||
=item File locking
|
||||
|
||||
Somehow, straighten out, document, and implement lockf(), flock(),
|
||||
and/or fcntl() file locking. It's a mess.
|
||||
and/or fcntl() file locking. It's a mess. See $d_fcntl_can_lock
|
||||
in recent config.sh files though.
|
||||
|
||||
=back
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
|
||||
Perl Kit, Version 5.0
|
||||
|
||||
Copyright 1989-2000, Larry Wall
|
||||
Copyright 1989-2001, Larry Wall
|
||||
All rights reserved.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
@ -22,8 +22,10 @@
|
||||
Kit, in the file named "Artistic". If not, I'll be glad to provide one.
|
||||
|
||||
You should also have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software Foundation,
|
||||
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
along with this program in the file named "Copying". If not, write to the
|
||||
Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
|
||||
02111-1307, USA or visit their web page on the internet at
|
||||
http://www.gnu.org/copyleft/gpl.html.
|
||||
|
||||
For those of you that choose to use the GNU General Public License,
|
||||
my interpretation of the GNU General Public License is that no Perl
|
||||
@ -70,7 +72,7 @@ corresponding README.
|
||||
2) Read the manual entries before running perl.
|
||||
|
||||
3) IMPORTANT! Help save the world! Communicate any problems and suggested
|
||||
patches to perlbug@perl.com so we can keep the world in sync.
|
||||
patches to perlbug@perl.org so we can keep the world in sync.
|
||||
If you have a problem, there's someone else out there who either has had
|
||||
or will have the same problem. It's usually helpful if you send the
|
||||
output of the "myconfig" script in the main perl directory.
|
||||
|
@ -21,7 +21,7 @@ Long answer: The question belies a true understanding of the
|
||||
localtime) supply adequate information to determine the
|
||||
year well beyond 2000 (2038 is when trouble strikes for
|
||||
32-bit machines). The year returned by these functions
|
||||
when used in an array context is the year minus 1900. For
|
||||
when used in a list context is the year minus 1900. For
|
||||
years between 1910 and 1999 this happens to be a 2-digit
|
||||
decimal number. To avoid the year 2000 problem simply do
|
||||
not treat the year as a 2-digit number. It isn't.
|
||||
|
@ -47,10 +47,6 @@ Would be nice to have
|
||||
to be used in re-entrant (=multithreaded) code
|
||||
Icky things: the _r API is not standardized and
|
||||
the _r-forms require per-thread data to store their state
|
||||
memory profiler: turn malloc.c:Perl_get_mstats() into
|
||||
an extension (Devel::MProf?) that would return the malloc
|
||||
stats in a nice Perl datastructure (also a simple interface
|
||||
to return just the grand total would be good)
|
||||
cross-compilation support
|
||||
host vs target: compile in the host, get the executable to
|
||||
the target, get the possible input files to the target,
|
||||
|
@ -1,6 +1,5 @@
|
||||
Unicode support
|
||||
finish byte <-> utf8 and localencoding <-> utf8 conversions
|
||||
make substr($bytestr,0,0,$charstr) do the right conversion
|
||||
add Unicode::Map equivivalent to core
|
||||
add support for I/O disciplines
|
||||
- a way to specify disciplines when opening things:
|
||||
@ -12,7 +11,25 @@ Unicode support
|
||||
eliminate need for "use utf8;"
|
||||
autoload byte.pm when byte:: is seen by the parser
|
||||
check uv_to_utf8() calls for buffer overflow
|
||||
(see also "Locales", "Regexen", and "Miscellaneous")
|
||||
make \uXXXX (and \u{XXXX}?) where XXXX are hex digits
|
||||
to work similarly to Unicode tech reports and Java
|
||||
notation \uXXXX (and already existing \x{XXXX))?
|
||||
more than four hexdigits? make also \U+XXXX work?
|
||||
overloadable regex assertions? e.g. in Thai \b cannot
|
||||
be deduced by any simple character class boundary rules,
|
||||
word boundaries must algorithmically computed
|
||||
|
||||
see ext/Encode/Todo for notes and references about proper detection
|
||||
of malformed UTF-8
|
||||
|
||||
SCSU? http://www.unicode.org/unicode/reports/tr6/
|
||||
Collation? http://www.unicode.org/unicode/reports/tr10/
|
||||
Normalization? http://www.unicode.org/unicode/reports/tr15/
|
||||
EBCDIC? http://www.unicode.org/unicode/reports/tr16/
|
||||
Regexes? http://www.unicode.org/unicode/reports/tr18/
|
||||
Case Mappings? http://www.unicode.org/unicode/reports/tr21/
|
||||
|
||||
See also "Locales", "Regexen", and "Miscellaneous".
|
||||
|
||||
Multi-threading
|
||||
support "use Thread;" under useithreads
|
||||
@ -39,17 +56,18 @@ Namespace cleanup
|
||||
API-space: complete the list of things that constitute public api
|
||||
|
||||
Configure
|
||||
fix the vicious cyclic multidependency of cc <-> libpth <-> loclibpth
|
||||
libswanted <-> usethreads <-> use64bitint <-> use64bitall <->
|
||||
uselargefiles <-> ...
|
||||
make configuring+building away from source directory work (VPATH et al)
|
||||
this is related to: cross-compilation configuring (see Todo)
|
||||
_r support (see Todo for mode detailed description)
|
||||
POSIX 1003.1 1996 Edition support--realtime stuff:
|
||||
POSIX semaphores, message queues, shared memory, realtime clocks,
|
||||
timers, signals (the metaconfig units mostly already exist for these)
|
||||
PREFERABLY AS AN EXTENSION
|
||||
UNIX98 support: reader-writer locks, realtime/asynchronous IO
|
||||
PREFERABLY AS AN EXTENSION
|
||||
IPv6 support: see RFC2292, RFC2553
|
||||
PREFERABLY AS AN EXTENSION
|
||||
there already is Socket6 in CPAN
|
||||
|
||||
Long doubles
|
||||
figure out where the PV->NV->PV conversion gets it wrong at least
|
||||
@ -60,6 +78,7 @@ Long doubles
|
||||
64-bit support
|
||||
Configure probe for quad_t, uquad_t, and (argh) u_quad_t, they might
|
||||
be in some systems the only thing working as quadtype and uquadtype.
|
||||
more pain: long_long, u_long_long.
|
||||
|
||||
Locales
|
||||
deprecate traditional/legacy locales?
|
||||
@ -67,15 +86,16 @@ Locales
|
||||
figure out how to support Unicode locales
|
||||
suggestion: integrate the IBM Classes for Unicode (ICU)
|
||||
http://oss.software.ibm.com/developerworks/opensource/icu/project/
|
||||
and check out also the Locale Converter:
|
||||
ICU is "portable, open-source Unicode library with:
|
||||
charset-independent locales (with multiple locales
|
||||
simultaneously supported in same thread; character
|
||||
conversions; formatting/parsing for numbers, currencies,
|
||||
date/time and messages; message catalogs (resources);
|
||||
transliteration, collation, normalization, and text
|
||||
boundaries (grapheme, word, line-break))".
|
||||
Check out also the Locale Converter:
|
||||
http://alphaworks.ibm.com/tech/localeconverter
|
||||
ICU is "portable, open-source Unicode library with:
|
||||
charset-independent locales (with multiple locales simultaneously
|
||||
supported in same thread; character conversions; formatting/parsing
|
||||
for numbers, currencies, date/time and messages; message catalogs
|
||||
(resources) ; transliteration, collation, normalization, and text
|
||||
boundaries (grapheme, word, line-break))".
|
||||
There is also 'iconv', either from XPG4 or GNU (glibc).
|
||||
There is also the iconv interface, either from XPG4 or GNU (glibc).
|
||||
iconv is about character set conversions.
|
||||
Either ICU or iconv would be valuable to get integrated
|
||||
into Perl, Configure already probes for libiconv and <iconv.h>.
|
||||
@ -101,6 +121,9 @@ Regexen
|
||||
this is also a part of the Unicode 3.0:
|
||||
http://www.unicode.org/unicode/uni2book/u2.html
|
||||
executive summary: there are several different levels of 'equivalence'
|
||||
trie optimization: factor out common suffixes (and prefixes?)
|
||||
from |-alternating groups (both for exact strings and character
|
||||
classes, use lookaheads?)
|
||||
approximate matching
|
||||
|
||||
Security
|
||||
@ -120,22 +143,27 @@ Win32 stuff
|
||||
work out DLL versioning
|
||||
|
||||
Miscellaneous
|
||||
introduce @( and @) because group names can have spaces
|
||||
add new modules (Archive::Tar, Compress::Zlib, CPAN::FTP?)
|
||||
sub-second sleep()? alarm()? time()? (integrate Time::HiRes?
|
||||
Configure doesn't yet probe for usleep/nanosleep/ualarm but
|
||||
the units exist)
|
||||
floating point handling: nans, infinities, fp exception masks, etc.
|
||||
at least the following interfaces exist: fp_classify(), fp_class(),
|
||||
class(), isnan(), isinf(), isfinite(), finite(), isnormal(),
|
||||
ordered(), fp_setmask(), fp_getmask(), fp_setround(), fp_getround(),
|
||||
ieeefp.h, fp_class.h. There are metaconfig units for most of these.
|
||||
Search for ifdef __osf__ in pp.c to find a temporary fix that
|
||||
needs to be done right.
|
||||
At least the following interfaces exist: fp_classify(), fp_class(),
|
||||
class(), isinf(), isfinite(), finite(), isnormal(), unordered(),
|
||||
<ieeefp.h>, <fp_class.h> (there are metaconfig units for all these),
|
||||
fp_setmask(), fp_getmask(), fp_setround(), fp_getround()
|
||||
(no metaconfig units yet for these).
|
||||
Don't forget finitel(), fp_classl(), fp_class_l(), (yes, both do,
|
||||
unfortunately, exist), and unorderedl().
|
||||
PREFERABLY AS AN EXTENSION.
|
||||
As of 5.6.1 there is cpp macro Perl_isnan().
|
||||
fix the basic arithmetics (+ - * / %) to preserve IVness/UVness if
|
||||
both arguments are IVs/UVs
|
||||
both arguments are IVs/UVs: it sucks that one cannot see
|
||||
the 'carry flag' (or equivalent) of the CPU from C,
|
||||
C is too high-level...
|
||||
replace pod2html with new PodtoHtml? (requires other modules from CPAN)
|
||||
automate testing with large parts of CPAN
|
||||
Unicode collation? http://www.unicode.org/unicode/reports/tr10/
|
||||
turn Cwd into an XS module? (Configure already probes for getcwd())
|
||||
mmap for speeding up input? (Configure already probes for the mmap family)
|
||||
sendmsg, recvmsg? (Configure doesn't probe for these but the units exist)
|
||||
@ -154,3 +182,5 @@ Documentation
|
||||
spot-check all new modules for completeness
|
||||
better docs for pack()/unpack()
|
||||
reorg tutorials vs. reference sections
|
||||
make roffitall to be dynamical about its pods and libs
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
/* av.c
|
||||
*
|
||||
* Copyright (c) 1991-2000, Larry Wall
|
||||
* Copyright (c) 1991-2001, Larry Wall
|
||||
*
|
||||
* You may distribute under the terms of either the GNU General Public
|
||||
* License or the Artistic License, as specified in the README file.
|
||||
@ -34,10 +34,8 @@ Perl_av_reify(pTHX_ AV *av)
|
||||
while (key) {
|
||||
sv = AvARRAY(av)[--key];
|
||||
assert(sv);
|
||||
if (sv != &PL_sv_undef) {
|
||||
dTHR;
|
||||
if (sv != &PL_sv_undef)
|
||||
(void)SvREFCNT_inc(sv);
|
||||
}
|
||||
}
|
||||
key = AvARRAY(av) - AvALLOC(av);
|
||||
while (key)
|
||||
@ -58,7 +56,6 @@ extended.
|
||||
void
|
||||
Perl_av_extend(pTHX_ AV *av, I32 key)
|
||||
{
|
||||
dTHR; /* only necessary if we have to extend stack */
|
||||
MAGIC *mg;
|
||||
if ((mg = SvTIED_mg((SV*)av, 'P'))) {
|
||||
dSP;
|
||||
@ -189,7 +186,6 @@ Perl_av_fetch(pTHX_ register AV *av, I32 key, I32 lval)
|
||||
|
||||
if (SvRMAGICAL(av)) {
|
||||
if (mg_find((SV*)av,'P') || mg_find((SV*)av,'D')) {
|
||||
dTHR;
|
||||
sv = sv_newmortal();
|
||||
mg_copy((SV*)av, sv, 0, key);
|
||||
PL_av_fetch_sv = sv;
|
||||
@ -272,7 +268,6 @@ Perl_av_store(pTHX_ register AV *av, I32 key, SV *val)
|
||||
ary = AvARRAY(av);
|
||||
if (AvFILLp(av) < key) {
|
||||
if (!AvREAL(av)) {
|
||||
dTHR;
|
||||
if (av == PL_curstack && key > PL_stack_sp - PL_stack_base)
|
||||
PL_stack_sp = PL_stack_base + key; /* XPUSH in disguise */
|
||||
do
|
||||
@ -554,6 +549,7 @@ Perl_av_unshift(pTHX_ register AV *av, register I32 num)
|
||||
register I32 i;
|
||||
register SV **ary;
|
||||
MAGIC* mg;
|
||||
I32 slide;
|
||||
|
||||
if (!av || num <= 0)
|
||||
return;
|
||||
@ -591,6 +587,9 @@ Perl_av_unshift(pTHX_ register AV *av, register I32 num)
|
||||
}
|
||||
if (num) {
|
||||
i = AvFILLp(av);
|
||||
/* Create extra elements */
|
||||
slide = i > 0 ? i : 0;
|
||||
num += slide;
|
||||
av_extend(av, i + num);
|
||||
AvFILLp(av) += num;
|
||||
ary = AvARRAY(av);
|
||||
@ -598,6 +597,10 @@ Perl_av_unshift(pTHX_ register AV *av, register I32 num)
|
||||
do {
|
||||
ary[--num] = &PL_sv_undef;
|
||||
} while (num);
|
||||
/* Make extra elements into a buffer */
|
||||
AvMAX(av) -= slide;
|
||||
AvFILLp(av) -= slide;
|
||||
SvPVX(av) = (char*)(AvARRAY(av) + slide);
|
||||
}
|
||||
}
|
||||
|
||||
@ -661,6 +664,14 @@ Perl_av_len(pTHX_ register AV *av)
|
||||
return AvFILL(av);
|
||||
}
|
||||
|
||||
/*
|
||||
=for apidoc av_fill
|
||||
|
||||
Ensure than an array has a given number of elements, equivalent to
|
||||
Perl's C<$#array = $fill;>.
|
||||
|
||||
=cut
|
||||
*/
|
||||
void
|
||||
Perl_av_fill(pTHX_ register AV *av, I32 fill)
|
||||
{
|
||||
@ -708,6 +719,14 @@ Perl_av_fill(pTHX_ register AV *av, I32 fill)
|
||||
(void)av_store(av,fill,&PL_sv_undef);
|
||||
}
|
||||
|
||||
/*
|
||||
=for apidoc av_delete
|
||||
|
||||
Deletes the element indexed by C<key> from the array. Returns the
|
||||
deleted element. C<flags> is currently ignored.
|
||||
|
||||
=cut
|
||||
*/
|
||||
SV *
|
||||
Perl_av_delete(pTHX_ AV *av, I32 key, I32 flags)
|
||||
{
|
||||
@ -758,10 +777,15 @@ Perl_av_delete(pTHX_ AV *av, I32 key, I32 flags)
|
||||
}
|
||||
|
||||
/*
|
||||
* This relies on the fact that uninitialized array elements
|
||||
* are set to &PL_sv_undef.
|
||||
*/
|
||||
=for apidoc av_exists
|
||||
|
||||
Returns true if the element indexed by C<key> has been initialized.
|
||||
|
||||
This relies on the fact that uninitialized array elements are set to
|
||||
C<&PL_sv_undef>.
|
||||
|
||||
=cut
|
||||
*/
|
||||
bool
|
||||
Perl_av_exists(pTHX_ AV *av, I32 key)
|
||||
{
|
||||
@ -775,9 +799,14 @@ Perl_av_exists(pTHX_ AV *av, I32 key)
|
||||
if (SvRMAGICAL(av)) {
|
||||
if (mg_find((SV*)av,'P') || mg_find((SV*)av,'D')) {
|
||||
SV *sv = sv_newmortal();
|
||||
MAGIC *mg;
|
||||
|
||||
mg_copy((SV*)av, sv, 0, key);
|
||||
magic_existspack(sv, mg_find(sv, 'p'));
|
||||
return SvTRUE(sv);
|
||||
mg = mg_find(sv, 'p');
|
||||
if (mg) {
|
||||
magic_existspack(sv, mg);
|
||||
return SvTRUE(sv);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (key <= AvFILLp(av) && AvARRAY(av)[key] != &PL_sv_undef
|
||||
|
@ -1,6 +1,6 @@
|
||||
/* av.h
|
||||
*
|
||||
* Copyright (c) 1991-2000, Larry Wall
|
||||
* Copyright (c) 1991-2001, Larry Wall
|
||||
*
|
||||
* You may distribute under the terms of either the GNU General Public
|
||||
* License or the Artistic License, as specified in the README file.
|
||||
@ -32,8 +32,8 @@ struct xpvav {
|
||||
* real if the array needs to be modified in some way. Functions that
|
||||
* modify fake AVs check both flags to call av_reify() as appropriate.
|
||||
*
|
||||
* Note that the Perl stack has neither flag set. (Thus, items that go
|
||||
* on the stack are never refcounted.)
|
||||
* Note that the Perl stack and @DB::args have neither flag set. (Thus,
|
||||
* items that go on the stack are never refcounted.)
|
||||
*
|
||||
* These internal details are subject to change any time. AV
|
||||
* manipulations external to perl should not care about any of this.
|
||||
|
@ -13,7 +13,7 @@ my @optype= qw(OP UNOP BINOP LOGOP LISTOP PMOP SVOP PADOP PVOP LOOP COP);
|
||||
|
||||
# Nullsv *must* come first in the following so that the condition
|
||||
# ($$sv == 0) can continue to be used to test (sv == Nullsv).
|
||||
my @specialsv = qw(Nullsv &PL_sv_undef &PL_sv_yes &PL_sv_no);
|
||||
my @specialsv = qw(Nullsv &PL_sv_undef &PL_sv_yes &PL_sv_no pWARN_ALL pWARN_NONE);
|
||||
|
||||
my (%alias_from, $from, $tos);
|
||||
while (($from, $tos) = each %alias_to) {
|
||||
@ -82,7 +82,7 @@ print BYTERUN_C $c_header, <<'EOT';
|
||||
#include "bytecode.h"
|
||||
|
||||
|
||||
static int optype_size[] = {
|
||||
static const int optype_size[] = {
|
||||
EOT
|
||||
my $i = 0;
|
||||
for ($i = 0; $i < @optype - 1; $i++) {
|
||||
@ -92,33 +92,27 @@ printf BYTERUN_C " sizeof(%s)\n", $optype[$i], $i;
|
||||
print BYTERUN_C <<'EOT';
|
||||
};
|
||||
|
||||
static SV *specialsv_list[4];
|
||||
|
||||
static int bytecode_iv_overflows = 0;
|
||||
static SV *bytecode_sv;
|
||||
static XPV bytecode_pv;
|
||||
static void **bytecode_obj_list;
|
||||
static I32 bytecode_obj_list_fill = -1;
|
||||
|
||||
void *
|
||||
bset_obj_store(pTHXo_ void *obj, I32 ix)
|
||||
bset_obj_store(pTHXo_ struct byteloader_state *bstate, void *obj, I32 ix)
|
||||
{
|
||||
if (ix > bytecode_obj_list_fill) {
|
||||
if (bytecode_obj_list_fill == -1)
|
||||
New(666, bytecode_obj_list, ix + 1, void*);
|
||||
else
|
||||
Renew(bytecode_obj_list, ix + 1, void*);
|
||||
bytecode_obj_list_fill = ix;
|
||||
if (ix > bstate->bs_obj_list_fill) {
|
||||
Renew(bstate->bs_obj_list, ix + 32, void*);
|
||||
bstate->bs_obj_list_fill = ix + 31;
|
||||
}
|
||||
bytecode_obj_list[ix] = obj;
|
||||
bstate->bs_obj_list[ix] = obj;
|
||||
return obj;
|
||||
}
|
||||
|
||||
void
|
||||
byterun(pTHXo_ struct bytestream bs)
|
||||
byterun(pTHXo_ register struct byteloader_state *bstate)
|
||||
{
|
||||
dTHR;
|
||||
int insn;
|
||||
register int insn;
|
||||
U32 ix;
|
||||
SV *specialsv_list[6];
|
||||
|
||||
BYTECODE_HEADER_CHECK; /* croak if incorrect platform */
|
||||
New(666, bstate->bs_obj_list, 32, void*); /* set op objlist */
|
||||
bstate->bs_obj_list_fill = 31;
|
||||
|
||||
EOT
|
||||
|
||||
@ -198,13 +192,25 @@ EOT
|
||||
#
|
||||
open(BYTERUN_H, ">ext/ByteLoader/byterun.h") or die "ext/ByteLoader/byterun.h: $!";
|
||||
print BYTERUN_H $c_header, <<'EOT';
|
||||
struct bytestream {
|
||||
void *data;
|
||||
int (*pfgetc)(void *);
|
||||
int (*pfread)(char *, size_t, size_t, void *);
|
||||
void (*pfreadpv)(U32, void *, XPV *);
|
||||
struct byteloader_fdata {
|
||||
SV *datasv;
|
||||
int next_out;
|
||||
int idx;
|
||||
};
|
||||
|
||||
struct byteloader_state {
|
||||
struct byteloader_fdata *bs_fdata;
|
||||
SV *bs_sv;
|
||||
void **bs_obj_list;
|
||||
int bs_obj_list_fill;
|
||||
XPV bs_pv;
|
||||
int bs_iv_overflows;
|
||||
};
|
||||
|
||||
int bl_getc(struct byteloader_fdata *);
|
||||
int bl_read(struct byteloader_fdata *, char *, size_t, size_t);
|
||||
extern void byterun(pTHXo_ struct byteloader_state *);
|
||||
|
||||
enum {
|
||||
EOT
|
||||
|
||||
@ -233,18 +239,6 @@ for ($i = 0; $i < @optype - 1; $i++) {
|
||||
}
|
||||
printf BYTERUN_H " OPt_%s\t\t/* %d */\n};\n\n", $optype[$i], $i;
|
||||
|
||||
print BYTERUN_H <<'EOT';
|
||||
extern void byterun(pTHXo_ struct bytestream bs);
|
||||
|
||||
#define INIT_SPECIALSV_LIST STMT_START { \
|
||||
EOT
|
||||
for ($i = 0; $i < @specialsv; $i++) {
|
||||
print BYTERUN_H "\tPL_specialsv_list[$i] = $specialsv[$i]; \\\n";
|
||||
}
|
||||
print BYTERUN_H <<'EOT';
|
||||
} STMT_END
|
||||
EOT
|
||||
|
||||
#
|
||||
# Finish off insn_data and create array initialisers in Asmdata.pm
|
||||
#
|
||||
@ -294,85 +288,86 @@ nop none none
|
||||
#opcode lvalue argtype flags
|
||||
#
|
||||
ret none none x
|
||||
ldsv bytecode_sv svindex
|
||||
ldsv bstate->bs_sv svindex
|
||||
ldop PL_op opindex
|
||||
stsv bytecode_sv U32 s
|
||||
stsv bstate->bs_sv U32 s
|
||||
stop PL_op U32 s
|
||||
ldspecsv bytecode_sv U8 x
|
||||
newsv bytecode_sv U8 x
|
||||
stpv bstate->bs_pv.xpv_pv U32 x
|
||||
ldspecsv bstate->bs_sv U8 x
|
||||
newsv bstate->bs_sv U8 x
|
||||
newop PL_op U8 x
|
||||
newopn PL_op U8 x
|
||||
newpv none PV
|
||||
pv_cur bytecode_pv.xpv_cur STRLEN
|
||||
pv_free bytecode_pv none x
|
||||
sv_upgrade bytecode_sv char x
|
||||
sv_refcnt SvREFCNT(bytecode_sv) U32
|
||||
sv_refcnt_add SvREFCNT(bytecode_sv) I32 x
|
||||
sv_flags SvFLAGS(bytecode_sv) U32
|
||||
xrv SvRV(bytecode_sv) svindex
|
||||
xpv bytecode_sv none x
|
||||
xiv32 SvIVX(bytecode_sv) I32
|
||||
xiv64 SvIVX(bytecode_sv) IV64
|
||||
xnv SvNVX(bytecode_sv) NV
|
||||
xlv_targoff LvTARGOFF(bytecode_sv) STRLEN
|
||||
xlv_targlen LvTARGLEN(bytecode_sv) STRLEN
|
||||
xlv_targ LvTARG(bytecode_sv) svindex
|
||||
xlv_type LvTYPE(bytecode_sv) char
|
||||
xbm_useful BmUSEFUL(bytecode_sv) I32
|
||||
xbm_previous BmPREVIOUS(bytecode_sv) U16
|
||||
xbm_rare BmRARE(bytecode_sv) U8
|
||||
xfm_lines FmLINES(bytecode_sv) I32
|
||||
xio_lines IoLINES(bytecode_sv) long
|
||||
xio_page IoPAGE(bytecode_sv) long
|
||||
xio_page_len IoPAGE_LEN(bytecode_sv) long
|
||||
xio_lines_left IoLINES_LEFT(bytecode_sv) long
|
||||
xio_top_name IoTOP_NAME(bytecode_sv) pvcontents
|
||||
xio_top_gv *(SV**)&IoTOP_GV(bytecode_sv) svindex
|
||||
xio_fmt_name IoFMT_NAME(bytecode_sv) pvcontents
|
||||
xio_fmt_gv *(SV**)&IoFMT_GV(bytecode_sv) svindex
|
||||
xio_bottom_name IoBOTTOM_NAME(bytecode_sv) pvcontents
|
||||
xio_bottom_gv *(SV**)&IoBOTTOM_GV(bytecode_sv) svindex
|
||||
xio_subprocess IoSUBPROCESS(bytecode_sv) short
|
||||
xio_type IoTYPE(bytecode_sv) char
|
||||
xio_flags IoFLAGS(bytecode_sv) char
|
||||
xcv_stash *(SV**)&CvSTASH(bytecode_sv) svindex
|
||||
xcv_start CvSTART(bytecode_sv) opindex
|
||||
xcv_root CvROOT(bytecode_sv) opindex
|
||||
xcv_gv *(SV**)&CvGV(bytecode_sv) svindex
|
||||
xcv_file CvFILE(bytecode_sv) pvcontents
|
||||
xcv_depth CvDEPTH(bytecode_sv) long
|
||||
xcv_padlist *(SV**)&CvPADLIST(bytecode_sv) svindex
|
||||
xcv_outside *(SV**)&CvOUTSIDE(bytecode_sv) svindex
|
||||
xcv_flags CvFLAGS(bytecode_sv) U16
|
||||
av_extend bytecode_sv SSize_t x
|
||||
av_push bytecode_sv svindex x
|
||||
xav_fill AvFILLp(bytecode_sv) SSize_t
|
||||
xav_max AvMAX(bytecode_sv) SSize_t
|
||||
xav_flags AvFLAGS(bytecode_sv) U8
|
||||
xhv_riter HvRITER(bytecode_sv) I32
|
||||
xhv_name HvNAME(bytecode_sv) pvcontents
|
||||
hv_store bytecode_sv svindex x
|
||||
sv_magic bytecode_sv char x
|
||||
mg_obj SvMAGIC(bytecode_sv)->mg_obj svindex
|
||||
mg_private SvMAGIC(bytecode_sv)->mg_private U16
|
||||
mg_flags SvMAGIC(bytecode_sv)->mg_flags U8
|
||||
mg_pv SvMAGIC(bytecode_sv) pvcontents x
|
||||
xmg_stash *(SV**)&SvSTASH(bytecode_sv) svindex
|
||||
gv_fetchpv bytecode_sv strconst x
|
||||
gv_stashpv bytecode_sv strconst x
|
||||
gp_sv GvSV(bytecode_sv) svindex
|
||||
gp_refcnt GvREFCNT(bytecode_sv) U32
|
||||
gp_refcnt_add GvREFCNT(bytecode_sv) I32 x
|
||||
gp_av *(SV**)&GvAV(bytecode_sv) svindex
|
||||
gp_hv *(SV**)&GvHV(bytecode_sv) svindex
|
||||
gp_cv *(SV**)&GvCV(bytecode_sv) svindex
|
||||
gp_file GvFILE(bytecode_sv) pvcontents
|
||||
gp_io *(SV**)&GvIOp(bytecode_sv) svindex
|
||||
gp_form *(SV**)&GvFORM(bytecode_sv) svindex
|
||||
gp_cvgen GvCVGEN(bytecode_sv) U32
|
||||
gp_line GvLINE(bytecode_sv) line_t
|
||||
gp_share bytecode_sv svindex x
|
||||
xgv_flags GvFLAGS(bytecode_sv) U8
|
||||
pv_cur bstate->bs_pv.xpv_cur STRLEN
|
||||
pv_free bstate->bs_pv none x
|
||||
sv_upgrade bstate->bs_sv char x
|
||||
sv_refcnt SvREFCNT(bstate->bs_sv) U32
|
||||
sv_refcnt_add SvREFCNT(bstate->bs_sv) I32 x
|
||||
sv_flags SvFLAGS(bstate->bs_sv) U32
|
||||
xrv SvRV(bstate->bs_sv) svindex
|
||||
xpv bstate->bs_sv none x
|
||||
xiv32 SvIVX(bstate->bs_sv) I32
|
||||
xiv64 SvIVX(bstate->bs_sv) IV64
|
||||
xnv SvNVX(bstate->bs_sv) NV
|
||||
xlv_targoff LvTARGOFF(bstate->bs_sv) STRLEN
|
||||
xlv_targlen LvTARGLEN(bstate->bs_sv) STRLEN
|
||||
xlv_targ LvTARG(bstate->bs_sv) svindex
|
||||
xlv_type LvTYPE(bstate->bs_sv) char
|
||||
xbm_useful BmUSEFUL(bstate->bs_sv) I32
|
||||
xbm_previous BmPREVIOUS(bstate->bs_sv) U16
|
||||
xbm_rare BmRARE(bstate->bs_sv) U8
|
||||
xfm_lines FmLINES(bstate->bs_sv) I32
|
||||
xio_lines IoLINES(bstate->bs_sv) long
|
||||
xio_page IoPAGE(bstate->bs_sv) long
|
||||
xio_page_len IoPAGE_LEN(bstate->bs_sv) long
|
||||
xio_lines_left IoLINES_LEFT(bstate->bs_sv) long
|
||||
xio_top_name IoTOP_NAME(bstate->bs_sv) pvcontents
|
||||
xio_top_gv *(SV**)&IoTOP_GV(bstate->bs_sv) svindex
|
||||
xio_fmt_name IoFMT_NAME(bstate->bs_sv) pvcontents
|
||||
xio_fmt_gv *(SV**)&IoFMT_GV(bstate->bs_sv) svindex
|
||||
xio_bottom_name IoBOTTOM_NAME(bstate->bs_sv) pvcontents
|
||||
xio_bottom_gv *(SV**)&IoBOTTOM_GV(bstate->bs_sv) svindex
|
||||
xio_subprocess IoSUBPROCESS(bstate->bs_sv) short
|
||||
xio_type IoTYPE(bstate->bs_sv) char
|
||||
xio_flags IoFLAGS(bstate->bs_sv) char
|
||||
xcv_stash *(SV**)&CvSTASH(bstate->bs_sv) svindex
|
||||
xcv_start CvSTART(bstate->bs_sv) opindex
|
||||
xcv_root CvROOT(bstate->bs_sv) opindex
|
||||
xcv_gv *(SV**)&CvGV(bstate->bs_sv) svindex
|
||||
xcv_file CvFILE(bstate->bs_sv) pvindex
|
||||
xcv_depth CvDEPTH(bstate->bs_sv) long
|
||||
xcv_padlist *(SV**)&CvPADLIST(bstate->bs_sv) svindex
|
||||
xcv_outside *(SV**)&CvOUTSIDE(bstate->bs_sv) svindex
|
||||
xcv_flags CvFLAGS(bstate->bs_sv) U16
|
||||
av_extend bstate->bs_sv SSize_t x
|
||||
av_push bstate->bs_sv svindex x
|
||||
xav_fill AvFILLp(bstate->bs_sv) SSize_t
|
||||
xav_max AvMAX(bstate->bs_sv) SSize_t
|
||||
xav_flags AvFLAGS(bstate->bs_sv) U8
|
||||
xhv_riter HvRITER(bstate->bs_sv) I32
|
||||
xhv_name HvNAME(bstate->bs_sv) pvcontents
|
||||
hv_store bstate->bs_sv svindex x
|
||||
sv_magic bstate->bs_sv char x
|
||||
mg_obj SvMAGIC(bstate->bs_sv)->mg_obj svindex
|
||||
mg_private SvMAGIC(bstate->bs_sv)->mg_private U16
|
||||
mg_flags SvMAGIC(bstate->bs_sv)->mg_flags U8
|
||||
mg_pv SvMAGIC(bstate->bs_sv) pvcontents x
|
||||
xmg_stash *(SV**)&SvSTASH(bstate->bs_sv) svindex
|
||||
gv_fetchpv bstate->bs_sv strconst x
|
||||
gv_stashpv bstate->bs_sv strconst x
|
||||
gp_sv GvSV(bstate->bs_sv) svindex
|
||||
gp_refcnt GvREFCNT(bstate->bs_sv) U32
|
||||
gp_refcnt_add GvREFCNT(bstate->bs_sv) I32 x
|
||||
gp_av *(SV**)&GvAV(bstate->bs_sv) svindex
|
||||
gp_hv *(SV**)&GvHV(bstate->bs_sv) svindex
|
||||
gp_cv *(SV**)&GvCV(bstate->bs_sv) svindex
|
||||
gp_file GvFILE(bstate->bs_sv) pvindex
|
||||
gp_io *(SV**)&GvIOp(bstate->bs_sv) svindex
|
||||
gp_form *(SV**)&GvFORM(bstate->bs_sv) svindex
|
||||
gp_cvgen GvCVGEN(bstate->bs_sv) U32
|
||||
gp_line GvLINE(bstate->bs_sv) line_t
|
||||
gp_share bstate->bs_sv svindex x
|
||||
xgv_flags GvFLAGS(bstate->bs_sv) U8
|
||||
op_next PL_op->op_next opindex
|
||||
op_sibling PL_op->op_sibling opindex
|
||||
op_ppaddr PL_op->op_ppaddr strconst x
|
||||
@ -384,7 +379,6 @@ op_private PL_op->op_private U8
|
||||
op_first cUNOP->op_first opindex
|
||||
op_last cBINOP->op_last opindex
|
||||
op_other cLOGOP->op_other opindex
|
||||
op_children cLISTOP->op_children U32
|
||||
op_pmreplroot cPMOP->op_pmreplroot opindex
|
||||
op_pmreplrootgv *(SV**)&cPMOP->op_pmreplroot svindex
|
||||
op_pmreplstart cPMOP->op_pmreplstart opindex
|
||||
@ -399,9 +393,9 @@ op_pv_tr cPVOP->op_pv op_tr_array
|
||||
op_redoop cLOOP->op_redoop opindex
|
||||
op_nextop cLOOP->op_nextop opindex
|
||||
op_lastop cLOOP->op_lastop opindex
|
||||
cop_label cCOP->cop_label pvcontents
|
||||
cop_stashpv cCOP pvcontents x
|
||||
cop_file cCOP pvcontents x
|
||||
cop_label cCOP->cop_label pvindex
|
||||
cop_stashpv cCOP pvindex x
|
||||
cop_file cCOP pvindex x
|
||||
cop_seq cCOP->cop_seq U32
|
||||
cop_arybase cCOP->cop_arybase I32
|
||||
cop_line cCOP line_t x
|
||||
@ -409,3 +403,6 @@ cop_warnings cCOP->cop_warnings svindex
|
||||
main_start PL_main_start opindex
|
||||
main_root PL_main_root opindex
|
||||
curpad PL_curpad svindex x
|
||||
push_begin PL_beginav svindex x
|
||||
push_init PL_initav svindex x
|
||||
push_end PL_endav svindex x
|
||||
|
@ -129,8 +129,8 @@ for file do
|
||||
fi
|
||||
|
||||
: Can we perhaps use $ansi2knr here
|
||||
echo "$cc -c -DPERL_CORE $ccflags $optimize $perltype $large $split"
|
||||
eval "$also "'"$cc -DPERL_CORE -c $ccflags $optimize $perltype $large $split"'
|
||||
echo "$cc -c -DPERL_CORE $ccflags $optimize $perltype"
|
||||
eval "$also "'"$cc -DPERL_CORE -c $ccflags $optimize $perltype"'
|
||||
|
||||
. $TOP/config.sh
|
||||
|
||||
|
@ -238,17 +238,6 @@ sed <<!GROK!THIS! >config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un-
|
||||
*/
|
||||
#$d_getpgid HAS_GETPGID /**/
|
||||
|
||||
/* HAS_GETPGRP:
|
||||
* This symbol, if defined, indicates that the getpgrp routine is
|
||||
* available to get the current process group.
|
||||
*/
|
||||
/* USE_BSD_GETPGRP:
|
||||
* This symbol, if defined, indicates that getpgrp needs one
|
||||
* arguments whereas USG one needs none.
|
||||
*/
|
||||
#$d_getpgrp HAS_GETPGRP /**/
|
||||
#$d_bsdgetpgrp USE_BSD_GETPGRP /**/
|
||||
|
||||
/* HAS_GETPGRP2:
|
||||
* This symbol, if defined, indicates that the getpgrp2() (as in DG/UX)
|
||||
* routine is available to get the current process group.
|
||||
@ -503,18 +492,6 @@ sed <<!GROK!THIS! >config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un-
|
||||
*/
|
||||
#$d_setpgid HAS_SETPGID /**/
|
||||
|
||||
/* HAS_SETPGRP:
|
||||
* This symbol, if defined, indicates that the setpgrp routine is
|
||||
* available to set the current process group.
|
||||
*/
|
||||
/* USE_BSD_SETPGRP:
|
||||
* This symbol, if defined, indicates that setpgrp needs two
|
||||
* arguments whereas USG one needs none. See also HAS_SETPGID
|
||||
* for a POSIX interface.
|
||||
*/
|
||||
#$d_setpgrp HAS_SETPGRP /**/
|
||||
#$d_bsdsetpgrp USE_BSD_SETPGRP /**/
|
||||
|
||||
/* HAS_SETPGRP2:
|
||||
* This symbol, if defined, indicates that the setpgrp2() (as in DG/UX)
|
||||
* routine is available to set the current process group.
|
||||
@ -998,12 +975,6 @@ sed <<!GROK!THIS! >config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un-
|
||||
*/
|
||||
#define SH_PATH "$sh" /**/
|
||||
|
||||
/* STDCHAR:
|
||||
* This symbol is defined to be the type of char used in stdio.h.
|
||||
* It has the values "unsigned char" or "char".
|
||||
*/
|
||||
#define STDCHAR $stdchar /**/
|
||||
|
||||
/* CROSSCOMPILE:
|
||||
* This symbol, if defined, signifies that we our
|
||||
* build process is a cross-compilation.
|
||||
@ -1198,21 +1169,21 @@ sed <<!GROK!THIS! >config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un-
|
||||
* This macro surrounds its token with double quotes.
|
||||
*/
|
||||
#if $cpp_stuff == 1
|
||||
# define CAT2(a,b) a/**/b
|
||||
# define STRINGIFY(a) "a"
|
||||
#define CAT2(a,b) a/**/b
|
||||
#define STRINGIFY(a) "a"
|
||||
/* If you can get stringification with catify, tell me how! */
|
||||
#endif
|
||||
#if $cpp_stuff == 42
|
||||
# define PeRl_CaTiFy(a, b) a ## b
|
||||
# define PeRl_StGiFy(a) #a
|
||||
#define PeRl_CaTiFy(a, b) a ## b
|
||||
#define PeRl_StGiFy(a) #a
|
||||
/* the additional level of indirection enables these macros to be
|
||||
* used as arguments to other macros. See K&R 2nd ed., page 231. */
|
||||
# define CAT2(a,b) PeRl_CaTiFy(a,b)
|
||||
# define StGiFy(a) PeRl_StGiFy(a)
|
||||
# define STRINGIFY(a) PeRl_StGiFy(a)
|
||||
#define CAT2(a,b) PeRl_CaTiFy(a,b)
|
||||
#define StGiFy(a) PeRl_StGiFy(a)
|
||||
#define STRINGIFY(a) PeRl_StGiFy(a)
|
||||
#endif
|
||||
#if $cpp_stuff != 1 && $cpp_stuff != 42
|
||||
#include "Bletch: How does this C preprocessor catenate tokens?"
|
||||
# include "Bletch: How does this C preprocessor catenate tokens?"
|
||||
#endif
|
||||
|
||||
/* CPPSTDIN:
|
||||
@ -1342,23 +1313,30 @@ sed <<!GROK!THIS! >config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un-
|
||||
*/
|
||||
#$d_endsent HAS_ENDSERVENT /**/
|
||||
|
||||
/* HAS_ENDSPENT:
|
||||
* This symbol, if defined, indicates that the endspent system call is
|
||||
* available to finalize the scan of SysV shadow password entries.
|
||||
*/
|
||||
#$d_endspent HAS_ENDSPENT /**/
|
||||
|
||||
/* HAS_FD_SET:
|
||||
* This symbol, when defined, indicates presence of the fd_set typedef
|
||||
* in <sys/types.h>
|
||||
*/
|
||||
#$d_fd_set HAS_FD_SET /**/
|
||||
|
||||
/* FLEXFILENAMES:
|
||||
* This symbol, if defined, indicates that the system supports filenames
|
||||
* longer than 14 characters.
|
||||
*/
|
||||
#$d_flexfnam FLEXFILENAMES /**/
|
||||
|
||||
/* HAS_FPOS64_T:
|
||||
* This symbol will be defined if the C compiler supports fpos64_t.
|
||||
*/
|
||||
#$d_fpos64_t HAS_FPOS64_T /**/
|
||||
|
||||
/* HAS_FREXPL:
|
||||
* This symbol, if defined, indicates that the frexpl routine is
|
||||
* available to break a long double floating-point number into
|
||||
* a normalized fraction and an integral power of 2.
|
||||
*/
|
||||
#$d_frexpl HAS_FREXPL /**/
|
||||
|
||||
/* HAS_STRUCT_FS_DATA:
|
||||
* This symbol, if defined, indicates that the struct fs_data
|
||||
* to do statfs() is supported.
|
||||
@ -1406,6 +1384,12 @@ sed <<!GROK!THIS! >config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un-
|
||||
*/
|
||||
#$d_getcwd HAS_GETCWD /**/
|
||||
|
||||
/* HAS_GETESPWNAM:
|
||||
* This symbol, if defined, indicates that the getespwnam system call is
|
||||
* available to retrieve enchanced (shadow) password entries by name.
|
||||
*/
|
||||
#$d_getespwnam HAS_GETESPWNAM /**/
|
||||
|
||||
/* HAS_GETFSSTAT:
|
||||
* This symbol, if defined, indicates that the getfsstat routine is
|
||||
* available to stat filesystems in bulk.
|
||||
@ -1511,6 +1495,13 @@ sed <<!GROK!THIS! >config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un-
|
||||
*/
|
||||
#$d_getnetprotos HAS_GETNET_PROTOS /**/
|
||||
|
||||
/* HAS_GETPAGESIZE:
|
||||
* This symbol, if defined, indicates that the getpagesize system call
|
||||
* is available to get system page size, which is the granularity of
|
||||
* many memory management calls.
|
||||
*/
|
||||
#$d_getpagsz HAS_GETPAGESIZE /**/
|
||||
|
||||
/* HAS_GETPROTOENT:
|
||||
* This symbol, if defined, indicates that the getprotoent() routine is
|
||||
* available to look up protocols in some data base or another.
|
||||
@ -1536,6 +1527,12 @@ sed <<!GROK!THIS! >config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un-
|
||||
*/
|
||||
#$d_getprotoprotos HAS_GETPROTO_PROTOS /**/
|
||||
|
||||
/* HAS_GETPRPWNAM:
|
||||
* This symbol, if defined, indicates that the getprpwnam system call is
|
||||
* available to retrieve protected (shadow) password entries by name.
|
||||
*/
|
||||
#$d_getprpwnam HAS_GETPRPWNAM /**/
|
||||
|
||||
/* HAS_GETPWENT:
|
||||
* This symbol, if defined, indicates that the getpwent routine is
|
||||
* available for sequential access of the passwd database.
|
||||
@ -1557,12 +1554,6 @@ sed <<!GROK!THIS! >config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un-
|
||||
*/
|
||||
#$d_getservprotos HAS_GETSERV_PROTOS /**/
|
||||
|
||||
/* HAS_GETSPENT:
|
||||
* This symbol, if defined, indicates that the getspent system call is
|
||||
* available to retrieve SysV shadow password entries sequentially.
|
||||
*/
|
||||
#$d_getspent HAS_GETSPENT /**/
|
||||
|
||||
/* HAS_GETSPNAM:
|
||||
* This symbol, if defined, indicates that the getspnam system call is
|
||||
* available to retrieve SysV shadow password entries by name.
|
||||
@ -1638,6 +1629,25 @@ sed <<!GROK!THIS! >config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un-
|
||||
*/
|
||||
#$d_isascii HAS_ISASCII /**/
|
||||
|
||||
/* HAS_ISNAN:
|
||||
* This symbol, if defined, indicates that the isnan routine is
|
||||
* available to check whether a double is a NaN.
|
||||
*/
|
||||
#$d_isnan HAS_ISNAN /**/
|
||||
|
||||
/* HAS_ISNANL:
|
||||
* This symbol, if defined, indicates that the isnanl routine is
|
||||
* available to check whether a long double is a NaN.
|
||||
*/
|
||||
#$d_isnanl HAS_ISNANL /**/
|
||||
|
||||
/* HAS_LCHOWN:
|
||||
* This symbol, if defined, indicates that the lchown routine is
|
||||
* available to operate on a symbolic link (instead of following the
|
||||
* link).
|
||||
*/
|
||||
#$d_lchown HAS_LCHOWN /**/
|
||||
|
||||
/* HAS_LDBL_DIG:
|
||||
* This symbol, if defined, indicates that this system's <float.h>
|
||||
* or <limits.h> defines the symbol LDBL_DIG, which is the number
|
||||
@ -1725,6 +1735,13 @@ sed <<!GROK!THIS! >config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un-
|
||||
#$d_mmap HAS_MMAP /**/
|
||||
#define Mmap_t $mmaptype /**/
|
||||
|
||||
/* HAS_MODFL:
|
||||
* This symbol, if defined, indicates that the modfl routine is
|
||||
* available to split a long double x into a fractional part f and
|
||||
* an integer part i such that |f| < 1.0 and (f + i) = x.
|
||||
*/
|
||||
#$d_modfl HAS_MODFL /**/
|
||||
|
||||
/* HAS_MPROTECT:
|
||||
* This symbol, if defined, indicates that the mprotect system call is
|
||||
* available to modify the access protection of a memory mapped file.
|
||||
@ -1855,12 +1872,6 @@ sed <<!GROK!THIS! >config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un-
|
||||
*/
|
||||
#$d_setsent HAS_SETSERVENT /**/
|
||||
|
||||
/* HAS_SETSPENT:
|
||||
* This symbol, if defined, indicates that the setspent system call is
|
||||
* available to initialize the scan of SysV shadow password entries.
|
||||
*/
|
||||
#$d_setspent HAS_SETSPENT /**/
|
||||
|
||||
/* HAS_SETVBUF:
|
||||
* This symbol, if defined, indicates that the setvbuf routine is
|
||||
* available to change buffering on an open stdio stream.
|
||||
@ -1964,6 +1975,12 @@ sed <<!GROK!THIS! >config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un-
|
||||
#$d_msg_proxy HAS_MSG_PROXY /**/
|
||||
#$d_scm_rights HAS_SCM_RIGHTS /**/
|
||||
|
||||
/* HAS_SOCKS5_INIT:
|
||||
* This symbol, if defined, indicates that the socks5_init routine is
|
||||
* available to initialize SOCKS 5.
|
||||
*/
|
||||
#$d_socks5_init HAS_SOCKS5_INIT /**/
|
||||
|
||||
/* HAS_SQRTL:
|
||||
* This symbol, if defined, indicates that the sqrtl routine is
|
||||
* available to do long double square roots.
|
||||
@ -2026,12 +2043,23 @@ sed <<!GROK!THIS! >config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un-
|
||||
* This symbol is defined if the FILE_cnt macro can be used as an
|
||||
* lvalue.
|
||||
*/
|
||||
/* STDIO_PTR_LVAL_SETS_CNT:
|
||||
* This symbol is defined if using the FILE_ptr macro as an lvalue
|
||||
* to increase the pointer by n has the side effect of decreasing the
|
||||
* value of File_cnt(fp) by n.
|
||||
*/
|
||||
/* STDIO_PTR_LVAL_NOCHANGE_CNT:
|
||||
* This symbol is defined if using the FILE_ptr macro as an lvalue
|
||||
* to increase the pointer by n leaves File_cnt(fp) unchanged.
|
||||
*/
|
||||
#$d_stdstdio USE_STDIO_PTR /**/
|
||||
#ifdef USE_STDIO_PTR
|
||||
#define FILE_ptr(fp) $stdio_ptr
|
||||
#$d_stdio_ptr_lval STDIO_PTR_LVALUE /**/
|
||||
#define FILE_cnt(fp) $stdio_cnt
|
||||
#$d_stdio_cnt_lval STDIO_CNT_LVALUE /**/
|
||||
#$d_stdio_ptr_lval_sets_cnt STDIO_PTR_LVAL_SETS_CNT /**/
|
||||
#$d_stdio_ptr_lval_nochange_cnt STDIO_PTR_LVAL_NOCHANGE_CNT /**/
|
||||
#endif
|
||||
|
||||
/* USE_STDIO_BASE:
|
||||
@ -2299,6 +2327,12 @@ sed <<!GROK!THIS! >config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un-
|
||||
*/
|
||||
#$i_inttypes I_INTTYPES /**/
|
||||
|
||||
/* I_LIBUTIL:
|
||||
* This symbol, if defined, indicates that <libutil.h> exists and
|
||||
* should be included.
|
||||
*/
|
||||
#$i_libutil I_LIBUTIL /**/
|
||||
|
||||
/* I_MACH_CTHREADS:
|
||||
* This symbol, if defined, indicates to the C program that it should
|
||||
* include <mach/cthreads.h>.
|
||||
@ -2329,6 +2363,12 @@ sed <<!GROK!THIS! >config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un-
|
||||
*/
|
||||
#$i_poll I_POLL /**/
|
||||
|
||||
/* I_PROT:
|
||||
* This symbol, if defined, indicates that <prot.h> exists and
|
||||
* should be included.
|
||||
*/
|
||||
#$i_prot I_PROT /**/
|
||||
|
||||
/* I_PTHREAD:
|
||||
* This symbol, if defined, indicates to the C program that it should
|
||||
* include <pthread.h>.
|
||||
@ -2491,8 +2531,18 @@ sed <<!GROK!THIS! >config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un-
|
||||
* This symbol, if defined, contains the string used by stdio to
|
||||
* format long doubles (format 'g') for output.
|
||||
*/
|
||||
/* PERL_PRIeldbl:
|
||||
* This symbol, if defined, contains the string used by stdio to
|
||||
* format long doubles (format 'e') for output.
|
||||
*/
|
||||
/* PERL_SCNfldbl:
|
||||
* This symbol, if defined, contains the string used by stdio to
|
||||
* format long doubles (format 'f') for input.
|
||||
*/
|
||||
#$d_PRIfldbl PERL_PRIfldbl $sPRIfldbl /**/
|
||||
#$d_PRIgldbl PERL_PRIgldbl $sPRIgldbl /**/
|
||||
#$d_PRIeldbl PERL_PRIeldbl $sPRIeldbl /**/
|
||||
#$d_SCNfldbl PERL_SCNfldbl $sSCNfldbl /**/
|
||||
|
||||
/* Off_t:
|
||||
* This symbol holds the type used to declare offsets in the kernel.
|
||||
@ -2580,6 +2630,16 @@ sed <<!GROK!THIS! >config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un-
|
||||
#define Netdb_name_t $netdb_name_type /**/
|
||||
#define Netdb_net_t $netdb_net_type /**/
|
||||
|
||||
/* PERL_OTHERLIBDIRS:
|
||||
* This variable contains a colon-separated set of paths for the perl
|
||||
* binary to search for additional library files or modules.
|
||||
* These directories will be tacked to the end of @INC.
|
||||
* Perl will automatically search below each path for version-
|
||||
* and architecture-specific directories. See PERL_INC_VERSION_LIST
|
||||
* for more details.
|
||||
*/
|
||||
#$d_perl_otherlibdirs PERL_OTHERLIBDIRS "$otherlibdirs" /**/
|
||||
|
||||
/* IVTYPE:
|
||||
* This symbol defines the C type used for Perl's IV.
|
||||
*/
|
||||
@ -2643,9 +2703,16 @@ sed <<!GROK!THIS! >config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un-
|
||||
/* U64SIZE:
|
||||
* This symbol contains the sizeof(U64).
|
||||
*/
|
||||
/* NVSIZE:
|
||||
* This symbol contains the sizeof(NV).
|
||||
*/
|
||||
/* NV_PRESERVES_UV:
|
||||
* This symbol, if defined, indicates that a variable of type NVTYPE
|
||||
* can preserve all the bit of a variable of type UVSIZE.
|
||||
* can preserve all the bits of a variable of type UVTYPE.
|
||||
*/
|
||||
/* NV_PRESERVES_UV_BITS:
|
||||
* This symbol contains the number of bits a variable of type NVTYPE
|
||||
* can preserve of a variable of type UVTYPE.
|
||||
*/
|
||||
#define IVTYPE $ivtype /**/
|
||||
#define UVTYPE $uvtype /**/
|
||||
@ -2672,7 +2739,9 @@ sed <<!GROK!THIS! >config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un-
|
||||
#define I64SIZE $i64size /**/
|
||||
#define U64SIZE $u64size /**/
|
||||
#endif
|
||||
#define NVSIZE $nvsize /**/
|
||||
#$d_nv_preserves_uv NV_PRESERVES_UV
|
||||
#define NV_PRESERVES_UV_BITS $d_nv_preserves_uv_bits
|
||||
|
||||
/* IVdf:
|
||||
* This symbol defines the format string used for printing a Perl IV
|
||||
@ -2688,12 +2757,27 @@ sed <<!GROK!THIS! >config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un-
|
||||
*/
|
||||
/* UVxf:
|
||||
* This symbol defines the format string used for printing a Perl UV
|
||||
* as an unsigned hexadecimal integer.
|
||||
* as an unsigned hexadecimal integer in lowercase abcdef.
|
||||
*/
|
||||
/* NVef:
|
||||
* This symbol defines the format string used for printing a Perl NV
|
||||
* using %e-ish floating point format.
|
||||
*/
|
||||
/* NVff:
|
||||
* This symbol defines the format string used for printing a Perl NV
|
||||
* using %f-ish floating point format.
|
||||
*/
|
||||
/* NVgf:
|
||||
* This symbol defines the format string used for printing a Perl NV
|
||||
* using %g-ish floating point format.
|
||||
*/
|
||||
#define IVdf $ivdformat /**/
|
||||
#define UVuf $uvuformat /**/
|
||||
#define UVof $uvoformat /**/
|
||||
#define UVxf $uvxformat /**/
|
||||
#define NVef $nveformat /**/
|
||||
#define NVff $nvfformat /**/
|
||||
#define NVgf $nvgformat /**/
|
||||
|
||||
/* Pid_t:
|
||||
* This symbol holds the type used to declare process ids in the kernel.
|
||||
@ -3092,24 +3176,63 @@ sed <<!GROK!THIS! >config.h -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un-
|
||||
#define PERL_XS_APIVERSION "$xs_apiversion"
|
||||
#define PERL_PM_APIVERSION "$pm_apiversion"
|
||||
|
||||
/* HAS_LCHOWN:
|
||||
* This symbol, if defined, indicates that the lchown routine is
|
||||
* available to operate on a symbolic link (instead of following the
|
||||
* link).
|
||||
/* HAS_GETPGRP:
|
||||
* This symbol, if defined, indicates that the getpgrp routine is
|
||||
* available to get the current process group.
|
||||
*/
|
||||
#$d_lchown HAS_LCHOWN /**/
|
||||
/* USE_BSD_GETPGRP:
|
||||
* This symbol, if defined, indicates that getpgrp needs one
|
||||
* arguments whereas USG one needs none.
|
||||
*/
|
||||
#$d_getpgrp HAS_GETPGRP /**/
|
||||
#$d_bsdgetpgrp USE_BSD_GETPGRP /**/
|
||||
|
||||
/* FLEXFILENAMES:
|
||||
* This symbol, if defined, indicates that the system supports filenames
|
||||
* longer than 14 characters.
|
||||
/* HAS_SETPGRP:
|
||||
* This symbol, if defined, indicates that the setpgrp routine is
|
||||
* available to set the current process group.
|
||||
*/
|
||||
#$d_flexfnam FLEXFILENAMES /**/
|
||||
/* USE_BSD_SETPGRP:
|
||||
* This symbol, if defined, indicates that setpgrp needs two
|
||||
* arguments whereas USG one needs none. See also HAS_SETPGID
|
||||
* for a POSIX interface.
|
||||
*/
|
||||
#$d_setpgrp HAS_SETPGRP /**/
|
||||
#$d_bsdsetpgrp USE_BSD_SETPGRP /**/
|
||||
|
||||
/* I_LIBUTIL:
|
||||
* This symbol, if defined, indicates that <libutil.h> exists and
|
||||
* should be included.
|
||||
/* STDCHAR:
|
||||
* This symbol is defined to be the type of char used in stdio.h.
|
||||
* It has the values "unsigned char" or "char".
|
||||
*/
|
||||
#$i_libutil I_LIBUTIL /**/
|
||||
#define STDCHAR $stdchar /**/
|
||||
|
||||
/* HAS__FWALK:
|
||||
* This symbol, if defined, indicates that the _fwalk system call is
|
||||
* available to apply a function to all the file handles.
|
||||
*/
|
||||
#$d__fwalk HAS__FWALK /**/
|
||||
|
||||
/* FCNTL_CAN_LOCK:
|
||||
* This symbol, if defined, indicates that fcntl() can be used
|
||||
* for file locking. Normally on Unix systems this is defined.
|
||||
* It may be undefined on VMS.
|
||||
*/
|
||||
#$d_fcntl_can_lock FCNTL_CAN_LOCK /**/
|
||||
|
||||
/* HAS_FSYNC:
|
||||
* This symbol, if defined, indicates that the fsync routine is
|
||||
* available to write a file's modified data and attributes to
|
||||
* permanent storage.
|
||||
*/
|
||||
#$d_fsync HAS_FSYNC /**/
|
||||
|
||||
/* HAS_SBRK_PROTO:
|
||||
* This symbol, if defined, indicates that the system provides
|
||||
* a prototype for the sbrk() function. Otherwise, it is up
|
||||
* to the program to supply one. Good guesses are
|
||||
* extern void* sbrk _((int));
|
||||
* extern void* sbrk _((size_t));
|
||||
*/
|
||||
#$d_sbrkproto HAS_SBRK_PROTO /**/
|
||||
|
||||
#endif
|
||||
!GROK!THIS!
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -86,7 +86,7 @@ EOM
|
||||
exit 1
|
||||
;;
|
||||
*)
|
||||
opts="$opts $1"
|
||||
opts="$opts '$1'"
|
||||
shift
|
||||
;;
|
||||
esac
|
||||
@ -126,7 +126,7 @@ case "$verbose" in
|
||||
*) copt="$copt -d";;
|
||||
esac
|
||||
|
||||
set X sh Configure $copt $create $opts
|
||||
eval "set X sh Configure $copt $create $opts"
|
||||
shift
|
||||
echo "$@"
|
||||
exec "$@"
|
||||
|
@ -1,6 +1,6 @@
|
||||
/* cop.h
|
||||
*
|
||||
* Copyright (c) 1991-2000, Larry Wall
|
||||
* Copyright (c) 1991-2001, Larry Wall
|
||||
*
|
||||
* You may distribute under the terms of either the GNU General Public
|
||||
* License or the Artistic License, as specified in the README file.
|
||||
@ -29,32 +29,33 @@ struct cop {
|
||||
# define CopFILE(c) ((c)->cop_file)
|
||||
# define CopFILEGV(c) (CopFILE(c) \
|
||||
? gv_fetchfile(CopFILE(c)) : Nullgv)
|
||||
# define CopFILE_set(c,pv) ((c)->cop_file = savepv(pv)) /* XXX */
|
||||
# define CopFILE_set(c,pv) ((c)->cop_file = savepv(pv))
|
||||
# define CopFILESV(c) (CopFILE(c) \
|
||||
? GvSV(gv_fetchfile(CopFILE(c))) : Nullsv)
|
||||
# define CopFILEAV(c) (CopFILE(c) \
|
||||
? GvAV(gv_fetchfile(CopFILE(c))) : Nullav)
|
||||
# define CopSTASHPV(c) ((c)->cop_stashpv)
|
||||
# define CopSTASHPV_set(c,pv) ((c)->cop_stashpv = savepv(pv)) /* XXX */
|
||||
# define CopSTASHPV_set(c,pv) ((c)->cop_stashpv = ((pv) ? savepv(pv) : Nullch))
|
||||
# define CopSTASH(c) (CopSTASHPV(c) \
|
||||
? gv_stashpv(CopSTASHPV(c),GV_ADD) : Nullhv)
|
||||
# define CopSTASH_set(c,hv) CopSTASHPV_set(c, HvNAME(hv))
|
||||
# define CopSTASH_eq(c,hv) (hv \
|
||||
# define CopSTASH_set(c,hv) CopSTASHPV_set(c, (hv) ? HvNAME(hv) : Nullch)
|
||||
# define CopSTASH_eq(c,hv) ((hv) \
|
||||
&& (CopSTASHPV(c) == HvNAME(hv) \
|
||||
|| (CopSTASHPV(c) && HvNAME(hv) \
|
||||
&& strEQ(CopSTASHPV(c), HvNAME(hv)))))
|
||||
#else
|
||||
# define CopFILEGV(c) ((c)->cop_filegv)
|
||||
# define CopFILEGV_set(c,gv) ((c)->cop_filegv = gv)
|
||||
# define CopFILE_set(c,pv) ((c)->cop_filegv = gv_fetchfile(pv))
|
||||
# define CopFILEGV_set(c,gv) ((c)->cop_filegv = (GV*)SvREFCNT_inc(gv))
|
||||
# define CopFILE_set(c,pv) CopFILEGV_set((c), gv_fetchfile(pv))
|
||||
# define CopFILESV(c) (CopFILEGV(c) ? GvSV(CopFILEGV(c)) : Nullsv)
|
||||
# define CopFILEAV(c) (CopFILEGV(c) ? GvAV(CopFILEGV(c)) : Nullav)
|
||||
# define CopFILE(c) (CopFILESV(c) ? SvPVX(CopFILESV(c)) : Nullch)
|
||||
# define CopSTASH(c) ((c)->cop_stash)
|
||||
# define CopSTASH_set(c,hv) ((c)->cop_stash = hv)
|
||||
# define CopSTASH_set(c,hv) ((c)->cop_stash = (hv))
|
||||
# define CopSTASHPV(c) (CopSTASH(c) ? HvNAME(CopSTASH(c)) : Nullch)
|
||||
# define CopSTASHPV_set(c,pv) CopSTASH_set(c, gv_stashpv(pv,GV_ADD))
|
||||
# define CopSTASH_eq(c,hv) (CopSTASH(c) == hv)
|
||||
/* cop_stash is not refcounted */
|
||||
# define CopSTASHPV_set(c,pv) CopSTASH_set((c), gv_stashpv(pv,GV_ADD))
|
||||
# define CopSTASH_eq(c,hv) (CopSTASH(c) == (hv))
|
||||
#endif /* USE_ITHREADS */
|
||||
|
||||
#define CopSTASH_ne(c,hv) (!CopSTASH_eq(c,hv))
|
||||
@ -79,6 +80,7 @@ struct block_sub {
|
||||
U16 olddepth;
|
||||
U8 hasargs;
|
||||
U8 lval; /* XXX merge lval and hasargs? */
|
||||
SV ** oldcurpad;
|
||||
};
|
||||
|
||||
#define PUSHSUB(cx) \
|
||||
@ -105,13 +107,14 @@ struct block_sub {
|
||||
} STMT_END
|
||||
#endif /* USE_THREADS */
|
||||
|
||||
#ifdef USE_ITHREADS
|
||||
/* junk in @_ spells trouble when cloning CVs, so don't leave any */
|
||||
# define CLEAR_ARGARRAY() av_clear(cx->blk_sub.argarray)
|
||||
#else
|
||||
# define CLEAR_ARGARRAY() NOOP
|
||||
#endif /* USE_ITHREADS */
|
||||
|
||||
/* junk in @_ spells trouble when cloning CVs and in pp_caller(), so don't
|
||||
* leave any (a fast av_clear(ary), basically) */
|
||||
#define CLEAR_ARGARRAY(ary) \
|
||||
STMT_START { \
|
||||
AvMAX(ary) += AvARRAY(ary) - AvALLOC(ary); \
|
||||
SvPVX(ary) = (char*)AvALLOC(ary); \
|
||||
AvFILLp(ary) = -1; \
|
||||
} STMT_END
|
||||
|
||||
#define POPSUB(cx,sv) \
|
||||
STMT_START { \
|
||||
@ -124,10 +127,10 @@ struct block_sub {
|
||||
cx->blk_sub.argarray = newAV(); \
|
||||
av_extend(cx->blk_sub.argarray, fill); \
|
||||
AvFLAGS(cx->blk_sub.argarray) = AVf_REIFY; \
|
||||
PL_curpad[0] = (SV*)cx->blk_sub.argarray; \
|
||||
cx->blk_sub.oldcurpad[0] = (SV*)cx->blk_sub.argarray; \
|
||||
} \
|
||||
else { \
|
||||
CLEAR_ARGARRAY(); \
|
||||
CLEAR_ARGARRAY(cx->blk_sub.argarray); \
|
||||
} \
|
||||
} \
|
||||
sv = (SV*)cx->blk_sub.cv; \
|
||||
@ -390,7 +393,7 @@ Used to indicate scalar context. See C<GIMME_V>, C<GIMME>, and
|
||||
L<perlcall>.
|
||||
|
||||
=for apidoc AmU||G_ARRAY
|
||||
Used to indicate array context. See C<GIMME_V>, C<GIMME> and
|
||||
Used to indicate list context. See C<GIMME_V>, C<GIMME> and
|
||||
L<perlcall>.
|
||||
|
||||
=for apidoc AmU||G_VOID
|
||||
@ -423,12 +426,14 @@ L<perlcall>.
|
||||
#define G_NOARGS 8 /* Don't construct a @_ array. */
|
||||
#define G_KEEPERR 16 /* Append errors to $@, don't overwrite it */
|
||||
#define G_NODEBUG 32 /* Disable debugging at toplevel. */
|
||||
#define G_METHOD 64 /* Calling method. */
|
||||
|
||||
/* flag bits for PL_in_eval */
|
||||
#define EVAL_NULL 0 /* not in an eval */
|
||||
#define EVAL_INEVAL 1 /* some enclosing scope is an eval */
|
||||
#define EVAL_WARNONLY 2 /* used by yywarn() when calling yyerror() */
|
||||
#define EVAL_KEEPERR 4 /* set by Perl_call_sv if G_KEEPERR */
|
||||
#define EVAL_INREQUIRE 8 /* The code is being required. */
|
||||
|
||||
/* Support for switching (stack and block) contexts.
|
||||
* This ensures magic doesn't invalidate local stack and cx pointers.
|
||||
@ -494,7 +499,7 @@ typedef struct stackinfo PERL_SI;
|
||||
* PUTBACK/SPAGAIN to flush/refresh any local SP that may be active */
|
||||
#define POPSTACK \
|
||||
STMT_START { \
|
||||
djSP; \
|
||||
dSP; \
|
||||
PERL_SI *prev = PL_curstackinfo->si_prev; \
|
||||
if (!prev) { \
|
||||
PerlIO_printf(Perl_error_log, "panic: POPSTACK\n"); \
|
||||
|
@ -1,6 +1,6 @@
|
||||
/* cv.h
|
||||
*
|
||||
* Copyright (c) 1991-2000, Larry Wall
|
||||
* Copyright (c) 1991-2001, Larry Wall
|
||||
*
|
||||
* You may distribute under the terms of either the GNU General Public
|
||||
* License or the Artistic License, as specified in the README file.
|
||||
|
@ -1,6 +1,6 @@
|
||||
/* deb.c
|
||||
*
|
||||
* Copyright (c) 1991-2000, Larry Wall
|
||||
* Copyright (c) 1991-2001, Larry Wall
|
||||
*
|
||||
* You may distribute under the terms of either the GNU General Public
|
||||
* License or the Artistic License, as specified in the README file.
|
||||
@ -45,7 +45,6 @@ void
|
||||
Perl_vdeb(pTHX_ const char *pat, va_list *args)
|
||||
{
|
||||
#ifdef DEBUGGING
|
||||
dTHR;
|
||||
char* file = CopFILE(PL_curcop);
|
||||
|
||||
#ifdef USE_THREADS
|
||||
@ -65,7 +64,6 @@ I32
|
||||
Perl_debstackptrs(pTHX)
|
||||
{
|
||||
#ifdef DEBUGGING
|
||||
dTHR;
|
||||
PerlIO_printf(Perl_debug_log,
|
||||
"%8"UVxf" %8"UVxf" %8"IVdf" %8"IVdf" %8"IVdf"\n",
|
||||
PTR2UV(PL_curstack), PTR2UV(PL_stack_base),
|
||||
@ -84,7 +82,6 @@ I32
|
||||
Perl_debstack(pTHX)
|
||||
{
|
||||
#ifdef DEBUGGING
|
||||
dTHR;
|
||||
I32 top = PL_stack_sp - PL_stack_base;
|
||||
register I32 i = top - 30;
|
||||
I32 *markscan = PL_markstack + PL_curstackinfo->si_markoff;
|
||||
|
@ -1,6 +1,6 @@
|
||||
/* doio.c
|
||||
*
|
||||
* Copyright (c) 1991-2000, Larry Wall
|
||||
* Copyright (c) 1991-2001, Larry Wall
|
||||
*
|
||||
* You may distribute under the terms of either the GNU General Public
|
||||
* License or the Artistic License, as specified in the README file.
|
||||
@ -51,26 +51,6 @@
|
||||
#include <signal.h>
|
||||
#endif
|
||||
|
||||
/* XXX If this causes problems, set i_unistd=undef in the hint file. */
|
||||
#ifdef I_UNISTD
|
||||
# include <unistd.h>
|
||||
#endif
|
||||
|
||||
#if defined(HAS_SOCKET) && !defined(VMS) /* VMS handles sockets via vmsish.h */
|
||||
# include <sys/socket.h>
|
||||
# if defined(USE_SOCKS) && defined(I_SOCKS)
|
||||
# include <socks.h>
|
||||
# endif
|
||||
# ifdef I_NETBSD
|
||||
# include <netdb.h>
|
||||
# endif
|
||||
# ifndef ENOTSOCK
|
||||
# ifdef I_NET_ERRNO
|
||||
# include <net/errno.h>
|
||||
# endif
|
||||
# endif
|
||||
#endif
|
||||
|
||||
bool
|
||||
Perl_do_open(pTHX_ GV *gv, register char *name, I32 len, int as_raw,
|
||||
int rawmode, int rawperm, PerlIO *supplied_fp)
|
||||
@ -87,7 +67,7 @@ Perl_do_open9(pTHX_ GV *gv, register char *name, I32 len, int as_raw,
|
||||
register IO *io = GvIOn(gv);
|
||||
PerlIO *saveifp = Nullfp;
|
||||
PerlIO *saveofp = Nullfp;
|
||||
char savetype = ' ';
|
||||
char savetype = IoTYPE_CLOSED;
|
||||
int writing = 0;
|
||||
PerlIO *fp;
|
||||
int fd;
|
||||
@ -108,7 +88,7 @@ Perl_do_open9(pTHX_ GV *gv, register char *name, I32 len, int as_raw,
|
||||
|
||||
if (IoIFP(io)) {
|
||||
fd = PerlIO_fileno(IoIFP(io));
|
||||
if (IoTYPE(io) == '-')
|
||||
if (IoTYPE(io) == IoTYPE_STD)
|
||||
result = 0;
|
||||
else if (fd <= PL_maxsysfd) {
|
||||
saveifp = IoIFP(io);
|
||||
@ -116,7 +96,7 @@ Perl_do_open9(pTHX_ GV *gv, register char *name, I32 len, int as_raw,
|
||||
savetype = IoTYPE(io);
|
||||
result = 0;
|
||||
}
|
||||
else if (IoTYPE(io) == '|')
|
||||
else if (IoTYPE(io) == IoTYPE_PIPE)
|
||||
result = PerlProc_pclose(IoIFP(io));
|
||||
else if (IoIFP(io) != IoOFP(io)) {
|
||||
if (IoOFP(io)) {
|
||||
@ -146,14 +126,14 @@ Perl_do_open9(pTHX_ GV *gv, register char *name, I32 len, int as_raw,
|
||||
|
||||
switch (result = rawmode & O_ACCMODE) {
|
||||
case O_RDONLY:
|
||||
IoTYPE(io) = '<';
|
||||
IoTYPE(io) = IoTYPE_RDONLY;
|
||||
break;
|
||||
case O_WRONLY:
|
||||
IoTYPE(io) = '>';
|
||||
IoTYPE(io) = IoTYPE_WRONLY;
|
||||
break;
|
||||
case O_RDWR:
|
||||
default:
|
||||
IoTYPE(io) = '+';
|
||||
IoTYPE(io) = IoTYPE_RDWR;
|
||||
break;
|
||||
}
|
||||
|
||||
@ -216,14 +196,14 @@ Perl_do_open9(pTHX_ GV *gv, register char *name, I32 len, int as_raw,
|
||||
}
|
||||
mode[0] = mode[1] = mode[2] = mode[3] = '\0';
|
||||
IoTYPE(io) = *type;
|
||||
if (*type == '+' && tlen > 1 && type[tlen-1] != '|') { /* scary */
|
||||
if (*type == IoTYPE_RDWR && tlen > 1 && type[tlen-1] != IoTYPE_PIPE) { /* scary */
|
||||
mode[1] = *type++;
|
||||
--tlen;
|
||||
writing = 1;
|
||||
}
|
||||
|
||||
if (*type == '|') {
|
||||
if (num_svs && (tlen != 2 || type[1] != '-')) {
|
||||
if (*type == IoTYPE_PIPE) {
|
||||
if (num_svs && (tlen != 2 || type[1] != IoTYPE_STD)) {
|
||||
unknown_desr:
|
||||
Perl_croak(aTHX_ "Unknown open() mode '%.*s'", (int)olen, oname);
|
||||
}
|
||||
@ -234,7 +214,6 @@ Perl_do_open9(pTHX_ GV *gv, register char *name, I32 len, int as_raw,
|
||||
len = tlen;
|
||||
}
|
||||
if (*name == '\0') { /* command is missing 19990114 */
|
||||
dTHR;
|
||||
if (ckWARN(WARN_PIPE))
|
||||
Perl_warner(aTHX_ WARN_PIPE, "Missing command in piped open");
|
||||
errno = EPIPE;
|
||||
@ -244,7 +223,6 @@ Perl_do_open9(pTHX_ GV *gv, register char *name, I32 len, int as_raw,
|
||||
TAINT_ENV();
|
||||
TAINT_PROPER("piped open");
|
||||
if (name[len-1] == '|') {
|
||||
dTHR;
|
||||
name[--len] = '\0' ;
|
||||
if (ckWARN(WARN_PIPE))
|
||||
Perl_warner(aTHX_ WARN_PIPE, "Can't open bidirectional pipe");
|
||||
@ -261,11 +239,12 @@ Perl_do_open9(pTHX_ GV *gv, register char *name, I32 len, int as_raw,
|
||||
}
|
||||
writing = 1;
|
||||
}
|
||||
else if (*type == '>') {
|
||||
else if (*type == IoTYPE_WRONLY) {
|
||||
TAINT_PROPER("open");
|
||||
type++;
|
||||
if (*type == '>') {
|
||||
mode[0] = IoTYPE(io) = 'a';
|
||||
if (*type == IoTYPE_WRONLY) {
|
||||
/* Two IoTYPE_WRONLYs in a row make for an IoTYPE_APPEND. */
|
||||
mode[0] = IoTYPE(io) = IoTYPE_APPEND;
|
||||
type++;
|
||||
tlen--;
|
||||
}
|
||||
@ -313,15 +292,30 @@ Perl_do_open9(pTHX_ GV *gv, register char *name, I32 len, int as_raw,
|
||||
* be optimized away on most platforms;
|
||||
* only Solaris and Linux seem to flush
|
||||
* on that. --jhi */
|
||||
PerlIO_seek(fp, 0, SEEK_CUR);
|
||||
#ifdef USE_SFIO
|
||||
/* sfio fails to clear error on next
|
||||
sfwrite, contrary to documentation.
|
||||
-- Nick Clark */
|
||||
if (PerlIO_seek(fp, 0, SEEK_CUR) == -1)
|
||||
PerlIO_clearerr(fp);
|
||||
#endif
|
||||
/* On the other hand, do all platforms
|
||||
* take gracefully to flushing a read-only
|
||||
* filehandle? Perhaps we should do
|
||||
* fsetpos(src)+fgetpos(dst)? --nik */
|
||||
PerlIO_flush(fp);
|
||||
fd = PerlIO_fileno(fp);
|
||||
if (IoTYPE(thatio) == 's')
|
||||
IoTYPE(io) = 's';
|
||||
/* When dup()ing STDIN, STDOUT or STDERR
|
||||
* explicitly set appropriate access mode */
|
||||
if (IoIFP(thatio) == PerlIO_stdout()
|
||||
|| IoIFP(thatio) == PerlIO_stderr())
|
||||
IoTYPE(io) = IoTYPE_WRONLY;
|
||||
else if (IoIFP(thatio) == PerlIO_stdin())
|
||||
IoTYPE(io) = IoTYPE_RDONLY;
|
||||
/* When dup()ing a socket, say result is
|
||||
* one as well */
|
||||
else if (IoTYPE(thatio) == IoTYPE_SOCKET)
|
||||
IoTYPE(io) = IoTYPE_SOCKET;
|
||||
}
|
||||
else
|
||||
fd = -1;
|
||||
@ -339,16 +333,16 @@ Perl_do_open9(pTHX_ GV *gv, register char *name, I32 len, int as_raw,
|
||||
else {
|
||||
/*SUPPRESS 530*/
|
||||
for (; isSPACE(*type); type++) ;
|
||||
if (strEQ(type,"-")) {
|
||||
if (*type == IoTYPE_STD && !type[1]) {
|
||||
fp = PerlIO_stdout();
|
||||
IoTYPE(io) = '-';
|
||||
IoTYPE(io) = IoTYPE_STD;
|
||||
}
|
||||
else {
|
||||
fp = PerlIO_open((num_svs ? name : type), mode);
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (*type == '<') {
|
||||
else if (*type == IoTYPE_RDONLY) {
|
||||
if (num_svs && tlen != 1)
|
||||
goto unknown_desr;
|
||||
/*SUPPRESS 530*/
|
||||
@ -363,16 +357,16 @@ Perl_do_open9(pTHX_ GV *gv, register char *name, I32 len, int as_raw,
|
||||
name = type;
|
||||
goto duplicity;
|
||||
}
|
||||
if (strEQ(type,"-")) {
|
||||
if (*type == IoTYPE_STD && !type[1]) {
|
||||
fp = PerlIO_stdin();
|
||||
IoTYPE(io) = '-';
|
||||
IoTYPE(io) = IoTYPE_STD;
|
||||
}
|
||||
else
|
||||
fp = PerlIO_open((num_svs ? name : type), mode);
|
||||
}
|
||||
else if (tlen > 1 && type[tlen-1] == '|') {
|
||||
else if (tlen > 1 && type[tlen-1] == IoTYPE_PIPE) {
|
||||
if (num_svs) {
|
||||
if (tlen != 2 || type[0] != '-')
|
||||
if (tlen != 2 || type[0] != IoTYPE_STD)
|
||||
goto unknown_desr;
|
||||
}
|
||||
else {
|
||||
@ -384,7 +378,6 @@ Perl_do_open9(pTHX_ GV *gv, register char *name, I32 len, int as_raw,
|
||||
name = type;
|
||||
}
|
||||
if (*name == '\0') { /* command is missing 19990114 */
|
||||
dTHR;
|
||||
if (ckWARN(WARN_PIPE))
|
||||
Perl_warner(aTHX_ WARN_PIPE, "Missing command in piped open");
|
||||
errno = EPIPE;
|
||||
@ -403,18 +396,18 @@ Perl_do_open9(pTHX_ GV *gv, register char *name, I32 len, int as_raw,
|
||||
mode = "r";
|
||||
fp = PerlProc_popen(name,mode);
|
||||
}
|
||||
IoTYPE(io) = '|';
|
||||
IoTYPE(io) = IoTYPE_PIPE;
|
||||
}
|
||||
else {
|
||||
if (num_svs)
|
||||
goto unknown_desr;
|
||||
name = type;
|
||||
IoTYPE(io) = '<';
|
||||
IoTYPE(io) = IoTYPE_RDONLY;
|
||||
/*SUPPRESS 530*/
|
||||
for (; isSPACE(*name); name++) ;
|
||||
if (strEQ(name,"-")) {
|
||||
fp = PerlIO_stdin();
|
||||
IoTYPE(io) = '-';
|
||||
IoTYPE(io) = IoTYPE_STD;
|
||||
}
|
||||
else {
|
||||
char *mode;
|
||||
@ -429,20 +422,17 @@ Perl_do_open9(pTHX_ GV *gv, register char *name, I32 len, int as_raw,
|
||||
}
|
||||
}
|
||||
if (!fp) {
|
||||
dTHR;
|
||||
if (ckWARN(WARN_NEWLINE) && IoTYPE(io) == '<' && strchr(name, '\n'))
|
||||
if (ckWARN(WARN_NEWLINE) && IoTYPE(io) == IoTYPE_RDONLY && strchr(name, '\n'))
|
||||
Perl_warner(aTHX_ WARN_NEWLINE, PL_warn_nl, "open");
|
||||
goto say_false;
|
||||
}
|
||||
if (IoTYPE(io) &&
|
||||
IoTYPE(io) != '|' && IoTYPE(io) != '-') {
|
||||
dTHR;
|
||||
if (IoTYPE(io) && IoTYPE(io) != IoTYPE_PIPE && IoTYPE(io) != IoTYPE_STD) {
|
||||
if (PerlLIO_fstat(PerlIO_fileno(fp),&PL_statbuf) < 0) {
|
||||
(void)PerlIO_close(fp);
|
||||
goto say_false;
|
||||
}
|
||||
if (S_ISSOCK(PL_statbuf.st_mode))
|
||||
IoTYPE(io) = 's'; /* in case a socket was passed in to us */
|
||||
IoTYPE(io) = IoTYPE_SOCKET; /* in case a socket was passed in to us */
|
||||
#ifdef HAS_SOCKET
|
||||
else if (
|
||||
#ifdef S_IFMT
|
||||
@ -450,13 +440,15 @@ Perl_do_open9(pTHX_ GV *gv, register char *name, I32 len, int as_raw,
|
||||
#else
|
||||
!PL_statbuf.st_mode
|
||||
#endif
|
||||
) {
|
||||
&& IoTYPE(io) != IoTYPE_WRONLY /* Dups of STD* filehandles already have */
|
||||
&& IoTYPE(io) != IoTYPE_RDONLY /* type so they aren't marked as sockets */
|
||||
) { /* on OS's that return 0 on fstat()ed pipe */
|
||||
char tmpbuf[256];
|
||||
Sock_size_t buflen = sizeof tmpbuf;
|
||||
if (PerlSock_getsockname(PerlIO_fileno(fp), (struct sockaddr *)tmpbuf,
|
||||
&buflen) >= 0
|
||||
|| errno != ENOTSOCK)
|
||||
IoTYPE(io) = 's'; /* some OS's return 0 on fstat()ed socket */
|
||||
IoTYPE(io) = IoTYPE_SOCKET; /* some OS's return 0 on fstat()ed socket */
|
||||
/* but some return 0 for streams too, sigh */
|
||||
}
|
||||
#endif
|
||||
@ -476,11 +468,22 @@ Perl_do_open9(pTHX_ GV *gv, register char *name, I32 len, int as_raw,
|
||||
SV *sv;
|
||||
|
||||
PerlLIO_dup2(PerlIO_fileno(fp), fd);
|
||||
#ifdef VMS
|
||||
if (fd != PerlIO_fileno(PerlIO_stdin())) {
|
||||
char newname[FILENAME_MAX+1];
|
||||
if (fgetname(fp, newname)) {
|
||||
if (fd == PerlIO_fileno(PerlIO_stdout())) Perl_vmssetuserlnm("SYS$OUTPUT", newname);
|
||||
if (fd == PerlIO_fileno(PerlIO_stderr())) Perl_vmssetuserlnm("SYS$ERROR", newname);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
LOCK_FDPID_MUTEX;
|
||||
sv = *av_fetch(PL_fdpid,PerlIO_fileno(fp),TRUE);
|
||||
(void)SvUPGRADE(sv, SVt_IV);
|
||||
pid = SvIVX(sv);
|
||||
SvIVX(sv) = 0;
|
||||
sv = *av_fetch(PL_fdpid,fd,TRUE);
|
||||
UNLOCK_FDPID_MUTEX;
|
||||
(void)SvUPGRADE(sv, SVt_IV);
|
||||
SvIVX(sv) = pid;
|
||||
if (!was_fdopen)
|
||||
@ -501,9 +504,8 @@ Perl_do_open9(pTHX_ GV *gv, register char *name, I32 len, int as_raw,
|
||||
IoIFP(io) = fp;
|
||||
IoFLAGS(io) &= ~IOf_NOLINE;
|
||||
if (writing) {
|
||||
dTHR;
|
||||
if (IoTYPE(io) == 's'
|
||||
|| (IoTYPE(io) == '>' && S_ISCHR(PL_statbuf.st_mode)) )
|
||||
if (IoTYPE(io) == IoTYPE_SOCKET
|
||||
|| (IoTYPE(io) == IoTYPE_WRONLY && S_ISCHR(PL_statbuf.st_mode)) )
|
||||
{
|
||||
char *mode;
|
||||
if (out_raw)
|
||||
@ -563,7 +565,6 @@ Perl_nextargv(pTHX_ register GV *gv)
|
||||
}
|
||||
PL_filemode = 0;
|
||||
while (av_len(GvAV(gv)) >= 0) {
|
||||
dTHR;
|
||||
STRLEN oldlen;
|
||||
sv = av_shift(GvAV(gv));
|
||||
SAVEFREESV(sv);
|
||||
@ -712,7 +713,6 @@ Perl_nextargv(pTHX_ register GV *gv)
|
||||
return IoIFP(GvIOp(gv));
|
||||
}
|
||||
else {
|
||||
dTHR;
|
||||
if (ckWARN_d(WARN_INPLACE)) {
|
||||
int eno = errno;
|
||||
if (PerlLIO_stat(PL_oldname, &PL_statbuf) >= 0
|
||||
@ -771,8 +771,8 @@ Perl_do_pipe(pTHX_ SV *sv, GV *rgv, GV *wgv)
|
||||
IoIFP(rstio) = PerlIO_fdopen(fd[0], "r");
|
||||
IoOFP(wstio) = PerlIO_fdopen(fd[1], "w");
|
||||
IoIFP(wstio) = IoOFP(wstio);
|
||||
IoTYPE(rstio) = '<';
|
||||
IoTYPE(wstio) = '>';
|
||||
IoTYPE(rstio) = IoTYPE_RDONLY;
|
||||
IoTYPE(wstio) = IoTYPE_WRONLY;
|
||||
if (!IoIFP(rstio) || !IoOFP(wstio)) {
|
||||
if (IoIFP(rstio)) PerlIO_close(IoIFP(rstio));
|
||||
else PerlLIO_close(fd[0]);
|
||||
@ -807,10 +807,8 @@ Perl_do_close(pTHX_ GV *gv, bool not_implicit)
|
||||
io = GvIO(gv);
|
||||
if (!io) { /* never opened */
|
||||
if (not_implicit) {
|
||||
dTHR;
|
||||
if (ckWARN(WARN_UNOPENED))
|
||||
Perl_warner(aTHX_ WARN_UNOPENED,
|
||||
"Close on unopened file <%s>",GvENAME(gv));
|
||||
if (ckWARN(WARN_UNOPENED)) /* no check for closed here */
|
||||
report_evil_fh(gv, io, PL_op->op_type);
|
||||
SETERRNO(EBADF,SS$_IVCHAN);
|
||||
}
|
||||
return FALSE;
|
||||
@ -821,7 +819,7 @@ Perl_do_close(pTHX_ GV *gv, bool not_implicit)
|
||||
IoPAGE(io) = 0;
|
||||
IoLINES_LEFT(io) = IoPAGE_LEN(io);
|
||||
}
|
||||
IoTYPE(io) = ' ';
|
||||
IoTYPE(io) = IoTYPE_CLOSED;
|
||||
return retval;
|
||||
}
|
||||
|
||||
@ -832,7 +830,7 @@ Perl_io_close(pTHX_ IO *io, bool not_implicit)
|
||||
int status;
|
||||
|
||||
if (IoIFP(io)) {
|
||||
if (IoTYPE(io) == '|') {
|
||||
if (IoTYPE(io) == IoTYPE_PIPE) {
|
||||
status = PerlProc_pclose(IoIFP(io));
|
||||
if (not_implicit) {
|
||||
STATUS_NATIVE_SET(status);
|
||||
@ -842,7 +840,7 @@ Perl_io_close(pTHX_ IO *io, bool not_implicit)
|
||||
retval = (status != -1);
|
||||
}
|
||||
}
|
||||
else if (IoTYPE(io) == '-')
|
||||
else if (IoTYPE(io) == IoTYPE_STD)
|
||||
retval = TRUE;
|
||||
else {
|
||||
if (IoOFP(io) && IoOFP(io) != IoIFP(io)) { /* a socket */
|
||||
@ -864,7 +862,6 @@ Perl_io_close(pTHX_ IO *io, bool not_implicit)
|
||||
bool
|
||||
Perl_do_eof(pTHX_ GV *gv)
|
||||
{
|
||||
dTHR;
|
||||
register IO *io;
|
||||
int ch;
|
||||
|
||||
@ -873,13 +870,22 @@ Perl_do_eof(pTHX_ GV *gv)
|
||||
if (!io)
|
||||
return TRUE;
|
||||
else if (ckWARN(WARN_IO)
|
||||
&& (IoTYPE(io) == '>' || IoIFP(io) == PerlIO_stdout()
|
||||
&& (IoTYPE(io) == IoTYPE_WRONLY || IoIFP(io) == PerlIO_stdout()
|
||||
|| IoIFP(io) == PerlIO_stderr()))
|
||||
{
|
||||
SV* sv = sv_newmortal();
|
||||
gv_efullname3(sv, gv, Nullch);
|
||||
Perl_warner(aTHX_ WARN_IO, "Filehandle %s opened only for output",
|
||||
SvPV_nolen(sv));
|
||||
/* integrate to report_evil_fh()? */
|
||||
char *name = NULL;
|
||||
if (isGV(gv)) {
|
||||
SV* sv = sv_newmortal();
|
||||
gv_efullname4(sv, gv, Nullch, FALSE);
|
||||
name = SvPV_nolen(sv);
|
||||
}
|
||||
if (name && *name)
|
||||
Perl_warner(aTHX_ WARN_IO,
|
||||
"Filehandle %s opened only for output", name);
|
||||
else
|
||||
Perl_warner(aTHX_ WARN_IO,
|
||||
"Filehandle opened only for output");
|
||||
}
|
||||
|
||||
while (IoIFP(io)) {
|
||||
@ -921,11 +927,8 @@ Perl_do_tell(pTHX_ GV *gv)
|
||||
#endif
|
||||
return PerlIO_tell(fp);
|
||||
}
|
||||
{
|
||||
dTHR;
|
||||
if (ckWARN(WARN_UNOPENED))
|
||||
Perl_warner(aTHX_ WARN_UNOPENED, "tell() on unopened file");
|
||||
}
|
||||
if (ckWARN2(WARN_UNOPENED,WARN_CLOSED))
|
||||
report_evil_fh(gv, io, PL_op->op_type);
|
||||
SETERRNO(EBADF,RMS$_IFI);
|
||||
return (Off_t)-1;
|
||||
}
|
||||
@ -943,11 +946,8 @@ Perl_do_seek(pTHX_ GV *gv, Off_t pos, int whence)
|
||||
#endif
|
||||
return PerlIO_seek(fp, pos, whence) >= 0;
|
||||
}
|
||||
{
|
||||
dTHR;
|
||||
if (ckWARN(WARN_UNOPENED))
|
||||
Perl_warner(aTHX_ WARN_UNOPENED, "seek() on unopened file");
|
||||
}
|
||||
if (ckWARN2(WARN_UNOPENED,WARN_CLOSED))
|
||||
report_evil_fh(gv, io, PL_op->op_type);
|
||||
SETERRNO(EBADF,RMS$_IFI);
|
||||
return FALSE;
|
||||
}
|
||||
@ -960,11 +960,8 @@ Perl_do_sysseek(pTHX_ GV *gv, Off_t pos, int whence)
|
||||
|
||||
if (gv && (io = GvIO(gv)) && (fp = IoIFP(io)))
|
||||
return PerlLIO_lseek(PerlIO_fileno(fp), pos, whence);
|
||||
{
|
||||
dTHR;
|
||||
if (ckWARN(WARN_UNOPENED))
|
||||
Perl_warner(aTHX_ WARN_UNOPENED, "sysseek() on unopened file");
|
||||
}
|
||||
if (ckWARN2(WARN_UNOPENED,WARN_CLOSED))
|
||||
report_evil_fh(gv, io, PL_op->op_type);
|
||||
SETERRNO(EBADF,RMS$_IFI);
|
||||
return (Off_t)-1;
|
||||
}
|
||||
@ -1140,11 +1137,8 @@ Perl_do_print(pTHX_ register SV *sv, PerlIO *fp)
|
||||
}
|
||||
switch (SvTYPE(sv)) {
|
||||
case SVt_NULL:
|
||||
{
|
||||
dTHR;
|
||||
if (ckWARN(WARN_UNINITIALIZED))
|
||||
report_uninit();
|
||||
}
|
||||
if (ckWARN(WARN_UNINITIALIZED))
|
||||
report_uninit();
|
||||
return TRUE;
|
||||
case SVt_IV:
|
||||
if (SvIOK(sv)) {
|
||||
@ -1167,7 +1161,7 @@ Perl_do_print(pTHX_ register SV *sv, PerlIO *fp)
|
||||
* but only until the system hard limit/the filesystem limit,
|
||||
* at which we would get EPERM. Note that when using buffered
|
||||
* io the write failure can be delayed until the flush/close. --jhi */
|
||||
if (len && (PerlIO_write(fp,tmps,len) == 0 || PerlIO_error(fp)))
|
||||
if (len && (PerlIO_write(fp,tmps,len) == 0))
|
||||
return FALSE;
|
||||
return !PerlIO_error(fp);
|
||||
}
|
||||
@ -1175,27 +1169,26 @@ Perl_do_print(pTHX_ register SV *sv, PerlIO *fp)
|
||||
I32
|
||||
Perl_my_stat(pTHX)
|
||||
{
|
||||
djSP;
|
||||
dSP;
|
||||
IO *io;
|
||||
GV* tmpgv;
|
||||
GV* gv;
|
||||
|
||||
if (PL_op->op_flags & OPf_REF) {
|
||||
EXTEND(SP,1);
|
||||
tmpgv = cGVOP_gv;
|
||||
gv = cGVOP_gv;
|
||||
do_fstat:
|
||||
io = GvIO(tmpgv);
|
||||
io = GvIO(gv);
|
||||
if (io && IoIFP(io)) {
|
||||
PL_statgv = tmpgv;
|
||||
PL_statgv = gv;
|
||||
sv_setpv(PL_statname,"");
|
||||
PL_laststype = OP_STAT;
|
||||
return (PL_laststatval = PerlLIO_fstat(PerlIO_fileno(IoIFP(io)), &PL_statcache));
|
||||
}
|
||||
else {
|
||||
if (tmpgv == PL_defgv)
|
||||
if (gv == PL_defgv)
|
||||
return PL_laststatval;
|
||||
if (ckWARN(WARN_UNOPENED))
|
||||
Perl_warner(aTHX_ WARN_UNOPENED, "Stat on unopened file <%s>",
|
||||
GvENAME(tmpgv));
|
||||
if (ckWARN2(WARN_UNOPENED,WARN_CLOSED))
|
||||
report_evil_fh(gv, io, PL_op->op_type);
|
||||
PL_statgv = Nullgv;
|
||||
sv_setpv(PL_statname,"");
|
||||
return (PL_laststatval = -1);
|
||||
@ -1207,11 +1200,11 @@ Perl_my_stat(pTHX)
|
||||
STRLEN n_a;
|
||||
PUTBACK;
|
||||
if (SvTYPE(sv) == SVt_PVGV) {
|
||||
tmpgv = (GV*)sv;
|
||||
gv = (GV*)sv;
|
||||
goto do_fstat;
|
||||
}
|
||||
else if (SvROK(sv) && SvTYPE(SvRV(sv)) == SVt_PVGV) {
|
||||
tmpgv = (GV*)SvRV(sv);
|
||||
gv = (GV*)SvRV(sv);
|
||||
goto do_fstat;
|
||||
}
|
||||
|
||||
@ -1229,7 +1222,7 @@ Perl_my_stat(pTHX)
|
||||
I32
|
||||
Perl_my_lstat(pTHX)
|
||||
{
|
||||
djSP;
|
||||
dSP;
|
||||
SV *sv;
|
||||
STRLEN n_a;
|
||||
if (PL_op->op_flags & OPf_REF) {
|
||||
@ -1271,7 +1264,6 @@ Perl_do_aexec5(pTHX_ SV *really, register SV **mark, register SV **sp,
|
||||
STRLEN n_a;
|
||||
|
||||
if (sp > mark) {
|
||||
dTHR;
|
||||
New(401,PL_Argv, sp - mark + 1, char*);
|
||||
a = PL_Argv;
|
||||
while (++mark <= sp) {
|
||||
@ -1281,15 +1273,18 @@ Perl_do_aexec5(pTHX_ SV *really, register SV **mark, register SV **sp,
|
||||
*a++ = "";
|
||||
}
|
||||
*a = Nullch;
|
||||
if (*PL_Argv[0] != '/') /* will execvp use PATH? */
|
||||
if (really)
|
||||
tmps = SvPV(really, n_a);
|
||||
if ((!really && *PL_Argv[0] != '/') ||
|
||||
(really && *tmps != '/')) /* will execvp use PATH? */
|
||||
TAINT_ENV(); /* testing IFS here is overkill, probably */
|
||||
if (really && *(tmps = SvPV(really, n_a)))
|
||||
PerlProc_execvp(tmps,PL_Argv);
|
||||
if (really && *tmps)
|
||||
PerlProc_execvp(tmps,EXEC_ARGV_CAST(PL_Argv));
|
||||
else
|
||||
PerlProc_execvp(PL_Argv[0],PL_Argv);
|
||||
PerlProc_execvp(PL_Argv[0],EXEC_ARGV_CAST(PL_Argv));
|
||||
if (ckWARN(WARN_EXEC))
|
||||
Perl_warner(aTHX_ WARN_EXEC, "Can't exec \"%s\": %s",
|
||||
PL_Argv[0], Strerror(errno));
|
||||
Perl_warner(aTHX_ WARN_EXEC, "Can't exec \"%s\": %s",
|
||||
(really ? tmps : PL_Argv[0]), Strerror(errno));
|
||||
if (do_report) {
|
||||
int e = errno;
|
||||
|
||||
@ -1419,7 +1414,6 @@ Perl_do_exec3(pTHX_ char *cmd, int fd, int do_report)
|
||||
goto doshell;
|
||||
}
|
||||
{
|
||||
dTHR;
|
||||
int e = errno;
|
||||
|
||||
if (ckWARN(WARN_EXEC))
|
||||
@ -1440,7 +1434,6 @@ Perl_do_exec3(pTHX_ char *cmd, int fd, int do_report)
|
||||
I32
|
||||
Perl_apply(pTHX_ I32 type, register SV **mark, register SV **sp)
|
||||
{
|
||||
dTHR;
|
||||
register I32 val;
|
||||
register I32 val2;
|
||||
register I32 tot = 0;
|
||||
@ -1725,7 +1718,6 @@ Perl_ingroup(pTHX_ Gid_t testgid, Uid_t effective)
|
||||
I32
|
||||
Perl_do_ipcget(pTHX_ I32 optype, SV **mark, SV **sp)
|
||||
{
|
||||
dTHR;
|
||||
key_t key;
|
||||
I32 n, flags;
|
||||
|
||||
@ -1758,7 +1750,6 @@ Perl_do_ipcget(pTHX_ I32 optype, SV **mark, SV **sp)
|
||||
I32
|
||||
Perl_do_ipcctl(pTHX_ I32 optype, SV **mark, SV **sp)
|
||||
{
|
||||
dTHR;
|
||||
SV *astr;
|
||||
char *a;
|
||||
I32 id, n, cmd, infosize, getinfo;
|
||||
@ -1883,7 +1874,6 @@ I32
|
||||
Perl_do_msgsnd(pTHX_ SV **mark, SV **sp)
|
||||
{
|
||||
#ifdef HAS_MSG
|
||||
dTHR;
|
||||
SV *mstr;
|
||||
char *mbuf;
|
||||
I32 id, msize, flags;
|
||||
@ -1906,7 +1896,6 @@ I32
|
||||
Perl_do_msgrcv(pTHX_ SV **mark, SV **sp)
|
||||
{
|
||||
#ifdef HAS_MSG
|
||||
dTHR;
|
||||
SV *mstr;
|
||||
char *mbuf;
|
||||
long mtype;
|
||||
@ -1915,6 +1904,9 @@ Perl_do_msgrcv(pTHX_ SV **mark, SV **sp)
|
||||
|
||||
id = SvIVx(*++mark);
|
||||
mstr = *++mark;
|
||||
/* suppress warning when reading into undef var --jhi */
|
||||
if (! SvOK(mstr))
|
||||
sv_setpvn(mstr, "", 0);
|
||||
msize = SvIVx(*++mark);
|
||||
mtype = (long)SvIVx(*++mark);
|
||||
flags = SvIVx(*++mark);
|
||||
@ -1941,7 +1933,6 @@ I32
|
||||
Perl_do_semop(pTHX_ SV **mark, SV **sp)
|
||||
{
|
||||
#ifdef HAS_SEM
|
||||
dTHR;
|
||||
SV *opstr;
|
||||
char *opbuf;
|
||||
I32 id;
|
||||
@ -1966,7 +1957,6 @@ I32
|
||||
Perl_do_shmio(pTHX_ I32 optype, SV **mark, SV **sp)
|
||||
{
|
||||
#ifdef HAS_SHM
|
||||
dTHR;
|
||||
SV *mstr;
|
||||
char *mbuf, *shm;
|
||||
I32 id, mpos, msize;
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -100,7 +100,11 @@
|
||||
#define fwrite1 fwrite
|
||||
|
||||
#define Fstat(fd,bufptr) fstat((fd),(bufptr))
|
||||
#define Fflush(fp) fflush(fp)
|
||||
#ifdef DJGPP
|
||||
# define Fflush(fp) djgpp_fflush(fp)
|
||||
#else
|
||||
# define Fflush(fp) fflush(fp)
|
||||
#endif
|
||||
#define Mkdir(path,mode) mkdir((path),(mode))
|
||||
|
||||
#ifndef WIN32
|
||||
|
@ -1,6 +1,6 @@
|
||||
/* dump.c
|
||||
*
|
||||
* Copyright (c) 1991-2000, Larry Wall
|
||||
* Copyright (c) 1991-2001, Larry Wall
|
||||
*
|
||||
* You may distribute under the terms of either the GNU General Public
|
||||
* License or the Artistic License, as specified in the README file.
|
||||
@ -29,7 +29,6 @@ Perl_dump_indent(pTHX_ I32 level, PerlIO *file, const char* pat, ...)
|
||||
void
|
||||
Perl_dump_vindent(pTHX_ I32 level, PerlIO *file, const char* pat, va_list *args)
|
||||
{
|
||||
dTHR;
|
||||
PerlIO_printf(file, "%*s", (int)(level*PL_dumpindent), "");
|
||||
PerlIO_vprintf(file, pat, *args);
|
||||
}
|
||||
@ -37,7 +36,6 @@ Perl_dump_vindent(pTHX_ I32 level, PerlIO *file, const char* pat, va_list *args)
|
||||
void
|
||||
Perl_dump_all(pTHX)
|
||||
{
|
||||
dTHR;
|
||||
PerlIO_setlinebuf(Perl_debug_log);
|
||||
if (PL_main_root)
|
||||
op_dump(PL_main_root);
|
||||
@ -47,7 +45,6 @@ Perl_dump_all(pTHX)
|
||||
void
|
||||
Perl_dump_packsubs(pTHX_ HV *stash)
|
||||
{
|
||||
dTHR;
|
||||
I32 i;
|
||||
HE *entry;
|
||||
|
||||
@ -279,9 +276,9 @@ Perl_sv_peek(pTHX_ SV *sv)
|
||||
}
|
||||
}
|
||||
else if (SvNOKp(sv)) {
|
||||
RESTORE_NUMERIC_STANDARD();
|
||||
STORE_NUMERIC_LOCAL_SET_STANDARD();
|
||||
Perl_sv_catpvf(aTHX_ t, "(%g)",SvNVX(sv));
|
||||
RESTORE_NUMERIC_LOCAL();
|
||||
RESTORE_NUMERIC_LOCAL();
|
||||
}
|
||||
else if (SvIOKp(sv)) {
|
||||
if (SvIsUV(sv))
|
||||
@ -369,7 +366,6 @@ Perl_pmop_dump(pTHX_ PMOP *pm)
|
||||
void
|
||||
Perl_do_op_dump(pTHX_ I32 level, PerlIO *file, OP *o)
|
||||
{
|
||||
dTHR;
|
||||
Perl_dump_indent(aTHX_ level, file, "{\n");
|
||||
level++;
|
||||
if (o->op_seq)
|
||||
@ -457,6 +453,7 @@ Perl_do_op_dump(pTHX_ I32 level, PerlIO *file, OP *o)
|
||||
}
|
||||
else if (o->op_type == OP_ENTERSUB ||
|
||||
o->op_type == OP_RV2SV ||
|
||||
o->op_type == OP_GVSV ||
|
||||
o->op_type == OP_RV2AV ||
|
||||
o->op_type == OP_RV2HV ||
|
||||
o->op_type == OP_RV2GV ||
|
||||
@ -768,8 +765,7 @@ Perl_do_gvgv_dump(pTHX_ I32 level, PerlIO *file, char *name, GV *sv)
|
||||
void
|
||||
Perl_do_sv_dump(pTHX_ I32 level, PerlIO *file, SV *sv, I32 nest, I32 maxnest, bool dumpops, STRLEN pvlim)
|
||||
{
|
||||
dTHR;
|
||||
SV *d = sv_newmortal();
|
||||
SV *d;
|
||||
char *s;
|
||||
U32 flags;
|
||||
U32 type;
|
||||
@ -783,7 +779,7 @@ Perl_do_sv_dump(pTHX_ I32 level, PerlIO *file, SV *sv, I32 nest, I32 maxnest, bo
|
||||
flags = SvFLAGS(sv);
|
||||
type = SvTYPE(sv);
|
||||
|
||||
Perl_sv_setpvf(aTHX_ d,
|
||||
d = Perl_newSVpvf(aTHX_
|
||||
"(0x%"UVxf") at 0x%"UVxf"\n%*s REFCNT = %"IVdf"\n%*s FLAGS = (",
|
||||
PTR2UV(SvANY(sv)), PTR2UV(sv),
|
||||
(int)(PL_dumpindent*level), "", (IV)SvREFCNT(sv),
|
||||
@ -824,6 +820,8 @@ Perl_do_sv_dump(pTHX_ I32 level, PerlIO *file, SV *sv, I32 nest, I32 maxnest, bo
|
||||
if (CvCLONED(sv)) sv_catpv(d, "CLONED,");
|
||||
if (CvNODEBUG(sv)) sv_catpv(d, "NODEBUG,");
|
||||
if (SvCOMPILED(sv)) sv_catpv(d, "COMPILED,");
|
||||
if (CvLVALUE(sv)) sv_catpv(d, "LVALUE,");
|
||||
if (CvMETHOD(sv)) sv_catpv(d, "METHOD,");
|
||||
break;
|
||||
case SVt_PVHV:
|
||||
if (HvSHAREKEYS(sv)) sv_catpv(d, "SHAREKEYS,");
|
||||
@ -833,6 +831,7 @@ Perl_do_sv_dump(pTHX_ I32 level, PerlIO *file, SV *sv, I32 nest, I32 maxnest, bo
|
||||
if (GvINTRO(sv)) sv_catpv(d, "INTRO,");
|
||||
if (GvMULTI(sv)) sv_catpv(d, "MULTI,");
|
||||
if (GvASSUMECV(sv)) sv_catpv(d, "ASSUMECV,");
|
||||
if (GvIN_PAD(sv)) sv_catpv(d, "IN_PAD,");
|
||||
if (GvIMPORTED(sv)) {
|
||||
sv_catpv(d, "IMPORT");
|
||||
if (GvIMPORTED(sv) == GVf_IMPORTED)
|
||||
@ -867,6 +866,7 @@ Perl_do_sv_dump(pTHX_ I32 level, PerlIO *file, SV *sv, I32 nest, I32 maxnest, bo
|
||||
switch (type) {
|
||||
case SVt_NULL:
|
||||
PerlIO_printf(file, "NULL%s\n", s);
|
||||
SvREFCNT_dec(d);
|
||||
return;
|
||||
case SVt_IV:
|
||||
PerlIO_printf(file, "IV%s\n", s);
|
||||
@ -915,6 +915,7 @@ Perl_do_sv_dump(pTHX_ I32 level, PerlIO *file, SV *sv, I32 nest, I32 maxnest, bo
|
||||
break;
|
||||
default:
|
||||
PerlIO_printf(file, "UNKNOWN(0x%"UVxf") %s\n", (UV)type, s);
|
||||
SvREFCNT_dec(d);
|
||||
return;
|
||||
}
|
||||
if (type >= SVt_PVIV || type == SVt_IV) {
|
||||
@ -927,7 +928,7 @@ Perl_do_sv_dump(pTHX_ I32 level, PerlIO *file, SV *sv, I32 nest, I32 maxnest, bo
|
||||
PerlIO_putc(file, '\n');
|
||||
}
|
||||
if (type >= SVt_PVNV || type == SVt_NV) {
|
||||
RESTORE_NUMERIC_STANDARD();
|
||||
STORE_NUMERIC_LOCAL_SET_STANDARD();
|
||||
/* %Vg doesn't work? --jhi */
|
||||
#ifdef USE_LONG_DOUBLE
|
||||
Perl_dump_indent(aTHX_ level, file, " NV = %.*" PERL_PRIgldbl "\n", LDBL_DIG, SvNVX(sv));
|
||||
@ -940,10 +941,13 @@ Perl_do_sv_dump(pTHX_ I32 level, PerlIO *file, SV *sv, I32 nest, I32 maxnest, bo
|
||||
Perl_dump_indent(aTHX_ level, file, " RV = 0x%"UVxf"\n", PTR2UV(SvRV(sv)));
|
||||
if (nest < maxnest)
|
||||
do_sv_dump(level+1, file, SvRV(sv), nest+1, maxnest, dumpops, pvlim);
|
||||
SvREFCNT_dec(d);
|
||||
return;
|
||||
}
|
||||
if (type < SVt_PV)
|
||||
if (type < SVt_PV) {
|
||||
SvREFCNT_dec(d);
|
||||
return;
|
||||
}
|
||||
if (type <= SVt_PVLV) {
|
||||
if (SvPVX(sv)) {
|
||||
Perl_dump_indent(aTHX_ level, file," PV = 0x%"UVxf" ", PTR2UV(SvPVX(sv)));
|
||||
@ -1042,7 +1046,7 @@ Perl_do_sv_dump(pTHX_ I32 level, PerlIO *file, SV *sv, I32 nest, I32 maxnest, bo
|
||||
theoret = HvKEYS(sv);
|
||||
theoret += theoret * theoret/pow2;
|
||||
PerlIO_putc(file, '\n');
|
||||
Perl_dump_indent(aTHX_ level, file, " hash quality = %.1f%%", theoret/sum*100);
|
||||
Perl_dump_indent(aTHX_ level, file, " hash quality = %.1"NVff"%%", theoret/sum*100);
|
||||
}
|
||||
PerlIO_putc(file, '\n');
|
||||
Perl_dump_indent(aTHX_ level, file, " KEYS = %"IVdf"\n", (IV)HvKEYS(sv));
|
||||
@ -1178,6 +1182,7 @@ Perl_do_sv_dump(pTHX_ I32 level, PerlIO *file, SV *sv, I32 nest, I32 maxnest, bo
|
||||
Perl_dump_indent(aTHX_ level, file, " FLAGS = 0x%"UVxf"\n", (UV)IoFLAGS(sv));
|
||||
break;
|
||||
}
|
||||
SvREFCNT_dec(d);
|
||||
}
|
||||
|
||||
void
|
||||
|
@ -71,6 +71,7 @@
|
||||
#define append_elem Perl_append_elem
|
||||
#define append_list Perl_append_list
|
||||
#define apply Perl_apply
|
||||
#define apply_attrs_string Perl_apply_attrs_string
|
||||
#define avhv_delete_ent Perl_avhv_delete_ent
|
||||
#define avhv_exists_ent Perl_avhv_exists_ent
|
||||
#define avhv_fetch_ent Perl_avhv_fetch_ent
|
||||
@ -129,6 +130,7 @@
|
||||
#define sv_catpvf_mg_nocontext Perl_sv_catpvf_mg_nocontext
|
||||
#define sv_setpvf_mg_nocontext Perl_sv_setpvf_mg_nocontext
|
||||
#define fprintf_nocontext Perl_fprintf_nocontext
|
||||
#define printf_nocontext Perl_printf_nocontext
|
||||
#endif
|
||||
#define cv_ckproto Perl_cv_ckproto
|
||||
#define cv_clone Perl_cv_clone
|
||||
@ -229,6 +231,7 @@
|
||||
#define gv_check Perl_gv_check
|
||||
#define gv_efullname Perl_gv_efullname
|
||||
#define gv_efullname3 Perl_gv_efullname3
|
||||
#define gv_efullname4 Perl_gv_efullname4
|
||||
#define gv_fetchfile Perl_gv_fetchfile
|
||||
#define gv_fetchmeth Perl_gv_fetchmeth
|
||||
#define gv_fetchmethod Perl_gv_fetchmethod
|
||||
@ -236,6 +239,7 @@
|
||||
#define gv_fetchpv Perl_gv_fetchpv
|
||||
#define gv_fullname Perl_gv_fullname
|
||||
#define gv_fullname3 Perl_gv_fullname3
|
||||
#define gv_fullname4 Perl_gv_fullname4
|
||||
#define gv_init Perl_gv_init
|
||||
#define gv_stashpv Perl_gv_stashpv
|
||||
#define gv_stashpvn Perl_gv_stashpvn
|
||||
@ -269,6 +273,8 @@
|
||||
#define instr Perl_instr
|
||||
#define io_close Perl_io_close
|
||||
#define invert Perl_invert
|
||||
#define is_gv_magical Perl_is_gv_magical
|
||||
#define is_lvalue_sub Perl_is_lvalue_sub
|
||||
#define is_uni_alnum Perl_is_uni_alnum
|
||||
#define is_uni_alnumc Perl_is_uni_alnumc
|
||||
#define is_uni_idfirst Perl_is_uni_idfirst
|
||||
@ -304,6 +310,7 @@
|
||||
#define to_uni_title_lc Perl_to_uni_title_lc
|
||||
#define to_uni_lower_lc Perl_to_uni_lower_lc
|
||||
#define is_utf8_char Perl_is_utf8_char
|
||||
#define is_utf8_string Perl_is_utf8_string
|
||||
#define is_utf8_alnum Perl_is_utf8_alnum
|
||||
#define is_utf8_alnumc Perl_is_utf8_alnumc
|
||||
#define is_utf8_idfirst Perl_is_utf8_idfirst
|
||||
@ -356,6 +363,7 @@
|
||||
#define magic_nextpack Perl_magic_nextpack
|
||||
#define magic_regdata_cnt Perl_magic_regdata_cnt
|
||||
#define magic_regdatum_get Perl_magic_regdatum_get
|
||||
#define magic_regdatum_set Perl_magic_regdatum_set
|
||||
#define magic_set Perl_magic_set
|
||||
#define magic_setamagic Perl_magic_setamagic
|
||||
#define magic_setarylen Perl_magic_setarylen
|
||||
@ -570,6 +578,7 @@
|
||||
#define save_freeop Perl_save_freeop
|
||||
#define save_freepv Perl_save_freepv
|
||||
#define save_generic_svref Perl_save_generic_svref
|
||||
#define save_generic_pvref Perl_save_generic_pvref
|
||||
#define save_gp Perl_save_gp
|
||||
#define save_hash Perl_save_hash
|
||||
#define save_helem Perl_save_helem
|
||||
@ -583,12 +592,14 @@
|
||||
#define save_iv Perl_save_iv
|
||||
#define save_list Perl_save_list
|
||||
#define save_long Perl_save_long
|
||||
#define save_mortalizesv Perl_save_mortalizesv
|
||||
#define save_nogv Perl_save_nogv
|
||||
#define save_op Perl_save_op
|
||||
#define save_scalar Perl_save_scalar
|
||||
#define save_pptr Perl_save_pptr
|
||||
#define save_vptr Perl_save_vptr
|
||||
#define save_re_context Perl_save_re_context
|
||||
#define save_padsv Perl_save_padsv
|
||||
#define save_sptr Perl_save_sptr
|
||||
#define save_svref Perl_save_svref
|
||||
#define save_threadsv Perl_save_threadsv
|
||||
@ -717,14 +728,19 @@
|
||||
#define utilize Perl_utilize
|
||||
#define utf16_to_utf8 Perl_utf16_to_utf8
|
||||
#define utf16_to_utf8_reversed Perl_utf16_to_utf8_reversed
|
||||
#define utf8_length Perl_utf8_length
|
||||
#define utf8_distance Perl_utf8_distance
|
||||
#define utf8_hop Perl_utf8_hop
|
||||
#define utf8_to_bytes Perl_utf8_to_bytes
|
||||
#define bytes_from_utf8 Perl_bytes_from_utf8
|
||||
#define bytes_to_utf8 Perl_bytes_to_utf8
|
||||
#define utf8_to_uv_simple Perl_utf8_to_uv_simple
|
||||
#define utf8_to_uv Perl_utf8_to_uv
|
||||
#define uv_to_utf8 Perl_uv_to_utf8
|
||||
#define vivify_defelem Perl_vivify_defelem
|
||||
#define vivify_ref Perl_vivify_ref
|
||||
#define wait4pid Perl_wait4pid
|
||||
#define report_closed_fh Perl_report_closed_fh
|
||||
#define report_evil_fh Perl_report_evil_fh
|
||||
#define report_uninit Perl_report_uninit
|
||||
#define warn Perl_warn
|
||||
#define vwarn Perl_vwarn
|
||||
@ -733,11 +749,10 @@
|
||||
#define watch Perl_watch
|
||||
#define whichsig Perl_whichsig
|
||||
#define yyerror Perl_yyerror
|
||||
#if defined(USE_PURE_BISON)
|
||||
#define yylex Perl_yylex
|
||||
#else
|
||||
#define yylex Perl_yylex
|
||||
#ifdef USE_PURE_BISON
|
||||
#define yylex_r Perl_yylex_r
|
||||
#endif
|
||||
#define yylex Perl_yylex
|
||||
#define yyparse Perl_yyparse
|
||||
#define yywarn Perl_yywarn
|
||||
#if defined(MYMALLOC)
|
||||
@ -759,6 +774,9 @@
|
||||
#endif
|
||||
#define runops_standard Perl_runops_standard
|
||||
#define runops_debug Perl_runops_debug
|
||||
#if defined(USE_THREADS)
|
||||
#define sv_lock Perl_sv_lock
|
||||
#endif
|
||||
#define sv_catpvf_mg Perl_sv_catpvf_mg
|
||||
#define sv_vcatpvf_mg Perl_sv_vcatpvf_mg
|
||||
#define sv_catpv_mg Perl_sv_catpv_mg
|
||||
@ -802,6 +820,8 @@
|
||||
#define sv_utf8_encode Perl_sv_utf8_encode
|
||||
#define sv_utf8_decode Perl_sv_utf8_decode
|
||||
#define sv_force_normal Perl_sv_force_normal
|
||||
#define sv_add_backref Perl_sv_add_backref
|
||||
#define sv_del_backref Perl_sv_del_backref
|
||||
#define tmps_grow Perl_tmps_grow
|
||||
#define sv_rvweaken Perl_sv_rvweaken
|
||||
#define magic_killbackrefs Perl_magic_killbackrefs
|
||||
@ -829,6 +849,12 @@
|
||||
#define ptr_table_fetch Perl_ptr_table_fetch
|
||||
#define ptr_table_store Perl_ptr_table_store
|
||||
#define ptr_table_split Perl_ptr_table_split
|
||||
#define ptr_table_clear Perl_ptr_table_clear
|
||||
#define ptr_table_free Perl_ptr_table_free
|
||||
#endif
|
||||
#if defined(HAVE_INTERP_INTERN)
|
||||
#define sys_intern_clear Perl_sys_intern_clear
|
||||
#define sys_intern_init Perl_sys_intern_init
|
||||
#endif
|
||||
#if defined(PERL_OBJECT)
|
||||
#else
|
||||
@ -838,16 +864,12 @@
|
||||
#define avhv_index S_avhv_index
|
||||
#endif
|
||||
#if defined(PERL_IN_DOOP_C) || defined(PERL_DECL_PROT)
|
||||
#define do_trans_CC_simple S_do_trans_CC_simple
|
||||
#define do_trans_CC_count S_do_trans_CC_count
|
||||
#define do_trans_CC_complex S_do_trans_CC_complex
|
||||
#define do_trans_UU_simple S_do_trans_UU_simple
|
||||
#define do_trans_UU_count S_do_trans_UU_count
|
||||
#define do_trans_UU_complex S_do_trans_UU_complex
|
||||
#define do_trans_UC_simple S_do_trans_UC_simple
|
||||
#define do_trans_CU_simple S_do_trans_CU_simple
|
||||
#define do_trans_UC_trivial S_do_trans_UC_trivial
|
||||
#define do_trans_CU_trivial S_do_trans_CU_trivial
|
||||
#define do_trans_simple S_do_trans_simple
|
||||
#define do_trans_count S_do_trans_count
|
||||
#define do_trans_complex S_do_trans_complex
|
||||
#define do_trans_simple_utf8 S_do_trans_simple_utf8
|
||||
#define do_trans_count_utf8 S_do_trans_count_utf8
|
||||
#define do_trans_complex_utf8 S_do_trans_complex_utf8
|
||||
#endif
|
||||
#if defined(PERL_IN_GV_C) || defined(PERL_DECL_PROT)
|
||||
#define gv_init_sv S_gv_init_sv
|
||||
@ -876,6 +898,7 @@
|
||||
#define scalarboolean S_scalarboolean
|
||||
#define too_few_arguments S_too_few_arguments
|
||||
#define too_many_arguments S_too_many_arguments
|
||||
#define trlist_upgrade S_trlist_upgrade
|
||||
#define op_clear S_op_clear
|
||||
#define null S_null
|
||||
#define pad_addlex S_pad_addlex
|
||||
@ -949,7 +972,6 @@
|
||||
#define dopoptoloop S_dopoptoloop
|
||||
#define dopoptosub S_dopoptosub
|
||||
#define dopoptosub_at S_dopoptosub_at
|
||||
#define free_closures S_free_closures
|
||||
#define save_lines S_save_lines
|
||||
#define doeval S_doeval
|
||||
#define doopen_pmc S_doopen_pmc
|
||||
@ -1063,8 +1085,6 @@
|
||||
#define sv_unglob S_sv_unglob
|
||||
#define not_a_number S_not_a_number
|
||||
#define visit S_visit
|
||||
#define sv_add_backref S_sv_add_backref
|
||||
#define sv_del_backref S_sv_del_backref
|
||||
# if defined(DEBUGGING)
|
||||
#define del_sv S_del_sv
|
||||
# endif
|
||||
@ -1086,6 +1106,7 @@
|
||||
#define scan_trans S_scan_trans
|
||||
#define scan_word S_scan_word
|
||||
#define skipspace S_skipspace
|
||||
#define swallow_bom S_swallow_bom
|
||||
#define checkcomma S_checkcomma
|
||||
#define force_ident S_force_ident
|
||||
#define incline S_incline
|
||||
@ -1099,6 +1120,7 @@
|
||||
#define sublex_push S_sublex_push
|
||||
#define sublex_start S_sublex_start
|
||||
#define filter_gets S_filter_gets
|
||||
#define find_in_my_stash S_find_in_my_stash
|
||||
#define new_constant S_new_constant
|
||||
#define ao S_ao
|
||||
#define depcom S_depcom
|
||||
@ -1118,6 +1140,7 @@
|
||||
#define isa_lookup S_isa_lookup
|
||||
#endif
|
||||
#if defined(PERL_IN_UTIL_C) || defined(PERL_DECL_PROT)
|
||||
#define stdize_locale S_stdize_locale
|
||||
#define mess_alloc S_mess_alloc
|
||||
# if defined(LEAKTEST)
|
||||
#define xstat S_xstat
|
||||
@ -1151,6 +1174,7 @@
|
||||
#define ck_open Perl_ck_open
|
||||
#define ck_repeat Perl_ck_repeat
|
||||
#define ck_require Perl_ck_require
|
||||
#define ck_return Perl_ck_return
|
||||
#define ck_rfun Perl_ck_rfun
|
||||
#define ck_rvconst Perl_ck_rvconst
|
||||
#define ck_sassign Perl_ck_sassign
|
||||
@ -1161,6 +1185,7 @@
|
||||
#define ck_spair Perl_ck_spair
|
||||
#define ck_split Perl_ck_split
|
||||
#define ck_subr Perl_ck_subr
|
||||
#define ck_substr Perl_ck_substr
|
||||
#define ck_svconst Perl_ck_svconst
|
||||
#define ck_trunc Perl_ck_trunc
|
||||
#define pp_aassign Perl_pp_aassign
|
||||
@ -1536,6 +1561,7 @@
|
||||
#define append_elem(a,b,c) Perl_append_elem(aTHX_ a,b,c)
|
||||
#define append_list(a,b,c) Perl_append_list(aTHX_ a,b,c)
|
||||
#define apply(a,b,c) Perl_apply(aTHX_ a,b,c)
|
||||
#define apply_attrs_string(a,b,c,d) Perl_apply_attrs_string(aTHX_ a,b,c,d)
|
||||
#define avhv_delete_ent(a,b,c,d) Perl_avhv_delete_ent(aTHX_ a,b,c,d)
|
||||
#define avhv_exists_ent(a,b,c) Perl_avhv_exists_ent(aTHX_ a,b,c)
|
||||
#define avhv_fetch_ent(a,b,c,d) Perl_avhv_fetch_ent(aTHX_ a,b,c,d)
|
||||
@ -1676,6 +1702,7 @@
|
||||
#define gv_check(a) Perl_gv_check(aTHX_ a)
|
||||
#define gv_efullname(a,b) Perl_gv_efullname(aTHX_ a,b)
|
||||
#define gv_efullname3(a,b,c) Perl_gv_efullname3(aTHX_ a,b,c)
|
||||
#define gv_efullname4(a,b,c,d) Perl_gv_efullname4(aTHX_ a,b,c,d)
|
||||
#define gv_fetchfile(a) Perl_gv_fetchfile(aTHX_ a)
|
||||
#define gv_fetchmeth(a,b,c,d) Perl_gv_fetchmeth(aTHX_ a,b,c,d)
|
||||
#define gv_fetchmethod(a,b) Perl_gv_fetchmethod(aTHX_ a,b)
|
||||
@ -1683,6 +1710,7 @@
|
||||
#define gv_fetchpv(a,b,c) Perl_gv_fetchpv(aTHX_ a,b,c)
|
||||
#define gv_fullname(a,b) Perl_gv_fullname(aTHX_ a,b)
|
||||
#define gv_fullname3(a,b,c) Perl_gv_fullname3(aTHX_ a,b,c)
|
||||
#define gv_fullname4(a,b,c,d) Perl_gv_fullname4(aTHX_ a,b,c,d)
|
||||
#define gv_init(a,b,c,d,e) Perl_gv_init(aTHX_ a,b,c,d,e)
|
||||
#define gv_stashpv(a,b) Perl_gv_stashpv(aTHX_ a,b)
|
||||
#define gv_stashpvn(a,b,c) Perl_gv_stashpvn(aTHX_ a,b,c)
|
||||
@ -1716,6 +1744,8 @@
|
||||
#define instr(a,b) Perl_instr(aTHX_ a,b)
|
||||
#define io_close(a,b) Perl_io_close(aTHX_ a,b)
|
||||
#define invert(a) Perl_invert(aTHX_ a)
|
||||
#define is_gv_magical(a,b,c) Perl_is_gv_magical(aTHX_ a,b,c)
|
||||
#define is_lvalue_sub() Perl_is_lvalue_sub(aTHX)
|
||||
#define is_uni_alnum(a) Perl_is_uni_alnum(aTHX_ a)
|
||||
#define is_uni_alnumc(a) Perl_is_uni_alnumc(aTHX_ a)
|
||||
#define is_uni_idfirst(a) Perl_is_uni_idfirst(aTHX_ a)
|
||||
@ -1751,6 +1781,7 @@
|
||||
#define to_uni_title_lc(a) Perl_to_uni_title_lc(aTHX_ a)
|
||||
#define to_uni_lower_lc(a) Perl_to_uni_lower_lc(aTHX_ a)
|
||||
#define is_utf8_char(a) Perl_is_utf8_char(aTHX_ a)
|
||||
#define is_utf8_string(a,b) Perl_is_utf8_string(aTHX_ a,b)
|
||||
#define is_utf8_alnum(a) Perl_is_utf8_alnum(aTHX_ a)
|
||||
#define is_utf8_alnumc(a) Perl_is_utf8_alnumc(aTHX_ a)
|
||||
#define is_utf8_idfirst(a) Perl_is_utf8_idfirst(aTHX_ a)
|
||||
@ -1802,6 +1833,7 @@
|
||||
#define magic_nextpack(a,b,c) Perl_magic_nextpack(aTHX_ a,b,c)
|
||||
#define magic_regdata_cnt(a,b) Perl_magic_regdata_cnt(aTHX_ a,b)
|
||||
#define magic_regdatum_get(a,b) Perl_magic_regdatum_get(aTHX_ a,b)
|
||||
#define magic_regdatum_set(a,b) Perl_magic_regdatum_set(aTHX_ a,b)
|
||||
#define magic_set(a,b) Perl_magic_set(aTHX_ a,b)
|
||||
#define magic_setamagic(a,b) Perl_magic_setamagic(aTHX_ a,b)
|
||||
#define magic_setarylen(a,b) Perl_magic_setarylen(aTHX_ a,b)
|
||||
@ -2014,6 +2046,7 @@
|
||||
#define save_freeop(a) Perl_save_freeop(aTHX_ a)
|
||||
#define save_freepv(a) Perl_save_freepv(aTHX_ a)
|
||||
#define save_generic_svref(a) Perl_save_generic_svref(aTHX_ a)
|
||||
#define save_generic_pvref(a) Perl_save_generic_pvref(aTHX_ a)
|
||||
#define save_gp(a,b) Perl_save_gp(aTHX_ a,b)
|
||||
#define save_hash(a) Perl_save_hash(aTHX_ a)
|
||||
#define save_helem(a,b,c) Perl_save_helem(aTHX_ a,b,c)
|
||||
@ -2027,12 +2060,14 @@
|
||||
#define save_iv(a) Perl_save_iv(aTHX_ a)
|
||||
#define save_list(a,b) Perl_save_list(aTHX_ a,b)
|
||||
#define save_long(a) Perl_save_long(aTHX_ a)
|
||||
#define save_mortalizesv(a) Perl_save_mortalizesv(aTHX_ a)
|
||||
#define save_nogv(a) Perl_save_nogv(aTHX_ a)
|
||||
#define save_op() Perl_save_op(aTHX)
|
||||
#define save_scalar(a) Perl_save_scalar(aTHX_ a)
|
||||
#define save_pptr(a) Perl_save_pptr(aTHX_ a)
|
||||
#define save_vptr(a) Perl_save_vptr(aTHX_ a)
|
||||
#define save_re_context() Perl_save_re_context(aTHX)
|
||||
#define save_padsv(a) Perl_save_padsv(aTHX_ a)
|
||||
#define save_sptr(a) Perl_save_sptr(aTHX_ a)
|
||||
#define save_svref(a) Perl_save_svref(aTHX_ a)
|
||||
#define save_threadsv(a) Perl_save_threadsv(aTHX_ a)
|
||||
@ -2043,7 +2078,7 @@
|
||||
#define scalarvoid(a) Perl_scalarvoid(aTHX_ a)
|
||||
#define scan_bin(a,b,c) Perl_scan_bin(aTHX_ a,b,c)
|
||||
#define scan_hex(a,b,c) Perl_scan_hex(aTHX_ a,b,c)
|
||||
#define scan_num(a) Perl_scan_num(aTHX_ a)
|
||||
#define scan_num(a,b) Perl_scan_num(aTHX_ a,b)
|
||||
#define scan_oct(a,b,c) Perl_scan_oct(aTHX_ a,b,c)
|
||||
#define scope(a) Perl_scope(aTHX_ a)
|
||||
#define screaminstr(a,b,c,d,e,f) Perl_screaminstr(aTHX_ a,b,c,d,e,f)
|
||||
@ -2157,27 +2192,31 @@
|
||||
#define unsharepvn(a,b,c) Perl_unsharepvn(aTHX_ a,b,c)
|
||||
#define unshare_hek(a) Perl_unshare_hek(aTHX_ a)
|
||||
#define utilize(a,b,c,d,e) Perl_utilize(aTHX_ a,b,c,d,e)
|
||||
#define utf16_to_utf8(a,b,c) Perl_utf16_to_utf8(aTHX_ a,b,c)
|
||||
#define utf16_to_utf8_reversed(a,b,c) Perl_utf16_to_utf8_reversed(aTHX_ a,b,c)
|
||||
#define utf16_to_utf8(a,b,c,d) Perl_utf16_to_utf8(aTHX_ a,b,c,d)
|
||||
#define utf16_to_utf8_reversed(a,b,c,d) Perl_utf16_to_utf8_reversed(aTHX_ a,b,c,d)
|
||||
#define utf8_length(a,b) Perl_utf8_length(aTHX_ a,b)
|
||||
#define utf8_distance(a,b) Perl_utf8_distance(aTHX_ a,b)
|
||||
#define utf8_hop(a,b) Perl_utf8_hop(aTHX_ a,b)
|
||||
#define utf8_to_uv(a,b) Perl_utf8_to_uv(aTHX_ a,b)
|
||||
#define utf8_to_bytes(a,b) Perl_utf8_to_bytes(aTHX_ a,b)
|
||||
#define bytes_from_utf8(a,b,c) Perl_bytes_from_utf8(aTHX_ a,b,c)
|
||||
#define bytes_to_utf8(a,b) Perl_bytes_to_utf8(aTHX_ a,b)
|
||||
#define utf8_to_uv_simple(a,b) Perl_utf8_to_uv_simple(aTHX_ a,b)
|
||||
#define utf8_to_uv(a,b,c,d) Perl_utf8_to_uv(aTHX_ a,b,c,d)
|
||||
#define uv_to_utf8(a,b) Perl_uv_to_utf8(aTHX_ a,b)
|
||||
#define vivify_defelem(a) Perl_vivify_defelem(aTHX_ a)
|
||||
#define vivify_ref(a,b) Perl_vivify_ref(aTHX_ a,b)
|
||||
#define wait4pid(a,b,c) Perl_wait4pid(aTHX_ a,b,c)
|
||||
#define report_closed_fh(a,b,c,d) Perl_report_closed_fh(aTHX_ a,b,c,d)
|
||||
#define report_evil_fh(a,b,c) Perl_report_evil_fh(aTHX_ a,b,c)
|
||||
#define report_uninit() Perl_report_uninit(aTHX)
|
||||
#define vwarn(a,b) Perl_vwarn(aTHX_ a,b)
|
||||
#define vwarner(a,b,c) Perl_vwarner(aTHX_ a,b,c)
|
||||
#define watch(a) Perl_watch(aTHX_ a)
|
||||
#define whichsig(a) Perl_whichsig(aTHX_ a)
|
||||
#define yyerror(a) Perl_yyerror(aTHX_ a)
|
||||
#if defined(USE_PURE_BISON)
|
||||
#define yylex(a,b) Perl_yylex(aTHX_ a,b)
|
||||
#else
|
||||
#define yylex() Perl_yylex(aTHX)
|
||||
#ifdef USE_PURE_BISON
|
||||
#define yylex_r(a,b) Perl_yylex_r(aTHX_ a,b)
|
||||
#endif
|
||||
#define yylex() Perl_yylex(aTHX)
|
||||
#define yyparse() Perl_yyparse(aTHX)
|
||||
#define yywarn(a) Perl_yywarn(aTHX_ a)
|
||||
#if defined(MYMALLOC)
|
||||
@ -2199,6 +2238,9 @@
|
||||
#endif
|
||||
#define runops_standard() Perl_runops_standard(aTHX)
|
||||
#define runops_debug() Perl_runops_debug(aTHX)
|
||||
#if defined(USE_THREADS)
|
||||
#define sv_lock(a) Perl_sv_lock(aTHX_ a)
|
||||
#endif
|
||||
#define sv_vcatpvf_mg(a,b,c) Perl_sv_vcatpvf_mg(aTHX_ a,b,c)
|
||||
#define sv_catpv_mg(a,b) Perl_sv_catpv_mg(aTHX_ a,b)
|
||||
#define sv_catpvn_mg(a,b,c) Perl_sv_catpvn_mg(aTHX_ a,b,c)
|
||||
@ -2238,6 +2280,8 @@
|
||||
#define sv_utf8_encode(a) Perl_sv_utf8_encode(aTHX_ a)
|
||||
#define sv_utf8_decode(a) Perl_sv_utf8_decode(aTHX_ a)
|
||||
#define sv_force_normal(a) Perl_sv_force_normal(aTHX_ a)
|
||||
#define sv_add_backref(a,b) Perl_sv_add_backref(aTHX_ a,b)
|
||||
#define sv_del_backref(a) Perl_sv_del_backref(aTHX_ a)
|
||||
#define tmps_grow(a) Perl_tmps_grow(aTHX_ a)
|
||||
#define sv_rvweaken(a) Perl_sv_rvweaken(aTHX_ a)
|
||||
#define magic_killbackrefs(a,b) Perl_magic_killbackrefs(aTHX_ a,b)
|
||||
@ -2265,6 +2309,12 @@
|
||||
#define ptr_table_fetch(a,b) Perl_ptr_table_fetch(aTHX_ a,b)
|
||||
#define ptr_table_store(a,b,c) Perl_ptr_table_store(aTHX_ a,b,c)
|
||||
#define ptr_table_split(a) Perl_ptr_table_split(aTHX_ a)
|
||||
#define ptr_table_clear(a) Perl_ptr_table_clear(aTHX_ a)
|
||||
#define ptr_table_free(a) Perl_ptr_table_free(aTHX_ a)
|
||||
#endif
|
||||
#if defined(HAVE_INTERP_INTERN)
|
||||
#define sys_intern_clear() Perl_sys_intern_clear(aTHX)
|
||||
#define sys_intern_init() Perl_sys_intern_init(aTHX)
|
||||
#endif
|
||||
#if defined(PERL_OBJECT)
|
||||
#else
|
||||
@ -2274,16 +2324,12 @@
|
||||
#define avhv_index(a,b,c) S_avhv_index(aTHX_ a,b,c)
|
||||
#endif
|
||||
#if defined(PERL_IN_DOOP_C) || defined(PERL_DECL_PROT)
|
||||
#define do_trans_CC_simple(a) S_do_trans_CC_simple(aTHX_ a)
|
||||
#define do_trans_CC_count(a) S_do_trans_CC_count(aTHX_ a)
|
||||
#define do_trans_CC_complex(a) S_do_trans_CC_complex(aTHX_ a)
|
||||
#define do_trans_UU_simple(a) S_do_trans_UU_simple(aTHX_ a)
|
||||
#define do_trans_UU_count(a) S_do_trans_UU_count(aTHX_ a)
|
||||
#define do_trans_UU_complex(a) S_do_trans_UU_complex(aTHX_ a)
|
||||
#define do_trans_UC_simple(a) S_do_trans_UC_simple(aTHX_ a)
|
||||
#define do_trans_CU_simple(a) S_do_trans_CU_simple(aTHX_ a)
|
||||
#define do_trans_UC_trivial(a) S_do_trans_UC_trivial(aTHX_ a)
|
||||
#define do_trans_CU_trivial(a) S_do_trans_CU_trivial(aTHX_ a)
|
||||
#define do_trans_simple(a) S_do_trans_simple(aTHX_ a)
|
||||
#define do_trans_count(a) S_do_trans_count(aTHX_ a)
|
||||
#define do_trans_complex(a) S_do_trans_complex(aTHX_ a)
|
||||
#define do_trans_simple_utf8(a) S_do_trans_simple_utf8(aTHX_ a)
|
||||
#define do_trans_count_utf8(a) S_do_trans_count_utf8(aTHX_ a)
|
||||
#define do_trans_complex_utf8(a) S_do_trans_complex_utf8(aTHX_ a)
|
||||
#endif
|
||||
#if defined(PERL_IN_GV_C) || defined(PERL_DECL_PROT)
|
||||
#define gv_init_sv(a,b) S_gv_init_sv(aTHX_ a,b)
|
||||
@ -2312,6 +2358,7 @@
|
||||
#define scalarboolean(a) S_scalarboolean(aTHX_ a)
|
||||
#define too_few_arguments(a,b) S_too_few_arguments(aTHX_ a,b)
|
||||
#define too_many_arguments(a,b) S_too_many_arguments(aTHX_ a,b)
|
||||
#define trlist_upgrade(a,b) S_trlist_upgrade(aTHX_ a,b)
|
||||
#define op_clear(a) S_op_clear(aTHX_ a)
|
||||
#define null(a) S_null(aTHX_ a)
|
||||
#define pad_addlex(a) S_pad_addlex(aTHX_ a)
|
||||
@ -2385,7 +2432,6 @@
|
||||
#define dopoptoloop(a) S_dopoptoloop(aTHX_ a)
|
||||
#define dopoptosub(a) S_dopoptosub(aTHX_ a)
|
||||
#define dopoptosub_at(a,b) S_dopoptosub_at(aTHX_ a,b)
|
||||
#define free_closures() S_free_closures(aTHX)
|
||||
#define save_lines(a,b) S_save_lines(aTHX_ a,b)
|
||||
#define doeval(a,b) S_doeval(aTHX_ a,b)
|
||||
#define doopen_pmc(a,b) S_doopen_pmc(aTHX_ a,b)
|
||||
@ -2498,8 +2544,6 @@
|
||||
#define sv_unglob(a) S_sv_unglob(aTHX_ a)
|
||||
#define not_a_number(a) S_not_a_number(aTHX_ a)
|
||||
#define visit(a) S_visit(aTHX_ a)
|
||||
#define sv_add_backref(a,b) S_sv_add_backref(aTHX_ a,b)
|
||||
#define sv_del_backref(a) S_sv_del_backref(aTHX_ a)
|
||||
# if defined(DEBUGGING)
|
||||
#define del_sv(a) S_del_sv(aTHX_ a)
|
||||
# endif
|
||||
@ -2521,6 +2565,7 @@
|
||||
#define scan_trans(a) S_scan_trans(aTHX_ a)
|
||||
#define scan_word(a,b,c,d,e) S_scan_word(aTHX_ a,b,c,d,e)
|
||||
#define skipspace(a) S_skipspace(aTHX_ a)
|
||||
#define swallow_bom(a) S_swallow_bom(aTHX_ a)
|
||||
#define checkcomma(a,b,c) S_checkcomma(aTHX_ a,b,c)
|
||||
#define force_ident(a,b) S_force_ident(aTHX_ a,b)
|
||||
#define incline(a) S_incline(aTHX_ a)
|
||||
@ -2534,6 +2579,7 @@
|
||||
#define sublex_push() S_sublex_push(aTHX)
|
||||
#define sublex_start() S_sublex_start(aTHX)
|
||||
#define filter_gets(a,b,c) S_filter_gets(aTHX_ a,b,c)
|
||||
#define find_in_my_stash(a,b) S_find_in_my_stash(aTHX_ a,b)
|
||||
#define new_constant(a,b,c,d,e,f) S_new_constant(aTHX_ a,b,c,d,e,f)
|
||||
#define ao(a) S_ao(aTHX_ a)
|
||||
#define depcom() S_depcom(aTHX)
|
||||
@ -2553,6 +2599,7 @@
|
||||
#define isa_lookup(a,b,c,d) S_isa_lookup(aTHX_ a,b,c,d)
|
||||
#endif
|
||||
#if defined(PERL_IN_UTIL_C) || defined(PERL_DECL_PROT)
|
||||
#define stdize_locale(a) S_stdize_locale(aTHX_ a)
|
||||
#define mess_alloc() S_mess_alloc(aTHX)
|
||||
# if defined(LEAKTEST)
|
||||
#define xstat(a) S_xstat(aTHX_ a)
|
||||
@ -2586,6 +2633,7 @@
|
||||
#define ck_open(a) Perl_ck_open(aTHX_ a)
|
||||
#define ck_repeat(a) Perl_ck_repeat(aTHX_ a)
|
||||
#define ck_require(a) Perl_ck_require(aTHX_ a)
|
||||
#define ck_return(a) Perl_ck_return(aTHX_ a)
|
||||
#define ck_rfun(a) Perl_ck_rfun(aTHX_ a)
|
||||
#define ck_rvconst(a) Perl_ck_rvconst(aTHX_ a)
|
||||
#define ck_sassign(a) Perl_ck_sassign(aTHX_ a)
|
||||
@ -2596,6 +2644,7 @@
|
||||
#define ck_spair(a) Perl_ck_spair(aTHX_ a)
|
||||
#define ck_split(a) Perl_ck_split(aTHX_ a)
|
||||
#define ck_subr(a) Perl_ck_subr(aTHX_ a)
|
||||
#define ck_substr(a) Perl_ck_substr(aTHX_ a)
|
||||
#define ck_svconst(a) Perl_ck_svconst(aTHX_ a)
|
||||
#define ck_trunc(a) Perl_ck_trunc(aTHX_ a)
|
||||
#define pp_aassign() Perl_pp_aassign(aTHX)
|
||||
@ -2981,6 +3030,8 @@
|
||||
#define append_list Perl_append_list
|
||||
#define Perl_apply CPerlObj::Perl_apply
|
||||
#define apply Perl_apply
|
||||
#define Perl_apply_attrs_string CPerlObj::Perl_apply_attrs_string
|
||||
#define apply_attrs_string Perl_apply_attrs_string
|
||||
#define Perl_avhv_delete_ent CPerlObj::Perl_avhv_delete_ent
|
||||
#define avhv_delete_ent Perl_avhv_delete_ent
|
||||
#define Perl_avhv_exists_ent CPerlObj::Perl_avhv_exists_ent
|
||||
@ -3092,6 +3143,8 @@
|
||||
#define sv_setpvf_mg_nocontext Perl_sv_setpvf_mg_nocontext
|
||||
#define Perl_fprintf_nocontext CPerlObj::Perl_fprintf_nocontext
|
||||
#define fprintf_nocontext Perl_fprintf_nocontext
|
||||
#define Perl_printf_nocontext CPerlObj::Perl_printf_nocontext
|
||||
#define printf_nocontext Perl_printf_nocontext
|
||||
#endif
|
||||
#define Perl_cv_ckproto CPerlObj::Perl_cv_ckproto
|
||||
#define cv_ckproto Perl_cv_ckproto
|
||||
@ -3281,6 +3334,8 @@
|
||||
#define gv_efullname Perl_gv_efullname
|
||||
#define Perl_gv_efullname3 CPerlObj::Perl_gv_efullname3
|
||||
#define gv_efullname3 Perl_gv_efullname3
|
||||
#define Perl_gv_efullname4 CPerlObj::Perl_gv_efullname4
|
||||
#define gv_efullname4 Perl_gv_efullname4
|
||||
#define Perl_gv_fetchfile CPerlObj::Perl_gv_fetchfile
|
||||
#define gv_fetchfile Perl_gv_fetchfile
|
||||
#define Perl_gv_fetchmeth CPerlObj::Perl_gv_fetchmeth
|
||||
@ -3295,6 +3350,8 @@
|
||||
#define gv_fullname Perl_gv_fullname
|
||||
#define Perl_gv_fullname3 CPerlObj::Perl_gv_fullname3
|
||||
#define gv_fullname3 Perl_gv_fullname3
|
||||
#define Perl_gv_fullname4 CPerlObj::Perl_gv_fullname4
|
||||
#define gv_fullname4 Perl_gv_fullname4
|
||||
#define Perl_gv_init CPerlObj::Perl_gv_init
|
||||
#define gv_init Perl_gv_init
|
||||
#define Perl_gv_stashpv CPerlObj::Perl_gv_stashpv
|
||||
@ -3361,6 +3418,10 @@
|
||||
#define io_close Perl_io_close
|
||||
#define Perl_invert CPerlObj::Perl_invert
|
||||
#define invert Perl_invert
|
||||
#define Perl_is_gv_magical CPerlObj::Perl_is_gv_magical
|
||||
#define is_gv_magical Perl_is_gv_magical
|
||||
#define Perl_is_lvalue_sub CPerlObj::Perl_is_lvalue_sub
|
||||
#define is_lvalue_sub Perl_is_lvalue_sub
|
||||
#define Perl_is_uni_alnum CPerlObj::Perl_is_uni_alnum
|
||||
#define is_uni_alnum Perl_is_uni_alnum
|
||||
#define Perl_is_uni_alnumc CPerlObj::Perl_is_uni_alnumc
|
||||
@ -3431,6 +3492,8 @@
|
||||
#define to_uni_lower_lc Perl_to_uni_lower_lc
|
||||
#define Perl_is_utf8_char CPerlObj::Perl_is_utf8_char
|
||||
#define is_utf8_char Perl_is_utf8_char
|
||||
#define Perl_is_utf8_string CPerlObj::Perl_is_utf8_string
|
||||
#define is_utf8_string Perl_is_utf8_string
|
||||
#define Perl_is_utf8_alnum CPerlObj::Perl_is_utf8_alnum
|
||||
#define is_utf8_alnum Perl_is_utf8_alnum
|
||||
#define Perl_is_utf8_alnumc CPerlObj::Perl_is_utf8_alnumc
|
||||
@ -3533,6 +3596,8 @@
|
||||
#define magic_regdata_cnt Perl_magic_regdata_cnt
|
||||
#define Perl_magic_regdatum_get CPerlObj::Perl_magic_regdatum_get
|
||||
#define magic_regdatum_get Perl_magic_regdatum_get
|
||||
#define Perl_magic_regdatum_set CPerlObj::Perl_magic_regdatum_set
|
||||
#define magic_regdatum_set Perl_magic_regdatum_set
|
||||
#define Perl_magic_set CPerlObj::Perl_magic_set
|
||||
#define magic_set Perl_magic_set
|
||||
#define Perl_magic_setamagic CPerlObj::Perl_magic_setamagic
|
||||
@ -3944,6 +4009,8 @@
|
||||
#define save_freepv Perl_save_freepv
|
||||
#define Perl_save_generic_svref CPerlObj::Perl_save_generic_svref
|
||||
#define save_generic_svref Perl_save_generic_svref
|
||||
#define Perl_save_generic_pvref CPerlObj::Perl_save_generic_pvref
|
||||
#define save_generic_pvref Perl_save_generic_pvref
|
||||
#define Perl_save_gp CPerlObj::Perl_save_gp
|
||||
#define save_gp Perl_save_gp
|
||||
#define Perl_save_hash CPerlObj::Perl_save_hash
|
||||
@ -3970,6 +4037,8 @@
|
||||
#define save_list Perl_save_list
|
||||
#define Perl_save_long CPerlObj::Perl_save_long
|
||||
#define save_long Perl_save_long
|
||||
#define Perl_save_mortalizesv CPerlObj::Perl_save_mortalizesv
|
||||
#define save_mortalizesv Perl_save_mortalizesv
|
||||
#define Perl_save_nogv CPerlObj::Perl_save_nogv
|
||||
#define save_nogv Perl_save_nogv
|
||||
#define Perl_save_op CPerlObj::Perl_save_op
|
||||
@ -3982,6 +4051,8 @@
|
||||
#define save_vptr Perl_save_vptr
|
||||
#define Perl_save_re_context CPerlObj::Perl_save_re_context
|
||||
#define save_re_context Perl_save_re_context
|
||||
#define Perl_save_padsv CPerlObj::Perl_save_padsv
|
||||
#define save_padsv Perl_save_padsv
|
||||
#define Perl_save_sptr CPerlObj::Perl_save_sptr
|
||||
#define save_sptr Perl_save_sptr
|
||||
#define Perl_save_svref CPerlObj::Perl_save_svref
|
||||
@ -4230,10 +4301,20 @@
|
||||
#define utf16_to_utf8 Perl_utf16_to_utf8
|
||||
#define Perl_utf16_to_utf8_reversed CPerlObj::Perl_utf16_to_utf8_reversed
|
||||
#define utf16_to_utf8_reversed Perl_utf16_to_utf8_reversed
|
||||
#define Perl_utf8_length CPerlObj::Perl_utf8_length
|
||||
#define utf8_length Perl_utf8_length
|
||||
#define Perl_utf8_distance CPerlObj::Perl_utf8_distance
|
||||
#define utf8_distance Perl_utf8_distance
|
||||
#define Perl_utf8_hop CPerlObj::Perl_utf8_hop
|
||||
#define utf8_hop Perl_utf8_hop
|
||||
#define Perl_utf8_to_bytes CPerlObj::Perl_utf8_to_bytes
|
||||
#define utf8_to_bytes Perl_utf8_to_bytes
|
||||
#define Perl_bytes_from_utf8 CPerlObj::Perl_bytes_from_utf8
|
||||
#define bytes_from_utf8 Perl_bytes_from_utf8
|
||||
#define Perl_bytes_to_utf8 CPerlObj::Perl_bytes_to_utf8
|
||||
#define bytes_to_utf8 Perl_bytes_to_utf8
|
||||
#define Perl_utf8_to_uv_simple CPerlObj::Perl_utf8_to_uv_simple
|
||||
#define utf8_to_uv_simple Perl_utf8_to_uv_simple
|
||||
#define Perl_utf8_to_uv CPerlObj::Perl_utf8_to_uv
|
||||
#define utf8_to_uv Perl_utf8_to_uv
|
||||
#define Perl_uv_to_utf8 CPerlObj::Perl_uv_to_utf8
|
||||
@ -4244,8 +4325,8 @@
|
||||
#define vivify_ref Perl_vivify_ref
|
||||
#define Perl_wait4pid CPerlObj::Perl_wait4pid
|
||||
#define wait4pid Perl_wait4pid
|
||||
#define Perl_report_closed_fh CPerlObj::Perl_report_closed_fh
|
||||
#define report_closed_fh Perl_report_closed_fh
|
||||
#define Perl_report_evil_fh CPerlObj::Perl_report_evil_fh
|
||||
#define report_evil_fh Perl_report_evil_fh
|
||||
#define Perl_report_uninit CPerlObj::Perl_report_uninit
|
||||
#define report_uninit Perl_report_uninit
|
||||
#define Perl_warn CPerlObj::Perl_warn
|
||||
@ -4262,13 +4343,12 @@
|
||||
#define whichsig Perl_whichsig
|
||||
#define Perl_yyerror CPerlObj::Perl_yyerror
|
||||
#define yyerror Perl_yyerror
|
||||
#if defined(USE_PURE_BISON)
|
||||
#define Perl_yylex CPerlObj::Perl_yylex
|
||||
#define yylex Perl_yylex
|
||||
#else
|
||||
#define Perl_yylex CPerlObj::Perl_yylex
|
||||
#define yylex Perl_yylex
|
||||
#ifdef USE_PURE_BISON
|
||||
#define Perl_yylex_r CPerlObj::Perl_yylex_r
|
||||
#define yylex_r Perl_yylex_r
|
||||
#endif
|
||||
#define Perl_yylex CPerlObj::Perl_yylex
|
||||
#define yylex Perl_yylex
|
||||
#define Perl_yyparse CPerlObj::Perl_yyparse
|
||||
#define yyparse Perl_yyparse
|
||||
#define Perl_yywarn CPerlObj::Perl_yywarn
|
||||
@ -4305,6 +4385,10 @@
|
||||
#define runops_standard Perl_runops_standard
|
||||
#define Perl_runops_debug CPerlObj::Perl_runops_debug
|
||||
#define runops_debug Perl_runops_debug
|
||||
#if defined(USE_THREADS)
|
||||
#define Perl_sv_lock CPerlObj::Perl_sv_lock
|
||||
#define sv_lock Perl_sv_lock
|
||||
#endif
|
||||
#define Perl_sv_catpvf_mg CPerlObj::Perl_sv_catpvf_mg
|
||||
#define sv_catpvf_mg Perl_sv_catpvf_mg
|
||||
#define Perl_sv_vcatpvf_mg CPerlObj::Perl_sv_vcatpvf_mg
|
||||
@ -4389,6 +4473,10 @@
|
||||
#define sv_utf8_decode Perl_sv_utf8_decode
|
||||
#define Perl_sv_force_normal CPerlObj::Perl_sv_force_normal
|
||||
#define sv_force_normal Perl_sv_force_normal
|
||||
#define Perl_sv_add_backref CPerlObj::Perl_sv_add_backref
|
||||
#define sv_add_backref Perl_sv_add_backref
|
||||
#define Perl_sv_del_backref CPerlObj::Perl_sv_del_backref
|
||||
#define sv_del_backref Perl_sv_del_backref
|
||||
#define Perl_tmps_grow CPerlObj::Perl_tmps_grow
|
||||
#define tmps_grow Perl_tmps_grow
|
||||
#define Perl_sv_rvweaken CPerlObj::Perl_sv_rvweaken
|
||||
@ -4440,6 +4528,16 @@
|
||||
#define ptr_table_store Perl_ptr_table_store
|
||||
#define Perl_ptr_table_split CPerlObj::Perl_ptr_table_split
|
||||
#define ptr_table_split Perl_ptr_table_split
|
||||
#define Perl_ptr_table_clear CPerlObj::Perl_ptr_table_clear
|
||||
#define ptr_table_clear Perl_ptr_table_clear
|
||||
#define Perl_ptr_table_free CPerlObj::Perl_ptr_table_free
|
||||
#define ptr_table_free Perl_ptr_table_free
|
||||
#endif
|
||||
#if defined(HAVE_INTERP_INTERN)
|
||||
#define Perl_sys_intern_clear CPerlObj::Perl_sys_intern_clear
|
||||
#define sys_intern_clear Perl_sys_intern_clear
|
||||
#define Perl_sys_intern_init CPerlObj::Perl_sys_intern_init
|
||||
#define sys_intern_init Perl_sys_intern_init
|
||||
#endif
|
||||
#if defined(PERL_OBJECT)
|
||||
#else
|
||||
@ -4451,26 +4549,18 @@
|
||||
#define avhv_index S_avhv_index
|
||||
#endif
|
||||
#if defined(PERL_IN_DOOP_C) || defined(PERL_DECL_PROT)
|
||||
#define S_do_trans_CC_simple CPerlObj::S_do_trans_CC_simple
|
||||
#define do_trans_CC_simple S_do_trans_CC_simple
|
||||
#define S_do_trans_CC_count CPerlObj::S_do_trans_CC_count
|
||||
#define do_trans_CC_count S_do_trans_CC_count
|
||||
#define S_do_trans_CC_complex CPerlObj::S_do_trans_CC_complex
|
||||
#define do_trans_CC_complex S_do_trans_CC_complex
|
||||
#define S_do_trans_UU_simple CPerlObj::S_do_trans_UU_simple
|
||||
#define do_trans_UU_simple S_do_trans_UU_simple
|
||||
#define S_do_trans_UU_count CPerlObj::S_do_trans_UU_count
|
||||
#define do_trans_UU_count S_do_trans_UU_count
|
||||
#define S_do_trans_UU_complex CPerlObj::S_do_trans_UU_complex
|
||||
#define do_trans_UU_complex S_do_trans_UU_complex
|
||||
#define S_do_trans_UC_simple CPerlObj::S_do_trans_UC_simple
|
||||
#define do_trans_UC_simple S_do_trans_UC_simple
|
||||
#define S_do_trans_CU_simple CPerlObj::S_do_trans_CU_simple
|
||||
#define do_trans_CU_simple S_do_trans_CU_simple
|
||||
#define S_do_trans_UC_trivial CPerlObj::S_do_trans_UC_trivial
|
||||
#define do_trans_UC_trivial S_do_trans_UC_trivial
|
||||
#define S_do_trans_CU_trivial CPerlObj::S_do_trans_CU_trivial
|
||||
#define do_trans_CU_trivial S_do_trans_CU_trivial
|
||||
#define S_do_trans_simple CPerlObj::S_do_trans_simple
|
||||
#define do_trans_simple S_do_trans_simple
|
||||
#define S_do_trans_count CPerlObj::S_do_trans_count
|
||||
#define do_trans_count S_do_trans_count
|
||||
#define S_do_trans_complex CPerlObj::S_do_trans_complex
|
||||
#define do_trans_complex S_do_trans_complex
|
||||
#define S_do_trans_simple_utf8 CPerlObj::S_do_trans_simple_utf8
|
||||
#define do_trans_simple_utf8 S_do_trans_simple_utf8
|
||||
#define S_do_trans_count_utf8 CPerlObj::S_do_trans_count_utf8
|
||||
#define do_trans_count_utf8 S_do_trans_count_utf8
|
||||
#define S_do_trans_complex_utf8 CPerlObj::S_do_trans_complex_utf8
|
||||
#define do_trans_complex_utf8 S_do_trans_complex_utf8
|
||||
#endif
|
||||
#if defined(PERL_IN_GV_C) || defined(PERL_DECL_PROT)
|
||||
#define S_gv_init_sv CPerlObj::S_gv_init_sv
|
||||
@ -4519,6 +4609,8 @@
|
||||
#define too_few_arguments S_too_few_arguments
|
||||
#define S_too_many_arguments CPerlObj::S_too_many_arguments
|
||||
#define too_many_arguments S_too_many_arguments
|
||||
#define S_trlist_upgrade CPerlObj::S_trlist_upgrade
|
||||
#define trlist_upgrade S_trlist_upgrade
|
||||
#define S_op_clear CPerlObj::S_op_clear
|
||||
#define op_clear S_op_clear
|
||||
#define S_null CPerlObj::S_null
|
||||
@ -4649,8 +4741,6 @@
|
||||
#define dopoptosub S_dopoptosub
|
||||
#define S_dopoptosub_at CPerlObj::S_dopoptosub_at
|
||||
#define dopoptosub_at S_dopoptosub_at
|
||||
#define S_free_closures CPerlObj::S_free_closures
|
||||
#define free_closures S_free_closures
|
||||
#define S_save_lines CPerlObj::S_save_lines
|
||||
#define save_lines S_save_lines
|
||||
#define S_doeval CPerlObj::S_doeval
|
||||
@ -4861,10 +4951,6 @@
|
||||
#define not_a_number S_not_a_number
|
||||
#define S_visit CPerlObj::S_visit
|
||||
#define visit S_visit
|
||||
#define S_sv_add_backref CPerlObj::S_sv_add_backref
|
||||
#define sv_add_backref S_sv_add_backref
|
||||
#define S_sv_del_backref CPerlObj::S_sv_del_backref
|
||||
#define sv_del_backref S_sv_del_backref
|
||||
# if defined(DEBUGGING)
|
||||
#define S_del_sv CPerlObj::S_del_sv
|
||||
#define del_sv S_del_sv
|
||||
@ -4903,6 +4989,8 @@
|
||||
#define scan_word S_scan_word
|
||||
#define S_skipspace CPerlObj::S_skipspace
|
||||
#define skipspace S_skipspace
|
||||
#define S_swallow_bom CPerlObj::S_swallow_bom
|
||||
#define swallow_bom S_swallow_bom
|
||||
#define S_checkcomma CPerlObj::S_checkcomma
|
||||
#define checkcomma S_checkcomma
|
||||
#define S_force_ident CPerlObj::S_force_ident
|
||||
@ -4929,6 +5017,8 @@
|
||||
#define sublex_start S_sublex_start
|
||||
#define S_filter_gets CPerlObj::S_filter_gets
|
||||
#define filter_gets S_filter_gets
|
||||
#define S_find_in_my_stash CPerlObj::S_find_in_my_stash
|
||||
#define find_in_my_stash S_find_in_my_stash
|
||||
#define S_new_constant CPerlObj::S_new_constant
|
||||
#define new_constant S_new_constant
|
||||
#define S_ao CPerlObj::S_ao
|
||||
@ -4957,6 +5047,8 @@
|
||||
#define isa_lookup S_isa_lookup
|
||||
#endif
|
||||
#if defined(PERL_IN_UTIL_C) || defined(PERL_DECL_PROT)
|
||||
#define S_stdize_locale CPerlObj::S_stdize_locale
|
||||
#define stdize_locale S_stdize_locale
|
||||
#define S_mess_alloc CPerlObj::S_mess_alloc
|
||||
#define mess_alloc S_mess_alloc
|
||||
# if defined(LEAKTEST)
|
||||
@ -5018,6 +5110,8 @@
|
||||
#define ck_repeat Perl_ck_repeat
|
||||
#define Perl_ck_require CPerlObj::Perl_ck_require
|
||||
#define ck_require Perl_ck_require
|
||||
#define Perl_ck_return CPerlObj::Perl_ck_return
|
||||
#define ck_return Perl_ck_return
|
||||
#define Perl_ck_rfun CPerlObj::Perl_ck_rfun
|
||||
#define ck_rfun Perl_ck_rfun
|
||||
#define Perl_ck_rvconst CPerlObj::Perl_ck_rvconst
|
||||
@ -5038,6 +5132,8 @@
|
||||
#define ck_split Perl_ck_split
|
||||
#define Perl_ck_subr CPerlObj::Perl_ck_subr
|
||||
#define ck_subr Perl_ck_subr
|
||||
#define Perl_ck_substr CPerlObj::Perl_ck_substr
|
||||
#define ck_substr Perl_ck_substr
|
||||
#define Perl_ck_svconst CPerlObj::Perl_ck_svconst
|
||||
#define ck_svconst Perl_ck_svconst
|
||||
#define Perl_ck_trunc CPerlObj::Perl_ck_trunc
|
||||
|
@ -25,6 +25,7 @@ sub walk_table (&@) {
|
||||
$F = $filename;
|
||||
}
|
||||
else {
|
||||
unlink $filename;
|
||||
open F, ">$filename" or die "Can't open $filename: $!";
|
||||
$F = \*F;
|
||||
}
|
||||
@ -198,6 +199,7 @@ my @extvars = qw(sv_undef sv_yes sv_no na dowarn
|
||||
diehook
|
||||
dirty
|
||||
perl_destruct_level
|
||||
ppaddr
|
||||
);
|
||||
|
||||
sub readsyms (\%$) {
|
||||
@ -916,6 +918,9 @@ START_EXTERN_C
|
||||
{ return &(PL_##v); }
|
||||
#define PERLVARA(v,n,t) PL_##v##_t* Perl_##v##_ptr(pTHXo) \
|
||||
{ return &(PL_##v); }
|
||||
#undef PERLVARIC
|
||||
#define PERLVARIC(v,t,i) const t* Perl_##v##_ptr(pTHXo) \
|
||||
{ return (const t *)&(PL_##v); }
|
||||
#include "perlvars.h"
|
||||
|
||||
#undef PERLVAR
|
||||
@ -1064,6 +1069,16 @@ Perl_fprintf_nocontext(PerlIO *stream, const char *format, ...)
|
||||
return (*PL_StdIO->pVprintf)(PL_StdIO, stream, format, arglist);
|
||||
}
|
||||
|
||||
#undef Perl_printf_nocontext
|
||||
int
|
||||
Perl_printf_nocontext(const char *format, ...)
|
||||
{
|
||||
dTHXo;
|
||||
va_list(arglist);
|
||||
va_start(arglist, format);
|
||||
return (*PL_StdIO->pVprintf)(PL_StdIO, PerlIO_stdout(), format, arglist);
|
||||
}
|
||||
|
||||
END_EXTERN_C
|
||||
|
||||
#endif /* PERL_OBJECT */
|
||||
@ -1078,12 +1093,12 @@ my %apidocs;
|
||||
my %gutsdocs;
|
||||
my %docfuncs;
|
||||
|
||||
sub autodoc ($) { # parse a file and extract documentation info
|
||||
my($fh) = @_;
|
||||
my($in, $doc);
|
||||
|
||||
sub autodoc ($$) { # parse a file and extract documentation info
|
||||
my($fh,$file) = @_;
|
||||
my($in, $doc, $line);
|
||||
FUNC:
|
||||
while (defined($in = <$fh>)) {
|
||||
$line++;
|
||||
if ($in =~ /^=for\s+apidoc\s+(.*)\n/) {
|
||||
my $proto = $1;
|
||||
$proto = "||$proto" unless $proto =~ /\|/;
|
||||
@ -1091,24 +1106,33 @@ FUNC:
|
||||
my $docs = "";
|
||||
DOC:
|
||||
while (defined($doc = <$fh>)) {
|
||||
$line++;
|
||||
last DOC if $doc =~ /^=\w+/;
|
||||
if ($doc =~ m:^\*/$:) {
|
||||
warn "=cut missing? $file:$line:$doc";;
|
||||
last DOC;
|
||||
}
|
||||
$docs .= $doc;
|
||||
}
|
||||
$docs = "\n$docs" if $docs and $docs !~ /^\n/;
|
||||
if ($flags =~ /m/) {
|
||||
if ($flags =~ /A/) {
|
||||
$apidocs{$name} = [$flags, $docs, $ret, @args];
|
||||
$apidocs{$name} = [$flags, $docs, $ret, $file, @args];
|
||||
}
|
||||
else {
|
||||
$gutsdocs{$name} = [$flags, $docs, $ret, @args];
|
||||
$gutsdocs{$name} = [$flags, $docs, $ret, $file, @args];
|
||||
}
|
||||
}
|
||||
else {
|
||||
$docfuncs{$name} = [$flags, $docs, $ret, @args];
|
||||
$docfuncs{$name} = [$flags, $docs, $ret, $file, @args];
|
||||
}
|
||||
if ($doc =~ /^=for/) {
|
||||
$in = $doc;
|
||||
redo FUNC;
|
||||
if (defined $doc) {
|
||||
if ($doc =~ /^=for/) {
|
||||
$in = $doc;
|
||||
redo FUNC;
|
||||
}
|
||||
} else {
|
||||
warn "$file:$line:$in";
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1116,8 +1140,10 @@ DOC:
|
||||
|
||||
sub docout ($$$) { # output the docs for one function
|
||||
my($fh, $name, $docref) = @_;
|
||||
my($flags, $docs, $ret, @args) = @$docref;
|
||||
my($flags, $docs, $ret, $file, @args) = @$docref;
|
||||
|
||||
$docs .= "NOTE: this function is experimental and may change or be
|
||||
removed without notice.\n\n" if $flags =~ /x/;
|
||||
$docs .= "NOTE: the perl_ form of this function is deprecated.\n\n"
|
||||
if $flags =~ /p/;
|
||||
|
||||
@ -1134,12 +1160,13 @@ sub docout ($$$) { # output the docs for one function
|
||||
print $fh "(" . join(", ", @args) . ")";
|
||||
print $fh "\n\n";
|
||||
}
|
||||
print $fh "=for hackers\nFound in file $file\n\n";
|
||||
}
|
||||
|
||||
my $file;
|
||||
for $file (glob('*.c'), glob('*.h')) {
|
||||
open F, "< $file" or die "Cannot open $file for docs: $!\n";
|
||||
autodoc(\*F);
|
||||
autodoc(\*F,$file);
|
||||
close F or die "Error closing $file: $!\n";
|
||||
}
|
||||
|
||||
@ -1156,16 +1183,21 @@ walk_table { # load documented functions into approriate hash
|
||||
if ($flags =~ /A/) {
|
||||
my $docref = delete $docfuncs{$func};
|
||||
warn "no docs for $func\n" unless $docref and @$docref;
|
||||
$apidocs{$func} = [$docref->[0] . 'A', $docref->[1], $retval, @args];
|
||||
$docref->[0].="x" if $flags =~ /M/;
|
||||
$apidocs{$func} = [$docref->[0] . 'A', $docref->[1], $retval,
|
||||
$docref->[3], @args];
|
||||
} else {
|
||||
my $docref = delete $docfuncs{$func};
|
||||
$gutsdocs{$func} = [$docref->[0], $docref->[1], $retval, @args];
|
||||
$gutsdocs{$func} = [$docref->[0], $docref->[1], $retval,
|
||||
$docref->[3], @args];
|
||||
}
|
||||
}
|
||||
return "";
|
||||
} \*DOC;
|
||||
|
||||
for (sort keys %docfuncs) {
|
||||
# Have you used a full for apidoc or just a func name?
|
||||
# Have you used Ap instead of Am in the for apidoc?
|
||||
warn "Unable to place $_!\n";
|
||||
}
|
||||
|
||||
@ -1235,7 +1267,7 @@ perlintern - autogenerated documentation of purely B<internal>
|
||||
=head1 DESCRIPTION
|
||||
|
||||
This file is the autogenerated documentation of functions in the
|
||||
Perl intrepreter that are documented using Perl's internal documentation
|
||||
Perl interpreter that are documented using Perl's internal documentation
|
||||
format but are not marked as part of the Perl API. In other words,
|
||||
B<they are not for use in extensions>!
|
||||
|
||||
@ -1252,7 +1284,7 @@ print GUTS <<'END';
|
||||
|
||||
=head1 AUTHORS
|
||||
|
||||
The autodocumentation system was orignally added to the Perl core by
|
||||
The autodocumentation system was originally added to the Perl core by
|
||||
Benjamin Stuhl. Documentation is by whoever was kind enough to
|
||||
document their functions.
|
||||
|
||||
@ -1285,6 +1317,7 @@ __END__
|
||||
: o has no compatibility macro (#define foo Perl_foo)
|
||||
: j not a member of CPerlObj
|
||||
: x not exported
|
||||
: M may change
|
||||
:
|
||||
: Individual flags may be separated by whitespace.
|
||||
:
|
||||
@ -1358,6 +1391,7 @@ Ap |bool |Gv_AMupdate |HV* stash
|
||||
p |OP* |append_elem |I32 optype|OP* head|OP* tail
|
||||
p |OP* |append_list |I32 optype|LISTOP* first|LISTOP* last
|
||||
p |I32 |apply |I32 type|SV** mark|SV** sp
|
||||
Ap |void |apply_attrs_string|char *stashpv|CV *cv|char *attrstr|STRLEN len
|
||||
Ap |SV* |avhv_delete_ent|AV *ar|SV* keysv|I32 flags|U32 hash
|
||||
Ap |bool |avhv_exists_ent|AV *ar|SV* keysv|U32 hash
|
||||
Ap |SV** |avhv_fetch_ent |AV *ar|SV* keysv|I32 lval|U32 hash
|
||||
@ -1366,17 +1400,17 @@ Ap |HE* |avhv_iternext |AV *ar
|
||||
Ap |SV* |avhv_iterval |AV *ar|HE* entry
|
||||
Ap |HV* |avhv_keys |AV *ar
|
||||
Apd |void |av_clear |AV* ar
|
||||
Ap |SV* |av_delete |AV* ar|I32 key|I32 flags
|
||||
Ap |bool |av_exists |AV* ar|I32 key
|
||||
Apd |SV* |av_delete |AV* ar|I32 key|I32 flags
|
||||
Apd |bool |av_exists |AV* ar|I32 key
|
||||
Apd |void |av_extend |AV* ar|I32 key
|
||||
Ap |AV* |av_fake |I32 size|SV** svp
|
||||
p |AV* |av_fake |I32 size|SV** svp
|
||||
Apd |SV** |av_fetch |AV* ar|I32 key|I32 lval
|
||||
Ap |void |av_fill |AV* ar|I32 fill
|
||||
Apd |void |av_fill |AV* ar|I32 fill
|
||||
Apd |I32 |av_len |AV* ar
|
||||
Apd |AV* |av_make |I32 size|SV** svp
|
||||
Apd |SV* |av_pop |AV* ar
|
||||
Apd |void |av_push |AV* ar|SV* val
|
||||
Ap |void |av_reify |AV* ar
|
||||
ApM |void |av_reify |AV* ar
|
||||
Apd |SV* |av_shift |AV* ar
|
||||
Apd |SV** |av_store |AV* ar|I32 key|SV* val
|
||||
Apd |void |av_undef |AV* ar
|
||||
@ -1406,7 +1440,7 @@ Afnrp |void |croak_nocontext|const char* pat|...
|
||||
Afnp |OP* |die_nocontext |const char* pat|...
|
||||
Afnp |void |deb_nocontext |const char* pat|...
|
||||
Afnp |char* |form_nocontext |const char* pat|...
|
||||
Afnp |void |load_module_nocontext|U32 flags|SV* name|SV* ver|...
|
||||
Anp |void |load_module_nocontext|U32 flags|SV* name|SV* ver|...
|
||||
Afnp |SV* |mess_nocontext |const char* pat|...
|
||||
Afnp |void |warn_nocontext |const char* pat|...
|
||||
Afnp |void |warner_nocontext|U32 err|const char* pat|...
|
||||
@ -1416,6 +1450,7 @@ Afnp |void |sv_setpvf_nocontext|SV* sv|const char* pat|...
|
||||
Afnp |void |sv_catpvf_mg_nocontext|SV* sv|const char* pat|...
|
||||
Afnp |void |sv_setpvf_mg_nocontext|SV* sv|const char* pat|...
|
||||
Afnp |int |fprintf_nocontext|PerlIO* stream|const char* fmt|...
|
||||
Afnp |int |printf_nocontext|const char* fmt|...
|
||||
#endif
|
||||
p |void |cv_ckproto |CV* cv|GV* gv|char* p
|
||||
p |CV* |cv_clone |CV* proto
|
||||
@ -1447,7 +1482,7 @@ p |OP* |die_where |char* message|STRLEN msglen
|
||||
Ap |void |dounwind |I32 cxix
|
||||
p |bool |do_aexec |SV* really|SV** mark|SV** sp
|
||||
p |bool |do_aexec5 |SV* really|SV** mark|SV** sp|int fd|int flag
|
||||
Ap |int |do_binmode |PerlIO *fp|int iotype|int flag
|
||||
Ap |int |do_binmode |PerlIO *fp|int iotype|int mode
|
||||
p |void |do_chop |SV* asv|SV* sv
|
||||
Ap |bool |do_close |GV* gv|bool not_implicit
|
||||
p |bool |do_eof |GV* gv
|
||||
@ -1464,7 +1499,7 @@ p |I32 |do_msgsnd |SV** mark|SV** sp
|
||||
p |I32 |do_semop |SV** mark|SV** sp
|
||||
p |I32 |do_shmio |I32 optype|SV** mark|SV** sp
|
||||
#endif
|
||||
p |void |do_join |SV* sv|SV* del|SV** mark|SV** sp
|
||||
Ap |void |do_join |SV* sv|SV* del|SV** mark|SV** sp
|
||||
p |OP* |do_kv
|
||||
Ap |bool |do_open |GV* gv|char* name|I32 len|int as_raw \
|
||||
|int rawmode|int rawperm|PerlIO* supplied_fp
|
||||
@ -1511,7 +1546,7 @@ Ap |char* |vform |const char* pat|va_list* args
|
||||
Ap |void |free_tmps
|
||||
p |OP* |gen_constant_list|OP* o
|
||||
#if !defined(HAS_GETENV_LEN)
|
||||
p |char* |getenv_len |char* key|unsigned long *len
|
||||
p |char* |getenv_len |const char* key|unsigned long *len
|
||||
#endif
|
||||
Ap |void |gp_free |GV* gv
|
||||
Ap |GP* |gp_ref |GP* gp
|
||||
@ -1523,6 +1558,7 @@ Ap |GV* |gv_autoload4 |HV* stash|const char* name|STRLEN len \
|
||||
Ap |void |gv_check |HV* stash
|
||||
Ap |void |gv_efullname |SV* sv|GV* gv
|
||||
Ap |void |gv_efullname3 |SV* sv|GV* gv|const char* prefix
|
||||
Ap |void |gv_efullname4 |SV* sv|GV* gv|const char* prefix|bool keepmain
|
||||
Ap |GV* |gv_fetchfile |const char* name
|
||||
Apd |GV* |gv_fetchmeth |HV* stash|const char* name|STRLEN len \
|
||||
|I32 level
|
||||
@ -1532,6 +1568,7 @@ Apd |GV* |gv_fetchmethod_autoload|HV* stash|const char* name \
|
||||
Ap |GV* |gv_fetchpv |const char* name|I32 add|I32 sv_type
|
||||
Ap |void |gv_fullname |SV* sv|GV* gv
|
||||
Ap |void |gv_fullname3 |SV* sv|GV* gv|const char* prefix
|
||||
Ap |void |gv_fullname4 |SV* sv|GV* gv|const char* prefix|bool keepmain
|
||||
Ap |void |gv_init |GV* gv|HV* stash|const char* name \
|
||||
|STRLEN len|int multi
|
||||
Apd |HV* |gv_stashpv |const char* name|I32 create
|
||||
@ -1567,6 +1604,8 @@ p |U32 |intro_my
|
||||
Ap |char* |instr |const char* big|const char* little
|
||||
p |bool |io_close |IO* io|bool not_implicit
|
||||
p |OP* |invert |OP* cmd
|
||||
dp |bool |is_gv_magical |char *name|STRLEN len|U32 flags
|
||||
p |I32 |is_lvalue_sub
|
||||
Ap |bool |is_uni_alnum |U32 c
|
||||
Ap |bool |is_uni_alnumc |U32 c
|
||||
Ap |bool |is_uni_idfirst |U32 c
|
||||
@ -1601,7 +1640,8 @@ Ap |bool |is_uni_xdigit_lc|U32 c
|
||||
Ap |U32 |to_uni_upper_lc|U32 c
|
||||
Ap |U32 |to_uni_title_lc|U32 c
|
||||
Ap |U32 |to_uni_lower_lc|U32 c
|
||||
Ap |int |is_utf8_char |U8 *p
|
||||
Apd |STRLEN |is_utf8_char |U8 *p
|
||||
Apd |bool |is_utf8_string |U8 *s|STRLEN len
|
||||
Ap |bool |is_utf8_alnum |U8 *p
|
||||
Ap |bool |is_utf8_alnumc |U8 *p
|
||||
Ap |bool |is_utf8_idfirst|U8 *p
|
||||
@ -1625,7 +1665,7 @@ p |void |lex_start |SV* line
|
||||
p |OP* |linklist |OP* o
|
||||
p |OP* |list |OP* o
|
||||
p |OP* |listkids |OP* o
|
||||
Afp |void |load_module|U32 flags|SV* name|SV* ver|...
|
||||
Ap |void |load_module|U32 flags|SV* name|SV* ver|...
|
||||
Ap |void |vload_module|U32 flags|SV* name|SV* ver|va_list* args
|
||||
p |OP* |localize |OP* arg|I32 lexical
|
||||
Apd |I32 |looks_like_number|SV* sv
|
||||
@ -1654,6 +1694,7 @@ p |int |magic_mutexfree|SV* sv|MAGIC* mg
|
||||
p |int |magic_nextpack |SV* sv|MAGIC* mg|SV* key
|
||||
p |U32 |magic_regdata_cnt|SV* sv|MAGIC* mg
|
||||
p |int |magic_regdatum_get|SV* sv|MAGIC* mg
|
||||
p |int |magic_regdatum_set|SV* sv|MAGIC* mg
|
||||
p |int |magic_set |SV* sv|MAGIC* mg
|
||||
p |int |magic_setamagic|SV* sv|MAGIC* mg
|
||||
p |int |magic_setarylen|SV* sv|MAGIC* mg
|
||||
@ -1824,9 +1865,9 @@ Apd |HV* |get_hv |const char* name|I32 create
|
||||
Apd |CV* |get_cv |const char* name|I32 create
|
||||
Ap |int |init_i18nl10n |int printwarn
|
||||
Ap |int |init_i18nl14n |int printwarn
|
||||
Ap |void |new_collate |const char* newcoll
|
||||
Ap |void |new_ctype |const char* newctype
|
||||
Ap |void |new_numeric |const char* newcoll
|
||||
Ap |void |new_collate |char* newcoll
|
||||
Ap |void |new_ctype |char* newctype
|
||||
Ap |void |new_numeric |char* newcoll
|
||||
Ap |void |set_numeric_local
|
||||
Ap |void |set_numeric_radix
|
||||
Ap |void |set_numeric_standard
|
||||
@ -1860,7 +1901,7 @@ p |void |regprop |SV* sv|regnode* o
|
||||
Ap |void |repeatcpy |char* to|const char* from|I32 len|I32 count
|
||||
Ap |char* |rninstr |const char* big|const char* bigend \
|
||||
|const char* little|const char* lend
|
||||
p |Sighandler_t|rsignal |int i|Sighandler_t t
|
||||
Ap |Sighandler_t|rsignal |int i|Sighandler_t t
|
||||
p |int |rsignal_restore|int i|Sigsave_t* t
|
||||
p |int |rsignal_save |int i|Sighandler_t t1|Sigsave_t* t2
|
||||
p |Sighandler_t|rsignal_state|int i
|
||||
@ -1885,6 +1926,7 @@ Ap |void |save_freesv |SV* sv
|
||||
p |void |save_freeop |OP* o
|
||||
Ap |void |save_freepv |char* pv
|
||||
Ap |void |save_generic_svref|SV** sptr
|
||||
Ap |void |save_generic_pvref|char** str
|
||||
Ap |void |save_gp |GV* gv|I32 empty
|
||||
Ap |HV* |save_hash |GV* gv
|
||||
Ap |void |save_helem |HV* hv|SV *key|SV **sptr
|
||||
@ -1898,12 +1940,14 @@ Ap |void |save_item |SV* item
|
||||
Ap |void |save_iv |IV* iv
|
||||
Ap |void |save_list |SV** sarg|I32 maxsarg
|
||||
Ap |void |save_long |long* longp
|
||||
Ap |void |save_mortalizesv|SV* sv
|
||||
Ap |void |save_nogv |GV* gv
|
||||
p |void |save_op
|
||||
Ap |SV* |save_scalar |GV* gv
|
||||
Ap |void |save_pptr |char** pptr
|
||||
Ap |void |save_vptr |void* pptr
|
||||
Ap |void |save_re_context
|
||||
Ap |void |save_padsv |PADOFFSET off
|
||||
Ap |void |save_sptr |SV** sptr
|
||||
Ap |SV* |save_svref |SV** sptr
|
||||
Ap |SV** |save_threadsv |PADOFFSET i
|
||||
@ -1912,10 +1956,10 @@ p |OP* |scalar |OP* o
|
||||
p |OP* |scalarkids |OP* o
|
||||
p |OP* |scalarseq |OP* o
|
||||
p |OP* |scalarvoid |OP* o
|
||||
Ap |NV |scan_bin |char* start|I32 len|I32* retlen
|
||||
Ap |NV |scan_hex |char* start|I32 len|I32* retlen
|
||||
Ap |char* |scan_num |char* s
|
||||
Ap |NV |scan_oct |char* start|I32 len|I32* retlen
|
||||
Ap |NV |scan_bin |char* start|STRLEN len|STRLEN* retlen
|
||||
Ap |NV |scan_hex |char* start|STRLEN len|STRLEN* retlen
|
||||
Ap |char* |scan_num |char* s|YYSTYPE *lvalp
|
||||
Ap |NV |scan_oct |char* start|STRLEN len|STRLEN* retlen
|
||||
p |OP* |scope |OP* o
|
||||
Ap |char* |screaminstr |SV* bigsv|SV* littlesv|I32 start_shift \
|
||||
|I32 end_shift|I32 *state|I32 last
|
||||
@ -1945,7 +1989,7 @@ Ap |NV |sv_nv |SV* sv
|
||||
Ap |char* |sv_pvn |SV *sv|STRLEN *len
|
||||
Ap |char* |sv_pvutf8n |SV *sv|STRLEN *len
|
||||
Ap |char* |sv_pvbyten |SV *sv|STRLEN *len
|
||||
Ap |I32 |sv_true |SV *sv
|
||||
Apd |I32 |sv_true |SV *sv
|
||||
p |void |sv_add_arena |char* ptr|U32 size|U32 flags
|
||||
Ap |int |sv_backoff |SV* sv
|
||||
Apd |SV* |sv_bless |SV* sv|HV* stash
|
||||
@ -1955,11 +1999,11 @@ Apd |void |sv_catpv |SV* sv|const char* ptr
|
||||
Apd |void |sv_catpvn |SV* sv|const char* ptr|STRLEN len
|
||||
Apd |void |sv_catsv |SV* dsv|SV* ssv
|
||||
Apd |void |sv_chop |SV* sv|char* ptr
|
||||
p |void |sv_clean_all
|
||||
p |I32 |sv_clean_all
|
||||
p |void |sv_clean_objs
|
||||
Ap |void |sv_clear |SV* sv
|
||||
Apd |void |sv_clear |SV* sv
|
||||
Apd |I32 |sv_cmp |SV* sv1|SV* sv2
|
||||
Ap |I32 |sv_cmp_locale |SV* sv1|SV* sv2
|
||||
Apd |I32 |sv_cmp_locale |SV* sv1|SV* sv2
|
||||
#if defined(USE_LOCALE_COLLATE)
|
||||
Ap |char* |sv_collxfrm |SV* sv|STRLEN* nxp
|
||||
#endif
|
||||
@ -1968,9 +2012,9 @@ Apd |void |sv_dec |SV* sv
|
||||
Ap |void |sv_dump |SV* sv
|
||||
Apd |bool |sv_derived_from|SV* sv|const char* name
|
||||
Apd |I32 |sv_eq |SV* sv1|SV* sv2
|
||||
Ap |void |sv_free |SV* sv
|
||||
Apd |void |sv_free |SV* sv
|
||||
p |void |sv_free_arenas
|
||||
Ap |char* |sv_gets |SV* sv|PerlIO* fp|I32 append
|
||||
Apd |char* |sv_gets |SV* sv|PerlIO* fp|I32 append
|
||||
Apd |char* |sv_grow |SV* sv|STRLEN newlen
|
||||
Apd |void |sv_inc |SV* sv
|
||||
Apd |void |sv_insert |SV* bigsv|STRLEN offset|STRLEN len \
|
||||
@ -1978,7 +2022,7 @@ Apd |void |sv_insert |SV* bigsv|STRLEN offset|STRLEN len \
|
||||
Apd |int |sv_isa |SV* sv|const char* name
|
||||
Apd |int |sv_isobject |SV* sv
|
||||
Apd |STRLEN |sv_len |SV* sv
|
||||
Ap |STRLEN |sv_len_utf8 |SV* sv
|
||||
Apd |STRLEN |sv_len_utf8 |SV* sv
|
||||
Apd |void |sv_magic |SV* sv|SV* obj|int how|const char* name \
|
||||
|I32 namlen
|
||||
Apd |SV* |sv_mortalcopy |SV* oldsv
|
||||
@ -1987,11 +2031,11 @@ Ap |SV* |sv_newref |SV* sv
|
||||
Ap |char* |sv_peek |SV* sv
|
||||
Ap |void |sv_pos_u2b |SV* sv|I32* offsetp|I32* lenp
|
||||
Ap |void |sv_pos_b2u |SV* sv|I32* offsetp
|
||||
Ap |char* |sv_pvn_force |SV* sv|STRLEN* lp
|
||||
Ap |char* |sv_pvutf8n_force|SV* sv|STRLEN* lp
|
||||
Apd |char* |sv_pvn_force |SV* sv|STRLEN* lp
|
||||
Apd |char* |sv_pvutf8n_force|SV* sv|STRLEN* lp
|
||||
Ap |char* |sv_pvbyten_force|SV* sv|STRLEN* lp
|
||||
Ap |char* |sv_reftype |SV* sv|int ob
|
||||
Ap |void |sv_replace |SV* sv|SV* nsv
|
||||
Apd |char* |sv_reftype |SV* sv|int ob
|
||||
Apd |void |sv_replace |SV* sv|SV* nsv
|
||||
Ap |void |sv_report_used
|
||||
Ap |void |sv_reset |char* s|HV* stash
|
||||
Afpd |void |sv_setpvf |SV* sv|const char* pat|...
|
||||
@ -2010,7 +2054,7 @@ Apd |void |sv_setpvn |SV* sv|const char* ptr|STRLEN len
|
||||
Apd |void |sv_setsv |SV* dsv|SV* ssv
|
||||
Ap |void |sv_taint |SV* sv
|
||||
Ap |bool |sv_tainted |SV* sv
|
||||
Ap |int |sv_unmagic |SV* sv|int type
|
||||
Apd |int |sv_unmagic |SV* sv|int type
|
||||
Apd |void |sv_unref |SV* sv
|
||||
Ap |void |sv_untaint |SV* sv
|
||||
Apd |bool |sv_upgrade |SV* sv|U32 mt
|
||||
@ -2039,29 +2083,33 @@ Ap |void |unlock_condpair|void* svv
|
||||
Ap |void |unsharepvn |const char* sv|I32 len|U32 hash
|
||||
p |void |unshare_hek |HEK* hek
|
||||
p |void |utilize |int aver|I32 floor|OP* version|OP* id|OP* arg
|
||||
Ap |U8* |utf16_to_utf8 |U16* p|U8 *d|I32 bytelen
|
||||
Ap |U8* |utf16_to_utf8_reversed|U16* p|U8 *d|I32 bytelen
|
||||
Ap |I32 |utf8_distance |U8 *a|U8 *b
|
||||
Ap |U8* |utf8_hop |U8 *s|I32 off
|
||||
Ap |UV |utf8_to_uv |U8 *s|I32* retlen
|
||||
Ap |U8* |uv_to_utf8 |U8 *d|UV uv
|
||||
ApM |U8* |utf16_to_utf8 |U8* p|U8 *d|I32 bytelen|I32 *newlen
|
||||
ApM |U8* |utf16_to_utf8_reversed|U8* p|U8 *d|I32 bytelen|I32 *newlen
|
||||
ApMd |STRLEN |utf8_length |U8* s|U8 *e
|
||||
ApMd |IV |utf8_distance |U8 *a|U8 *b
|
||||
ApMd |U8* |utf8_hop |U8 *s|I32 off
|
||||
ApMd |U8* |utf8_to_bytes |U8 *s|STRLEN *len
|
||||
ApMd |U8* |bytes_from_utf8|U8 *s|STRLEN *len|bool *is_utf8
|
||||
ApMd |U8* |bytes_to_utf8 |U8 *s|STRLEN *len
|
||||
ApMd |UV |utf8_to_uv_simple|U8 *s|STRLEN* retlen
|
||||
ApMd |UV |utf8_to_uv |U8 *s|STRLEN curlen|STRLEN* retlen|U32 flags
|
||||
ApMd |U8* |uv_to_utf8 |U8 *d|UV uv
|
||||
p |void |vivify_defelem |SV* sv
|
||||
p |void |vivify_ref |SV* sv|U32 to_what
|
||||
p |I32 |wait4pid |Pid_t pid|int* statusp|int flags
|
||||
p |void |report_closed_fh|GV *gv|IO *io|const char *func|const char *obj
|
||||
p |void |report_evil_fh |GV *gv|IO *io|I32 op
|
||||
p |void |report_uninit
|
||||
Afpd |void |warn |const char* pat|...
|
||||
Ap |void |vwarn |const char* pat|va_list* args
|
||||
Afp |void |warner |U32 err|const char* pat|...
|
||||
Ap |void |vwarner |U32 err|const char* pat|va_list* args
|
||||
p |void |watch |char** addr
|
||||
p |I32 |whichsig |char* sig
|
||||
Ap |I32 |whichsig |char* sig
|
||||
p |int |yyerror |char* s
|
||||
#if defined(USE_PURE_BISON)
|
||||
p |int |yylex |YYSTYPE *lvalp|int *lcharp
|
||||
#else
|
||||
p |int |yylex
|
||||
#ifdef USE_PURE_BISON
|
||||
p |int |yylex_r |YYSTYPE *lvalp|int *lcharp
|
||||
#endif
|
||||
p |int |yylex
|
||||
p |int |yyparse
|
||||
p |int |yywarn |char* s
|
||||
#if defined(MYMALLOC)
|
||||
@ -2083,6 +2131,9 @@ Ap |struct perl_vars *|GetVars
|
||||
#endif
|
||||
Ap |int |runops_standard
|
||||
Ap |int |runops_debug
|
||||
#if defined(USE_THREADS)
|
||||
Ap |SV* |sv_lock |SV *sv
|
||||
#endif
|
||||
Afpd |void |sv_catpvf_mg |SV *sv|const char* pat|...
|
||||
Ap |void |sv_vcatpvf_mg |SV* sv|const char* pat|va_list* args
|
||||
Apd |void |sv_catpv_mg |SV *sv|const char *ptr
|
||||
@ -2127,13 +2178,15 @@ Ap |char* |sv_2pvbyte_nolen|SV* sv
|
||||
Ap |char* |sv_pv |SV *sv
|
||||
Ap |char* |sv_pvutf8 |SV *sv
|
||||
Ap |char* |sv_pvbyte |SV *sv
|
||||
Ap |void |sv_utf8_upgrade|SV *sv
|
||||
Ap |bool |sv_utf8_downgrade|SV *sv|bool fail_ok
|
||||
Ap |void |sv_utf8_encode |SV *sv
|
||||
Ap |bool |sv_utf8_decode |SV *sv
|
||||
ApMd |void |sv_utf8_upgrade|SV *sv
|
||||
ApMd |bool |sv_utf8_downgrade|SV *sv|bool fail_ok
|
||||
ApMd |void |sv_utf8_encode |SV *sv
|
||||
ApM |bool |sv_utf8_decode |SV *sv
|
||||
Ap |void |sv_force_normal|SV *sv
|
||||
Ap |void |sv_add_backref |SV *tsv|SV *sv
|
||||
Ap |void |sv_del_backref |SV *sv
|
||||
Ap |void |tmps_grow |I32 n
|
||||
Ap |SV* |sv_rvweaken |SV *sv
|
||||
Apd |SV* |sv_rvweaken |SV *sv
|
||||
p |int |magic_killbackrefs|SV *sv|MAGIC *mg
|
||||
Ap |OP* |newANONATTRSUB |I32 floor|OP *proto|OP *attrs|OP *block
|
||||
Ap |CV* |newATTRSUB |I32 floor|OP *o|OP *proto|OP *attrs|OP *block
|
||||
@ -2160,6 +2213,12 @@ Ap |PTR_TBL_t*|ptr_table_new
|
||||
Ap |void* |ptr_table_fetch|PTR_TBL_t *tbl|void *sv
|
||||
Ap |void |ptr_table_store|PTR_TBL_t *tbl|void *oldsv|void *newsv
|
||||
Ap |void |ptr_table_split|PTR_TBL_t *tbl
|
||||
Ap |void |ptr_table_clear|PTR_TBL_t *tbl
|
||||
Ap |void |ptr_table_free|PTR_TBL_t *tbl
|
||||
#endif
|
||||
#if defined(HAVE_INTERP_INTERN)
|
||||
Ap |void |sys_intern_clear
|
||||
Ap |void |sys_intern_init
|
||||
#endif
|
||||
|
||||
#if defined(PERL_OBJECT)
|
||||
@ -2174,16 +2233,12 @@ s |I32 |avhv_index |AV* av|SV* sv|U32 hash
|
||||
#endif
|
||||
|
||||
#if defined(PERL_IN_DOOP_C) || defined(PERL_DECL_PROT)
|
||||
s |I32 |do_trans_CC_simple |SV *sv
|
||||
s |I32 |do_trans_CC_count |SV *sv
|
||||
s |I32 |do_trans_CC_complex |SV *sv
|
||||
s |I32 |do_trans_UU_simple |SV *sv
|
||||
s |I32 |do_trans_UU_count |SV *sv
|
||||
s |I32 |do_trans_UU_complex |SV *sv
|
||||
s |I32 |do_trans_UC_simple |SV *sv
|
||||
s |I32 |do_trans_CU_simple |SV *sv
|
||||
s |I32 |do_trans_UC_trivial |SV *sv
|
||||
s |I32 |do_trans_CU_trivial |SV *sv
|
||||
s |I32 |do_trans_simple |SV *sv
|
||||
s |I32 |do_trans_count |SV *sv
|
||||
s |I32 |do_trans_complex |SV *sv
|
||||
s |I32 |do_trans_simple_utf8 |SV *sv
|
||||
s |I32 |do_trans_count_utf8 |SV *sv
|
||||
s |I32 |do_trans_complex_utf8 |SV *sv
|
||||
#endif
|
||||
|
||||
#if defined(PERL_IN_GV_C) || defined(PERL_DECL_PROT)
|
||||
@ -2217,6 +2272,7 @@ s |OP* |no_fh_allowed |OP *o
|
||||
s |OP* |scalarboolean |OP *o
|
||||
s |OP* |too_few_arguments|OP *o|char* name
|
||||
s |OP* |too_many_arguments|OP *o|char* name
|
||||
s |U8* |trlist_upgrade |U8** sp|U8** ep
|
||||
s |void |op_clear |OP* o
|
||||
s |void |null |OP* o
|
||||
s |PADOFFSET|pad_addlex |SV* name
|
||||
@ -2294,7 +2350,6 @@ s |I32 |dopoptolabel |char *label
|
||||
s |I32 |dopoptoloop |I32 startingblock
|
||||
s |I32 |dopoptosub |I32 startingblock
|
||||
s |I32 |dopoptosub_at |PERL_CONTEXT* cxstk|I32 startingblock
|
||||
s |void |free_closures
|
||||
s |void |save_lines |AV *array|SV *sv
|
||||
s |OP* |doeval |int gimme|OP** startop
|
||||
s |PerlIO *|doopen_pmc |const char *name|const char *mode
|
||||
@ -2322,7 +2377,7 @@ s |regnode*|reg |I32|I32 *
|
||||
s |regnode*|reganode |U8|U32
|
||||
s |regnode*|regatom |I32 *
|
||||
s |regnode*|regbranch |I32 *|I32
|
||||
s |void |reguni |UV|char *|I32*
|
||||
s |void |reguni |UV|char *|STRLEN*
|
||||
s |regnode*|regclass
|
||||
s |regnode*|regclassutf8
|
||||
s |I32 |regcurly |char *
|
||||
@ -2420,9 +2475,7 @@ s |void |del_xpvbm |XPVBM* p
|
||||
s |void |del_xrv |XRV* p
|
||||
s |void |sv_unglob |SV* sv
|
||||
s |void |not_a_number |SV *sv
|
||||
s |void |visit |SVFUNC_t f
|
||||
s |void |sv_add_backref |SV *tsv|SV *sv
|
||||
s |void |sv_del_backref |SV *sv
|
||||
s |I32 |visit |SVFUNC_t f
|
||||
# if defined(DEBUGGING)
|
||||
s |void |del_sv |SV *p
|
||||
# endif
|
||||
@ -2448,6 +2501,7 @@ s |char* |scan_trans |char *start
|
||||
s |char* |scan_word |char *s|char *dest|STRLEN destlen \
|
||||
|int allow_package|STRLEN *slp
|
||||
s |char* |skipspace |char *s
|
||||
s |char* |swallow_bom |U8 *s
|
||||
s |void |checkcomma |char *s|char *name|char *what
|
||||
s |void |force_ident |char *s|int kind
|
||||
s |void |incline |char *s
|
||||
@ -2461,6 +2515,7 @@ s |I32 |sublex_done
|
||||
s |I32 |sublex_push
|
||||
s |I32 |sublex_start
|
||||
s |char * |filter_gets |SV *sv|PerlIO *fp|STRLEN append
|
||||
s |HV * |find_in_my_stash|char *pkgname|I32 len
|
||||
s |SV* |new_constant |char *s|STRLEN len|const char *key|SV *sv \
|
||||
|SV *pv|const char *type
|
||||
s |int |ao |int toketype
|
||||
@ -2483,6 +2538,7 @@ s |SV*|isa_lookup |HV *stash|const char *name|int len|int level
|
||||
#endif
|
||||
|
||||
#if defined(PERL_IN_UTIL_C) || defined(PERL_DECL_PROT)
|
||||
s |char* |stdize_locale |char* locs
|
||||
s |SV* |mess_alloc
|
||||
# if defined(LEAKTEST)
|
||||
s |void |xstat |int
|
||||
|
@ -196,6 +196,7 @@
|
||||
#define PL_argvoutgv (PERL_GET_INTERP->Iargvoutgv)
|
||||
#define PL_basetime (PERL_GET_INTERP->Ibasetime)
|
||||
#define PL_beginav (PERL_GET_INTERP->Ibeginav)
|
||||
#define PL_beginav_save (PERL_GET_INTERP->Ibeginav_save)
|
||||
#define PL_bitcount (PERL_GET_INTERP->Ibitcount)
|
||||
#define PL_bufend (PERL_GET_INTERP->Ibufend)
|
||||
#define PL_bufptr (PERL_GET_INTERP->Ibufptr)
|
||||
@ -228,6 +229,7 @@
|
||||
#define PL_doextract (PERL_GET_INTERP->Idoextract)
|
||||
#define PL_doswitches (PERL_GET_INTERP->Idoswitches)
|
||||
#define PL_dowarn (PERL_GET_INTERP->Idowarn)
|
||||
#define PL_dummy1_bincompat (PERL_GET_INTERP->Idummy1_bincompat)
|
||||
#define PL_e_script (PERL_GET_INTERP->Ie_script)
|
||||
#define PL_egid (PERL_GET_INTERP->Iegid)
|
||||
#define PL_endav (PERL_GET_INTERP->Iendav)
|
||||
@ -246,6 +248,7 @@
|
||||
#define PL_exitlistlen (PERL_GET_INTERP->Iexitlistlen)
|
||||
#define PL_expect (PERL_GET_INTERP->Iexpect)
|
||||
#define PL_fdpid (PERL_GET_INTERP->Ifdpid)
|
||||
#define PL_fdpid_mutex (PERL_GET_INTERP->Ifdpid_mutex)
|
||||
#define PL_filemode (PERL_GET_INTERP->Ifilemode)
|
||||
#define PL_forkprocess (PERL_GET_INTERP->Iforkprocess)
|
||||
#define PL_formfeed (PERL_GET_INTERP->Iformfeed)
|
||||
@ -254,6 +257,7 @@
|
||||
#define PL_gid (PERL_GET_INTERP->Igid)
|
||||
#define PL_glob_index (PERL_GET_INTERP->Iglob_index)
|
||||
#define PL_globalstash (PERL_GET_INTERP->Iglobalstash)
|
||||
#define PL_he_arenaroot (PERL_GET_INTERP->Ihe_arenaroot)
|
||||
#define PL_he_root (PERL_GET_INTERP->Ihe_root)
|
||||
#define PL_hintgv (PERL_GET_INTERP->Ihintgv)
|
||||
#define PL_hints (PERL_GET_INTERP->Ihints)
|
||||
@ -322,9 +326,10 @@
|
||||
#define PL_nomemok (PERL_GET_INTERP->Inomemok)
|
||||
#define PL_nthreads (PERL_GET_INTERP->Inthreads)
|
||||
#define PL_nthreads_cond (PERL_GET_INTERP->Inthreads_cond)
|
||||
#define PL_nullstash (PERL_GET_INTERP->Inullstash)
|
||||
#define PL_numeric_local (PERL_GET_INTERP->Inumeric_local)
|
||||
#define PL_numeric_name (PERL_GET_INTERP->Inumeric_name)
|
||||
#define PL_numeric_radix (PERL_GET_INTERP->Inumeric_radix)
|
||||
#define PL_numeric_radix_sv (PERL_GET_INTERP->Inumeric_radix_sv)
|
||||
#define PL_numeric_standard (PERL_GET_INTERP->Inumeric_standard)
|
||||
#define PL_ofmt (PERL_GET_INTERP->Iofmt)
|
||||
#define PL_oldbufptr (PERL_GET_INTERP->Ioldbufptr)
|
||||
@ -376,6 +381,7 @@
|
||||
#define PL_subname (PERL_GET_INTERP->Isubname)
|
||||
#define PL_sv_arenaroot (PERL_GET_INTERP->Isv_arenaroot)
|
||||
#define PL_sv_count (PERL_GET_INTERP->Isv_count)
|
||||
#define PL_sv_lock_mutex (PERL_GET_INTERP->Isv_lock_mutex)
|
||||
#define PL_sv_mutex (PERL_GET_INTERP->Isv_mutex)
|
||||
#define PL_sv_no (PERL_GET_INTERP->Isv_no)
|
||||
#define PL_sv_objcount (PERL_GET_INTERP->Isv_objcount)
|
||||
@ -414,16 +420,27 @@
|
||||
#define PL_widesyscalls (PERL_GET_INTERP->Iwidesyscalls)
|
||||
#define PL_xiv_arenaroot (PERL_GET_INTERP->Ixiv_arenaroot)
|
||||
#define PL_xiv_root (PERL_GET_INTERP->Ixiv_root)
|
||||
#define PL_xnv_arenaroot (PERL_GET_INTERP->Ixnv_arenaroot)
|
||||
#define PL_xnv_root (PERL_GET_INTERP->Ixnv_root)
|
||||
#define PL_xpv_arenaroot (PERL_GET_INTERP->Ixpv_arenaroot)
|
||||
#define PL_xpv_root (PERL_GET_INTERP->Ixpv_root)
|
||||
#define PL_xpvav_arenaroot (PERL_GET_INTERP->Ixpvav_arenaroot)
|
||||
#define PL_xpvav_root (PERL_GET_INTERP->Ixpvav_root)
|
||||
#define PL_xpvbm_arenaroot (PERL_GET_INTERP->Ixpvbm_arenaroot)
|
||||
#define PL_xpvbm_root (PERL_GET_INTERP->Ixpvbm_root)
|
||||
#define PL_xpvcv_arenaroot (PERL_GET_INTERP->Ixpvcv_arenaroot)
|
||||
#define PL_xpvcv_root (PERL_GET_INTERP->Ixpvcv_root)
|
||||
#define PL_xpvhv_arenaroot (PERL_GET_INTERP->Ixpvhv_arenaroot)
|
||||
#define PL_xpvhv_root (PERL_GET_INTERP->Ixpvhv_root)
|
||||
#define PL_xpviv_arenaroot (PERL_GET_INTERP->Ixpviv_arenaroot)
|
||||
#define PL_xpviv_root (PERL_GET_INTERP->Ixpviv_root)
|
||||
#define PL_xpvlv_arenaroot (PERL_GET_INTERP->Ixpvlv_arenaroot)
|
||||
#define PL_xpvlv_root (PERL_GET_INTERP->Ixpvlv_root)
|
||||
#define PL_xpvmg_arenaroot (PERL_GET_INTERP->Ixpvmg_arenaroot)
|
||||
#define PL_xpvmg_root (PERL_GET_INTERP->Ixpvmg_root)
|
||||
#define PL_xpvnv_arenaroot (PERL_GET_INTERP->Ixpvnv_arenaroot)
|
||||
#define PL_xpvnv_root (PERL_GET_INTERP->Ixpvnv_root)
|
||||
#define PL_xrv_arenaroot (PERL_GET_INTERP->Ixrv_arenaroot)
|
||||
#define PL_xrv_root (PERL_GET_INTERP->Ixrv_root)
|
||||
#define PL_yychar (PERL_GET_INTERP->Iyychar)
|
||||
#define PL_yydebug (PERL_GET_INTERP->Iyydebug)
|
||||
@ -460,6 +477,7 @@
|
||||
#define PL_argvoutgv (vTHX->Iargvoutgv)
|
||||
#define PL_basetime (vTHX->Ibasetime)
|
||||
#define PL_beginav (vTHX->Ibeginav)
|
||||
#define PL_beginav_save (vTHX->Ibeginav_save)
|
||||
#define PL_bitcount (vTHX->Ibitcount)
|
||||
#define PL_bufend (vTHX->Ibufend)
|
||||
#define PL_bufptr (vTHX->Ibufptr)
|
||||
@ -492,6 +510,7 @@
|
||||
#define PL_doextract (vTHX->Idoextract)
|
||||
#define PL_doswitches (vTHX->Idoswitches)
|
||||
#define PL_dowarn (vTHX->Idowarn)
|
||||
#define PL_dummy1_bincompat (vTHX->Idummy1_bincompat)
|
||||
#define PL_e_script (vTHX->Ie_script)
|
||||
#define PL_egid (vTHX->Iegid)
|
||||
#define PL_endav (vTHX->Iendav)
|
||||
@ -510,6 +529,7 @@
|
||||
#define PL_exitlistlen (vTHX->Iexitlistlen)
|
||||
#define PL_expect (vTHX->Iexpect)
|
||||
#define PL_fdpid (vTHX->Ifdpid)
|
||||
#define PL_fdpid_mutex (vTHX->Ifdpid_mutex)
|
||||
#define PL_filemode (vTHX->Ifilemode)
|
||||
#define PL_forkprocess (vTHX->Iforkprocess)
|
||||
#define PL_formfeed (vTHX->Iformfeed)
|
||||
@ -518,6 +538,7 @@
|
||||
#define PL_gid (vTHX->Igid)
|
||||
#define PL_glob_index (vTHX->Iglob_index)
|
||||
#define PL_globalstash (vTHX->Iglobalstash)
|
||||
#define PL_he_arenaroot (vTHX->Ihe_arenaroot)
|
||||
#define PL_he_root (vTHX->Ihe_root)
|
||||
#define PL_hintgv (vTHX->Ihintgv)
|
||||
#define PL_hints (vTHX->Ihints)
|
||||
@ -586,9 +607,10 @@
|
||||
#define PL_nomemok (vTHX->Inomemok)
|
||||
#define PL_nthreads (vTHX->Inthreads)
|
||||
#define PL_nthreads_cond (vTHX->Inthreads_cond)
|
||||
#define PL_nullstash (vTHX->Inullstash)
|
||||
#define PL_numeric_local (vTHX->Inumeric_local)
|
||||
#define PL_numeric_name (vTHX->Inumeric_name)
|
||||
#define PL_numeric_radix (vTHX->Inumeric_radix)
|
||||
#define PL_numeric_radix_sv (vTHX->Inumeric_radix_sv)
|
||||
#define PL_numeric_standard (vTHX->Inumeric_standard)
|
||||
#define PL_ofmt (vTHX->Iofmt)
|
||||
#define PL_oldbufptr (vTHX->Ioldbufptr)
|
||||
@ -640,6 +662,7 @@
|
||||
#define PL_subname (vTHX->Isubname)
|
||||
#define PL_sv_arenaroot (vTHX->Isv_arenaroot)
|
||||
#define PL_sv_count (vTHX->Isv_count)
|
||||
#define PL_sv_lock_mutex (vTHX->Isv_lock_mutex)
|
||||
#define PL_sv_mutex (vTHX->Isv_mutex)
|
||||
#define PL_sv_no (vTHX->Isv_no)
|
||||
#define PL_sv_objcount (vTHX->Isv_objcount)
|
||||
@ -678,16 +701,27 @@
|
||||
#define PL_widesyscalls (vTHX->Iwidesyscalls)
|
||||
#define PL_xiv_arenaroot (vTHX->Ixiv_arenaroot)
|
||||
#define PL_xiv_root (vTHX->Ixiv_root)
|
||||
#define PL_xnv_arenaroot (vTHX->Ixnv_arenaroot)
|
||||
#define PL_xnv_root (vTHX->Ixnv_root)
|
||||
#define PL_xpv_arenaroot (vTHX->Ixpv_arenaroot)
|
||||
#define PL_xpv_root (vTHX->Ixpv_root)
|
||||
#define PL_xpvav_arenaroot (vTHX->Ixpvav_arenaroot)
|
||||
#define PL_xpvav_root (vTHX->Ixpvav_root)
|
||||
#define PL_xpvbm_arenaroot (vTHX->Ixpvbm_arenaroot)
|
||||
#define PL_xpvbm_root (vTHX->Ixpvbm_root)
|
||||
#define PL_xpvcv_arenaroot (vTHX->Ixpvcv_arenaroot)
|
||||
#define PL_xpvcv_root (vTHX->Ixpvcv_root)
|
||||
#define PL_xpvhv_arenaroot (vTHX->Ixpvhv_arenaroot)
|
||||
#define PL_xpvhv_root (vTHX->Ixpvhv_root)
|
||||
#define PL_xpviv_arenaroot (vTHX->Ixpviv_arenaroot)
|
||||
#define PL_xpviv_root (vTHX->Ixpviv_root)
|
||||
#define PL_xpvlv_arenaroot (vTHX->Ixpvlv_arenaroot)
|
||||
#define PL_xpvlv_root (vTHX->Ixpvlv_root)
|
||||
#define PL_xpvmg_arenaroot (vTHX->Ixpvmg_arenaroot)
|
||||
#define PL_xpvmg_root (vTHX->Ixpvmg_root)
|
||||
#define PL_xpvnv_arenaroot (vTHX->Ixpvnv_arenaroot)
|
||||
#define PL_xpvnv_root (vTHX->Ixpvnv_root)
|
||||
#define PL_xrv_arenaroot (vTHX->Ixrv_arenaroot)
|
||||
#define PL_xrv_root (vTHX->Ixrv_root)
|
||||
#define PL_yychar (vTHX->Iyychar)
|
||||
#define PL_yydebug (vTHX->Iyydebug)
|
||||
@ -861,6 +895,7 @@
|
||||
#define PL_argvoutgv (aTHXo->interp.Iargvoutgv)
|
||||
#define PL_basetime (aTHXo->interp.Ibasetime)
|
||||
#define PL_beginav (aTHXo->interp.Ibeginav)
|
||||
#define PL_beginav_save (aTHXo->interp.Ibeginav_save)
|
||||
#define PL_bitcount (aTHXo->interp.Ibitcount)
|
||||
#define PL_bufend (aTHXo->interp.Ibufend)
|
||||
#define PL_bufptr (aTHXo->interp.Ibufptr)
|
||||
@ -893,6 +928,7 @@
|
||||
#define PL_doextract (aTHXo->interp.Idoextract)
|
||||
#define PL_doswitches (aTHXo->interp.Idoswitches)
|
||||
#define PL_dowarn (aTHXo->interp.Idowarn)
|
||||
#define PL_dummy1_bincompat (aTHXo->interp.Idummy1_bincompat)
|
||||
#define PL_e_script (aTHXo->interp.Ie_script)
|
||||
#define PL_egid (aTHXo->interp.Iegid)
|
||||
#define PL_endav (aTHXo->interp.Iendav)
|
||||
@ -911,6 +947,7 @@
|
||||
#define PL_exitlistlen (aTHXo->interp.Iexitlistlen)
|
||||
#define PL_expect (aTHXo->interp.Iexpect)
|
||||
#define PL_fdpid (aTHXo->interp.Ifdpid)
|
||||
#define PL_fdpid_mutex (aTHXo->interp.Ifdpid_mutex)
|
||||
#define PL_filemode (aTHXo->interp.Ifilemode)
|
||||
#define PL_forkprocess (aTHXo->interp.Iforkprocess)
|
||||
#define PL_formfeed (aTHXo->interp.Iformfeed)
|
||||
@ -919,6 +956,7 @@
|
||||
#define PL_gid (aTHXo->interp.Igid)
|
||||
#define PL_glob_index (aTHXo->interp.Iglob_index)
|
||||
#define PL_globalstash (aTHXo->interp.Iglobalstash)
|
||||
#define PL_he_arenaroot (aTHXo->interp.Ihe_arenaroot)
|
||||
#define PL_he_root (aTHXo->interp.Ihe_root)
|
||||
#define PL_hintgv (aTHXo->interp.Ihintgv)
|
||||
#define PL_hints (aTHXo->interp.Ihints)
|
||||
@ -987,9 +1025,10 @@
|
||||
#define PL_nomemok (aTHXo->interp.Inomemok)
|
||||
#define PL_nthreads (aTHXo->interp.Inthreads)
|
||||
#define PL_nthreads_cond (aTHXo->interp.Inthreads_cond)
|
||||
#define PL_nullstash (aTHXo->interp.Inullstash)
|
||||
#define PL_numeric_local (aTHXo->interp.Inumeric_local)
|
||||
#define PL_numeric_name (aTHXo->interp.Inumeric_name)
|
||||
#define PL_numeric_radix (aTHXo->interp.Inumeric_radix)
|
||||
#define PL_numeric_radix_sv (aTHXo->interp.Inumeric_radix_sv)
|
||||
#define PL_numeric_standard (aTHXo->interp.Inumeric_standard)
|
||||
#define PL_ofmt (aTHXo->interp.Iofmt)
|
||||
#define PL_oldbufptr (aTHXo->interp.Ioldbufptr)
|
||||
@ -1041,6 +1080,7 @@
|
||||
#define PL_subname (aTHXo->interp.Isubname)
|
||||
#define PL_sv_arenaroot (aTHXo->interp.Isv_arenaroot)
|
||||
#define PL_sv_count (aTHXo->interp.Isv_count)
|
||||
#define PL_sv_lock_mutex (aTHXo->interp.Isv_lock_mutex)
|
||||
#define PL_sv_mutex (aTHXo->interp.Isv_mutex)
|
||||
#define PL_sv_no (aTHXo->interp.Isv_no)
|
||||
#define PL_sv_objcount (aTHXo->interp.Isv_objcount)
|
||||
@ -1079,16 +1119,27 @@
|
||||
#define PL_widesyscalls (aTHXo->interp.Iwidesyscalls)
|
||||
#define PL_xiv_arenaroot (aTHXo->interp.Ixiv_arenaroot)
|
||||
#define PL_xiv_root (aTHXo->interp.Ixiv_root)
|
||||
#define PL_xnv_arenaroot (aTHXo->interp.Ixnv_arenaroot)
|
||||
#define PL_xnv_root (aTHXo->interp.Ixnv_root)
|
||||
#define PL_xpv_arenaroot (aTHXo->interp.Ixpv_arenaroot)
|
||||
#define PL_xpv_root (aTHXo->interp.Ixpv_root)
|
||||
#define PL_xpvav_arenaroot (aTHXo->interp.Ixpvav_arenaroot)
|
||||
#define PL_xpvav_root (aTHXo->interp.Ixpvav_root)
|
||||
#define PL_xpvbm_arenaroot (aTHXo->interp.Ixpvbm_arenaroot)
|
||||
#define PL_xpvbm_root (aTHXo->interp.Ixpvbm_root)
|
||||
#define PL_xpvcv_arenaroot (aTHXo->interp.Ixpvcv_arenaroot)
|
||||
#define PL_xpvcv_root (aTHXo->interp.Ixpvcv_root)
|
||||
#define PL_xpvhv_arenaroot (aTHXo->interp.Ixpvhv_arenaroot)
|
||||
#define PL_xpvhv_root (aTHXo->interp.Ixpvhv_root)
|
||||
#define PL_xpviv_arenaroot (aTHXo->interp.Ixpviv_arenaroot)
|
||||
#define PL_xpviv_root (aTHXo->interp.Ixpviv_root)
|
||||
#define PL_xpvlv_arenaroot (aTHXo->interp.Ixpvlv_arenaroot)
|
||||
#define PL_xpvlv_root (aTHXo->interp.Ixpvlv_root)
|
||||
#define PL_xpvmg_arenaroot (aTHXo->interp.Ixpvmg_arenaroot)
|
||||
#define PL_xpvmg_root (aTHXo->interp.Ixpvmg_root)
|
||||
#define PL_xpvnv_arenaroot (aTHXo->interp.Ixpvnv_arenaroot)
|
||||
#define PL_xpvnv_root (aTHXo->interp.Ixpvnv_root)
|
||||
#define PL_xrv_arenaroot (aTHXo->interp.Ixrv_arenaroot)
|
||||
#define PL_xrv_root (aTHXo->interp.Ixrv_root)
|
||||
#define PL_yychar (aTHXo->interp.Iyychar)
|
||||
#define PL_yydebug (aTHXo->interp.Iyydebug)
|
||||
@ -1126,6 +1177,7 @@
|
||||
#define PL_Iargvoutgv PL_argvoutgv
|
||||
#define PL_Ibasetime PL_basetime
|
||||
#define PL_Ibeginav PL_beginav
|
||||
#define PL_Ibeginav_save PL_beginav_save
|
||||
#define PL_Ibitcount PL_bitcount
|
||||
#define PL_Ibufend PL_bufend
|
||||
#define PL_Ibufptr PL_bufptr
|
||||
@ -1158,6 +1210,7 @@
|
||||
#define PL_Idoextract PL_doextract
|
||||
#define PL_Idoswitches PL_doswitches
|
||||
#define PL_Idowarn PL_dowarn
|
||||
#define PL_Idummy1_bincompat PL_dummy1_bincompat
|
||||
#define PL_Ie_script PL_e_script
|
||||
#define PL_Iegid PL_egid
|
||||
#define PL_Iendav PL_endav
|
||||
@ -1176,6 +1229,7 @@
|
||||
#define PL_Iexitlistlen PL_exitlistlen
|
||||
#define PL_Iexpect PL_expect
|
||||
#define PL_Ifdpid PL_fdpid
|
||||
#define PL_Ifdpid_mutex PL_fdpid_mutex
|
||||
#define PL_Ifilemode PL_filemode
|
||||
#define PL_Iforkprocess PL_forkprocess
|
||||
#define PL_Iformfeed PL_formfeed
|
||||
@ -1184,6 +1238,7 @@
|
||||
#define PL_Igid PL_gid
|
||||
#define PL_Iglob_index PL_glob_index
|
||||
#define PL_Iglobalstash PL_globalstash
|
||||
#define PL_Ihe_arenaroot PL_he_arenaroot
|
||||
#define PL_Ihe_root PL_he_root
|
||||
#define PL_Ihintgv PL_hintgv
|
||||
#define PL_Ihints PL_hints
|
||||
@ -1252,9 +1307,10 @@
|
||||
#define PL_Inomemok PL_nomemok
|
||||
#define PL_Inthreads PL_nthreads
|
||||
#define PL_Inthreads_cond PL_nthreads_cond
|
||||
#define PL_Inullstash PL_nullstash
|
||||
#define PL_Inumeric_local PL_numeric_local
|
||||
#define PL_Inumeric_name PL_numeric_name
|
||||
#define PL_Inumeric_radix PL_numeric_radix
|
||||
#define PL_Inumeric_radix_sv PL_numeric_radix_sv
|
||||
#define PL_Inumeric_standard PL_numeric_standard
|
||||
#define PL_Iofmt PL_ofmt
|
||||
#define PL_Ioldbufptr PL_oldbufptr
|
||||
@ -1306,6 +1362,7 @@
|
||||
#define PL_Isubname PL_subname
|
||||
#define PL_Isv_arenaroot PL_sv_arenaroot
|
||||
#define PL_Isv_count PL_sv_count
|
||||
#define PL_Isv_lock_mutex PL_sv_lock_mutex
|
||||
#define PL_Isv_mutex PL_sv_mutex
|
||||
#define PL_Isv_no PL_sv_no
|
||||
#define PL_Isv_objcount PL_sv_objcount
|
||||
@ -1344,16 +1401,27 @@
|
||||
#define PL_Iwidesyscalls PL_widesyscalls
|
||||
#define PL_Ixiv_arenaroot PL_xiv_arenaroot
|
||||
#define PL_Ixiv_root PL_xiv_root
|
||||
#define PL_Ixnv_arenaroot PL_xnv_arenaroot
|
||||
#define PL_Ixnv_root PL_xnv_root
|
||||
#define PL_Ixpv_arenaroot PL_xpv_arenaroot
|
||||
#define PL_Ixpv_root PL_xpv_root
|
||||
#define PL_Ixpvav_arenaroot PL_xpvav_arenaroot
|
||||
#define PL_Ixpvav_root PL_xpvav_root
|
||||
#define PL_Ixpvbm_arenaroot PL_xpvbm_arenaroot
|
||||
#define PL_Ixpvbm_root PL_xpvbm_root
|
||||
#define PL_Ixpvcv_arenaroot PL_xpvcv_arenaroot
|
||||
#define PL_Ixpvcv_root PL_xpvcv_root
|
||||
#define PL_Ixpvhv_arenaroot PL_xpvhv_arenaroot
|
||||
#define PL_Ixpvhv_root PL_xpvhv_root
|
||||
#define PL_Ixpviv_arenaroot PL_xpviv_arenaroot
|
||||
#define PL_Ixpviv_root PL_xpviv_root
|
||||
#define PL_Ixpvlv_arenaroot PL_xpvlv_arenaroot
|
||||
#define PL_Ixpvlv_root PL_xpvlv_root
|
||||
#define PL_Ixpvmg_arenaroot PL_xpvmg_arenaroot
|
||||
#define PL_Ixpvmg_root PL_xpvmg_root
|
||||
#define PL_Ixpvnv_arenaroot PL_xpvnv_arenaroot
|
||||
#define PL_Ixpvnv_root PL_xpvnv_root
|
||||
#define PL_Ixrv_arenaroot PL_xrv_arenaroot
|
||||
#define PL_Ixrv_root PL_xrv_root
|
||||
#define PL_Iyychar PL_yychar
|
||||
#define PL_Iyydebug PL_yydebug
|
||||
@ -1683,6 +1751,7 @@
|
||||
#define no_modify PL_no_modify
|
||||
#define perl_destruct_level PL_perl_destruct_level
|
||||
#define perldb PL_perldb
|
||||
#define ppaddr PL_ppaddr
|
||||
#define rsfp PL_rsfp
|
||||
#define rsfp_filters PL_rsfp_filters
|
||||
#define stack_base PL_stack_base
|
||||
|
@ -9,11 +9,17 @@ package B;
|
||||
use XSLoader ();
|
||||
require Exporter;
|
||||
@ISA = qw(Exporter);
|
||||
@EXPORT_OK = qw(minus_c ppname
|
||||
|
||||
# walkoptree_slow comes from B.pm (you are there),
|
||||
# walkoptree comes from B.xs
|
||||
@EXPORT_OK = qw(minus_c ppname save_BEGINs
|
||||
class peekop cast_I32 cstring cchar hash threadsv_names
|
||||
main_root main_start main_cv svref_2object opnumber amagic_generation
|
||||
walkoptree walkoptree_slow walkoptree_exec walksymtable
|
||||
parents comppadlist sv_undef compile_stats timing_info init_av);
|
||||
main_root main_start main_cv svref_2object opnumber
|
||||
amagic_generation
|
||||
walkoptree_slow walkoptree walkoptree_exec walksymtable
|
||||
parents comppadlist sv_undef compile_stats timing_info
|
||||
begin_av init_av end_av);
|
||||
|
||||
sub OPf_KIDS ();
|
||||
use strict;
|
||||
@B::SV::ISA = 'B::OBJECT';
|
||||
@ -54,6 +60,21 @@ use strict;
|
||||
package B::OBJECT;
|
||||
}
|
||||
|
||||
sub B::GV::SAFENAME {
|
||||
my $name = (shift())->NAME;
|
||||
|
||||
# The regex below corresponds to the isCONTROLVAR macro
|
||||
# from toke.c
|
||||
|
||||
$name =~ s/^([\cA-\cZ\c\\c[\c]\c?\c_\c^])/"^".chr(64 ^ ord($1))/e;
|
||||
return $name;
|
||||
}
|
||||
|
||||
sub B::IV::int_value {
|
||||
my ($self) = @_;
|
||||
return (($self->FLAGS() & SVf_IVisUV()) ? $self->UVX : $self->IV);
|
||||
}
|
||||
|
||||
my $debug;
|
||||
my $op_count = 0;
|
||||
my @parents = ();
|
||||
@ -125,6 +146,7 @@ sub objsym {
|
||||
|
||||
sub walkoptree_exec {
|
||||
my ($op, $method, $level) = @_;
|
||||
$level ||= 0;
|
||||
my ($sym, $ppname);
|
||||
my $prefix = " " x $level;
|
||||
for (; $$op; $op = $op->next) {
|
||||
@ -184,7 +206,7 @@ sub walksymtable {
|
||||
*glob = "*main::".$prefix.$sym;
|
||||
if ($sym =~ /::$/) {
|
||||
$sym = $prefix . $sym;
|
||||
if ($sym ne "main::" && &$recurse($sym)) {
|
||||
if ($sym ne "main::" && $sym ne "<none>::" && &$recurse($sym)) {
|
||||
walksymtable(\%glob, $method, $recurse, $sym);
|
||||
}
|
||||
} else {
|
||||
@ -326,8 +348,22 @@ C<REFCNT> (corresponding to the C function C<SvREFCNT>).
|
||||
|
||||
=item IV
|
||||
|
||||
Returns the value of the IV, I<interpreted as
|
||||
a signed integer>. This will be misleading
|
||||
if C<FLAGS & SVf_IVisUV>. Perhaps you want the
|
||||
C<int_value> method instead?
|
||||
|
||||
=item IVX
|
||||
|
||||
=item UVX
|
||||
|
||||
=item int_value
|
||||
|
||||
This method returns the value of the IV as an integer.
|
||||
It differs from C<IV> in that it returns the correct
|
||||
value regardless of whether it's stored signed or
|
||||
unsigned.
|
||||
|
||||
=item needs64bits
|
||||
|
||||
=item packiv
|
||||
@ -358,6 +394,22 @@ C<REFCNT> (corresponding to the C function C<SvREFCNT>).
|
||||
|
||||
=item PV
|
||||
|
||||
This method is the one you usually want. It constructs a
|
||||
string using the length and offset information in the struct:
|
||||
for ordinary scalars it will return the string that you'd see
|
||||
from Perl, even if it contains null characters.
|
||||
|
||||
=item PVX
|
||||
|
||||
This method is less often useful. It assumes that the string
|
||||
stored in the struct is null-terminated, and disregards the
|
||||
length information.
|
||||
|
||||
It is the appropriate method to use if you need to get the name
|
||||
of a lexical variable from a padname array. Lexical variable names
|
||||
are always stored with a null terminator, and the length field
|
||||
(SvCUR) is overloaded for other purposes and can't be relied on here.
|
||||
|
||||
=back
|
||||
|
||||
=head2 B::PVMG METHODS
|
||||
@ -426,6 +478,21 @@ This method returns TRUE if the GP field of the GV is NULL.
|
||||
|
||||
=item NAME
|
||||
|
||||
=item SAFENAME
|
||||
|
||||
This method returns the name of the glob, but if the first
|
||||
character of the name is a control character, then it converts
|
||||
it to ^X first, so that *^G would return "^G" rather than "\cG".
|
||||
|
||||
It's useful if you want to print out the name of a variable.
|
||||
If you restrict yourself to globs which exist at compile-time
|
||||
then the result ought to be unambiguous, because code like
|
||||
C<${"^G"} = 1> is compiled as two ops - a constant string and
|
||||
a dereference (rv2gv) - so that the glob is created at runtime.
|
||||
|
||||
If you're working with globs at runtime, and need to disambiguate
|
||||
*^G from *{"^G"}, then you should use the raw NAME method.
|
||||
|
||||
=item STASH
|
||||
|
||||
=item SV
|
||||
|
@ -81,7 +81,7 @@ static char *opclassnames[] = {
|
||||
|
||||
static int walkoptree_debug = 0; /* Flag for walkoptree debug hook */
|
||||
|
||||
static SV *specialsv_list[4];
|
||||
static SV *specialsv_list[6];
|
||||
|
||||
static opclass
|
||||
cc_opclass(pTHX_ OP *o)
|
||||
@ -386,11 +386,15 @@ BOOT:
|
||||
specialsv_list[1] = &PL_sv_undef;
|
||||
specialsv_list[2] = &PL_sv_yes;
|
||||
specialsv_list[3] = &PL_sv_no;
|
||||
specialsv_list[4] = pWARN_ALL;
|
||||
specialsv_list[5] = pWARN_NONE;
|
||||
#include "defsubs.h"
|
||||
}
|
||||
|
||||
#define B_main_cv() PL_main_cv
|
||||
#define B_init_av() PL_initav
|
||||
#define B_begin_av() PL_beginav_save
|
||||
#define B_end_av() PL_endav
|
||||
#define B_main_root() PL_main_root
|
||||
#define B_main_start() PL_main_start
|
||||
#define B_amagic_generation() PL_amagic_generation
|
||||
@ -402,6 +406,12 @@ BOOT:
|
||||
B::AV
|
||||
B_init_av()
|
||||
|
||||
B::AV
|
||||
B_begin_av()
|
||||
|
||||
B::AV
|
||||
B_end_av()
|
||||
|
||||
B::CV
|
||||
B_main_cv()
|
||||
|
||||
@ -515,6 +525,11 @@ minus_c()
|
||||
CODE:
|
||||
PL_minus_c = TRUE;
|
||||
|
||||
void
|
||||
save_BEGINs()
|
||||
CODE:
|
||||
PL_minus_c |= 0x10;
|
||||
|
||||
SV *
|
||||
cstring(sv)
|
||||
SV * sv
|
||||
@ -567,11 +582,12 @@ char *
|
||||
OP_name(o)
|
||||
B::OP o
|
||||
CODE:
|
||||
ST(0) = sv_newmortal();
|
||||
sv_setpv(ST(0), PL_op_name[o->op_type]);
|
||||
RETVAL = PL_op_name[o->op_type];
|
||||
OUTPUT:
|
||||
RETVAL
|
||||
|
||||
|
||||
char *
|
||||
void
|
||||
OP_ppaddr(o)
|
||||
B::OP o
|
||||
PREINIT:
|
||||
@ -633,13 +649,20 @@ B::OP
|
||||
LOGOP_other(o)
|
||||
B::LOGOP o
|
||||
|
||||
#define LISTOP_children(o) o->op_children
|
||||
|
||||
MODULE = B PACKAGE = B::LISTOP PREFIX = LISTOP_
|
||||
|
||||
U32
|
||||
LISTOP_children(o)
|
||||
B::LISTOP o
|
||||
OP * kid = NO_INIT
|
||||
int i = NO_INIT
|
||||
CODE:
|
||||
i = 0;
|
||||
for (kid = o->op_first; kid; kid = kid->op_sibling)
|
||||
i++;
|
||||
RETVAL = i;
|
||||
OUTPUT:
|
||||
RETVAL
|
||||
|
||||
#define PMOP_pmreplroot(o) o->op_pmreplroot
|
||||
#define PMOP_pmreplstart(o) o->op_pmreplstart
|
||||
@ -693,8 +716,8 @@ PMOP_precomp(o)
|
||||
if (rx)
|
||||
sv_setpvn(ST(0), rx->precomp, rx->prelen);
|
||||
|
||||
#define SVOP_sv(o) cSVOPo->op_sv
|
||||
#define SVOP_gv(o) ((GV*)cSVOPo->op_sv)
|
||||
#define SVOP_sv(o) cSVOPo->op_sv
|
||||
#define SVOP_gv(o) ((GV*)cSVOPo->op_sv)
|
||||
|
||||
MODULE = B PACKAGE = B::SVOP PREFIX = SVOP_
|
||||
|
||||
@ -862,11 +885,11 @@ packiv(sv)
|
||||
|
||||
MODULE = B PACKAGE = B::NV PREFIX = Sv
|
||||
|
||||
double
|
||||
NV
|
||||
SvNV(sv)
|
||||
B::NV sv
|
||||
|
||||
double
|
||||
NV
|
||||
SvNVX(sv)
|
||||
B::NV sv
|
||||
|
||||
@ -878,6 +901,10 @@ SvRV(sv)
|
||||
|
||||
MODULE = B PACKAGE = B::PV PREFIX = Sv
|
||||
|
||||
char*
|
||||
SvPVX(sv)
|
||||
B::PV sv
|
||||
|
||||
void
|
||||
SvPV(sv)
|
||||
B::PV sv
|
||||
@ -1210,7 +1237,7 @@ CvXSUBANY(cv)
|
||||
|
||||
MODULE = B PACKAGE = B::CV
|
||||
|
||||
U8
|
||||
U16
|
||||
CvFLAGS(cv)
|
||||
B::CV cv
|
||||
|
||||
@ -1251,7 +1278,7 @@ HvARRAY(hv)
|
||||
I32 len;
|
||||
(void)hv_iterinit(hv);
|
||||
EXTEND(sp, HvKEYS(hv) * 2);
|
||||
while (sv = hv_iternextsv(hv, &key, &len)) {
|
||||
while ((sv = hv_iternextsv(hv, &key, &len))) {
|
||||
PUSHs(newSVpvn(key, len));
|
||||
PUSHs(make_sv_object(aTHX_ sv_newmortal(), sv));
|
||||
}
|
||||
|
@ -15,7 +15,7 @@ use Exporter;
|
||||
our(%insn_data, @insn_name, @optype, @specialsv_name);
|
||||
|
||||
@optype = qw(OP UNOP BINOP LOGOP LISTOP PMOP SVOP PADOP PVOP LOOP COP);
|
||||
@specialsv_name = qw(Nullsv &PL_sv_undef &PL_sv_yes &PL_sv_no);
|
||||
@specialsv_name = qw(Nullsv &PL_sv_undef &PL_sv_yes &PL_sv_no pWARN_ALL pWARN_NONE);
|
||||
|
||||
# XXX insn_data is initialised this way because with a large
|
||||
# %insn_data = (foo => [...], bar => [...], ...) initialiser
|
||||
@ -27,93 +27,93 @@ $insn_data{ldsv} = [1, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{ldop} = [2, \&PUT_opindex, "GET_opindex"];
|
||||
$insn_data{stsv} = [3, \&PUT_U32, "GET_U32"];
|
||||
$insn_data{stop} = [4, \&PUT_U32, "GET_U32"];
|
||||
$insn_data{ldspecsv} = [5, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{newsv} = [6, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{newop} = [7, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{newopn} = [8, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{newpv} = [9, \&PUT_PV, "GET_PV"];
|
||||
$insn_data{pv_cur} = [11, \&PUT_U32, "GET_U32"];
|
||||
$insn_data{pv_free} = [12, \&PUT_none, "GET_none"];
|
||||
$insn_data{sv_upgrade} = [13, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{sv_refcnt} = [14, \&PUT_U32, "GET_U32"];
|
||||
$insn_data{sv_refcnt_add} = [15, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{sv_flags} = [16, \&PUT_U32, "GET_U32"];
|
||||
$insn_data{xrv} = [17, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{xpv} = [18, \&PUT_none, "GET_none"];
|
||||
$insn_data{xiv32} = [19, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{xiv64} = [20, \&PUT_IV64, "GET_IV64"];
|
||||
$insn_data{xnv} = [21, \&PUT_NV, "GET_NV"];
|
||||
$insn_data{xlv_targoff} = [22, \&PUT_U32, "GET_U32"];
|
||||
$insn_data{xlv_targlen} = [23, \&PUT_U32, "GET_U32"];
|
||||
$insn_data{xlv_targ} = [24, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{xlv_type} = [25, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{xbm_useful} = [26, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{xbm_previous} = [27, \&PUT_U16, "GET_U16"];
|
||||
$insn_data{xbm_rare} = [28, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{xfm_lines} = [29, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{xio_lines} = [30, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{xio_page} = [31, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{xio_page_len} = [32, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{xio_lines_left} = [33, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{xio_top_name} = [34, \&PUT_pvcontents, "GET_pvcontents"];
|
||||
$insn_data{xio_top_gv} = [36, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{xio_fmt_name} = [37, \&PUT_pvcontents, "GET_pvcontents"];
|
||||
$insn_data{xio_fmt_gv} = [38, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{xio_bottom_name} = [39, \&PUT_pvcontents, "GET_pvcontents"];
|
||||
$insn_data{xio_bottom_gv} = [40, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{xio_subprocess} = [41, \&PUT_U16, "GET_U16"];
|
||||
$insn_data{xio_type} = [42, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{xio_flags} = [43, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{xcv_stash} = [44, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{xcv_start} = [45, \&PUT_opindex, "GET_opindex"];
|
||||
$insn_data{xcv_root} = [46, \&PUT_opindex, "GET_opindex"];
|
||||
$insn_data{xcv_gv} = [47, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{xcv_file} = [48, \&PUT_pvcontents, "GET_pvcontents"];
|
||||
$insn_data{xcv_depth} = [49, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{xcv_padlist} = [50, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{xcv_outside} = [51, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{xcv_flags} = [52, \&PUT_U16, "GET_U16"];
|
||||
$insn_data{av_extend} = [53, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{av_push} = [54, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{xav_fill} = [55, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{xav_max} = [56, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{xav_flags} = [57, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{xhv_riter} = [58, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{xhv_name} = [59, \&PUT_pvcontents, "GET_pvcontents"];
|
||||
$insn_data{hv_store} = [60, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{sv_magic} = [61, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{mg_obj} = [62, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{mg_private} = [63, \&PUT_U16, "GET_U16"];
|
||||
$insn_data{mg_flags} = [64, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{mg_pv} = [65, \&PUT_pvcontents, "GET_pvcontents"];
|
||||
$insn_data{xmg_stash} = [66, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{gv_fetchpv} = [67, \&PUT_strconst, "GET_strconst"];
|
||||
$insn_data{gv_stashpv} = [68, \&PUT_strconst, "GET_strconst"];
|
||||
$insn_data{gp_sv} = [69, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{gp_refcnt} = [70, \&PUT_U32, "GET_U32"];
|
||||
$insn_data{gp_refcnt_add} = [71, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{gp_av} = [72, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{gp_hv} = [73, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{gp_cv} = [74, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{gp_file} = [75, \&PUT_pvcontents, "GET_pvcontents"];
|
||||
$insn_data{gp_io} = [76, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{gp_form} = [77, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{gp_cvgen} = [78, \&PUT_U32, "GET_U32"];
|
||||
$insn_data{gp_line} = [79, \&PUT_U16, "GET_U16"];
|
||||
$insn_data{gp_share} = [80, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{xgv_flags} = [81, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{op_next} = [82, \&PUT_opindex, "GET_opindex"];
|
||||
$insn_data{op_sibling} = [83, \&PUT_opindex, "GET_opindex"];
|
||||
$insn_data{op_ppaddr} = [84, \&PUT_strconst, "GET_strconst"];
|
||||
$insn_data{op_targ} = [85, \&PUT_U32, "GET_U32"];
|
||||
$insn_data{op_type} = [86, \&PUT_U16, "GET_U16"];
|
||||
$insn_data{op_seq} = [87, \&PUT_U16, "GET_U16"];
|
||||
$insn_data{op_flags} = [88, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{op_private} = [89, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{op_first} = [90, \&PUT_opindex, "GET_opindex"];
|
||||
$insn_data{op_last} = [91, \&PUT_opindex, "GET_opindex"];
|
||||
$insn_data{op_other} = [92, \&PUT_opindex, "GET_opindex"];
|
||||
$insn_data{op_children} = [93, \&PUT_U32, "GET_U32"];
|
||||
$insn_data{stpv} = [5, \&PUT_U32, "GET_U32"];
|
||||
$insn_data{ldspecsv} = [6, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{newsv} = [7, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{newop} = [8, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{newopn} = [9, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{newpv} = [11, \&PUT_PV, "GET_PV"];
|
||||
$insn_data{pv_cur} = [12, \&PUT_U32, "GET_U32"];
|
||||
$insn_data{pv_free} = [13, \&PUT_none, "GET_none"];
|
||||
$insn_data{sv_upgrade} = [14, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{sv_refcnt} = [15, \&PUT_U32, "GET_U32"];
|
||||
$insn_data{sv_refcnt_add} = [16, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{sv_flags} = [17, \&PUT_U32, "GET_U32"];
|
||||
$insn_data{xrv} = [18, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{xpv} = [19, \&PUT_none, "GET_none"];
|
||||
$insn_data{xiv32} = [20, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{xiv64} = [21, \&PUT_IV64, "GET_IV64"];
|
||||
$insn_data{xnv} = [22, \&PUT_NV, "GET_NV"];
|
||||
$insn_data{xlv_targoff} = [23, \&PUT_U32, "GET_U32"];
|
||||
$insn_data{xlv_targlen} = [24, \&PUT_U32, "GET_U32"];
|
||||
$insn_data{xlv_targ} = [25, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{xlv_type} = [26, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{xbm_useful} = [27, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{xbm_previous} = [28, \&PUT_U16, "GET_U16"];
|
||||
$insn_data{xbm_rare} = [29, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{xfm_lines} = [30, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{xio_lines} = [31, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{xio_page} = [32, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{xio_page_len} = [33, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{xio_lines_left} = [34, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{xio_top_name} = [36, \&PUT_pvcontents, "GET_pvcontents"];
|
||||
$insn_data{xio_top_gv} = [37, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{xio_fmt_name} = [38, \&PUT_pvcontents, "GET_pvcontents"];
|
||||
$insn_data{xio_fmt_gv} = [39, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{xio_bottom_name} = [40, \&PUT_pvcontents, "GET_pvcontents"];
|
||||
$insn_data{xio_bottom_gv} = [41, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{xio_subprocess} = [42, \&PUT_U16, "GET_U16"];
|
||||
$insn_data{xio_type} = [43, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{xio_flags} = [44, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{xcv_stash} = [45, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{xcv_start} = [46, \&PUT_opindex, "GET_opindex"];
|
||||
$insn_data{xcv_root} = [47, \&PUT_opindex, "GET_opindex"];
|
||||
$insn_data{xcv_gv} = [48, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{xcv_file} = [49, \&PUT_pvindex, "GET_pvindex"];
|
||||
$insn_data{xcv_depth} = [50, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{xcv_padlist} = [51, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{xcv_outside} = [52, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{xcv_flags} = [53, \&PUT_U16, "GET_U16"];
|
||||
$insn_data{av_extend} = [54, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{av_push} = [55, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{xav_fill} = [56, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{xav_max} = [57, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{xav_flags} = [58, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{xhv_riter} = [59, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{xhv_name} = [60, \&PUT_pvcontents, "GET_pvcontents"];
|
||||
$insn_data{hv_store} = [61, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{sv_magic} = [62, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{mg_obj} = [63, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{mg_private} = [64, \&PUT_U16, "GET_U16"];
|
||||
$insn_data{mg_flags} = [65, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{mg_pv} = [66, \&PUT_pvcontents, "GET_pvcontents"];
|
||||
$insn_data{xmg_stash} = [67, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{gv_fetchpv} = [68, \&PUT_strconst, "GET_strconst"];
|
||||
$insn_data{gv_stashpv} = [69, \&PUT_strconst, "GET_strconst"];
|
||||
$insn_data{gp_sv} = [70, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{gp_refcnt} = [71, \&PUT_U32, "GET_U32"];
|
||||
$insn_data{gp_refcnt_add} = [72, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{gp_av} = [73, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{gp_hv} = [74, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{gp_cv} = [75, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{gp_file} = [76, \&PUT_pvindex, "GET_pvindex"];
|
||||
$insn_data{gp_io} = [77, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{gp_form} = [78, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{gp_cvgen} = [79, \&PUT_U32, "GET_U32"];
|
||||
$insn_data{gp_line} = [80, \&PUT_U16, "GET_U16"];
|
||||
$insn_data{gp_share} = [81, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{xgv_flags} = [82, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{op_next} = [83, \&PUT_opindex, "GET_opindex"];
|
||||
$insn_data{op_sibling} = [84, \&PUT_opindex, "GET_opindex"];
|
||||
$insn_data{op_ppaddr} = [85, \&PUT_strconst, "GET_strconst"];
|
||||
$insn_data{op_targ} = [86, \&PUT_U32, "GET_U32"];
|
||||
$insn_data{op_type} = [87, \&PUT_U16, "GET_U16"];
|
||||
$insn_data{op_seq} = [88, \&PUT_U16, "GET_U16"];
|
||||
$insn_data{op_flags} = [89, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{op_private} = [90, \&PUT_U8, "GET_U8"];
|
||||
$insn_data{op_first} = [91, \&PUT_opindex, "GET_opindex"];
|
||||
$insn_data{op_last} = [92, \&PUT_opindex, "GET_opindex"];
|
||||
$insn_data{op_other} = [93, \&PUT_opindex, "GET_opindex"];
|
||||
$insn_data{op_pmreplroot} = [94, \&PUT_opindex, "GET_opindex"];
|
||||
$insn_data{op_pmreplrootgv} = [95, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{op_pmreplstart} = [96, \&PUT_opindex, "GET_opindex"];
|
||||
@ -128,9 +128,9 @@ $insn_data{op_pv_tr} = [104, \&PUT_op_tr_array, "GET_op_tr_array"];
|
||||
$insn_data{op_redoop} = [105, \&PUT_opindex, "GET_opindex"];
|
||||
$insn_data{op_nextop} = [106, \&PUT_opindex, "GET_opindex"];
|
||||
$insn_data{op_lastop} = [107, \&PUT_opindex, "GET_opindex"];
|
||||
$insn_data{cop_label} = [108, \&PUT_pvcontents, "GET_pvcontents"];
|
||||
$insn_data{cop_stashpv} = [109, \&PUT_pvcontents, "GET_pvcontents"];
|
||||
$insn_data{cop_file} = [110, \&PUT_pvcontents, "GET_pvcontents"];
|
||||
$insn_data{cop_label} = [108, \&PUT_pvindex, "GET_pvindex"];
|
||||
$insn_data{cop_stashpv} = [109, \&PUT_pvindex, "GET_pvindex"];
|
||||
$insn_data{cop_file} = [110, \&PUT_pvindex, "GET_pvindex"];
|
||||
$insn_data{cop_seq} = [111, \&PUT_U32, "GET_U32"];
|
||||
$insn_data{cop_arybase} = [112, \&PUT_I32, "GET_I32"];
|
||||
$insn_data{cop_line} = [113, \&PUT_U16, "GET_U16"];
|
||||
@ -138,6 +138,9 @@ $insn_data{cop_warnings} = [114, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{main_start} = [115, \&PUT_opindex, "GET_opindex"];
|
||||
$insn_data{main_root} = [116, \&PUT_opindex, "GET_opindex"];
|
||||
$insn_data{curpad} = [117, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{push_begin} = [118, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{push_init} = [119, \&PUT_svindex, "GET_svindex"];
|
||||
$insn_data{push_end} = [120, \&PUT_svindex, "GET_svindex"];
|
||||
|
||||
my ($insn_name, $insn_data);
|
||||
while (($insn_name, $insn_data) = each %insn_data) {
|
||||
|
@ -4,14 +4,17 @@
|
||||
#
|
||||
# You may distribute under the terms of either the GNU General Public
|
||||
# License or the Artistic License, as specified in the README file.
|
||||
|
||||
package B::Assembler;
|
||||
use Exporter;
|
||||
use B qw(ppname);
|
||||
use B::Asmdata qw(%insn_data @insn_name);
|
||||
use Config qw(%Config);
|
||||
require ByteLoader; # we just need its $VERSIOM
|
||||
|
||||
@ISA = qw(Exporter);
|
||||
@EXPORT_OK = qw(assemble_fh assemble_insn strip_comments
|
||||
parse_statement uncstring);
|
||||
@EXPORT_OK = qw(assemble_fh newasm endasm assemble);
|
||||
$VERSION = 0.02;
|
||||
|
||||
use strict;
|
||||
my %opnumber;
|
||||
@ -20,7 +23,7 @@ for ($i = 0; defined($opname = ppname($i)); $i++) {
|
||||
$opnumber{$opname} = $i;
|
||||
}
|
||||
|
||||
my ($linenum, $errors);
|
||||
my($linenum, $errors, $out); # global state, set up by newasm
|
||||
|
||||
sub error {
|
||||
my $str = shift;
|
||||
@ -49,13 +52,15 @@ sub B::Asmdata::PUT_U8 {
|
||||
return $c;
|
||||
}
|
||||
|
||||
sub B::Asmdata::PUT_U16 { pack("n", $_[0]) }
|
||||
sub B::Asmdata::PUT_U32 { pack("N", $_[0]) }
|
||||
sub B::Asmdata::PUT_I32 { pack("N", $_[0]) }
|
||||
sub B::Asmdata::PUT_NV { sprintf("%lf\0", $_[0]) }
|
||||
sub B::Asmdata::PUT_objindex { pack("N", $_[0]) } # could allow names here
|
||||
sub B::Asmdata::PUT_U16 { pack("S", $_[0]) }
|
||||
sub B::Asmdata::PUT_U32 { pack("L", $_[0]) }
|
||||
sub B::Asmdata::PUT_I32 { pack("L", $_[0]) }
|
||||
sub B::Asmdata::PUT_NV { sprintf("%s\0", $_[0]) } # "%lf" looses precision and pack('d',...)
|
||||
# may not even be portable between compilers
|
||||
sub B::Asmdata::PUT_objindex { pack("L", $_[0]) } # could allow names here
|
||||
sub B::Asmdata::PUT_svindex { &B::Asmdata::PUT_objindex }
|
||||
sub B::Asmdata::PUT_opindex { &B::Asmdata::PUT_objindex }
|
||||
sub B::Asmdata::PUT_pvindex { &B::Asmdata::PUT_objindex }
|
||||
|
||||
sub B::Asmdata::PUT_strconst {
|
||||
my $arg = shift;
|
||||
@ -79,7 +84,7 @@ sub B::Asmdata::PUT_PV {
|
||||
my $arg = shift;
|
||||
$arg = uncstring($arg);
|
||||
error "bad string argument: $arg" unless defined($arg);
|
||||
return pack("N", length($arg)) . $arg;
|
||||
return pack("L", length($arg)) . $arg;
|
||||
}
|
||||
sub B::Asmdata::PUT_comment_t {
|
||||
my $arg = shift;
|
||||
@ -90,7 +95,7 @@ sub B::Asmdata::PUT_comment_t {
|
||||
}
|
||||
return $arg . "\n";
|
||||
}
|
||||
sub B::Asmdata::PUT_double { sprintf("%s\0", $_[0]) }
|
||||
sub B::Asmdata::PUT_double { sprintf("%s\0", $_[0]) } # see PUT_NV above
|
||||
sub B::Asmdata::PUT_none {
|
||||
my $arg = shift;
|
||||
error "extraneous argument: $arg" if defined $arg;
|
||||
@ -103,12 +108,12 @@ sub B::Asmdata::PUT_op_tr_array {
|
||||
error "wrong number of arguments to op_tr_array";
|
||||
@ary = (0) x 256;
|
||||
}
|
||||
return pack("n256", @ary);
|
||||
return pack("S256", @ary);
|
||||
}
|
||||
# XXX Check this works
|
||||
sub B::Asmdata::PUT_IV64 {
|
||||
my $arg = shift;
|
||||
return pack("NN", $arg >> 32, $arg & 0xffffffff);
|
||||
return pack("LL", $arg >> 32, $arg & 0xffffffff);
|
||||
}
|
||||
|
||||
my %unesc = (n => "\n", r => "\r", t => "\t", a => "\a",
|
||||
@ -138,6 +143,24 @@ sub strip_comments {
|
||||
return $stmt;
|
||||
}
|
||||
|
||||
# create the ByteCode header: magic, archname, ByteLoader $VERSION, ivsize,
|
||||
# ptrsize, byteorder
|
||||
# nvtype is irrelevant (floats are stored as strings)
|
||||
# byteorder is strconst not U32 because of varying size issues
|
||||
|
||||
sub gen_header {
|
||||
my $header = "";
|
||||
|
||||
$header .= B::Asmdata::PUT_U32(0x43424c50); # 'PLBC'
|
||||
$header .= B::Asmdata::PUT_strconst('"' . $Config{archname}. '"');
|
||||
$header .= B::Asmdata::PUT_strconst(qq["$ByteLoader::VERSION"]);
|
||||
$header .= B::Asmdata::PUT_U32($Config{ivsize});
|
||||
$header .= B::Asmdata::PUT_U32($Config{ptrsize});
|
||||
$header .= B::Asmdata::PUT_strconst(sprintf(qq["0x%s"], $Config{byteorder}));
|
||||
|
||||
$header;
|
||||
}
|
||||
|
||||
sub parse_statement {
|
||||
my $stmt = shift;
|
||||
my ($insn, $arg) = $stmt =~ m{
|
||||
@ -183,27 +206,52 @@ sub assemble_insn {
|
||||
|
||||
sub assemble_fh {
|
||||
my ($fh, $out) = @_;
|
||||
my ($line, $insn, $arg);
|
||||
$linenum = 0;
|
||||
$errors = 0;
|
||||
my $line;
|
||||
my $asm = newasm($out);
|
||||
while ($line = <$fh>) {
|
||||
$linenum++;
|
||||
chomp $line;
|
||||
if ($debug) {
|
||||
my $quotedline = $line;
|
||||
$quotedline =~ s/\\/\\\\/g;
|
||||
$quotedline =~ s/"/\\"/g;
|
||||
&$out(assemble_insn("comment", qq("$quotedline")));
|
||||
}
|
||||
$line = strip_comments($line) or next;
|
||||
($insn, $arg) = parse_statement($line);
|
||||
&$out(assemble_insn($insn, $arg));
|
||||
if ($debug) {
|
||||
&$out(assemble_insn("nop", undef));
|
||||
}
|
||||
assemble($line);
|
||||
}
|
||||
endasm();
|
||||
}
|
||||
|
||||
sub newasm {
|
||||
my($outsub) = @_;
|
||||
|
||||
die "Invalid printing routine for B::Assembler\n" unless ref $outsub eq 'CODE';
|
||||
die <<EOD if ref $out;
|
||||
Can't have multiple byteassembly sessions at once!
|
||||
(perhaps you forgot an endasm()?)
|
||||
EOD
|
||||
|
||||
$linenum = $errors = 0;
|
||||
$out = $outsub;
|
||||
|
||||
$out->(gen_header());
|
||||
}
|
||||
|
||||
sub endasm {
|
||||
if ($errors) {
|
||||
die "Assembly failed with $errors error(s)\n";
|
||||
die "There were $errors assembly errors\n";
|
||||
}
|
||||
$linenum = $errors = $out = 0;
|
||||
}
|
||||
|
||||
sub assemble {
|
||||
my($line) = @_;
|
||||
my ($insn, $arg);
|
||||
$linenum++;
|
||||
chomp $line;
|
||||
if ($debug) {
|
||||
my $quotedline = $line;
|
||||
$quotedline =~ s/\\/\\\\/g;
|
||||
$quotedline =~ s/"/\\"/g;
|
||||
$out->(assemble_insn("comment", qq("$quotedline")));
|
||||
}
|
||||
$line = strip_comments($line) or next;
|
||||
($insn, $arg) = parse_statement($line);
|
||||
$out->(assemble_insn($insn, $arg));
|
||||
if ($debug) {
|
||||
$out->(assemble_insn("nop", undef));
|
||||
}
|
||||
}
|
||||
|
||||
@ -217,14 +265,21 @@ B::Assembler - Assemble Perl bytecode
|
||||
|
||||
=head1 SYNOPSIS
|
||||
|
||||
use Assembler;
|
||||
use B::Assembler qw(newasm endasm assemble);
|
||||
newasm(\&printsub); # sets up for assembly
|
||||
assemble($buf); # assembles one line
|
||||
endasm(); # closes down
|
||||
|
||||
use B::Assembler qw(assemble_fh);
|
||||
assemble_fh($fh, \&printsub); # assemble everything in $fh
|
||||
|
||||
=head1 DESCRIPTION
|
||||
|
||||
See F<ext/B/B/Assembler.pm>.
|
||||
|
||||
=head1 AUTHOR
|
||||
=head1 AUTHORS
|
||||
|
||||
Malcolm Beattie, C<mbeattie@sable.ox.ac.uk>
|
||||
Per-statement interface by Benjamin Stuhl, C<sho_pi@hotmail.com>
|
||||
|
||||
=cut
|
||||
|
@ -6,16 +6,18 @@
|
||||
# License or the Artistic License, as specified in the README file.
|
||||
#
|
||||
package B::Bytecode;
|
||||
|
||||
use strict;
|
||||
use Carp;
|
||||
use IO::File;
|
||||
|
||||
use B qw(minus_c main_cv main_root main_start comppadlist
|
||||
use B qw(main_cv main_root main_start comppadlist
|
||||
class peekop walkoptree svref_2object cstring walksymtable
|
||||
SVf_POK SVp_POK SVf_IOK SVp_IOK
|
||||
init_av begin_av end_av
|
||||
SVf_POK SVp_POK SVf_IOK SVp_IOK SVf_NOK SVp_NOK
|
||||
SVf_READONLY GVf_IMPORTED_AV GVf_IMPORTED_CV GVf_IMPORTED_HV
|
||||
GVf_IMPORTED_SV SVTYPEMASK
|
||||
);
|
||||
use B::Asmdata qw(@optype @specialsv_name);
|
||||
use B::Assembler qw(assemble_fh);
|
||||
use B::Assembler qw(newasm endasm assemble);
|
||||
|
||||
my %optype_enum;
|
||||
my $i;
|
||||
@ -31,41 +33,76 @@ sub POK () { SVf_POK|SVp_POK }
|
||||
# XXX Shouldn't be hardwired
|
||||
sub IOK () { SVf_IOK|SVp_IOK }
|
||||
|
||||
my ($verbose, $module_only, $no_assemble, $debug_bc, $debug_cv);
|
||||
my $assembler_pid;
|
||||
# Following is SVf_NOK|SVp_NOK
|
||||
# XXX Shouldn't be hardwired
|
||||
sub NOK () { SVf_NOK|SVp_NOK }
|
||||
|
||||
# nonexistant flags (see B::GV::bytecode for usage)
|
||||
sub GVf_IMPORTED_IO () { 0; }
|
||||
sub GVf_IMPORTED_FORM () { 0; }
|
||||
|
||||
my ($verbose, $no_assemble, $debug_bc, $debug_cv);
|
||||
my @packages; # list of packages to compile
|
||||
|
||||
sub asm (@) { # print replacement that knows about assembling
|
||||
if ($no_assemble) {
|
||||
print @_;
|
||||
} else {
|
||||
my $buf = join '', @_;
|
||||
assemble($_) for (split /\n/, $buf);
|
||||
}
|
||||
}
|
||||
|
||||
sub asmf (@) { # printf replacement that knows about assembling
|
||||
if ($no_assemble) {
|
||||
printf shift(), @_;
|
||||
} else {
|
||||
my $format = shift;
|
||||
my $buf = sprintf $format, @_;
|
||||
assemble($_) for (split /\n/, $buf);
|
||||
}
|
||||
}
|
||||
|
||||
# Optimisation options. On the command line, use hyphens instead of
|
||||
# underscores for compatibility with gcc-style options. We use
|
||||
# underscores here because they are OK in (strict) barewords.
|
||||
my ($strip_syntree, $compress_nullops, $omit_seq, $bypass_nullops);
|
||||
my %optimise = (strip_syntax_tree => \$strip_syntree,
|
||||
compress_nullops => \$compress_nullops,
|
||||
my ($compress_nullops, $omit_seq, $bypass_nullops);
|
||||
my %optimise = (compress_nullops => \$compress_nullops,
|
||||
omit_sequence_numbers => \$omit_seq,
|
||||
bypass_nullops => \$bypass_nullops);
|
||||
|
||||
my $strip_syntree; # this is left here in case stripping the
|
||||
# syntree ever becomes safe again
|
||||
# -- BKS, June 2000
|
||||
|
||||
my $nextix = 0;
|
||||
my %symtable; # maps object addresses to object indices.
|
||||
# Filled in at allocation (newsv/newop) time.
|
||||
|
||||
my %saved; # maps object addresses (for SVish classes) to "saved yet?"
|
||||
# flag. Set at FOO::bytecode time usually by SV::bytecode.
|
||||
# Manipulated via saved(), mark_saved(), unmark_saved().
|
||||
|
||||
my %strtable; # maps shared strings to object indices
|
||||
# Filled in at allocation (pvix) time
|
||||
|
||||
my $svix = -1; # we keep track of when the sv register contains an element
|
||||
# of the object table to avoid unnecessary repeated
|
||||
# consecutive ldsv instructions.
|
||||
|
||||
my $opix = -1; # Ditto for the op register.
|
||||
|
||||
sub ldsv {
|
||||
my $ix = shift;
|
||||
if ($ix != $svix) {
|
||||
print "ldsv $ix\n";
|
||||
asm "ldsv $ix\n";
|
||||
$svix = $ix;
|
||||
}
|
||||
}
|
||||
|
||||
sub stsv {
|
||||
my $ix = shift;
|
||||
print "stsv $ix\n";
|
||||
asm "stsv $ix\n";
|
||||
$svix = $ix;
|
||||
}
|
||||
|
||||
@ -76,14 +113,14 @@ sub set_svix {
|
||||
sub ldop {
|
||||
my $ix = shift;
|
||||
if ($ix != $opix) {
|
||||
print "ldop $ix\n";
|
||||
asm "ldop $ix\n";
|
||||
$opix = $ix;
|
||||
}
|
||||
}
|
||||
|
||||
sub stop {
|
||||
my $ix = shift;
|
||||
print "stop $ix\n";
|
||||
asm "stop $ix\n";
|
||||
$opix = $ix;
|
||||
}
|
||||
|
||||
@ -100,12 +137,29 @@ sub pvstring {
|
||||
}
|
||||
}
|
||||
|
||||
sub nv {
|
||||
# print full precision
|
||||
my $str = sprintf "%.40f", $_[0];
|
||||
$str =~ s/0+$//; # remove trailing zeros
|
||||
$str =~ s/\.$/.0/;
|
||||
return $str;
|
||||
}
|
||||
|
||||
sub saved { $saved{${$_[0]}} }
|
||||
sub mark_saved { $saved{${$_[0]}} = 1 }
|
||||
sub unmark_saved { $saved{${$_[0]}} = 0 }
|
||||
|
||||
sub debug { $debug_bc = shift }
|
||||
|
||||
sub pvix { # save a shared PV (mainly for COPs)
|
||||
return $strtable{$_[0]} if defined($strtable{$_[0]});
|
||||
asmf "newpv %s\n", pvstring($_[0]);
|
||||
my $ix = $nextix++;
|
||||
$strtable{$_[0]} = $ix;
|
||||
asmf "stpv %d\n", $ix;
|
||||
return $ix;
|
||||
}
|
||||
|
||||
sub B::OBJECT::nyi {
|
||||
my $obj = shift;
|
||||
warn sprintf("bytecode save method for %s (0x%x) not yet implemented\n",
|
||||
@ -129,7 +183,7 @@ sub B::OBJECT::objix {
|
||||
|
||||
sub B::SV::newix {
|
||||
my ($sv, $ix) = @_;
|
||||
printf "newsv %d\t# %s\n", $sv->FLAGS & 0xf, class($sv);
|
||||
asmf "newsv %d\t# %s\n", $sv->FLAGS & SVTYPEMASK, class($sv);
|
||||
stsv($ix);
|
||||
}
|
||||
|
||||
@ -137,7 +191,7 @@ sub B::GV::newix {
|
||||
my ($gv, $ix) = @_;
|
||||
my $gvname = $gv->NAME;
|
||||
my $name = cstring($gv->STASH->NAME . "::" . $gvname);
|
||||
print "gv_fetchpv $name\n";
|
||||
asm "gv_fetchpv $name\n";
|
||||
stsv($ix);
|
||||
}
|
||||
|
||||
@ -146,7 +200,7 @@ sub B::HV::newix {
|
||||
my $name = $hv->NAME;
|
||||
if ($name) {
|
||||
# It's a stash
|
||||
printf "gv_stashpv %s\n", cstring($name);
|
||||
asmf "gv_stashpv %s\n", cstring($name);
|
||||
stsv($ix);
|
||||
} else {
|
||||
# It's an ordinary HV. Fall back to ordinary newix method
|
||||
@ -158,7 +212,7 @@ sub B::SPECIAL::newix {
|
||||
my ($sv, $ix) = @_;
|
||||
# Special case. $$sv is not the address of the SV but an
|
||||
# index into svspecialsv_list.
|
||||
printf "ldspecsv $$sv\t# %s\n", $specialsv_name[$$sv];
|
||||
asmf "ldspecsv $$sv\t# %s\n", $specialsv_name[$$sv];
|
||||
stsv($ix);
|
||||
}
|
||||
|
||||
@ -166,8 +220,8 @@ sub B::OP::newix {
|
||||
my ($op, $ix) = @_;
|
||||
my $class = class($op);
|
||||
my $typenum = $optype_enum{$class};
|
||||
croak "OP::newix: can't understand class $class" unless defined($typenum);
|
||||
print "newop $typenum\t# $class\n";
|
||||
croak("OP::newix: can't understand class $class") unless defined($typenum);
|
||||
asm "newop $typenum\t# $class\n";
|
||||
stop($ix);
|
||||
}
|
||||
|
||||
@ -180,7 +234,7 @@ sub B::OP::bytecode {
|
||||
my $op = shift;
|
||||
my $next = $op->next;
|
||||
my $nextix;
|
||||
my $sibix = $op->sibling->objix;
|
||||
my $sibix = $op->sibling->objix unless $strip_syntree;
|
||||
my $ix = $op->objix;
|
||||
my $type = $op->type;
|
||||
|
||||
@ -189,24 +243,24 @@ sub B::OP::bytecode {
|
||||
}
|
||||
$nextix = $next->objix;
|
||||
|
||||
printf "# %s\n", peekop($op) if $debug_bc;
|
||||
asmf "# %s\n", peekop($op) if $debug_bc;
|
||||
ldop($ix);
|
||||
print "op_next $nextix\n";
|
||||
print "op_sibling $sibix\n" unless $strip_syntree;
|
||||
printf "op_type %s\t# %d\n", "pp_" . $op->name, $type;
|
||||
printf("op_seq %d\n", $op->seq) unless $omit_seq;
|
||||
asm "op_next $nextix\n";
|
||||
asm "op_sibling $sibix\n" unless $strip_syntree;
|
||||
asmf "op_type %s\t# %d\n", "pp_" . $op->name, $type;
|
||||
asmf("op_seq %d\n", $op->seq) unless $omit_seq;
|
||||
if ($type || !$compress_nullops) {
|
||||
printf "op_targ %d\nop_flags 0x%x\nop_private 0x%x\n",
|
||||
asmf "op_targ %d\nop_flags 0x%x\nop_private 0x%x\n",
|
||||
$op->targ, $op->flags, $op->private;
|
||||
}
|
||||
}
|
||||
|
||||
sub B::UNOP::bytecode {
|
||||
my $op = shift;
|
||||
my $firstix = $op->first->objix;
|
||||
my $firstix = $op->first->objix unless $strip_syntree;
|
||||
$op->B::OP::bytecode;
|
||||
if (($op->type || !$compress_nullops) && !$strip_syntree) {
|
||||
print "op_first $firstix\n";
|
||||
asm "op_first $firstix\n";
|
||||
}
|
||||
}
|
||||
|
||||
@ -214,7 +268,7 @@ sub B::LOGOP::bytecode {
|
||||
my $op = shift;
|
||||
my $otherix = $op->other->objix;
|
||||
$op->B::UNOP::bytecode;
|
||||
print "op_other $otherix\n";
|
||||
asm "op_other $otherix\n";
|
||||
}
|
||||
|
||||
sub B::SVOP::bytecode {
|
||||
@ -222,7 +276,7 @@ sub B::SVOP::bytecode {
|
||||
my $sv = $op->sv;
|
||||
my $svix = $sv->objix;
|
||||
$op->B::OP::bytecode;
|
||||
print "op_sv $svix\n";
|
||||
asm "op_sv $svix\n";
|
||||
$sv->bytecode;
|
||||
}
|
||||
|
||||
@ -230,7 +284,7 @@ sub B::PADOP::bytecode {
|
||||
my $op = shift;
|
||||
my $padix = $op->padix;
|
||||
$op->B::OP::bytecode;
|
||||
print "op_padix $padix\n";
|
||||
asm "op_padix $padix\n";
|
||||
}
|
||||
|
||||
sub B::PVOP::bytecode {
|
||||
@ -243,27 +297,18 @@ sub B::PVOP::bytecode {
|
||||
#
|
||||
if ($op->name eq "trans") {
|
||||
my @shorts = unpack("s256", $pv); # assembler handles endianness
|
||||
print "op_pv_tr ", join(",", @shorts), "\n";
|
||||
asm "op_pv_tr ", join(",", @shorts), "\n";
|
||||
} else {
|
||||
printf "newpv %s\nop_pv\n", pvstring($pv);
|
||||
asmf "newpv %s\nop_pv\n", pvstring($pv);
|
||||
}
|
||||
}
|
||||
|
||||
sub B::BINOP::bytecode {
|
||||
my $op = shift;
|
||||
my $lastix = $op->last->objix;
|
||||
my $lastix = $op->last->objix unless $strip_syntree;
|
||||
$op->B::UNOP::bytecode;
|
||||
if (($op->type || !$compress_nullops) && !$strip_syntree) {
|
||||
print "op_last $lastix\n";
|
||||
}
|
||||
}
|
||||
|
||||
sub B::LISTOP::bytecode {
|
||||
my $op = shift;
|
||||
my $children = $op->children;
|
||||
$op->B::BINOP::bytecode;
|
||||
if (($op->type || !$compress_nullops) && !$strip_syntree) {
|
||||
print "op_children $children\n";
|
||||
asm "op_last $lastix\n";
|
||||
}
|
||||
}
|
||||
|
||||
@ -273,28 +318,29 @@ sub B::LOOP::bytecode {
|
||||
my $nextopix = $op->nextop->objix;
|
||||
my $lastopix = $op->lastop->objix;
|
||||
$op->B::LISTOP::bytecode;
|
||||
print "op_redoop $redoopix\nop_nextop $nextopix\nop_lastop $lastopix\n";
|
||||
asm "op_redoop $redoopix\nop_nextop $nextopix\nop_lastop $lastopix\n";
|
||||
}
|
||||
|
||||
sub B::COP::bytecode {
|
||||
my $op = shift;
|
||||
my $stashpv = $op->stashpv;
|
||||
my $file = $op->file;
|
||||
my $line = $op->line;
|
||||
if ($debug_bc) { # do this early to aid debugging
|
||||
asmf "# line %s:%d\n", $file, $line;
|
||||
}
|
||||
my $stashpv = $op->stashpv;
|
||||
my $warnings = $op->warnings;
|
||||
my $warningsix = $warnings->objix;
|
||||
if ($debug_bc) {
|
||||
printf "# line %s:%d\n", $file, $line;
|
||||
}
|
||||
my $labelix = pvix($op->label);
|
||||
my $stashix = pvix($stashpv);
|
||||
my $fileix = pvix($file);
|
||||
$warnings->bytecode;
|
||||
$op->B::OP::bytecode;
|
||||
printf <<"EOT", pvstring($op->label), pvstring($stashpv), $op->cop_seq, pvstring($file), $op->arybase;
|
||||
newpv %s
|
||||
cop_label
|
||||
newpv %s
|
||||
cop_stashpv
|
||||
asmf <<"EOT", $labelix, $stashix, $op->cop_seq, $fileix, $op->arybase;
|
||||
cop_label %d
|
||||
cop_stashpv %d
|
||||
cop_seq %d
|
||||
newpv %s
|
||||
cop_file
|
||||
cop_file %d
|
||||
cop_arybase %d
|
||||
cop_line $line
|
||||
cop_warnings $warningsix
|
||||
@ -322,13 +368,13 @@ sub B::PMOP::bytecode {
|
||||
}
|
||||
$op->B::LISTOP::bytecode;
|
||||
if ($opname eq "pushre") {
|
||||
printf "op_pmreplrootgv $replrootix\n";
|
||||
asmf "op_pmreplrootgv $replrootix\n";
|
||||
} else {
|
||||
print "op_pmreplroot $replrootix\nop_pmreplstart $replstartix\n";
|
||||
asm "op_pmreplroot $replrootix\nop_pmreplstart $replstartix\n";
|
||||
}
|
||||
my $re = pvstring($op->precomp);
|
||||
# op_pmnext omitted since a perl bug means it's sometime corrupt
|
||||
printf <<"EOT", $op->pmflags, $op->pmpermflags;
|
||||
asmf <<"EOT", $op->pmflags, $op->pmpermflags;
|
||||
op_pmflags 0x%x
|
||||
op_pmpermflags 0x%x
|
||||
newpv $re
|
||||
@ -343,7 +389,7 @@ sub B::SV::bytecode {
|
||||
my $refcnt = $sv->REFCNT;
|
||||
my $flags = sprintf("0x%x", $sv->FLAGS);
|
||||
ldsv($ix);
|
||||
print "sv_refcnt $refcnt\nsv_flags $flags\n";
|
||||
asm "sv_refcnt $refcnt\nsv_flags $flags\n";
|
||||
mark_saved($sv);
|
||||
}
|
||||
|
||||
@ -351,7 +397,7 @@ sub B::PV::bytecode {
|
||||
my $sv = shift;
|
||||
return if saved($sv);
|
||||
$sv->B::SV::bytecode;
|
||||
printf("newpv %s\nxpv\n", pvstring($sv->PV)) if $sv->FLAGS & POK;
|
||||
asmf("newpv %s\nxpv\n", pvstring($sv->PV)) if $sv->FLAGS & POK;
|
||||
}
|
||||
|
||||
sub B::IV::bytecode {
|
||||
@ -359,14 +405,14 @@ sub B::IV::bytecode {
|
||||
return if saved($sv);
|
||||
my $iv = $sv->IVX;
|
||||
$sv->B::SV::bytecode;
|
||||
printf "%s $iv\n", $sv->needs64bits ? "xiv64" : "xiv32";
|
||||
asmf "%s $iv\n", $sv->needs64bits ? "xiv64" : "xiv32" if $sv->FLAGS & IOK; # could be PVNV
|
||||
}
|
||||
|
||||
sub B::NV::bytecode {
|
||||
my $sv = shift;
|
||||
return if saved($sv);
|
||||
$sv->B::SV::bytecode;
|
||||
printf "xnv %s\n", $sv->NVX;
|
||||
asmf "xnv %s\n", nv($sv->NVX);
|
||||
}
|
||||
|
||||
sub B::RV::bytecode {
|
||||
@ -376,7 +422,7 @@ sub B::RV::bytecode {
|
||||
my $rvix = $rv->objix;
|
||||
$rv->bytecode;
|
||||
$sv->B::SV::bytecode;
|
||||
print "xrv $rvix\n";
|
||||
asm "xrv $rvix\n";
|
||||
}
|
||||
|
||||
sub B::PVIV::bytecode {
|
||||
@ -384,7 +430,7 @@ sub B::PVIV::bytecode {
|
||||
return if saved($sv);
|
||||
my $iv = $sv->IVX;
|
||||
$sv->B::PV::bytecode;
|
||||
printf "%s $iv\n", $sv->needs64bits ? "xiv64" : "xiv32";
|
||||
asmf "%s $iv\n", $sv->needs64bits ? "xiv64" : "xiv32";
|
||||
}
|
||||
|
||||
sub B::PVNV::bytecode {
|
||||
@ -404,12 +450,12 @@ sub B::PVNV::bytecode {
|
||||
} else {
|
||||
my $pv = $sv->PV;
|
||||
$sv->B::IV::bytecode;
|
||||
printf "xnv %s\n", $sv->NVX;
|
||||
asmf "xnv %s\n", nv($sv->NVX);
|
||||
if ($flag == 1) {
|
||||
$pv .= "\0" . $sv->TABLE;
|
||||
printf "newpv %s\npv_cur %d\nxpv\n", pvstring($pv),length($pv)-257;
|
||||
asmf "newpv %s\npv_cur %d\nxpv\n", pvstring($pv),length($pv)-257;
|
||||
} else {
|
||||
printf("newpv %s\nxpv\n", pvstring($pv)) if $sv->FLAGS & POK;
|
||||
asmf("newpv %s\nxpv\n", pvstring($pv)) if $sv->FLAGS & POK;
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -431,9 +477,9 @@ sub B::PVMG::bytecode {
|
||||
#
|
||||
@mgobjix = map($_->OBJ->objix, @mgchain);
|
||||
$sv->B::PVNV::bytecode($flag);
|
||||
print "xmg_stash $stashix\n";
|
||||
asm "xmg_stash $stashix\n";
|
||||
foreach $mg (@mgchain) {
|
||||
printf "sv_magic %s\nmg_obj %d\nnewpv %s\nmg_pv\n",
|
||||
asmf "sv_magic %s\nmg_obj %d\nnewpv %s\nmg_pv\n",
|
||||
cstring($mg->TYPE), shift(@mgobjix), pvstring($mg->PTR);
|
||||
}
|
||||
}
|
||||
@ -442,7 +488,7 @@ sub B::PVLV::bytecode {
|
||||
my $sv = shift;
|
||||
return if saved($sv);
|
||||
$sv->B::PVMG::bytecode;
|
||||
printf <<'EOT', $sv->TARGOFF, $sv->TARGLEN, cstring($sv->TYPE);
|
||||
asmf <<'EOT', $sv->TARGOFF, $sv->TARGLEN, cstring($sv->TYPE);
|
||||
xlv_targoff %d
|
||||
xlv_targlen %d
|
||||
xlv_type %s
|
||||
@ -454,46 +500,63 @@ sub B::BM::bytecode {
|
||||
return if saved($sv);
|
||||
# See PVNV::bytecode for an explanation of what the argument does
|
||||
$sv->B::PVMG::bytecode(1);
|
||||
printf "xbm_useful %d\nxbm_previous %d\nxbm_rare %d\n",
|
||||
asmf "xbm_useful %d\nxbm_previous %d\nxbm_rare %d\n",
|
||||
$sv->USEFUL, $sv->PREVIOUS, $sv->RARE;
|
||||
}
|
||||
|
||||
sub empty_gv { # is a GV empty except for imported stuff?
|
||||
my $gv = shift;
|
||||
|
||||
return 0 if ($gv->SV->FLAGS & SVTYPEMASK); # sv not SVt_NULL
|
||||
my @subfield_names = qw(AV HV CV FORM IO);
|
||||
@subfield_names = grep {;
|
||||
no strict 'refs';
|
||||
!($gv->GvFLAGS & ${\"GVf_IMPORTED_$_"}->()) && ${$gv->$_()};
|
||||
} @subfield_names;
|
||||
return scalar @subfield_names;
|
||||
}
|
||||
|
||||
sub B::GV::bytecode {
|
||||
my $gv = shift;
|
||||
return if saved($gv);
|
||||
return unless grep { $_ eq $gv->STASH->NAME; } @packages;
|
||||
return if $gv->NAME =~ m/^\(/; # ignore overloads - they'll be rebuilt
|
||||
my $ix = $gv->objix;
|
||||
mark_saved($gv);
|
||||
ldsv($ix);
|
||||
printf <<"EOT", $gv->FLAGS, $gv->GvFLAGS;
|
||||
asmf <<"EOT", $gv->FLAGS, $gv->GvFLAGS;
|
||||
sv_flags 0x%x
|
||||
xgv_flags 0x%x
|
||||
EOT
|
||||
my $refcnt = $gv->REFCNT;
|
||||
printf("sv_refcnt_add %d\n", $refcnt - 1) if $refcnt > 1;
|
||||
asmf("sv_refcnt_add %d\n", $refcnt - 1) if $refcnt > 1;
|
||||
return if $gv->is_empty;
|
||||
printf <<"EOT", $gv->LINE, pvstring($gv->FILE);
|
||||
asmf <<"EOT", $gv->LINE, pvix($gv->FILE);
|
||||
gp_line %d
|
||||
newpv %s
|
||||
gp_file
|
||||
gp_file %d
|
||||
EOT
|
||||
my $gvname = $gv->NAME;
|
||||
my $name = cstring($gv->STASH->NAME . "::" . $gvname);
|
||||
my $egv = $gv->EGV;
|
||||
my $egvix = $egv->objix;
|
||||
my $gvrefcnt = $gv->GvREFCNT;
|
||||
printf("gp_refcnt_add %d\n", $gvrefcnt - 1) if $gvrefcnt > 1;
|
||||
asmf("gp_refcnt_add %d\n", $gvrefcnt - 1) if $gvrefcnt > 1;
|
||||
if ($gvrefcnt > 1 && $ix != $egvix) {
|
||||
print "gp_share $egvix\n";
|
||||
asm "gp_share $egvix\n";
|
||||
} else {
|
||||
if ($gvname !~ /^([^A-Za-z]|STDIN|STDOUT|STDERR|ARGV|SIG|ENV)$/) {
|
||||
my $i;
|
||||
my @subfield_names = qw(SV AV HV CV FORM IO);
|
||||
@subfield_names = grep {;
|
||||
no strict 'refs';
|
||||
!($gv->GvFLAGS & ${\"GVf_IMPORTED_$_"}->());
|
||||
} @subfield_names;
|
||||
my @subfields = map($gv->$_(), @subfield_names);
|
||||
my @ixes = map($_->objix, @subfields);
|
||||
# Reset sv register for $gv
|
||||
ldsv($ix);
|
||||
for ($i = 0; $i < @ixes; $i++) {
|
||||
printf "gp_%s %d\n", lc($subfield_names[$i]), $ixes[$i];
|
||||
asmf "gp_%s %d\n", lc($subfield_names[$i]), $ixes[$i];
|
||||
}
|
||||
# Now save all the subfields
|
||||
my $sv;
|
||||
@ -523,10 +586,10 @@ sub B::HV::bytecode {
|
||||
}
|
||||
ldsv($ix);
|
||||
for ($i = 0; $i < @contents; $i += 2) {
|
||||
printf("newpv %s\nhv_store %d\n",
|
||||
asmf("newpv %s\nhv_store %d\n",
|
||||
pvstring($contents[$i]), $ixes[$i / 2]);
|
||||
}
|
||||
printf "sv_refcnt %d\nsv_flags 0x%x\n", $hv->REFCNT, $hv->FLAGS;
|
||||
asmf "sv_refcnt %d\nsv_flags 0x%x\n", $hv->REFCNT, $hv->FLAGS;
|
||||
}
|
||||
}
|
||||
|
||||
@ -551,22 +614,26 @@ sub B::AV::bytecode {
|
||||
# create an AV with NEWSV and SvUPGRADE rather than doing newAV
|
||||
# which is what sets AvMAX and AvFILL.
|
||||
ldsv($ix);
|
||||
printf "xav_flags 0x%x\nxav_max -1\nxav_fill -1\n", $av->AvFLAGS;
|
||||
asmf "sv_flags 0x%x\n", $av->FLAGS & ~SVf_READONLY; # SvREADONLY_off($av) in case PADCONST
|
||||
asmf "xav_flags 0x%x\nxav_max -1\nxav_fill -1\n", $av->AvFLAGS;
|
||||
if ($fill > -1) {
|
||||
my $elix;
|
||||
foreach $elix (@ixes) {
|
||||
print "av_push $elix\n";
|
||||
asm "av_push $elix\n";
|
||||
}
|
||||
} else {
|
||||
if ($max > -1) {
|
||||
print "av_extend $max\n";
|
||||
asm "av_extend $max\n";
|
||||
}
|
||||
}
|
||||
asmf "sv_flags 0x%x\n", $av->FLAGS; # restore flags from above
|
||||
}
|
||||
|
||||
sub B::CV::bytecode {
|
||||
my $cv = shift;
|
||||
return if saved($cv);
|
||||
return if ${$cv->GV} && ($cv->GV->GvFLAGS & GVf_IMPORTED_CV);
|
||||
my $fileix = pvix($cv->FILE);
|
||||
my $ix = $cv->objix;
|
||||
$cv->B::PVMG::bytecode;
|
||||
my $i;
|
||||
@ -581,10 +648,10 @@ sub B::CV::bytecode {
|
||||
# Reset sv register for $cv (since above ->objix calls stomped on it)
|
||||
ldsv($ix);
|
||||
for ($i = 0; $i < @ixes; $i++) {
|
||||
printf "xcv_%s %d\n", lc($subfield_names[$i]), $ixes[$i];
|
||||
asmf "xcv_%s %d\n", lc($subfield_names[$i]), $ixes[$i];
|
||||
}
|
||||
printf "xcv_depth %d\nxcv_flags 0x%x\n", $cv->DEPTH, $cv->CvFLAGS;
|
||||
printf "newpv %s\nxcv_file\n", pvstring($cv->FILE);
|
||||
asmf "xcv_depth %d\nxcv_flags 0x%x\n", $cv->DEPTH, $cv->CvFLAGS;
|
||||
asmf "xcv_file %d\n", $fileix;
|
||||
# Now save all the subfields (except for CvROOT which was handled
|
||||
# above) and CvSTART (now the initial element of @subfields).
|
||||
shift @subfields; # bye-bye CvSTART
|
||||
@ -607,17 +674,17 @@ sub B::IO::bytecode {
|
||||
|
||||
$io->B::PVMG::bytecode;
|
||||
ldsv($ix);
|
||||
print "xio_top_gv $top_gvix\n";
|
||||
print "xio_fmt_gv $fmt_gvix\n";
|
||||
print "xio_bottom_gv $bottom_gvix\n";
|
||||
asm "xio_top_gv $top_gvix\n";
|
||||
asm "xio_fmt_gv $fmt_gvix\n";
|
||||
asm "xio_bottom_gv $bottom_gvix\n";
|
||||
my $field;
|
||||
foreach $field (qw(TOP_NAME FMT_NAME BOTTOM_NAME)) {
|
||||
printf "newpv %s\nxio_%s\n", pvstring($io->$field()), lc($field);
|
||||
asmf "newpv %s\nxio_%s\n", pvstring($io->$field()), lc($field);
|
||||
}
|
||||
foreach $field (qw(LINES PAGE PAGE_LEN LINES_LEFT SUBPROCESS)) {
|
||||
printf "xio_%s %d\n", lc($field), $io->$field();
|
||||
asmf "xio_%s %d\n", lc($field), $io->$field();
|
||||
}
|
||||
printf "xio_type %s\nxio_flags 0x%x\n", cstring($io->IoTYPE), $io->IoFLAGS;
|
||||
asmf "xio_type %s\nxio_flags 0x%x\n", cstring($io->IoTYPE), $io->IoFLAGS;
|
||||
$top_gv->bytecode;
|
||||
$fmt_gv->bytecode;
|
||||
$bottom_gv->bytecode;
|
||||
@ -628,8 +695,7 @@ sub B::SPECIAL::bytecode {
|
||||
}
|
||||
|
||||
sub bytecompile_object {
|
||||
my $sv;
|
||||
foreach $sv (@_) {
|
||||
for my $sv (@_) {
|
||||
svref_2object($sv)->bytecode;
|
||||
}
|
||||
}
|
||||
@ -637,7 +703,7 @@ sub bytecompile_object {
|
||||
sub B::GV::bytecodecv {
|
||||
my $gv = shift;
|
||||
my $cv = $gv->CV;
|
||||
if ($$cv && !saved($cv)) {
|
||||
if ($$cv && !saved($cv) && !($gv->FLAGS & GVf_IMPORTED_CV)) {
|
||||
if ($debug_cv) {
|
||||
warn sprintf("saving extra CV &%s::%s (0x%x) from GV 0x%x\n",
|
||||
$gv->STASH->NAME, $gv->NAME, $$cv, $$gv);
|
||||
@ -646,43 +712,66 @@ sub B::GV::bytecodecv {
|
||||
}
|
||||
}
|
||||
|
||||
sub save_call_queues {
|
||||
if (begin_av()->isa("B::AV")) { # this is just to save 'use Foo;' calls
|
||||
for my $cv (begin_av()->ARRAY) {
|
||||
next unless grep { $_ eq $cv->STASH->NAME; } @packages;
|
||||
my $op = $cv->START;
|
||||
OPLOOP:
|
||||
while ($$op) {
|
||||
if ($op->name eq 'require') { # save any BEGIN that does a require
|
||||
$cv->bytecode;
|
||||
asmf "push_begin %d\n", $cv->objix;
|
||||
last OPLOOP;
|
||||
}
|
||||
$op = $op->next;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (init_av()->isa("B::AV")) {
|
||||
for my $cv (init_av()->ARRAY) {
|
||||
next unless grep { $_ eq $cv->STASH->NAME; } @packages;
|
||||
$cv->bytecode;
|
||||
asmf "push_init %d\n", $cv->objix;
|
||||
}
|
||||
}
|
||||
if (end_av()->isa("B::AV")) {
|
||||
for my $cv (end_av()->ARRAY) {
|
||||
next unless grep { $_ eq $cv->STASH->NAME; } @packages;
|
||||
$cv->bytecode;
|
||||
asmf "push_end %d\n", $cv->objix;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
sub symwalk {
|
||||
no strict 'refs';
|
||||
my $ok = 1 if grep { (my $name = $_[0]) =~ s/::$//; $_ eq $name;} @packages;
|
||||
if (grep { /^$_[0]/; } @packages) {
|
||||
walksymtable(\%{"$_[0]"}, "bytecodecv", \&symwalk, $_[0]);
|
||||
}
|
||||
warn "considering $_[0] ... " . ($ok ? "accepted\n" : "rejected\n")
|
||||
if $debug_bc;
|
||||
$ok;
|
||||
}
|
||||
|
||||
sub bytecompile_main {
|
||||
my $curpad = (comppadlist->ARRAY)[1];
|
||||
my $curpadix = $curpad->objix;
|
||||
$curpad->bytecode;
|
||||
walkoptree(main_root, "bytecode");
|
||||
save_call_queues();
|
||||
walkoptree(main_root, "bytecode") unless ref(main_root) eq "B::NULL";
|
||||
warn "done main program, now walking symbol table\n" if $debug_bc;
|
||||
my ($pack, %exclude);
|
||||
foreach $pack (qw(B O AutoLoader DynaLoader XSLoader Config DB VMS strict vars
|
||||
FileHandle Exporter Carp UNIVERSAL IO Fcntl Symbol
|
||||
SelectSaver blib Cwd))
|
||||
{
|
||||
$exclude{$pack."::"} = 1;
|
||||
if (@packages) {
|
||||
no strict qw(refs);
|
||||
walksymtable(\%{"main::"}, "bytecodecv", \&symwalk);
|
||||
} else {
|
||||
die "No packages requested for compilation!\n";
|
||||
}
|
||||
no strict qw(vars refs);
|
||||
walksymtable(\%{"main::"}, "bytecodecv", sub {
|
||||
warn "considering $_[0]\n" if $debug_bc;
|
||||
return !defined($exclude{$_[0]});
|
||||
});
|
||||
if (!$module_only) {
|
||||
printf "main_root %d\n", main_root->objix;
|
||||
printf "main_start %d\n", main_start->objix;
|
||||
printf "curpad $curpadix\n";
|
||||
# XXX Do min_intro_pending and max_intro_pending matter?
|
||||
}
|
||||
}
|
||||
|
||||
sub prepare_assemble {
|
||||
my $newfh = IO::File->new_tmpfile;
|
||||
select($newfh);
|
||||
binmode $newfh;
|
||||
return $newfh;
|
||||
}
|
||||
|
||||
sub do_assemble {
|
||||
my $fh = shift;
|
||||
seek($fh, 0, 0); # rewind the temporary file
|
||||
assemble_fh($fh, sub { print OUT @_ });
|
||||
asmf "main_root %d\n", main_root->objix;
|
||||
asmf "main_start %d\n", main_start->objix;
|
||||
asmf "curpad $curpadix\n";
|
||||
# XXX Do min_intro_pending and max_intro_pending matter?
|
||||
}
|
||||
|
||||
sub compile {
|
||||
@ -690,7 +779,7 @@ sub compile {
|
||||
my ($option, $opt, $arg);
|
||||
open(OUT, ">&STDOUT");
|
||||
binmode OUT;
|
||||
select(OUT);
|
||||
select OUT;
|
||||
OPTION:
|
||||
while ($option = shift @options) {
|
||||
if ($option =~ /^-(.)(.*)/) {
|
||||
@ -727,8 +816,6 @@ sub compile {
|
||||
}
|
||||
} elsif ($opt eq "v") {
|
||||
$verbose = 1;
|
||||
} elsif ($opt eq "m") {
|
||||
$module_only = 1;
|
||||
} elsif ($opt eq "S") {
|
||||
$no_assemble = 1;
|
||||
} elsif ($opt eq "f") {
|
||||
@ -747,9 +834,6 @@ sub compile {
|
||||
foreach $ref (values %optimise) {
|
||||
$$ref = 0;
|
||||
}
|
||||
if ($arg >= 6) {
|
||||
$strip_syntree = 1;
|
||||
}
|
||||
if ($arg >= 2) {
|
||||
$bypass_nullops = 1;
|
||||
}
|
||||
@ -757,28 +841,30 @@ sub compile {
|
||||
$compress_nullops = 1;
|
||||
$omit_seq = 1;
|
||||
}
|
||||
} elsif ($opt eq "u") {
|
||||
$arg ||= shift @options;
|
||||
push @packages, $arg;
|
||||
} else {
|
||||
warn qq(ignoring unknown option "$opt$arg"\n);
|
||||
}
|
||||
}
|
||||
if (! @packages) {
|
||||
warn "No package specified for compilation, assuming main::\n";
|
||||
@packages = qw(main);
|
||||
}
|
||||
if (@options) {
|
||||
return sub {
|
||||
my $objname;
|
||||
my $newfh;
|
||||
$newfh = prepare_assemble() unless $no_assemble;
|
||||
foreach $objname (@options) {
|
||||
eval "bytecompile_object(\\$objname)";
|
||||
}
|
||||
do_assemble($newfh) unless $no_assemble;
|
||||
}
|
||||
die "Extraneous options left on B::Bytecode commandline: @options\n";
|
||||
} else {
|
||||
return sub {
|
||||
my $newfh;
|
||||
$newfh = prepare_assemble() unless $no_assemble;
|
||||
return sub {
|
||||
newasm(\&apr) unless $no_assemble;
|
||||
bytecompile_main();
|
||||
do_assemble($newfh) unless $no_assemble;
|
||||
}
|
||||
endasm() unless $no_assemble;
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
sub apr { print @_; }
|
||||
|
||||
1;
|
||||
|
||||
__END__
|
||||
@ -848,18 +934,11 @@ which is only used by perl's internal compiler.
|
||||
If op->op_next ever points to a NULLOP, replaces the op_next field
|
||||
with the first non-NULLOP in the path of execution.
|
||||
|
||||
=item B<-fstrip-syntax-tree>
|
||||
|
||||
Leaves out code to fill in the pointers which link the internal syntax
|
||||
tree together. They're not needed at run-time but leaving them out
|
||||
will make it impossible to recompile or disassemble the resulting
|
||||
program. It will also stop C<goto label> statements from working.
|
||||
|
||||
=item B<-On>
|
||||
|
||||
Optimisation level (n = 0, 1, 2, ...). B<-O> means B<-O1>.
|
||||
B<-O1> sets B<-fcompress-nullops> B<-fomit-sequence numbers>.
|
||||
B<-O6> adds B<-fstrip-syntax-tree>.
|
||||
B<-O2> adds B<-fbypass-nullops>.
|
||||
|
||||
=item B<-D>
|
||||
|
||||
@ -887,33 +966,33 @@ Prints each CV taken from the final symbol tree walk.
|
||||
Output (bytecode) assembler source rather than piping it
|
||||
through the assembler and outputting bytecode.
|
||||
|
||||
=item B<-m>
|
||||
|
||||
Compile as a module rather than a standalone program. Currently this
|
||||
just means that the bytecodes for initialising C<main_start>,
|
||||
C<main_root> and C<curpad> are omitted.
|
||||
|
||||
=item B<-upackage>
|
||||
|
||||
Stores package in the output.
|
||||
|
||||
=back
|
||||
|
||||
=head1 EXAMPLES
|
||||
|
||||
perl -MO=Bytecode,-O6,-o,foo.plc foo.pl
|
||||
perl -MO=Bytecode,-O6,-ofoo.plc,-umain foo.pl
|
||||
|
||||
perl -MO=Bytecode,-S foo.pl > foo.S
|
||||
perl -MO=Bytecode,-S,-umain foo.pl > foo.S
|
||||
assemble foo.S > foo.plc
|
||||
|
||||
Note that C<assemble> lives in the C<B> subdirectory of your perl
|
||||
library directory. The utility called perlcc may also be used to
|
||||
help make use of this compiler.
|
||||
|
||||
perl -MO=Bytecode,-m,-oFoo.pmc Foo.pm
|
||||
perl -MO=Bytecode,-uFoo,-oFoo.pmc Foo.pm
|
||||
|
||||
=head1 BUGS
|
||||
|
||||
Plenty. Current status: experimental.
|
||||
Output is still huge and there are still occasional crashes during
|
||||
either compilation or ByteLoading. Current status: experimental.
|
||||
|
||||
=head1 AUTHOR
|
||||
=head1 AUTHORS
|
||||
|
||||
Malcolm Beattie, C<mbeattie@sable.ox.ac.uk>
|
||||
Benjamin Stuhl, C<sho_pi@hotmail.com>
|
||||
|
||||
=cut
|
||||
|
@ -225,11 +225,10 @@ sub B::LISTOP::save {
|
||||
my ($op, $level) = @_;
|
||||
my $sym = objsym($op);
|
||||
return $sym if defined $sym;
|
||||
$listopsect->add(sprintf("s\\_%x, s\\_%x, NULL, %u, %u, %u, 0x%x, 0x%x, s\\_%x, s\\_%x, %u",
|
||||
$listopsect->add(sprintf("s\\_%x, s\\_%x, NULL, %u, %u, %u, 0x%x, 0x%x, s\\_%x, s\\_%x",
|
||||
${$op->next}, ${$op->sibling},
|
||||
$op->targ, $op->type, $op_seq, $op->flags,
|
||||
$op->private, ${$op->first}, ${$op->last},
|
||||
$op->children));
|
||||
$op->private, ${$op->first}, ${$op->last}));
|
||||
my $ix = $listopsect->index;
|
||||
$init->add(sprintf("listop_list[$ix].op_ppaddr = %s;", $op->ppaddr));
|
||||
savesym($op, "(OP*)&listop_list[$ix]");
|
||||
@ -255,11 +254,11 @@ sub B::LOOP::save {
|
||||
#warn sprintf("LOOP: redoop %s, nextop %s, lastop %s\n",
|
||||
# peekop($op->redoop), peekop($op->nextop),
|
||||
# peekop($op->lastop)); # debug
|
||||
$loopsect->add(sprintf("s\\_%x, s\\_%x, NULL, %u, %u, %u, 0x%x, 0x%x, s\\_%x, s\\_%x, %u, s\\_%x, s\\_%x, s\\_%x",
|
||||
$loopsect->add(sprintf("s\\_%x, s\\_%x, NULL, %u, %u, %u, 0x%x, 0x%x, s\\_%x, s\\_%x, s\\_%x, s\\_%x, s\\_%x",
|
||||
${$op->next}, ${$op->sibling},
|
||||
$op->targ, $op->type, $op_seq, $op->flags,
|
||||
$op->private, ${$op->first}, ${$op->last},
|
||||
$op->children, ${$op->redoop}, ${$op->nextop},
|
||||
${$op->redoop}, ${$op->nextop},
|
||||
${$op->lastop}));
|
||||
my $ix = $loopsect->index;
|
||||
$init->add(sprintf("loop_list[$ix].op_ppaddr = %s;", $op->ppaddr));
|
||||
@ -351,10 +350,10 @@ sub B::PMOP::save {
|
||||
# pmnext handling is broken in perl itself, I think. Bad op_pmnext
|
||||
# fields aren't noticed in perl's runtime (unless you try reset) but we
|
||||
# segfault when trying to dereference it to find op->op_pmnext->op_type
|
||||
$pmopsect->add(sprintf("s\\_%x, s\\_%x, NULL, %u, %u, %u, 0x%x, 0x%x, s\\_%x, s\\_%x, %u, %s, %s, 0, 0, 0x%x, 0x%x",
|
||||
$pmopsect->add(sprintf("s\\_%x, s\\_%x, NULL, %u, %u, %u, 0x%x, 0x%x, s\\_%x, s\\_%x, %s, %s, 0, 0, 0x%x, 0x%x",
|
||||
${$op->next}, ${$op->sibling}, $op->targ,
|
||||
$op->type, $op_seq, $op->flags, $op->private,
|
||||
${$op->first}, ${$op->last}, $op->children,
|
||||
${$op->first}, ${$op->last},
|
||||
$replrootfield, $replstartfield,
|
||||
$op->pmflags, $op->pmpermflags,));
|
||||
my $pm = sprintf("pmop_list[%d]", $pmopsect->index);
|
||||
@ -1020,9 +1019,8 @@ sub output_all {
|
||||
print <<"EOT";
|
||||
static int $init_name()
|
||||
{
|
||||
dTHR;
|
||||
dTARG;
|
||||
djSP;
|
||||
dSP;
|
||||
EOT
|
||||
$init->output(\*STDOUT, "\t%s\n");
|
||||
print "\treturn 0;\n}\n";
|
||||
@ -1050,15 +1048,15 @@ typedef struct {
|
||||
STRLEN xpv_cur; /* length of xp_pv as a C string */
|
||||
STRLEN xpv_len; /* allocated size */
|
||||
IV xof_off; /* integer value */
|
||||
double xnv_nv; /* numeric value, if any */
|
||||
NV xnv_nv; /* numeric value, if any */
|
||||
MAGIC* xmg_magic; /* magic for scalar array */
|
||||
HV* xmg_stash; /* class package */
|
||||
|
||||
HV * xcv_stash;
|
||||
OP * xcv_start;
|
||||
OP * xcv_root;
|
||||
void (*xcv_xsub) (CV*);
|
||||
void * xcv_xsubany;
|
||||
void (*xcv_xsub) (pTHXo_ CV*);
|
||||
ANY xcv_xsubany;
|
||||
GV * xcv_gv;
|
||||
char * xcv_file;
|
||||
long xcv_depth; /* >= 2 indicates recursive call */
|
||||
@ -1174,7 +1172,7 @@ xs_init(pTHX)
|
||||
{
|
||||
char *file = __FILE__;
|
||||
dTARG;
|
||||
djSP;
|
||||
dSP;
|
||||
EOT
|
||||
print "\n#ifdef USE_DYNAMIC_LOADING";
|
||||
print qq/\n\tnewXS("DynaLoader::boot_DynaLoader", boot_DynaLoader, file);/;
|
||||
@ -1210,7 +1208,7 @@ dl_init(pTHX)
|
||||
{
|
||||
char *file = __FILE__;
|
||||
dTARG;
|
||||
djSP;
|
||||
dSP;
|
||||
EOT
|
||||
print("/* Dynamicboot strapping code*/\n\tSAVETMPS;\n");
|
||||
print("\ttarg=sv_newmortal();\n");
|
||||
@ -1338,7 +1336,7 @@ sub should_save
|
||||
# Now see if current package looks like an OO class this is probably too strong.
|
||||
foreach my $m (qw(new DESTROY TIESCALAR TIEARRAY TIEHASH TIEHANDLE))
|
||||
{
|
||||
if ($package->can($m))
|
||||
if (UNIVERSAL::can($package, $m))
|
||||
{
|
||||
warn "$package has method $m: saving package\n";#debug
|
||||
return mark_package($package);
|
||||
@ -1368,7 +1366,7 @@ sub walkpackages
|
||||
if ($sym =~ /::$/)
|
||||
{
|
||||
$sym = $prefix . $sym;
|
||||
if ($sym ne "main::" && &$recurse($sym))
|
||||
if ($sym ne "main::" && $sym ne "<none>::" && &$recurse($sym))
|
||||
{
|
||||
walkpackages(\%glob, $recurse, $sym);
|
||||
}
|
||||
|
@ -151,7 +151,7 @@ sub init_pp {
|
||||
$ppname = shift;
|
||||
$runtime_list_ref = [];
|
||||
$declare_ref = {};
|
||||
runtime("djSP;");
|
||||
runtime("dSP;");
|
||||
declare("I32", "oldsave");
|
||||
declare("SV", "**svp");
|
||||
map { declare("SV", "*$_") } qw(sv src dst left right);
|
||||
|
@ -33,6 +33,16 @@ sub B::BINOP::debug {
|
||||
printf "\top_last\t\t0x%x\n", ${$op->last};
|
||||
}
|
||||
|
||||
sub B::LOOP::debug {
|
||||
my ($op) = @_;
|
||||
$op->B::BINOP::debug();
|
||||
printf <<'EOT', ${$op->redoop}, ${$op->nextop}, ${$op->lastop};
|
||||
op_redoop 0x%x
|
||||
op_nextop 0x%x
|
||||
op_lastop 0x%x
|
||||
EOT
|
||||
}
|
||||
|
||||
sub B::LOGOP::debug {
|
||||
my ($op) = @_;
|
||||
$op->B::UNOP::debug();
|
||||
@ -53,7 +63,6 @@ sub B::PMOP::debug {
|
||||
printf "\top_pmnext\t0x%x\n", ${$op->pmnext};
|
||||
printf "\top_pmregexp->precomp\t%s\n", cstring($op->precomp);
|
||||
printf "\top_pmflags\t0x%x\n", $op->pmflags;
|
||||
$op->pmshort->debug;
|
||||
$op->pmreplroot->debug;
|
||||
}
|
||||
|
||||
@ -209,14 +218,14 @@ EOT
|
||||
sub B::GV::debug {
|
||||
my ($gv) = @_;
|
||||
if ($done_gv{$$gv}++) {
|
||||
printf "GV %s::%s\n", $gv->STASH->NAME, $gv->NAME;
|
||||
printf "GV %s::%s\n", $gv->STASH->NAME, $gv->SAFENAME;
|
||||
return;
|
||||
}
|
||||
my ($sv) = $gv->SV;
|
||||
my ($av) = $gv->AV;
|
||||
my ($cv) = $gv->CV;
|
||||
$gv->B::SV::debug;
|
||||
printf <<'EOT', $gv->NAME, $gv->STASH->NAME, $gv->STASH, $$sv, $gv->GvREFCNT, $gv->FORM, $$av, ${$gv->HV}, ${$gv->EGV}, $$cv, $gv->CVGEN, $gv->LINE, $gv->FILE, $gv->GvFLAGS;
|
||||
printf <<'EOT', $gv->SAFENAME, $gv->STASH->NAME, $gv->STASH, $$sv, $gv->GvREFCNT, $gv->FORM, $$av, ${$gv->HV}, ${$gv->EGV}, $$cv, $gv->CVGEN, $gv->LINE, $gv->FILE, $gv->GvFLAGS;
|
||||
NAME %s
|
||||
STASH %s (0x%x)
|
||||
SV 0x%x
|
||||
@ -244,7 +253,7 @@ sub B::SPECIAL::debug {
|
||||
sub compile {
|
||||
my $order = shift;
|
||||
B::clearsym();
|
||||
if ($order eq "exec") {
|
||||
if ($order && $order eq "exec") {
|
||||
return sub { walkoptree_exec(main_start, "debug") }
|
||||
} else {
|
||||
return sub { walkoptree(main_root, "debug") }
|
||||
|
@ -1,5 +1,5 @@
|
||||
# B::Deparse.pm
|
||||
# Copyright (c) 1998, 1999 Stephen McCamant. All rights reserved.
|
||||
# Copyright (c) 1998, 1999, 2000 Stephen McCamant. All rights reserved.
|
||||
# This module is free software; you can redistribute and/or modify
|
||||
# it under the same terms as Perl itself.
|
||||
|
||||
@ -8,16 +8,16 @@
|
||||
|
||||
package B::Deparse;
|
||||
use Carp 'cluck', 'croak';
|
||||
use Config;
|
||||
use B qw(class main_root main_start main_cv svref_2object opnumber
|
||||
OPf_WANT OPf_WANT_VOID OPf_WANT_SCALAR OPf_WANT_LIST
|
||||
OPf_KIDS OPf_REF OPf_STACKED OPf_SPECIAL
|
||||
OPpLVAL_INTRO OPpENTERSUB_AMPER OPpSLICE OPpCONST_BARE
|
||||
OPpTRANS_SQUASH OPpTRANS_DELETE OPpTRANS_COMPLEMENT OPpTARGET_MY
|
||||
SVf_IOK SVf_NOK SVf_ROK SVf_POK
|
||||
CVf_METHOD CVf_LOCKED CVf_LVALUE
|
||||
PMf_KEEP PMf_GLOBAL PMf_CONTINUE PMf_EVAL PMf_ONCE
|
||||
PMf_MULTILINE PMf_SINGLELINE PMf_FOLD PMf_EXTENDED);
|
||||
$VERSION = 0.59;
|
||||
$VERSION = 0.60;
|
||||
use strict;
|
||||
|
||||
# Changes between 0.50 and 0.51:
|
||||
@ -83,6 +83,12 @@ use strict;
|
||||
# - added support for Chip's OP_METHOD_NAMED
|
||||
# - added support for Ilya's OPpTARGET_MY optimization
|
||||
# - elided arrows before `()' subscripts when possible
|
||||
# Changes between 0.59 and 0.60
|
||||
# - support for method attribues was added
|
||||
# - some warnings fixed
|
||||
# - separate recognition of constant subs
|
||||
# - rewrote continue block handling, now recoginizing for loops
|
||||
# - added more control of expanding control structures
|
||||
|
||||
# Todo:
|
||||
# - finish tr/// changes
|
||||
@ -93,8 +99,8 @@ use strict;
|
||||
# - left/right context
|
||||
# - recognize `use utf8', `use integer', etc
|
||||
# - treat top-level block specially for incremental output
|
||||
# - interpret in high bit chars in string as utf8 \x{...} (when?)
|
||||
# - copy comments (look at real text with $^P?)
|
||||
# - interpret high bit chars in string as utf8 \x{...} (when?)
|
||||
# - copy comments (look at real text with $^P?)
|
||||
# - avoid semis in one-statement blocks
|
||||
# - associativity of &&=, ||=, ?:
|
||||
# - ',' => '=>' (auto-unquote?)
|
||||
@ -108,7 +114,6 @@ use strict;
|
||||
# - version using op_next instead of op_first/sibling?
|
||||
# - avoid string copies (pass arrays, one big join?)
|
||||
# - auto-apply `-u'?
|
||||
# - while{} with one-statement continue => for(; XXX; XXX) {}?
|
||||
# - -uPackage:: descend recursively?
|
||||
# - here-docs?
|
||||
# - <DATA>?
|
||||
@ -252,17 +257,17 @@ sub walk_sub {
|
||||
walk_tree($op, sub {
|
||||
my $op = shift;
|
||||
if ($op->name eq "gv") {
|
||||
my $gv = $self->maybe_padgv($op);
|
||||
my $gv = $self->gv_or_padgv($op);
|
||||
if ($op->next->name eq "entersub") {
|
||||
next if $self->{'subs_done'}{$$gv}++;
|
||||
next if class($gv->CV) eq "SPECIAL";
|
||||
return if $self->{'subs_done'}{$$gv}++;
|
||||
return if class($gv->CV) eq "SPECIAL";
|
||||
$self->todo($gv, $gv->CV, 0);
|
||||
$self->walk_sub($gv->CV);
|
||||
} elsif ($op->next->name eq "enterwrite"
|
||||
or ($op->next->name eq "rv2gv"
|
||||
and $op->next->next->name eq "enterwrite")) {
|
||||
next if $self->{'forms_done'}{$$gv}++;
|
||||
next if class($gv->FORM) eq "SPECIAL";
|
||||
return if $self->{'forms_done'}{$$gv}++;
|
||||
return if class($gv->FORM) eq "SPECIAL";
|
||||
$self->todo($gv, $gv->FORM, 1);
|
||||
$self->walk_sub($gv->FORM);
|
||||
}
|
||||
@ -345,6 +350,10 @@ sub new {
|
||||
$self->{'cuddle'} = "\n";
|
||||
$self->{'indent_size'} = 4;
|
||||
$self->{'use_tabs'} = 0;
|
||||
$self->{'expand'} = 0;
|
||||
$self->{'unquote'} = 0;
|
||||
$self->{'linenums'} = 0;
|
||||
$self->{'parens'} = 0;
|
||||
$self->{'ex_const'} = "'???'";
|
||||
while (my $arg = shift @_) {
|
||||
if (substr($arg, 0, 2) eq "-u") {
|
||||
@ -357,6 +366,8 @@ sub new {
|
||||
$self->{'unquote'} = 1;
|
||||
} elsif (substr($arg, 0, 2) eq "-s") {
|
||||
$self->style_opts(substr $arg, 2);
|
||||
} elsif ($arg =~ /^-x(\d)$/) {
|
||||
$self->{'expand'} = $1;
|
||||
}
|
||||
}
|
||||
return $self;
|
||||
@ -378,7 +389,7 @@ sub compile {
|
||||
while (scalar(@{$self->{'subs_todo'}})) {
|
||||
push @text, $self->next_todo;
|
||||
}
|
||||
print indent(join("", @text)), "\n" if @text;
|
||||
print $self->indent(join("", @text)), "\n" if @text;
|
||||
}
|
||||
}
|
||||
|
||||
@ -393,6 +404,7 @@ sub deparse {
|
||||
my $self = shift;
|
||||
my($op, $cx) = @_;
|
||||
# cluck if class($op) eq "NULL";
|
||||
# cluck unless $op;
|
||||
# return $self->$ {\("pp_" . $op->name)}($op, $cx);
|
||||
my $meth = "pp_" . $op->name;
|
||||
return $self->$meth($op, $cx);
|
||||
@ -433,6 +445,13 @@ sub deparse_sub {
|
||||
if ($cv->FLAGS & SVf_POK) {
|
||||
$proto = "(". $cv->PV . ") ";
|
||||
}
|
||||
if ($cv->CvFLAGS & (CVf_METHOD|CVf_LOCKED|CVf_LVALUE)) {
|
||||
$proto .= ": ";
|
||||
$proto .= "lvalue " if $cv->CvFLAGS & CVf_LVALUE;
|
||||
$proto .= "locked " if $cv->CvFLAGS & CVf_LOCKED;
|
||||
$proto .= "method " if $cv->CvFLAGS & CVf_METHOD;
|
||||
}
|
||||
|
||||
local($self->{'curcv'}) = $cv;
|
||||
local($self->{'curstash'}) = $self->{'curstash'};
|
||||
if (not null $cv->ROOT) {
|
||||
@ -553,7 +572,11 @@ sub maybe_local {
|
||||
my $self = shift;
|
||||
my($op, $cx, $text) = @_;
|
||||
if ($op->private & OPpLVAL_INTRO and not $self->{'avoid_local'}{$$op}) {
|
||||
return $self->maybe_parens_func("local", $text, $cx, 16);
|
||||
if (want_scalar($op)) {
|
||||
return "local $text";
|
||||
} else {
|
||||
return $self->maybe_parens_func("local", $text, $cx, 16);
|
||||
}
|
||||
} else {
|
||||
return $text;
|
||||
}
|
||||
@ -581,7 +604,11 @@ sub maybe_my {
|
||||
my $self = shift;
|
||||
my($op, $cx, $text) = @_;
|
||||
if ($op->private & OPpLVAL_INTRO and not $self->{'avoid_local'}{$$op}) {
|
||||
return $self->maybe_parens_func("my", $text, $cx, 16);
|
||||
if (want_scalar($op)) {
|
||||
return "my $text";
|
||||
} else {
|
||||
return $self->maybe_parens_func("my", $text, $cx, 16);
|
||||
}
|
||||
} else {
|
||||
return $text;
|
||||
}
|
||||
@ -672,70 +699,69 @@ sub pp_entertry { # see also leavetry
|
||||
return "XXX";
|
||||
}
|
||||
|
||||
# leave and scope/lineseq should probably share code
|
||||
sub pp_leave {
|
||||
sub lineseq {
|
||||
my $self = shift;
|
||||
my($op, $cx) = @_;
|
||||
my ($kid, $expr);
|
||||
my @exprs;
|
||||
local($self->{'curstash'}) = $self->{'curstash'};
|
||||
$kid = $op->first->sibling; # skip enter
|
||||
if (is_miniwhile($kid)) {
|
||||
my $top = $kid->first;
|
||||
my $name = $top->name;
|
||||
if ($name eq "and") {
|
||||
$name = "while";
|
||||
} elsif ($name eq "or") {
|
||||
$name = "until";
|
||||
} else { # no conditional -> while 1 or until 0
|
||||
return $self->deparse($top->first, 1) . " while 1";
|
||||
my(@ops) = @_;
|
||||
my($expr, @exprs);
|
||||
for (my $i = 0; $i < @ops; $i++) {
|
||||
$expr = "";
|
||||
if (is_state $ops[$i]) {
|
||||
$expr = $self->deparse($ops[$i], 0);
|
||||
$i++;
|
||||
last if $i > $#ops;
|
||||
}
|
||||
my $cond = $top->first;
|
||||
my $body = $cond->sibling->first; # skip lineseq
|
||||
$cond = $self->deparse($cond, 1);
|
||||
$body = $self->deparse($body, 1);
|
||||
return "$body $name $cond";
|
||||
if (!is_state $ops[$i] and $ops[$i+1] and !null($ops[$i+1]) and
|
||||
$ops[$i+1]->name eq "leaveloop" and $self->{'expand'} < 3)
|
||||
{
|
||||
push @exprs, $expr . $self->for_loop($ops[$i], 0);
|
||||
$i++;
|
||||
next;
|
||||
}
|
||||
$expr .= $self->deparse($ops[$i], 0);
|
||||
push @exprs, $expr if length $expr;
|
||||
}
|
||||
return join(";\n", @exprs);
|
||||
}
|
||||
|
||||
sub scopeop {
|
||||
my($real_block, $self, $op, $cx) = @_;
|
||||
my $kid;
|
||||
my @kids;
|
||||
local($self->{'curstash'}) = $self->{'curstash'} if $real_block;
|
||||
if ($real_block) {
|
||||
$kid = $op->first->sibling; # skip enter
|
||||
if (is_miniwhile($kid)) {
|
||||
my $top = $kid->first;
|
||||
my $name = $top->name;
|
||||
if ($name eq "and") {
|
||||
$name = "while";
|
||||
} elsif ($name eq "or") {
|
||||
$name = "until";
|
||||
} else { # no conditional -> while 1 or until 0
|
||||
return $self->deparse($top->first, 1) . " while 1";
|
||||
}
|
||||
my $cond = $top->first;
|
||||
my $body = $cond->sibling->first; # skip lineseq
|
||||
$cond = $self->deparse($cond, 1);
|
||||
$body = $self->deparse($body, 1);
|
||||
return "$body $name $cond";
|
||||
}
|
||||
} else {
|
||||
$kid = $op->first;
|
||||
}
|
||||
for (; !null($kid); $kid = $kid->sibling) {
|
||||
$expr = "";
|
||||
if (is_state $kid) {
|
||||
$expr = $self->deparse($kid, 0);
|
||||
$kid = $kid->sibling;
|
||||
last if null $kid;
|
||||
}
|
||||
$expr .= $self->deparse($kid, 0);
|
||||
push @exprs, $expr if length $expr;
|
||||
}
|
||||
if ($cx > 0) { # inside an expression
|
||||
return "do { " . join(";\n", @exprs) . " }";
|
||||
} else {
|
||||
return join(";\n", @exprs) . ";";
|
||||
}
|
||||
}
|
||||
|
||||
sub pp_scope {
|
||||
my $self = shift;
|
||||
my($op, $cx) = @_;
|
||||
my ($kid, $expr);
|
||||
my @exprs;
|
||||
for ($kid = $op->first; !null($kid); $kid = $kid->sibling) {
|
||||
$expr = "";
|
||||
if (is_state $kid) {
|
||||
$expr = $self->deparse($kid, 0);
|
||||
$kid = $kid->sibling;
|
||||
last if null $kid;
|
||||
}
|
||||
$expr .= $self->deparse($kid, 0);
|
||||
push @exprs, $expr if length $expr;
|
||||
push @kids, $kid;
|
||||
}
|
||||
if ($cx > 0) { # inside an expression, (a do {} while for lineseq)
|
||||
return "do { " . join(";\n", @exprs) . " }";
|
||||
return "do { " . $self->lineseq(@kids) . " }";
|
||||
} else {
|
||||
return join(";\n", @exprs) . ";";
|
||||
return $self->lineseq(@kids) . ";";
|
||||
}
|
||||
}
|
||||
|
||||
sub pp_lineseq { pp_scope(@_) }
|
||||
sub pp_scope { scopeop(0, @_); }
|
||||
sub pp_lineseq { scopeop(0, @_); }
|
||||
sub pp_leave { scopeop(1, @_); }
|
||||
|
||||
# The BEGIN {} is used here because otherwise this code isn't executed
|
||||
# when you run B::Deparse on itself.
|
||||
@ -747,7 +773,7 @@ sub gv_name {
|
||||
my $self = shift;
|
||||
my $gv = shift;
|
||||
my $stash = $gv->STASH->NAME;
|
||||
my $name = $gv->NAME;
|
||||
my $name = $gv->SAFENAME;
|
||||
if ($stash eq $self->{'curstash'} or $globalnames{$name}
|
||||
or $name =~ /^[^A-Za-z_]/)
|
||||
{
|
||||
@ -755,8 +781,8 @@ sub gv_name {
|
||||
} else {
|
||||
$stash = $stash . "::";
|
||||
}
|
||||
if ($name =~ /^([\cA-\cZ])$/) {
|
||||
$name = "^" . chr(64 + ord($1));
|
||||
if ($name =~ /^\^../) {
|
||||
$name = "{$name}"; # ${^WARNING_BITS} etc
|
||||
}
|
||||
return $stash . $name;
|
||||
}
|
||||
@ -840,7 +866,7 @@ sub pp_i_preinc { pfixop(@_, "++", 23) }
|
||||
sub pp_i_predec { pfixop(@_, "--", 23) }
|
||||
sub pp_i_postinc { maybe_targmy(@_, \&pfixop, "++", 23, POSTFIX) }
|
||||
sub pp_i_postdec { maybe_targmy(@_, \&pfixop, "--", 23, POSTFIX) }
|
||||
sub pp_complement { maybe_targmy(@_. \&pfixop, "~", 21) }
|
||||
sub pp_complement { maybe_targmy(@_, \&pfixop, "~", 21) }
|
||||
|
||||
sub pp_negate { maybe_targmy(@_, \&real_negate) }
|
||||
sub real_negate {
|
||||
@ -917,7 +943,6 @@ sub pp_prototype { unop(@_, "prototype") }
|
||||
sub pp_close { unop(@_, "close") }
|
||||
sub pp_fileno { unop(@_, "fileno") }
|
||||
sub pp_umask { unop(@_, "umask") }
|
||||
sub pp_binmode { unop(@_, "binmode") }
|
||||
sub pp_untie { unop(@_, "untie") }
|
||||
sub pp_tied { unop(@_, "tied") }
|
||||
sub pp_dbmclose { unop(@_, "dbmclose") }
|
||||
@ -1373,11 +1398,14 @@ sub logop {
|
||||
my ($op, $cx, $lowop, $lowprec, $highop, $highprec, $blockname) = @_;
|
||||
my $left = $op->first;
|
||||
my $right = $op->first->sibling;
|
||||
if ($cx == 0 and is_scope($right) and $blockname) { # if ($a) {$b}
|
||||
if ($cx == 0 and is_scope($right) and $blockname
|
||||
and $self->{'expand'} < 7)
|
||||
{ # if ($a) {$b}
|
||||
$left = $self->deparse($left, 1);
|
||||
$right = $self->deparse($right, 0);
|
||||
return "$blockname ($left) {\n\t$right\n\b}\cK";
|
||||
} elsif ($cx == 0 and $blockname and not $self->{'parens'}) { # $b if $a
|
||||
} elsif ($cx == 0 and $blockname and not $self->{'parens'}
|
||||
and $self->{'expand'} < 7) { # $b if $a
|
||||
$right = $self->deparse($right, 1);
|
||||
$left = $self->deparse($left, 1);
|
||||
return "$right $blockname $left";
|
||||
@ -1457,6 +1485,7 @@ sub pp_return { listop(@_, "return") }
|
||||
sub pp_open { listop(@_, "open") }
|
||||
sub pp_pipe_op { listop(@_, "pipe") }
|
||||
sub pp_tie { listop(@_, "tie") }
|
||||
sub pp_binmode { listop(@_, "binmode") }
|
||||
sub pp_dbmopen { listop(@_, "dbmopen") }
|
||||
sub pp_sselect { listop(@_, "select") }
|
||||
sub pp_select { listop(@_, "select") }
|
||||
@ -1653,6 +1682,13 @@ sub pp_list {
|
||||
}
|
||||
}
|
||||
|
||||
sub is_ifelse_cont {
|
||||
my $op = shift;
|
||||
return ($op->name eq "null" and class($op) eq "UNOP"
|
||||
and $op->first->name =~ /^(and|cond_expr)$/
|
||||
and is_scope($op->first->first->sibling));
|
||||
}
|
||||
|
||||
sub pp_cond_expr {
|
||||
my $self = shift;
|
||||
my($op, $cx) = @_;
|
||||
@ -1660,52 +1696,55 @@ sub pp_cond_expr {
|
||||
my $true = $cond->sibling;
|
||||
my $false = $true->sibling;
|
||||
my $cuddle = $self->{'cuddle'};
|
||||
unless ($cx == 0 and is_scope($true) and is_scope($false)) {
|
||||
unless ($cx == 0 and (is_scope($true) and $true->name ne "null") and
|
||||
(is_scope($false) || is_ifelse_cont($false))
|
||||
and $self->{'expand'} < 7) {
|
||||
$cond = $self->deparse($cond, 8);
|
||||
$true = $self->deparse($true, 8);
|
||||
$false = $self->deparse($false, 8);
|
||||
return $self->maybe_parens("$cond ? $true : $false", $cx, 8);
|
||||
}
|
||||
}
|
||||
|
||||
$cond = $self->deparse($cond, 1);
|
||||
$true = $self->deparse($true, 0);
|
||||
if ($false->name eq "lineseq") { # braces w/o scope => elsif
|
||||
my $head = "if ($cond) {\n\t$true\n\b}";
|
||||
my @elsifs;
|
||||
while (!null($false) and $false->name eq "lineseq") {
|
||||
my $newop = $false->first->sibling->first;
|
||||
my $newcond = $newop->first;
|
||||
my $newtrue = $newcond->sibling;
|
||||
$false = $newtrue->sibling; # last in chain is OP_AND => no else
|
||||
$newcond = $self->deparse($newcond, 1);
|
||||
$newtrue = $self->deparse($newtrue, 0);
|
||||
push @elsifs, "elsif ($newcond) {\n\t$newtrue\n\b}";
|
||||
}
|
||||
if (!null($false)) {
|
||||
$false = $cuddle . "else {\n\t" .
|
||||
$self->deparse($false, 0) . "\n\b}\cK";
|
||||
} else {
|
||||
$false = "\cK";
|
||||
}
|
||||
return $head . join($cuddle, "", @elsifs) . $false;
|
||||
my $head = "if ($cond) {\n\t$true\n\b}";
|
||||
my @elsifs;
|
||||
while (!null($false) and is_ifelse_cont($false)) {
|
||||
my $newop = $false->first;
|
||||
my $newcond = $newop->first;
|
||||
my $newtrue = $newcond->sibling;
|
||||
$false = $newtrue->sibling; # last in chain is OP_AND => no else
|
||||
$newcond = $self->deparse($newcond, 1);
|
||||
$newtrue = $self->deparse($newtrue, 0);
|
||||
push @elsifs, "elsif ($newcond) {\n\t$newtrue\n\b}";
|
||||
}
|
||||
$false = $self->deparse($false, 0);
|
||||
return "if ($cond) {\n\t$true\n\b}${cuddle}else {\n\t$false\n\b}\cK";
|
||||
if (!null($false)) {
|
||||
$false = $cuddle . "else {\n\t" .
|
||||
$self->deparse($false, 0) . "\n\b}\cK";
|
||||
} else {
|
||||
$false = "\cK";
|
||||
}
|
||||
return $head . join($cuddle, "", @elsifs) . $false;
|
||||
}
|
||||
|
||||
sub pp_leaveloop {
|
||||
sub loop_common {
|
||||
my $self = shift;
|
||||
my($op, $cx) = @_;
|
||||
my($op, $cx, $init) = @_;
|
||||
my $enter = $op->first;
|
||||
my $kid = $enter->sibling;
|
||||
local($self->{'curstash'}) = $self->{'curstash'};
|
||||
my $head = "";
|
||||
my $bare = 0;
|
||||
my $body;
|
||||
my $cond = undef;
|
||||
if ($kid->name eq "lineseq") { # bare or infinite loop
|
||||
if (is_state $kid->last) { # infinite
|
||||
$head = "for (;;) "; # shorter than while (1)
|
||||
$cond = "";
|
||||
} else {
|
||||
$bare = 1;
|
||||
}
|
||||
$body = $kid;
|
||||
} elsif ($enter->name eq "enteriter") { # foreach
|
||||
my $ary = $enter->first->sibling; # first was pushmark
|
||||
my $var = $ary->sibling;
|
||||
@ -1737,62 +1776,60 @@ sub pp_leaveloop {
|
||||
$var = "\$" . $self->deparse($var, 1);
|
||||
}
|
||||
$head = "foreach $var ($ary) ";
|
||||
$kid = $kid->first->first->sibling; # skip OP_AND and OP_ITER
|
||||
$body = $kid->first->first->sibling; # skip OP_AND and OP_ITER
|
||||
} elsif ($kid->name eq "null") { # while/until
|
||||
$kid = $kid->first;
|
||||
my $name = {"and" => "while", "or" => "until"}
|
||||
->{$kid->name};
|
||||
$head = "$name (" . $self->deparse($kid->first, 1) . ") ";
|
||||
$kid = $kid->first->sibling;
|
||||
my $name = {"and" => "while", "or" => "until"}->{$kid->name};
|
||||
$cond = $self->deparse($kid->first, 1);
|
||||
$head = "$name ($cond) ";
|
||||
$body = $kid->first->sibling;
|
||||
} elsif ($kid->name eq "stub") { # bare and empty
|
||||
return "{;}"; # {} could be a hashref
|
||||
}
|
||||
# The third-to-last kid is the continue block if the pointer used
|
||||
# by `next BLOCK' points to its first OP, which happens to be the
|
||||
# the op_next of the head of the _previous_ statement.
|
||||
# Unless it's a bare loop, in which case it's last, since there's
|
||||
# no unstack or extra nextstate.
|
||||
# Except if the previous head isn't null but the first kid is
|
||||
# (because it's a nulled out nextstate in a scope), in which
|
||||
# case the head's next is advanced past the null but the nextop's
|
||||
# isn't, so we need to try nextop->next.
|
||||
my $precont;
|
||||
my $cont = $kid->first;
|
||||
if ($bare) {
|
||||
while (!null($cont->sibling)) {
|
||||
$precont = $cont;
|
||||
$cont = $cont->sibling;
|
||||
}
|
||||
} else {
|
||||
while (!null($cont->sibling->sibling->sibling)) {
|
||||
$precont = $cont;
|
||||
$cont = $cont->sibling;
|
||||
# If there isn't a continue block, then the next pointer for the loop
|
||||
# will point to the unstack, which is kid's penultimate child, except
|
||||
# in a bare loop, when it will point to the leaveloop. When neither of
|
||||
# these conditions hold, then the third-to-last child in the continue
|
||||
# block (or the last in a bare loop).
|
||||
my $cont_start = $enter->nextop;
|
||||
my $cont;
|
||||
if ($$cont_start != $$op and $ {$cont_start->sibling} != $ {$body->last}) {
|
||||
if ($bare) {
|
||||
$cont = $body->last;
|
||||
} else {
|
||||
$cont = $body->first;
|
||||
while (!null($cont->sibling->sibling->sibling)) {
|
||||
$cont = $cont->sibling;
|
||||
}
|
||||
}
|
||||
my $state = $body->first;
|
||||
my $cuddle = $self->{'cuddle'};
|
||||
my @states;
|
||||
for (; $$state != $$cont; $state = $state->sibling) {
|
||||
push @states, $state;
|
||||
}
|
||||
$body = $self->lineseq(@states);
|
||||
if (defined $cond and not is_scope $cont and $self->{'expand'} < 3) {
|
||||
$head = "for ($init; $cond; " . $self->deparse($cont, 1) .") ";
|
||||
$cont = "\cK";
|
||||
} else {
|
||||
$cont = $cuddle . "continue {\n\t" .
|
||||
$self->deparse($cont, 0) . "\n\b}\cK";
|
||||
}
|
||||
}
|
||||
if ($precont and $ {$precont->next} == $ {$enter->nextop}
|
||||
|| $ {$precont->next} == $ {$enter->nextop->next} )
|
||||
{
|
||||
my $state = $kid->first;
|
||||
my $cuddle = $self->{'cuddle'};
|
||||
my($expr, @exprs);
|
||||
for (; $$state != $$cont; $state = $state->sibling) {
|
||||
$expr = "";
|
||||
if (is_state $state) {
|
||||
$expr = $self->deparse($state, 0);
|
||||
$state = $state->sibling;
|
||||
last if null $kid;
|
||||
}
|
||||
$expr .= $self->deparse($state, 0);
|
||||
push @exprs, $expr if $expr;
|
||||
}
|
||||
$kid = join(";\n", @exprs);
|
||||
$cont = $cuddle . "continue {\n\t" .
|
||||
$self->deparse($cont, 0) . "\n\b}\cK";
|
||||
} else {
|
||||
$cont = "\cK";
|
||||
$kid = $self->deparse($kid, 0);
|
||||
$body = $self->deparse($body, 0);
|
||||
}
|
||||
return $head . "{\n\t" . $kid . "\n\b}" . $cont;
|
||||
return $head . "{\n\t" . $body . "\n\b}" . $cont;
|
||||
}
|
||||
|
||||
sub pp_leaveloop { loop_common(@_, "") }
|
||||
|
||||
sub for_loop {
|
||||
my $self = shift;
|
||||
my($op, $cx) = @_;
|
||||
my $init = $self->deparse($op, 1);
|
||||
return $self->loop_common($op->sibling, $cx, $init);
|
||||
}
|
||||
|
||||
sub pp_leavetry {
|
||||
@ -1814,7 +1851,7 @@ sub pp_null {
|
||||
} elsif ($op->first->name eq "enter") {
|
||||
return $self->pp_leave($op, $cx);
|
||||
} elsif ($op->targ == OP_STRINGIFY) {
|
||||
return $self->dquote($op);
|
||||
return $self->dquote($op, $cx);
|
||||
} elsif (!null($op->first->sibling) and
|
||||
$op->first->sibling->name eq "readline" and
|
||||
$op->first->sibling->flags & OPf_STACKED) {
|
||||
@ -1832,21 +1869,10 @@ sub pp_null {
|
||||
}
|
||||
}
|
||||
|
||||
# the aassign in-common check messes up SvCUR (always setting it
|
||||
# to a value >= 100), but it's probably safe to assume there
|
||||
# won't be any NULs in the names of my() variables. (with
|
||||
# stash variables, I wouldn't be so sure)
|
||||
sub padname_fix {
|
||||
my $str = shift;
|
||||
$str = substr($str, 0, index($str, "\0")) if index($str, "\0") != -1;
|
||||
return $str;
|
||||
}
|
||||
|
||||
sub padname {
|
||||
my $self = shift;
|
||||
my $targ = shift;
|
||||
my $str = $self->padname_sv($targ)->PV;
|
||||
return padname_fix($str);
|
||||
return $self->padname_sv($targ)->PVX;
|
||||
}
|
||||
|
||||
sub padany {
|
||||
@ -1879,37 +1905,34 @@ sub pp_threadsv {
|
||||
return $self->maybe_local($op, $cx, "\$" . $threadsv_names[$op->targ]);
|
||||
}
|
||||
|
||||
sub maybe_padgv {
|
||||
sub gv_or_padgv {
|
||||
my $self = shift;
|
||||
my $op = shift;
|
||||
my $gv;
|
||||
if ($Config{useithreads}) {
|
||||
$gv = $self->padval($op->padix);
|
||||
if (class($op) eq "PADOP") {
|
||||
return $self->padval($op->padix);
|
||||
} else { # class($op) eq "SVOP"
|
||||
return $op->gv;
|
||||
}
|
||||
else {
|
||||
$gv = $op->gv;
|
||||
}
|
||||
return $gv;
|
||||
}
|
||||
|
||||
sub pp_gvsv {
|
||||
my $self = shift;
|
||||
my($op, $cx) = @_;
|
||||
my $gv = $self->maybe_padgv($op);
|
||||
my $gv = $self->gv_or_padgv($op);
|
||||
return $self->maybe_local($op, $cx, "\$" . $self->gv_name($gv));
|
||||
}
|
||||
|
||||
sub pp_gv {
|
||||
my $self = shift;
|
||||
my($op, $cx) = @_;
|
||||
my $gv = $self->maybe_padgv($op);
|
||||
my $gv = $self->gv_or_padgv($op);
|
||||
return $self->gv_name($gv);
|
||||
}
|
||||
|
||||
sub pp_aelemfast {
|
||||
my $self = shift;
|
||||
my($op, $cx) = @_;
|
||||
my $gv = $self->maybe_padgv($op);
|
||||
my $gv = $self->gv_or_padgv($op);
|
||||
return "\$" . $self->gv_name($gv) . "[" . $op->private . "]";
|
||||
}
|
||||
|
||||
@ -2220,7 +2243,7 @@ sub pp_entersub {
|
||||
$amper = "&";
|
||||
$kid = "{" . $self->deparse($kid, 0) . "}";
|
||||
} elsif ($kid->first->name eq "gv") {
|
||||
my $gv = $self->maybe_padgv($kid->first);
|
||||
my $gv = $self->gv_or_padgv($kid->first);
|
||||
if (class($gv->CV) ne "SPECIAL") {
|
||||
$proto = $gv->CV->PV if $gv->CV->FLAGS & SVf_POK;
|
||||
}
|
||||
@ -2252,9 +2275,9 @@ sub pp_entersub {
|
||||
} else {
|
||||
if (defined $proto and $proto eq "") {
|
||||
return $kid;
|
||||
} elsif ($proto eq "\$") {
|
||||
} elsif (defined $proto and $proto eq "\$") {
|
||||
return $self->maybe_parens_func($kid, $args, $cx, 16);
|
||||
} elsif ($proto or $simple) {
|
||||
} elsif (defined($proto) && $proto or $simple) {
|
||||
return $self->maybe_parens_func($kid, $args, $cx, 5);
|
||||
} else {
|
||||
return "$kid(" . $args . ")";
|
||||
@ -2350,7 +2373,7 @@ sub const {
|
||||
if (class($sv) eq "SPECIAL") {
|
||||
return ('undef', '1', '0')[$$sv-1]; # sv_undef, sv_yes, sv_no
|
||||
} elsif ($sv->FLAGS & SVf_IOK) {
|
||||
return $sv->IV;
|
||||
return $sv->int_value;
|
||||
} elsif ($sv->FLAGS & SVf_NOK) {
|
||||
return $sv->NV;
|
||||
} elsif ($sv->FLAGS & SVf_ROK) {
|
||||
@ -2381,7 +2404,9 @@ sub pp_const {
|
||||
# return $self->const_sv($op)->PV;
|
||||
# }
|
||||
my $sv = $self->const_sv($op);
|
||||
return const($sv);
|
||||
# return const($sv);
|
||||
my $c = const $sv;
|
||||
return $c =~ /^-\d/ ? $self->maybe_parens($c, $cx, 21) : $c;
|
||||
}
|
||||
|
||||
sub dq {
|
||||
@ -2391,7 +2416,13 @@ sub dq {
|
||||
if ($type eq "const") {
|
||||
return uninterp(escape_str(unback($self->const_sv($op)->PV)));
|
||||
} elsif ($type eq "concat") {
|
||||
return $self->dq($op->first) . $self->dq($op->last);
|
||||
my $first = $self->dq($op->first);
|
||||
my $last = $self->dq($op->last);
|
||||
# Disambiguate "${foo}bar", "${foo}{bar}", "${foo}[1]"
|
||||
if ($last =~ /^[{\[\w]/) {
|
||||
$first =~ s/([%\$@])([A-Za-z_]\w*)$/${1}{$2}/;
|
||||
}
|
||||
return $first . $last;
|
||||
} elsif ($type eq "uc") {
|
||||
return '\U' . $self->dq($op->first->sibling) . '\E';
|
||||
} elsif ($type eq "lc") {
|
||||
@ -2418,7 +2449,7 @@ sub pp_backtick {
|
||||
|
||||
sub dquote {
|
||||
my $self = shift;
|
||||
my($op, $cx) = shift;
|
||||
my($op, $cx) = @_;
|
||||
my $kid = $op->first->sibling; # skip ex-stringify, pushmark
|
||||
return $self->deparse($kid, $cx) if $self->{'unquote'};
|
||||
$self->maybe_targmy($kid, $cx,
|
||||
@ -2486,7 +2517,7 @@ sub pchr { # ASCII
|
||||
|
||||
sub collapse {
|
||||
my(@chars) = @_;
|
||||
my($c, $str, $tr);
|
||||
my($str, $c, $tr) = ("");
|
||||
for ($c = 0; $c < @chars; $c++) {
|
||||
$tr = $chars[$c];
|
||||
$str .= pchr($tr);
|
||||
@ -2539,7 +2570,7 @@ sub tr_decode_byte {
|
||||
}
|
||||
@from = @newfrom;
|
||||
}
|
||||
unless ($flags & OPpTRANS_DELETE) {
|
||||
unless ($flags & OPpTRANS_DELETE || !@to) {
|
||||
pop @to while $#to and $to[$#to] == $to[$#to -1];
|
||||
}
|
||||
my($from, $to);
|
||||
@ -2678,9 +2709,15 @@ sub re_dq {
|
||||
my $op = shift;
|
||||
my $type = $op->name;
|
||||
if ($type eq "const") {
|
||||
return uninterp($self->const_sv($op)->PV);
|
||||
return re_uninterp($self->const_sv($op)->PV);
|
||||
} elsif ($type eq "concat") {
|
||||
return $self->re_dq($op->first) . $self->re_dq($op->last);
|
||||
my $first = $self->re_dq($op->first);
|
||||
my $last = $self->re_dq($op->last);
|
||||
# Disambiguate "${foo}bar", "${foo}{bar}", "${foo}[1]"
|
||||
if ($last =~ /^[{\[\w]/) {
|
||||
$first =~ s/([%\$@])([A-Za-z_]\w*)$/${1}{$2}/;
|
||||
}
|
||||
return $first . $last;
|
||||
} elsif ($type eq "uc") {
|
||||
return '\U' . $self->re_dq($op->first->sibling) . '\E';
|
||||
} elsif ($type eq "lc") {
|
||||
@ -2842,8 +2879,8 @@ B::Deparse - Perl compiler backend to produce perl code
|
||||
|
||||
=head1 SYNOPSIS
|
||||
|
||||
B<perl> B<-MO=Deparse>[B<,-u>I<PACKAGE>][B<,-p>][B<,-q>][B<,-l>][B<,-s>I<LETTERS>]
|
||||
I<prog.pl>
|
||||
B<perl> B<-MO=Deparse>[B<,-u>I<PACKAGE>][B<,-p>][B<,-q>][B<,-l>]
|
||||
[B<,-s>I<LETTERS>][B<,-x>I<LEVEL>] I<prog.pl>
|
||||
|
||||
=head1 DESCRIPTION
|
||||
|
||||
@ -2988,6 +3025,55 @@ file is compiled as a main program.
|
||||
|
||||
=back
|
||||
|
||||
=item B<-x>I<LEVEL>
|
||||
|
||||
Expand conventional syntax constructions into equivalent ones that expose
|
||||
their internal operation. I<LEVEL> should be a digit, with higher values
|
||||
meaning more expansion. As with B<-q>, this actually involves turning off
|
||||
special cases in B::Deparse's normal operations.
|
||||
|
||||
If I<LEVEL> is at least 3, for loops will be translated into equivalent
|
||||
while loops with continue blocks; for instance
|
||||
|
||||
for ($i = 0; $i < 10; ++$i) {
|
||||
print $i;
|
||||
}
|
||||
|
||||
turns into
|
||||
|
||||
$i = 0;
|
||||
while ($i < 10) {
|
||||
print $i;
|
||||
} continue {
|
||||
++$i
|
||||
}
|
||||
|
||||
Note that in a few cases this translation can't be perfectly carried back
|
||||
into the source code -- if the loop's initializer declares a my variable,
|
||||
for instance, it won't have the correct scope outside of the loop.
|
||||
|
||||
If I<LEVEL> is at least 7, if statements will be translated into equivalent
|
||||
expressions using C<&&>, C<?:> and C<do {}>; for instance
|
||||
|
||||
print 'hi' if $nice;
|
||||
if ($nice) {
|
||||
print 'hi';
|
||||
}
|
||||
if ($nice) {
|
||||
print 'hi';
|
||||
} else {
|
||||
print 'bye';
|
||||
}
|
||||
|
||||
turns into
|
||||
|
||||
$nice and print 'hi';
|
||||
$nice and do { print 'hi' };
|
||||
$nice ? do { print 'hi' } : do { print 'bye' };
|
||||
|
||||
Long sequences of elsifs will turn into nested ternary operators, which
|
||||
B::Deparse doesn't know how to indent nicely.
|
||||
|
||||
=back
|
||||
|
||||
=head1 USING B::Deparse AS A MODULE
|
||||
@ -3034,7 +3120,7 @@ See the 'to do' list at the beginning of the module file.
|
||||
|
||||
=head1 AUTHOR
|
||||
|
||||
Stephen McCamant <smccam@uclink4.berkeley.edu>, based on an earlier
|
||||
Stephen McCamant <smcc@CSUA.Berkeley.EDU>, based on an earlier
|
||||
version by Malcolm Beattie <mbeattie@sable.ox.ac.uk>, with
|
||||
contributions from Gisle Aas, James Duncan, Albert Dvornik, Hugo van
|
||||
der Sanden, Gurusamy Sarathy, and Nick Ing-Simmons.
|
||||
|
@ -31,6 +31,13 @@ sub GET_U16 {
|
||||
return unpack("n", $str);
|
||||
}
|
||||
|
||||
sub GET_NV {
|
||||
my $fh = shift;
|
||||
my $str = $fh->readn(8);
|
||||
croak "reached EOF while reading NV" unless length($str) == 8;
|
||||
return unpack("N", $str);
|
||||
}
|
||||
|
||||
sub GET_U32 {
|
||||
my $fh = shift;
|
||||
my $str = $fh->readn(4);
|
||||
|
@ -116,7 +116,7 @@ Malcolm Beattie, mbeattie@sable.ox.ac.uk.
|
||||
=cut
|
||||
|
||||
use strict;
|
||||
use B qw(walkoptree_slow main_root walksymtable svref_2object parents
|
||||
use B qw(walkoptree main_root walksymtable svref_2object parents
|
||||
OPf_WANT_LIST OPf_WANT OPf_STACKED G_ARRAY
|
||||
);
|
||||
|
||||
@ -277,12 +277,12 @@ sub B::GV::lintcv {
|
||||
return if !$$cv || $done_cv{$$cv}++;
|
||||
my $root = $cv->ROOT;
|
||||
#warn " root = $root (0x$$root)\n";#debug
|
||||
walkoptree_slow($root, "lint") if $$root;
|
||||
walkoptree($root, "lint") if $$root;
|
||||
}
|
||||
|
||||
sub do_lint {
|
||||
my %search_pack;
|
||||
walkoptree_slow(main_root, "lint") if ${main_root()};
|
||||
walkoptree(main_root, "lint") if ${main_root()};
|
||||
|
||||
# Now do subs in main
|
||||
no strict qw(vars refs);
|
||||
|
@ -12,7 +12,24 @@ use B::Terse ();
|
||||
# to see the names of file scope lexicals used by bar.pl
|
||||
#
|
||||
|
||||
sub showarray {
|
||||
sub shownamearray {
|
||||
my ($name, $av) = @_;
|
||||
my @els = $av->ARRAY;
|
||||
my $count = @els;
|
||||
my $i;
|
||||
print "$name has $count entries\n";
|
||||
for ($i = 0; $i < $count; $i++) {
|
||||
print "$i: ";
|
||||
my $sv = $els[$i];
|
||||
if (class($sv) ne "SPECIAL") {
|
||||
printf "%s (0x%lx) %s\n", class($sv), $$sv, $sv->PVX;
|
||||
} else {
|
||||
$sv->terse;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
sub showvaluearray {
|
||||
my ($name, $av) = @_;
|
||||
my @els = $av->ARRAY;
|
||||
my $count = @els;
|
||||
@ -26,8 +43,8 @@ sub showarray {
|
||||
|
||||
sub showlex {
|
||||
my ($objname, $namesav, $valsav) = @_;
|
||||
showarray("Pad of lexical names for $objname", $namesav);
|
||||
showarray("Pad of lexical values for $objname", $valsav);
|
||||
shownamearray("Pad of lexical names for $objname", $namesav);
|
||||
showvaluearray("Pad of lexical values for $objname", $valsav);
|
||||
}
|
||||
|
||||
sub showlex_obj {
|
||||
|
@ -2,11 +2,19 @@
|
||||
# vishalb@hotmail.com
|
||||
package B::Stash;
|
||||
|
||||
=pod
|
||||
|
||||
=head1 NAME
|
||||
|
||||
B::Stash - show what stashes are loaded
|
||||
|
||||
=cut
|
||||
|
||||
BEGIN { %Seen = %INC }
|
||||
|
||||
CHECK {
|
||||
my @arr=scan($main::{"main::"});
|
||||
@arr=map{s/\:\:$//;$_;} @arr;
|
||||
@arr=map{s/\:\:$//;$_ eq "<none>"?():$_;} @arr;
|
||||
print "-umain,-u", join (",-u",@arr) ,"\n";
|
||||
}
|
||||
sub scan{
|
||||
|
@ -1,7 +1,7 @@
|
||||
package B::Terse;
|
||||
use strict;
|
||||
use B qw(peekop class walkoptree_slow walkoptree_exec
|
||||
main_start main_root cstring svref_2object);
|
||||
use B qw(peekop class walkoptree walkoptree_exec walkoptree_slow
|
||||
main_start main_root cstring svref_2object SVf_IVisUV);
|
||||
use B::Asmdata qw(@specialsv_name);
|
||||
|
||||
sub terse {
|
||||
@ -15,7 +15,7 @@ sub terse {
|
||||
}
|
||||
|
||||
sub compile {
|
||||
my $order = shift;
|
||||
my $order = @_ ? shift : "";
|
||||
my @options = @_;
|
||||
B::clearsym();
|
||||
if (@options) {
|
||||
@ -37,7 +37,7 @@ sub compile {
|
||||
}
|
||||
|
||||
sub indent {
|
||||
my $level = shift;
|
||||
my $level = @_ ? shift : 0;
|
||||
return " " x $level;
|
||||
}
|
||||
|
||||
@ -102,13 +102,14 @@ sub B::GV::terse {
|
||||
$stash = $stash . "::";
|
||||
}
|
||||
print indent($level);
|
||||
printf "%s (0x%lx) *%s%s\n", class($gv), $$gv, $stash, $gv->NAME;
|
||||
printf "%s (0x%lx) *%s%s\n", class($gv), $$gv, $stash, $gv->SAFENAME;
|
||||
}
|
||||
|
||||
sub B::IV::terse {
|
||||
my ($sv, $level) = @_;
|
||||
print indent($level);
|
||||
printf "%s (0x%lx) %d\n", class($sv), $$sv, $sv->IV;
|
||||
my $v = $sv->FLAGS & SVf_IVisUV ? "%u" : "%d";
|
||||
printf "%s (0x%lx) $v\n", class($sv), $$sv, $sv->int_value;
|
||||
}
|
||||
|
||||
sub B::NV::terse {
|
||||
|
@ -1,5 +1,6 @@
|
||||
use ExtUtils::MakeMaker;
|
||||
use Config;
|
||||
use File::Spec;
|
||||
|
||||
my $e = $Config{'exe_ext'};
|
||||
my $o = $Config{'obj_ext'};
|
||||
@ -29,8 +30,19 @@ sub post_constants {
|
||||
"\nLIBS = $Config::Config{libs}\n"
|
||||
}
|
||||
|
||||
sub postamble {
|
||||
'
|
||||
B$(OBJ_EXT) : defsubs.h
|
||||
'
|
||||
sub upupfile {
|
||||
File::Spec->catfile(File::Spec->updir,
|
||||
File::Spec->updir, $_[0]);
|
||||
}
|
||||
|
||||
sub MY::postamble {
|
||||
my $op_h = upupfile('op.h');
|
||||
my $cop_h = upupfile('cop.h');
|
||||
my $noecho = shift->{NOECHO};
|
||||
"
|
||||
B\$(OBJ_EXT) : defsubs.h
|
||||
|
||||
defsubs.h :: $op_h $cop_h
|
||||
$noecho \$(NOOP)
|
||||
"
|
||||
}
|
||||
|
@ -1,5 +1,5 @@
|
||||
package O;
|
||||
use B qw(minus_c);
|
||||
use B qw(minus_c save_BEGINs);
|
||||
use Carp;
|
||||
|
||||
sub import {
|
||||
@ -11,6 +11,7 @@ sub import {
|
||||
my $compilesub = &{"B::${backend}::compile"}(@options);
|
||||
if (ref($compilesub) eq "CODE") {
|
||||
minus_c;
|
||||
save_BEGINs;
|
||||
eval 'CHECK { &$compilesub() }';
|
||||
} else {
|
||||
die $compilesub;
|
||||
|
@ -6,16 +6,23 @@ my ($out) = __FILE__ =~ /(^.*)\.PL/i;
|
||||
$out =~ s/_h$/.h/;
|
||||
open(OUT,">$out") || die "Cannot open $file:$!";
|
||||
print "Extracting $out...\n";
|
||||
foreach my $const (qw(AVf_REAL
|
||||
foreach my $const (qw(
|
||||
AVf_REAL
|
||||
HEf_SVKEY
|
||||
SVf_READONLY SVTYPEMASK
|
||||
GVf_IMPORTED_AV GVf_IMPORTED_HV
|
||||
GVf_IMPORTED_SV GVf_IMPORTED_CV
|
||||
CVf_METHOD CVf_LOCKED CVf_LVALUE
|
||||
SVf_IOK SVf_IVisUV SVf_NOK SVf_POK
|
||||
SVf_ROK SVp_IOK SVp_POK ))
|
||||
SVf_ROK SVp_IOK SVp_POK SVp_NOK
|
||||
))
|
||||
{
|
||||
doconst($const);
|
||||
}
|
||||
foreach my $file (qw(op.h cop.h))
|
||||
{
|
||||
open(OPH,"../../$file") || die "Cannot open ../../$file:$!";
|
||||
my $path = $^O eq 'MacOS' ? ":::$file" : "../../$file";
|
||||
open(OPH,"$path") || die "Cannot open $path:$!";
|
||||
while (<OPH>)
|
||||
{
|
||||
doconst($1) if (/#define\s+(\w+)\s+([\(\)\|\dx]+)\s*(?:$|\/\*)/);
|
||||
|
@ -9,13 +9,13 @@ PP(pp_range)
|
||||
}
|
||||
|
||||
pp_range is a LOGOP.
|
||||
In array context, it just returns op_next.
|
||||
In list context, it just returns op_next.
|
||||
In scalar context it checks the truth of targ and returns
|
||||
op_other if true, op_next if false.
|
||||
|
||||
flip is an UNOP.
|
||||
It "looks after" its child which is always a pp_range LOGOP.
|
||||
In array context, it just returns the child's op_other.
|
||||
In list context, it just returns the child's op_other.
|
||||
In scalar context, there are three possible outcomes:
|
||||
(1) set child's targ to 1, our targ to 1 and return op_next.
|
||||
(2) set child's targ to 1, our targ to 0, sp-- and return child's op_other.
|
||||
|
@ -2,7 +2,7 @@ package ByteLoader;
|
||||
|
||||
use XSLoader ();
|
||||
|
||||
$VERSION = 0.03;
|
||||
$VERSION = 0.04;
|
||||
|
||||
XSLoader::load 'ByteLoader', $VERSION;
|
||||
|
||||
@ -17,10 +17,10 @@ ByteLoader - load byte compiled perl code
|
||||
|
||||
=head1 SYNOPSIS
|
||||
|
||||
use ByteLoader 0.03;
|
||||
use ByteLoader 0.04;
|
||||
<byte code>
|
||||
|
||||
use ByteLoader 0.03;
|
||||
use ByteLoader 0.04;
|
||||
<byte code>
|
||||
|
||||
=head1 DESCRIPTION
|
||||
|
@ -4,47 +4,95 @@
|
||||
#include "XSUB.h"
|
||||
#include "byterun.h"
|
||||
|
||||
static int
|
||||
xgetc(PerlIO *io)
|
||||
/* Something arbitary for a buffer size */
|
||||
#define BYTELOADER_BUFFER 8096
|
||||
|
||||
int
|
||||
bl_getc(struct byteloader_fdata *data)
|
||||
{
|
||||
dTHX;
|
||||
return PerlIO_getc(io);
|
||||
if (SvCUR(data->datasv) <= data->next_out) {
|
||||
int result;
|
||||
/* Run out of buffered data, so attempt to read some more */
|
||||
*(SvPV_nolen (data->datasv)) = '\0';
|
||||
SvCUR_set (data->datasv, 0);
|
||||
data->next_out = 0;
|
||||
result = FILTER_READ (data->idx + 1, data->datasv, BYTELOADER_BUFFER);
|
||||
|
||||
/* Filter returned error, or we got EOF and no data, then return EOF.
|
||||
Not sure if filter is allowed to return EOF and add data simultaneously
|
||||
Think not, but will bullet proof against it. */
|
||||
if (result < 0 || SvCUR(data->datasv) == 0)
|
||||
return EOF;
|
||||
/* Else there must be at least one byte present, which is good enough */
|
||||
}
|
||||
|
||||
return *((char *) SvPV_nolen (data->datasv) + data->next_out++);
|
||||
}
|
||||
|
||||
static int
|
||||
xfread(char *buf, size_t size, size_t n, PerlIO *io)
|
||||
int
|
||||
bl_read(struct byteloader_fdata *data, char *buf, size_t size, size_t n)
|
||||
{
|
||||
dTHX;
|
||||
int i = PerlIO_read(io, buf, n * size);
|
||||
if (i > 0)
|
||||
i /= size;
|
||||
return i;
|
||||
}
|
||||
char *start;
|
||||
STRLEN len;
|
||||
size_t wanted = size * n;
|
||||
|
||||
static void
|
||||
freadpv(U32 len, void *data, XPV *pv)
|
||||
{
|
||||
dTHX;
|
||||
New(666, pv->xpv_pv, len, char);
|
||||
PerlIO_read((PerlIO*)data, (void*)pv->xpv_pv, len);
|
||||
pv->xpv_len = len;
|
||||
pv->xpv_cur = len - 1;
|
||||
start = SvPV (data->datasv, len);
|
||||
if (len < (data->next_out + wanted)) {
|
||||
int result;
|
||||
|
||||
/* Shuffle data to start of buffer */
|
||||
len -= data->next_out;
|
||||
if (len) {
|
||||
memmove (start, start + data->next_out, len + 1);
|
||||
SvCUR_set (data->datasv, len);
|
||||
} else {
|
||||
*start = '\0'; /* Avoid call to memmove. */
|
||||
SvCUR_set (data->datasv, 0);
|
||||
}
|
||||
data->next_out = 0;
|
||||
|
||||
/* Attempt to read more data. */
|
||||
do {
|
||||
result = FILTER_READ (data->idx + 1, data->datasv, BYTELOADER_BUFFER);
|
||||
|
||||
start = SvPV (data->datasv, len);
|
||||
} while (result > 0 && len < wanted);
|
||||
/* Loop while not (EOF || error) and short reads */
|
||||
|
||||
/* If not enough data read, truncate copy */
|
||||
if (wanted > len)
|
||||
wanted = len;
|
||||
}
|
||||
|
||||
if (wanted > 0) {
|
||||
memcpy (buf, start + data->next_out, wanted);
|
||||
data->next_out += wanted;
|
||||
wanted /= size;
|
||||
}
|
||||
return (int) wanted;
|
||||
}
|
||||
|
||||
static I32
|
||||
byteloader_filter(pTHXo_ int idx, SV *buf_sv, int maxlen)
|
||||
{
|
||||
dTHR;
|
||||
OP *saveroot = PL_main_root;
|
||||
OP *savestart = PL_main_start;
|
||||
struct bytestream bs;
|
||||
struct byteloader_state bstate;
|
||||
struct byteloader_fdata data;
|
||||
|
||||
bs.data = PL_rsfp;
|
||||
bs.pfgetc = (int(*) (void*))xgetc;
|
||||
bs.pfread = (int(*) (char*,size_t,size_t,void*))xfread;
|
||||
bs.pfreadpv = freadpv;
|
||||
data.next_out = 0;
|
||||
data.datasv = FILTER_DATA(idx);
|
||||
data.idx = idx;
|
||||
|
||||
byterun(aTHXo_ bs);
|
||||
bstate.bs_fdata = &data;
|
||||
bstate.bs_obj_list = Null(void**);
|
||||
bstate.bs_obj_list_fill = -1;
|
||||
bstate.bs_sv = Nullsv;
|
||||
bstate.bs_iv_overflows = 0;
|
||||
|
||||
byterun(aTHXo_ &bstate);
|
||||
|
||||
if (PL_in_eval) {
|
||||
OP *o;
|
||||
@ -70,8 +118,12 @@ PROTOTYPES: ENABLE
|
||||
|
||||
void
|
||||
import(...)
|
||||
PREINIT:
|
||||
SV *sv = newSVpvn ("", 0);
|
||||
PPCODE:
|
||||
filter_add(byteloader_filter, NULL);
|
||||
if (!sv)
|
||||
croak ("Could not allocate ByteLoader buffers");
|
||||
filter_add(byteloader_filter, sv);
|
||||
|
||||
void
|
||||
unimport(...)
|
||||
|
@ -5,29 +5,33 @@ typedef char *op_tr_array;
|
||||
typedef int comment_t;
|
||||
typedef SV *svindex;
|
||||
typedef OP *opindex;
|
||||
typedef char *pvindex;
|
||||
typedef IV IV64;
|
||||
|
||||
#define BGET_FREAD(argp, len, nelem) \
|
||||
bs.pfread((char*)(argp),(len),(nelem),bs.data)
|
||||
#define BGET_FGETC() bs.pfgetc(bs.data)
|
||||
bl_read(bstate->bs_fdata,(char*)(argp),(len),(nelem))
|
||||
#define BGET_FGETC() bl_getc(bstate->bs_fdata)
|
||||
|
||||
#define BGET_U32(arg) \
|
||||
BGET_FREAD(&arg, sizeof(U32), 1); arg = PerlSock_ntohl((U32)arg)
|
||||
BGET_FREAD(&arg, sizeof(U32), 1)
|
||||
#define BGET_I32(arg) \
|
||||
BGET_FREAD(&arg, sizeof(I32), 1); arg = (I32)PerlSock_ntohl((U32)arg)
|
||||
BGET_FREAD(&arg, sizeof(I32), 1)
|
||||
#define BGET_U16(arg) \
|
||||
BGET_FREAD(&arg, sizeof(U16), 1); arg = PerlSock_ntohs((U16)arg)
|
||||
BGET_FREAD(&arg, sizeof(U16), 1)
|
||||
#define BGET_U8(arg) arg = BGET_FGETC()
|
||||
|
||||
#define BGET_PV(arg) STMT_START { \
|
||||
BGET_U32(arg); \
|
||||
if (arg) \
|
||||
bs.pfreadpv(arg, bs.data, &bytecode_pv); \
|
||||
else { \
|
||||
bytecode_pv.xpv_pv = 0; \
|
||||
bytecode_pv.xpv_len = 0; \
|
||||
bytecode_pv.xpv_cur = 0; \
|
||||
} \
|
||||
#define BGET_PV(arg) STMT_START { \
|
||||
BGET_U32(arg); \
|
||||
if (arg) { \
|
||||
New(666, bstate->bs_pv.xpv_pv, arg, char); \
|
||||
bl_read(bstate->bs_fdata, (void*)bstate->bs_pv.xpv_pv, arg, 1); \
|
||||
bstate->bs_pv.xpv_len = arg; \
|
||||
bstate->bs_pv.xpv_cur = arg - 1; \
|
||||
} else { \
|
||||
bstate->bs_pv.xpv_pv = 0; \
|
||||
bstate->bs_pv.xpv_len = 0; \
|
||||
bstate->bs_pv.xpv_cur = 0; \
|
||||
} \
|
||||
} STMT_END
|
||||
|
||||
#ifdef BYTELOADER_LOG_COMMENTS
|
||||
@ -63,22 +67,20 @@ typedef IV IV64;
|
||||
arg = (I32)lo; \
|
||||
} \
|
||||
else { \
|
||||
bytecode_iv_overflows++; \
|
||||
bstate->bs_iv_overflows++; \
|
||||
arg = 0; \
|
||||
} \
|
||||
} STMT_END
|
||||
|
||||
#define BGET_op_tr_array(arg) do { \
|
||||
unsigned short *ary; \
|
||||
int i; \
|
||||
New(666, ary, 256, unsigned short); \
|
||||
BGET_FREAD(ary, 256, 2); \
|
||||
for (i = 0; i < 256; i++) \
|
||||
ary[i] = PerlSock_ntohs(ary[i]); \
|
||||
arg = (char *) ary; \
|
||||
#define BGET_op_tr_array(arg) do { \
|
||||
unsigned short *ary; \
|
||||
int i; \
|
||||
New(666, ary, 256, unsigned short); \
|
||||
BGET_FREAD(ary, sizeof(unsigned short), 256); \
|
||||
arg = (char *) ary; \
|
||||
} while (0)
|
||||
|
||||
#define BGET_pvcontents(arg) arg = bytecode_pv.xpv_pv
|
||||
#define BGET_pvcontents(arg) arg = bstate->bs_pv.xpv_pv
|
||||
#define BGET_strconst(arg) STMT_START { \
|
||||
for (arg = PL_tokenbuf; (*arg = BGET_FGETC()); arg++) /* nothing */; \
|
||||
arg = PL_tokenbuf; \
|
||||
@ -91,14 +93,21 @@ typedef IV IV64;
|
||||
} STMT_END
|
||||
|
||||
#define BGET_objindex(arg, type) STMT_START { \
|
||||
U32 ix; \
|
||||
BGET_U32(ix); \
|
||||
arg = (type)bytecode_obj_list[ix]; \
|
||||
arg = (type)bstate->bs_obj_list[ix]; \
|
||||
} STMT_END
|
||||
#define BGET_svindex(arg) BGET_objindex(arg, svindex)
|
||||
#define BGET_opindex(arg) BGET_objindex(arg, opindex)
|
||||
#define BGET_pvindex(arg) STMT_START { \
|
||||
BGET_objindex(arg, pvindex); \
|
||||
arg = arg ? savepv(arg) : arg; \
|
||||
} STMT_END
|
||||
|
||||
#define BSET_ldspecsv(sv, arg) sv = specialsv_list[arg]
|
||||
#define BSET_stpv(pv, arg) STMT_START { \
|
||||
BSET_OBJ_STORE(pv, arg); \
|
||||
SAVEFREEPV(pv); \
|
||||
} STMT_END
|
||||
|
||||
#define BSET_sv_refcnt_add(svrefcnt, arg) svrefcnt += arg
|
||||
#define BSET_gp_refcnt_add(gprefcnt, arg) gprefcnt += arg
|
||||
@ -110,23 +119,29 @@ typedef IV IV64;
|
||||
#define BSET_gv_fetchpv(sv, arg) sv = (SV*)gv_fetchpv(arg, TRUE, SVt_PV)
|
||||
#define BSET_gv_stashpv(sv, arg) sv = (SV*)gv_stashpv(arg, TRUE)
|
||||
#define BSET_sv_magic(sv, arg) sv_magic(sv, Nullsv, arg, 0, 0)
|
||||
#define BSET_mg_pv(mg, arg) mg->mg_ptr = arg; mg->mg_len = bytecode_pv.xpv_cur
|
||||
#define BSET_mg_pv(mg, arg) mg->mg_ptr = arg; mg->mg_len = bstate->bs_pv.xpv_cur
|
||||
#define BSET_sv_upgrade(sv, arg) (void)SvUPGRADE(sv, arg)
|
||||
#define BSET_xpv(sv) do { \
|
||||
SvPV_set(sv, bytecode_pv.xpv_pv); \
|
||||
SvCUR_set(sv, bytecode_pv.xpv_cur); \
|
||||
SvLEN_set(sv, bytecode_pv.xpv_len); \
|
||||
SvPV_set(sv, bstate->bs_pv.xpv_pv); \
|
||||
SvCUR_set(sv, bstate->bs_pv.xpv_cur); \
|
||||
SvLEN_set(sv, bstate->bs_pv.xpv_len); \
|
||||
} while (0)
|
||||
#define BSET_av_extend(sv, arg) av_extend((AV*)sv, arg)
|
||||
|
||||
#define BSET_av_push(sv, arg) av_push((AV*)sv, arg)
|
||||
#define BSET_hv_store(sv, arg) \
|
||||
hv_store((HV*)sv, bytecode_pv.xpv_pv, bytecode_pv.xpv_cur, arg, 0)
|
||||
hv_store((HV*)sv, bstate->bs_pv.xpv_pv, bstate->bs_pv.xpv_cur, arg, 0)
|
||||
#define BSET_pv_free(pv) Safefree(pv.xpv_pv)
|
||||
#define BSET_pregcomp(o, arg) \
|
||||
((PMOP*)o)->op_pmregexp = arg ? \
|
||||
CALLREGCOMP(aTHX_ arg, arg + bytecode_pv.xpv_cur, ((PMOP*)o)) : 0
|
||||
#define BSET_newsv(sv, arg) sv = NEWSV(666,0); SvUPGRADE(sv, arg)
|
||||
CALLREGCOMP(aTHX_ arg, arg + bstate->bs_pv.xpv_cur, ((PMOP*)o)) : 0
|
||||
#define BSET_newsv(sv, arg) \
|
||||
STMT_START { \
|
||||
sv = (arg == SVt_PVAV ? (SV*)newAV() : \
|
||||
arg == SVt_PVHV ? (SV*)newHV() : \
|
||||
NEWSV(666,0)); \
|
||||
SvUPGRADE(sv, arg); \
|
||||
} STMT_END
|
||||
#define BSET_newop(o, arg) ((o = (OP*)safemalloc(optype_size[arg])), \
|
||||
memzero((char*)o,optype_size[arg]))
|
||||
#define BSET_newopn(o, arg) STMT_START { \
|
||||
@ -135,7 +150,10 @@ typedef IV IV64;
|
||||
oldop->op_next = o; \
|
||||
} STMT_END
|
||||
|
||||
#define BSET_ret(foo) return
|
||||
#define BSET_ret(foo) STMT_START { \
|
||||
Safefree(bstate->bs_obj_list); \
|
||||
return; \
|
||||
} STMT_END
|
||||
|
||||
/*
|
||||
* Kludge special-case workaround for OP_MAPSTART
|
||||
@ -152,10 +170,88 @@ typedef IV IV64;
|
||||
PL_comppad = (AV *)arg; \
|
||||
pad = AvARRAY(arg); \
|
||||
} STMT_END
|
||||
/* this works now that Sarathy's changed the CopFILE_set macro to do the SvREFCNT_inc()
|
||||
-- BKS 6-2-2000 */
|
||||
#define BSET_cop_file(cop, arg) CopFILE_set(cop,arg)
|
||||
#define BSET_cop_line(cop, arg) CopLINE_set(cop,arg)
|
||||
#define BSET_cop_stashpv(cop, arg) CopSTASHPV_set(cop,arg)
|
||||
|
||||
#define BSET_OBJ_STORE(obj, ix) \
|
||||
(I32)ix > bytecode_obj_list_fill ? \
|
||||
bset_obj_store(aTHXo_ obj, (I32)ix) : (bytecode_obj_list[ix] = obj)
|
||||
/* this is simply stolen from the code in newATTRSUB() */
|
||||
#define BSET_push_begin(ary,cv) \
|
||||
STMT_START { \
|
||||
I32 oldscope = PL_scopestack_ix; \
|
||||
ENTER; \
|
||||
SAVECOPFILE(&PL_compiling); \
|
||||
SAVECOPLINE(&PL_compiling); \
|
||||
save_svref(&PL_rs); \
|
||||
sv_setsv(PL_rs, PL_nrs); \
|
||||
if (!PL_beginav) \
|
||||
PL_beginav = newAV(); \
|
||||
av_push(PL_beginav, cv); \
|
||||
call_list(oldscope, PL_beginav); \
|
||||
PL_curcop = &PL_compiling; \
|
||||
PL_compiling.op_private = PL_hints; \
|
||||
LEAVE; \
|
||||
} STMT_END
|
||||
#define BSET_push_init(ary,cv) \
|
||||
STMT_START { \
|
||||
av_unshift((PL_initav ? PL_initav : (PL_initav = newAV(), PL_initav)), 1); \
|
||||
av_store(PL_initav, 0, cv); \
|
||||
} STMT_END
|
||||
#define BSET_push_end(ary,cv) \
|
||||
STMT_START { \
|
||||
av_unshift((PL_endav ? PL_endav : (PL_endav = newAV(), PL_endav)), 1); \
|
||||
av_store(PL_endav, 0, cv); \
|
||||
} STMT_END
|
||||
#define BSET_OBJ_STORE(obj, ix) \
|
||||
(I32)ix > bstate->bs_obj_list_fill ? \
|
||||
bset_obj_store(aTHXo_ bstate, obj, (I32)ix) : (bstate->bs_obj_list[ix] = obj)
|
||||
|
||||
/* NOTE: the bytecode header only sanity-checks the bytecode. If a script cares about
|
||||
* what version of Perl it's being called under, it should do a 'require 5.6.0' or
|
||||
* equivalent. However, since the header includes checks requiring an exact match in
|
||||
* ByteLoader versions (we can't guarantee forward compatibility), you don't
|
||||
* need to specify one:
|
||||
* use ByteLoader;
|
||||
* is all you need.
|
||||
* -- BKS, June 2000
|
||||
*/
|
||||
|
||||
#define HEADER_FAIL(f) \
|
||||
Perl_croak(aTHX_ "Invalid bytecode for this architecture: " f)
|
||||
#define HEADER_FAIL1(f, arg1) \
|
||||
Perl_croak(aTHX_ "Invalid bytecode for this architecture: " f, arg1)
|
||||
#define HEADER_FAIL2(f, arg1, arg2) \
|
||||
Perl_croak(aTHX_ "Invalid bytecode for this architecture: " f, arg1, arg2)
|
||||
|
||||
#define BYTECODE_HEADER_CHECK \
|
||||
STMT_START { \
|
||||
U32 sz = 0; \
|
||||
strconst str; \
|
||||
\
|
||||
BGET_U32(sz); /* Magic: 'PLBC' */ \
|
||||
if (sz != 0x43424c50) { \
|
||||
HEADER_FAIL1("bad magic (want 0x43424c50, got %#x)", (int)sz); \
|
||||
} \
|
||||
BGET_strconst(str); /* archname */ \
|
||||
if (strNE(str, ARCHNAME)) { \
|
||||
HEADER_FAIL2("wrong architecture (want %s, you have %s)",str,ARCHNAME); \
|
||||
} \
|
||||
BGET_strconst(str); /* ByteLoader version */ \
|
||||
if (strNE(str, VERSION)) { \
|
||||
HEADER_FAIL2("mismatched ByteLoader versions (want %s, you have %s)", \
|
||||
str, VERSION); \
|
||||
} \
|
||||
BGET_U32(sz); /* ivsize */ \
|
||||
if (sz != IVSIZE) { \
|
||||
HEADER_FAIL("different IVSIZE"); \
|
||||
} \
|
||||
BGET_U32(sz); /* ptrsize */ \
|
||||
if (sz != PTRSIZE) { \
|
||||
HEADER_FAIL("different PTRSIZE"); \
|
||||
} \
|
||||
BGET_strconst(str); /* byteorder */ \
|
||||
if (strNE(str, STRINGIFY(BYTEORDER))) { \
|
||||
HEADER_FAIL("different byteorder"); \
|
||||
} \
|
||||
} STMT_END
|
||||
|
@ -26,7 +26,7 @@
|
||||
#include "bytecode.h"
|
||||
|
||||
|
||||
static int optype_size[] = {
|
||||
static const int optype_size[] = {
|
||||
sizeof(OP),
|
||||
sizeof(UNOP),
|
||||
sizeof(BINOP),
|
||||
@ -40,38 +40,34 @@ static int optype_size[] = {
|
||||
sizeof(COP)
|
||||
};
|
||||
|
||||
static SV *specialsv_list[4];
|
||||
|
||||
static int bytecode_iv_overflows = 0;
|
||||
static SV *bytecode_sv;
|
||||
static XPV bytecode_pv;
|
||||
static void **bytecode_obj_list;
|
||||
static I32 bytecode_obj_list_fill = -1;
|
||||
|
||||
void *
|
||||
bset_obj_store(pTHXo_ void *obj, I32 ix)
|
||||
bset_obj_store(pTHXo_ struct byteloader_state *bstate, void *obj, I32 ix)
|
||||
{
|
||||
if (ix > bytecode_obj_list_fill) {
|
||||
if (bytecode_obj_list_fill == -1)
|
||||
New(666, bytecode_obj_list, ix + 1, void*);
|
||||
else
|
||||
Renew(bytecode_obj_list, ix + 1, void*);
|
||||
bytecode_obj_list_fill = ix;
|
||||
if (ix > bstate->bs_obj_list_fill) {
|
||||
Renew(bstate->bs_obj_list, ix + 32, void*);
|
||||
bstate->bs_obj_list_fill = ix + 31;
|
||||
}
|
||||
bytecode_obj_list[ix] = obj;
|
||||
bstate->bs_obj_list[ix] = obj;
|
||||
return obj;
|
||||
}
|
||||
|
||||
void
|
||||
byterun(pTHXo_ struct bytestream bs)
|
||||
byterun(pTHXo_ register struct byteloader_state *bstate)
|
||||
{
|
||||
dTHR;
|
||||
int insn;
|
||||
register int insn;
|
||||
U32 ix;
|
||||
SV *specialsv_list[6];
|
||||
|
||||
BYTECODE_HEADER_CHECK; /* croak if incorrect platform */
|
||||
New(666, bstate->bs_obj_list, 32, void*); /* set op objlist */
|
||||
bstate->bs_obj_list_fill = 31;
|
||||
|
||||
specialsv_list[0] = Nullsv;
|
||||
specialsv_list[1] = &PL_sv_undef;
|
||||
specialsv_list[2] = &PL_sv_yes;
|
||||
specialsv_list[3] = &PL_sv_no;
|
||||
specialsv_list[4] = pWARN_ALL;
|
||||
specialsv_list[5] = pWARN_NONE;
|
||||
|
||||
while ((insn = BGET_FGETC()) != EOF) {
|
||||
switch (insn) {
|
||||
@ -95,7 +91,7 @@ byterun(pTHXo_ struct bytestream bs)
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
bytecode_sv = arg;
|
||||
bstate->bs_sv = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_LDOP: /* 2 */
|
||||
@ -109,7 +105,7 @@ byterun(pTHXo_ struct bytestream bs)
|
||||
{
|
||||
U32 arg;
|
||||
BGET_U32(arg);
|
||||
BSET_OBJ_STORE(bytecode_sv, arg);
|
||||
BSET_OBJ_STORE(bstate->bs_sv, arg);
|
||||
break;
|
||||
}
|
||||
case INSN_STOP: /* 4 */
|
||||
@ -119,610 +115,610 @@ byterun(pTHXo_ struct bytestream bs)
|
||||
BSET_OBJ_STORE(PL_op, arg);
|
||||
break;
|
||||
}
|
||||
case INSN_LDSPECSV: /* 5 */
|
||||
case INSN_STPV: /* 5 */
|
||||
{
|
||||
U32 arg;
|
||||
BGET_U32(arg);
|
||||
BSET_stpv(bstate->bs_pv.xpv_pv, arg);
|
||||
break;
|
||||
}
|
||||
case INSN_LDSPECSV: /* 6 */
|
||||
{
|
||||
U8 arg;
|
||||
BGET_U8(arg);
|
||||
BSET_ldspecsv(bytecode_sv, arg);
|
||||
BSET_ldspecsv(bstate->bs_sv, arg);
|
||||
break;
|
||||
}
|
||||
case INSN_NEWSV: /* 6 */
|
||||
case INSN_NEWSV: /* 7 */
|
||||
{
|
||||
U8 arg;
|
||||
BGET_U8(arg);
|
||||
BSET_newsv(bytecode_sv, arg);
|
||||
BSET_newsv(bstate->bs_sv, arg);
|
||||
break;
|
||||
}
|
||||
case INSN_NEWOP: /* 7 */
|
||||
case INSN_NEWOP: /* 8 */
|
||||
{
|
||||
U8 arg;
|
||||
BGET_U8(arg);
|
||||
BSET_newop(PL_op, arg);
|
||||
break;
|
||||
}
|
||||
case INSN_NEWOPN: /* 8 */
|
||||
case INSN_NEWOPN: /* 9 */
|
||||
{
|
||||
U8 arg;
|
||||
BGET_U8(arg);
|
||||
BSET_newopn(PL_op, arg);
|
||||
break;
|
||||
}
|
||||
case INSN_NEWPV: /* 9 */
|
||||
case INSN_NEWPV: /* 11 */
|
||||
{
|
||||
PV arg;
|
||||
BGET_PV(arg);
|
||||
break;
|
||||
}
|
||||
case INSN_PV_CUR: /* 11 */
|
||||
case INSN_PV_CUR: /* 12 */
|
||||
{
|
||||
STRLEN arg;
|
||||
BGET_U32(arg);
|
||||
bytecode_pv.xpv_cur = arg;
|
||||
bstate->bs_pv.xpv_cur = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_PV_FREE: /* 12 */
|
||||
case INSN_PV_FREE: /* 13 */
|
||||
{
|
||||
BSET_pv_free(bytecode_pv);
|
||||
BSET_pv_free(bstate->bs_pv);
|
||||
break;
|
||||
}
|
||||
case INSN_SV_UPGRADE: /* 13 */
|
||||
case INSN_SV_UPGRADE: /* 14 */
|
||||
{
|
||||
char arg;
|
||||
BGET_U8(arg);
|
||||
BSET_sv_upgrade(bytecode_sv, arg);
|
||||
BSET_sv_upgrade(bstate->bs_sv, arg);
|
||||
break;
|
||||
}
|
||||
case INSN_SV_REFCNT: /* 14 */
|
||||
case INSN_SV_REFCNT: /* 15 */
|
||||
{
|
||||
U32 arg;
|
||||
BGET_U32(arg);
|
||||
SvREFCNT(bytecode_sv) = arg;
|
||||
SvREFCNT(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_SV_REFCNT_ADD: /* 15 */
|
||||
case INSN_SV_REFCNT_ADD: /* 16 */
|
||||
{
|
||||
I32 arg;
|
||||
BGET_I32(arg);
|
||||
BSET_sv_refcnt_add(SvREFCNT(bytecode_sv), arg);
|
||||
BSET_sv_refcnt_add(SvREFCNT(bstate->bs_sv), arg);
|
||||
break;
|
||||
}
|
||||
case INSN_SV_FLAGS: /* 16 */
|
||||
case INSN_SV_FLAGS: /* 17 */
|
||||
{
|
||||
U32 arg;
|
||||
BGET_U32(arg);
|
||||
SvFLAGS(bytecode_sv) = arg;
|
||||
SvFLAGS(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XRV: /* 17 */
|
||||
case INSN_XRV: /* 18 */
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
SvRV(bytecode_sv) = arg;
|
||||
SvRV(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XPV: /* 18 */
|
||||
case INSN_XPV: /* 19 */
|
||||
{
|
||||
BSET_xpv(bytecode_sv);
|
||||
BSET_xpv(bstate->bs_sv);
|
||||
break;
|
||||
}
|
||||
case INSN_XIV32: /* 19 */
|
||||
case INSN_XIV32: /* 20 */
|
||||
{
|
||||
I32 arg;
|
||||
BGET_I32(arg);
|
||||
SvIVX(bytecode_sv) = arg;
|
||||
SvIVX(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XIV64: /* 20 */
|
||||
case INSN_XIV64: /* 21 */
|
||||
{
|
||||
IV64 arg;
|
||||
BGET_IV64(arg);
|
||||
SvIVX(bytecode_sv) = arg;
|
||||
SvIVX(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XNV: /* 21 */
|
||||
case INSN_XNV: /* 22 */
|
||||
{
|
||||
NV arg;
|
||||
BGET_NV(arg);
|
||||
SvNVX(bytecode_sv) = arg;
|
||||
SvNVX(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XLV_TARGOFF: /* 22 */
|
||||
case INSN_XLV_TARGOFF: /* 23 */
|
||||
{
|
||||
STRLEN arg;
|
||||
BGET_U32(arg);
|
||||
LvTARGOFF(bytecode_sv) = arg;
|
||||
LvTARGOFF(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XLV_TARGLEN: /* 23 */
|
||||
case INSN_XLV_TARGLEN: /* 24 */
|
||||
{
|
||||
STRLEN arg;
|
||||
BGET_U32(arg);
|
||||
LvTARGLEN(bytecode_sv) = arg;
|
||||
LvTARGLEN(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XLV_TARG: /* 24 */
|
||||
case INSN_XLV_TARG: /* 25 */
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
LvTARG(bytecode_sv) = arg;
|
||||
LvTARG(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XLV_TYPE: /* 25 */
|
||||
case INSN_XLV_TYPE: /* 26 */
|
||||
{
|
||||
char arg;
|
||||
BGET_U8(arg);
|
||||
LvTYPE(bytecode_sv) = arg;
|
||||
LvTYPE(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XBM_USEFUL: /* 26 */
|
||||
case INSN_XBM_USEFUL: /* 27 */
|
||||
{
|
||||
I32 arg;
|
||||
BGET_I32(arg);
|
||||
BmUSEFUL(bytecode_sv) = arg;
|
||||
BmUSEFUL(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XBM_PREVIOUS: /* 27 */
|
||||
case INSN_XBM_PREVIOUS: /* 28 */
|
||||
{
|
||||
U16 arg;
|
||||
BGET_U16(arg);
|
||||
BmPREVIOUS(bytecode_sv) = arg;
|
||||
BmPREVIOUS(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XBM_RARE: /* 28 */
|
||||
case INSN_XBM_RARE: /* 29 */
|
||||
{
|
||||
U8 arg;
|
||||
BGET_U8(arg);
|
||||
BmRARE(bytecode_sv) = arg;
|
||||
BmRARE(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XFM_LINES: /* 29 */
|
||||
case INSN_XFM_LINES: /* 30 */
|
||||
{
|
||||
I32 arg;
|
||||
BGET_I32(arg);
|
||||
FmLINES(bytecode_sv) = arg;
|
||||
FmLINES(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XIO_LINES: /* 30 */
|
||||
case INSN_XIO_LINES: /* 31 */
|
||||
{
|
||||
long arg;
|
||||
BGET_I32(arg);
|
||||
IoLINES(bytecode_sv) = arg;
|
||||
IoLINES(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XIO_PAGE: /* 31 */
|
||||
case INSN_XIO_PAGE: /* 32 */
|
||||
{
|
||||
long arg;
|
||||
BGET_I32(arg);
|
||||
IoPAGE(bytecode_sv) = arg;
|
||||
IoPAGE(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XIO_PAGE_LEN: /* 32 */
|
||||
case INSN_XIO_PAGE_LEN: /* 33 */
|
||||
{
|
||||
long arg;
|
||||
BGET_I32(arg);
|
||||
IoPAGE_LEN(bytecode_sv) = arg;
|
||||
IoPAGE_LEN(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XIO_LINES_LEFT: /* 33 */
|
||||
case INSN_XIO_LINES_LEFT: /* 34 */
|
||||
{
|
||||
long arg;
|
||||
BGET_I32(arg);
|
||||
IoLINES_LEFT(bytecode_sv) = arg;
|
||||
IoLINES_LEFT(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XIO_TOP_NAME: /* 34 */
|
||||
case INSN_XIO_TOP_NAME: /* 36 */
|
||||
{
|
||||
pvcontents arg;
|
||||
BGET_pvcontents(arg);
|
||||
IoTOP_NAME(bytecode_sv) = arg;
|
||||
IoTOP_NAME(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XIO_TOP_GV: /* 36 */
|
||||
case INSN_XIO_TOP_GV: /* 37 */
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
*(SV**)&IoTOP_GV(bytecode_sv) = arg;
|
||||
*(SV**)&IoTOP_GV(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XIO_FMT_NAME: /* 37 */
|
||||
case INSN_XIO_FMT_NAME: /* 38 */
|
||||
{
|
||||
pvcontents arg;
|
||||
BGET_pvcontents(arg);
|
||||
IoFMT_NAME(bytecode_sv) = arg;
|
||||
IoFMT_NAME(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XIO_FMT_GV: /* 38 */
|
||||
case INSN_XIO_FMT_GV: /* 39 */
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
*(SV**)&IoFMT_GV(bytecode_sv) = arg;
|
||||
*(SV**)&IoFMT_GV(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XIO_BOTTOM_NAME: /* 39 */
|
||||
case INSN_XIO_BOTTOM_NAME: /* 40 */
|
||||
{
|
||||
pvcontents arg;
|
||||
BGET_pvcontents(arg);
|
||||
IoBOTTOM_NAME(bytecode_sv) = arg;
|
||||
IoBOTTOM_NAME(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XIO_BOTTOM_GV: /* 40 */
|
||||
case INSN_XIO_BOTTOM_GV: /* 41 */
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
*(SV**)&IoBOTTOM_GV(bytecode_sv) = arg;
|
||||
*(SV**)&IoBOTTOM_GV(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XIO_SUBPROCESS: /* 41 */
|
||||
case INSN_XIO_SUBPROCESS: /* 42 */
|
||||
{
|
||||
short arg;
|
||||
BGET_U16(arg);
|
||||
IoSUBPROCESS(bytecode_sv) = arg;
|
||||
IoSUBPROCESS(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XIO_TYPE: /* 42 */
|
||||
case INSN_XIO_TYPE: /* 43 */
|
||||
{
|
||||
char arg;
|
||||
BGET_U8(arg);
|
||||
IoTYPE(bytecode_sv) = arg;
|
||||
IoTYPE(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XIO_FLAGS: /* 43 */
|
||||
case INSN_XIO_FLAGS: /* 44 */
|
||||
{
|
||||
char arg;
|
||||
BGET_U8(arg);
|
||||
IoFLAGS(bytecode_sv) = arg;
|
||||
IoFLAGS(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XCV_STASH: /* 44 */
|
||||
case INSN_XCV_STASH: /* 45 */
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
*(SV**)&CvSTASH(bytecode_sv) = arg;
|
||||
*(SV**)&CvSTASH(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XCV_START: /* 45 */
|
||||
case INSN_XCV_START: /* 46 */
|
||||
{
|
||||
opindex arg;
|
||||
BGET_opindex(arg);
|
||||
CvSTART(bytecode_sv) = arg;
|
||||
CvSTART(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XCV_ROOT: /* 46 */
|
||||
case INSN_XCV_ROOT: /* 47 */
|
||||
{
|
||||
opindex arg;
|
||||
BGET_opindex(arg);
|
||||
CvROOT(bytecode_sv) = arg;
|
||||
CvROOT(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XCV_GV: /* 47 */
|
||||
case INSN_XCV_GV: /* 48 */
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
*(SV**)&CvGV(bytecode_sv) = arg;
|
||||
*(SV**)&CvGV(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XCV_FILE: /* 48 */
|
||||
case INSN_XCV_FILE: /* 49 */
|
||||
{
|
||||
pvcontents arg;
|
||||
BGET_pvcontents(arg);
|
||||
CvFILE(bytecode_sv) = arg;
|
||||
pvindex arg;
|
||||
BGET_pvindex(arg);
|
||||
CvFILE(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XCV_DEPTH: /* 49 */
|
||||
case INSN_XCV_DEPTH: /* 50 */
|
||||
{
|
||||
long arg;
|
||||
BGET_I32(arg);
|
||||
CvDEPTH(bytecode_sv) = arg;
|
||||
CvDEPTH(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XCV_PADLIST: /* 50 */
|
||||
case INSN_XCV_PADLIST: /* 51 */
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
*(SV**)&CvPADLIST(bytecode_sv) = arg;
|
||||
*(SV**)&CvPADLIST(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XCV_OUTSIDE: /* 51 */
|
||||
case INSN_XCV_OUTSIDE: /* 52 */
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
*(SV**)&CvOUTSIDE(bytecode_sv) = arg;
|
||||
*(SV**)&CvOUTSIDE(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XCV_FLAGS: /* 52 */
|
||||
case INSN_XCV_FLAGS: /* 53 */
|
||||
{
|
||||
U16 arg;
|
||||
BGET_U16(arg);
|
||||
CvFLAGS(bytecode_sv) = arg;
|
||||
CvFLAGS(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_AV_EXTEND: /* 53 */
|
||||
case INSN_AV_EXTEND: /* 54 */
|
||||
{
|
||||
SSize_t arg;
|
||||
BGET_I32(arg);
|
||||
BSET_av_extend(bytecode_sv, arg);
|
||||
BSET_av_extend(bstate->bs_sv, arg);
|
||||
break;
|
||||
}
|
||||
case INSN_AV_PUSH: /* 54 */
|
||||
case INSN_AV_PUSH: /* 55 */
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
BSET_av_push(bytecode_sv, arg);
|
||||
BSET_av_push(bstate->bs_sv, arg);
|
||||
break;
|
||||
}
|
||||
case INSN_XAV_FILL: /* 55 */
|
||||
case INSN_XAV_FILL: /* 56 */
|
||||
{
|
||||
SSize_t arg;
|
||||
BGET_I32(arg);
|
||||
AvFILLp(bytecode_sv) = arg;
|
||||
AvFILLp(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XAV_MAX: /* 56 */
|
||||
case INSN_XAV_MAX: /* 57 */
|
||||
{
|
||||
SSize_t arg;
|
||||
BGET_I32(arg);
|
||||
AvMAX(bytecode_sv) = arg;
|
||||
AvMAX(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XAV_FLAGS: /* 57 */
|
||||
case INSN_XAV_FLAGS: /* 58 */
|
||||
{
|
||||
U8 arg;
|
||||
BGET_U8(arg);
|
||||
AvFLAGS(bytecode_sv) = arg;
|
||||
AvFLAGS(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XHV_RITER: /* 58 */
|
||||
case INSN_XHV_RITER: /* 59 */
|
||||
{
|
||||
I32 arg;
|
||||
BGET_I32(arg);
|
||||
HvRITER(bytecode_sv) = arg;
|
||||
HvRITER(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_XHV_NAME: /* 59 */
|
||||
case INSN_XHV_NAME: /* 60 */
|
||||
{
|
||||
pvcontents arg;
|
||||
BGET_pvcontents(arg);
|
||||
HvNAME(bytecode_sv) = arg;
|
||||
HvNAME(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_HV_STORE: /* 60 */
|
||||
case INSN_HV_STORE: /* 61 */
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
BSET_hv_store(bytecode_sv, arg);
|
||||
BSET_hv_store(bstate->bs_sv, arg);
|
||||
break;
|
||||
}
|
||||
case INSN_SV_MAGIC: /* 61 */
|
||||
case INSN_SV_MAGIC: /* 62 */
|
||||
{
|
||||
char arg;
|
||||
BGET_U8(arg);
|
||||
BSET_sv_magic(bytecode_sv, arg);
|
||||
BSET_sv_magic(bstate->bs_sv, arg);
|
||||
break;
|
||||
}
|
||||
case INSN_MG_OBJ: /* 62 */
|
||||
case INSN_MG_OBJ: /* 63 */
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
SvMAGIC(bytecode_sv)->mg_obj = arg;
|
||||
SvMAGIC(bstate->bs_sv)->mg_obj = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_MG_PRIVATE: /* 63 */
|
||||
case INSN_MG_PRIVATE: /* 64 */
|
||||
{
|
||||
U16 arg;
|
||||
BGET_U16(arg);
|
||||
SvMAGIC(bytecode_sv)->mg_private = arg;
|
||||
SvMAGIC(bstate->bs_sv)->mg_private = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_MG_FLAGS: /* 64 */
|
||||
case INSN_MG_FLAGS: /* 65 */
|
||||
{
|
||||
U8 arg;
|
||||
BGET_U8(arg);
|
||||
SvMAGIC(bytecode_sv)->mg_flags = arg;
|
||||
SvMAGIC(bstate->bs_sv)->mg_flags = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_MG_PV: /* 65 */
|
||||
case INSN_MG_PV: /* 66 */
|
||||
{
|
||||
pvcontents arg;
|
||||
BGET_pvcontents(arg);
|
||||
BSET_mg_pv(SvMAGIC(bytecode_sv), arg);
|
||||
BSET_mg_pv(SvMAGIC(bstate->bs_sv), arg);
|
||||
break;
|
||||
}
|
||||
case INSN_XMG_STASH: /* 66 */
|
||||
case INSN_XMG_STASH: /* 67 */
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
*(SV**)&SvSTASH(bytecode_sv) = arg;
|
||||
*(SV**)&SvSTASH(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_GV_FETCHPV: /* 67 */
|
||||
case INSN_GV_FETCHPV: /* 68 */
|
||||
{
|
||||
strconst arg;
|
||||
BGET_strconst(arg);
|
||||
BSET_gv_fetchpv(bytecode_sv, arg);
|
||||
BSET_gv_fetchpv(bstate->bs_sv, arg);
|
||||
break;
|
||||
}
|
||||
case INSN_GV_STASHPV: /* 68 */
|
||||
case INSN_GV_STASHPV: /* 69 */
|
||||
{
|
||||
strconst arg;
|
||||
BGET_strconst(arg);
|
||||
BSET_gv_stashpv(bytecode_sv, arg);
|
||||
BSET_gv_stashpv(bstate->bs_sv, arg);
|
||||
break;
|
||||
}
|
||||
case INSN_GP_SV: /* 69 */
|
||||
case INSN_GP_SV: /* 70 */
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
GvSV(bytecode_sv) = arg;
|
||||
GvSV(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_GP_REFCNT: /* 70 */
|
||||
case INSN_GP_REFCNT: /* 71 */
|
||||
{
|
||||
U32 arg;
|
||||
BGET_U32(arg);
|
||||
GvREFCNT(bytecode_sv) = arg;
|
||||
GvREFCNT(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_GP_REFCNT_ADD: /* 71 */
|
||||
case INSN_GP_REFCNT_ADD: /* 72 */
|
||||
{
|
||||
I32 arg;
|
||||
BGET_I32(arg);
|
||||
BSET_gp_refcnt_add(GvREFCNT(bytecode_sv), arg);
|
||||
BSET_gp_refcnt_add(GvREFCNT(bstate->bs_sv), arg);
|
||||
break;
|
||||
}
|
||||
case INSN_GP_AV: /* 72 */
|
||||
case INSN_GP_AV: /* 73 */
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
*(SV**)&GvAV(bytecode_sv) = arg;
|
||||
*(SV**)&GvAV(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_GP_HV: /* 73 */
|
||||
case INSN_GP_HV: /* 74 */
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
*(SV**)&GvHV(bytecode_sv) = arg;
|
||||
*(SV**)&GvHV(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_GP_CV: /* 74 */
|
||||
case INSN_GP_CV: /* 75 */
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
*(SV**)&GvCV(bytecode_sv) = arg;
|
||||
*(SV**)&GvCV(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_GP_FILE: /* 75 */
|
||||
case INSN_GP_FILE: /* 76 */
|
||||
{
|
||||
pvcontents arg;
|
||||
BGET_pvcontents(arg);
|
||||
GvFILE(bytecode_sv) = arg;
|
||||
pvindex arg;
|
||||
BGET_pvindex(arg);
|
||||
GvFILE(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_GP_IO: /* 76 */
|
||||
case INSN_GP_IO: /* 77 */
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
*(SV**)&GvIOp(bytecode_sv) = arg;
|
||||
*(SV**)&GvIOp(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_GP_FORM: /* 77 */
|
||||
case INSN_GP_FORM: /* 78 */
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
*(SV**)&GvFORM(bytecode_sv) = arg;
|
||||
*(SV**)&GvFORM(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_GP_CVGEN: /* 78 */
|
||||
case INSN_GP_CVGEN: /* 79 */
|
||||
{
|
||||
U32 arg;
|
||||
BGET_U32(arg);
|
||||
GvCVGEN(bytecode_sv) = arg;
|
||||
GvCVGEN(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_GP_LINE: /* 79 */
|
||||
case INSN_GP_LINE: /* 80 */
|
||||
{
|
||||
line_t arg;
|
||||
BGET_U16(arg);
|
||||
GvLINE(bytecode_sv) = arg;
|
||||
GvLINE(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_GP_SHARE: /* 80 */
|
||||
case INSN_GP_SHARE: /* 81 */
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
BSET_gp_share(bytecode_sv, arg);
|
||||
BSET_gp_share(bstate->bs_sv, arg);
|
||||
break;
|
||||
}
|
||||
case INSN_XGV_FLAGS: /* 81 */
|
||||
case INSN_XGV_FLAGS: /* 82 */
|
||||
{
|
||||
U8 arg;
|
||||
BGET_U8(arg);
|
||||
GvFLAGS(bytecode_sv) = arg;
|
||||
GvFLAGS(bstate->bs_sv) = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_OP_NEXT: /* 82 */
|
||||
case INSN_OP_NEXT: /* 83 */
|
||||
{
|
||||
opindex arg;
|
||||
BGET_opindex(arg);
|
||||
PL_op->op_next = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_OP_SIBLING: /* 83 */
|
||||
case INSN_OP_SIBLING: /* 84 */
|
||||
{
|
||||
opindex arg;
|
||||
BGET_opindex(arg);
|
||||
PL_op->op_sibling = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_OP_PPADDR: /* 84 */
|
||||
case INSN_OP_PPADDR: /* 85 */
|
||||
{
|
||||
strconst arg;
|
||||
BGET_strconst(arg);
|
||||
BSET_op_ppaddr(PL_op->op_ppaddr, arg);
|
||||
break;
|
||||
}
|
||||
case INSN_OP_TARG: /* 85 */
|
||||
case INSN_OP_TARG: /* 86 */
|
||||
{
|
||||
PADOFFSET arg;
|
||||
BGET_U32(arg);
|
||||
PL_op->op_targ = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_OP_TYPE: /* 86 */
|
||||
case INSN_OP_TYPE: /* 87 */
|
||||
{
|
||||
OPCODE arg;
|
||||
BGET_U16(arg);
|
||||
BSET_op_type(PL_op, arg);
|
||||
break;
|
||||
}
|
||||
case INSN_OP_SEQ: /* 87 */
|
||||
case INSN_OP_SEQ: /* 88 */
|
||||
{
|
||||
U16 arg;
|
||||
BGET_U16(arg);
|
||||
PL_op->op_seq = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_OP_FLAGS: /* 88 */
|
||||
case INSN_OP_FLAGS: /* 89 */
|
||||
{
|
||||
U8 arg;
|
||||
BGET_U8(arg);
|
||||
PL_op->op_flags = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_OP_PRIVATE: /* 89 */
|
||||
case INSN_OP_PRIVATE: /* 90 */
|
||||
{
|
||||
U8 arg;
|
||||
BGET_U8(arg);
|
||||
PL_op->op_private = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_OP_FIRST: /* 90 */
|
||||
case INSN_OP_FIRST: /* 91 */
|
||||
{
|
||||
opindex arg;
|
||||
BGET_opindex(arg);
|
||||
cUNOP->op_first = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_OP_LAST: /* 91 */
|
||||
case INSN_OP_LAST: /* 92 */
|
||||
{
|
||||
opindex arg;
|
||||
BGET_opindex(arg);
|
||||
cBINOP->op_last = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_OP_OTHER: /* 92 */
|
||||
case INSN_OP_OTHER: /* 93 */
|
||||
{
|
||||
opindex arg;
|
||||
BGET_opindex(arg);
|
||||
cLOGOP->op_other = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_OP_CHILDREN: /* 93 */
|
||||
{
|
||||
U32 arg;
|
||||
BGET_U32(arg);
|
||||
cLISTOP->op_children = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_OP_PMREPLROOT: /* 94 */
|
||||
{
|
||||
opindex arg;
|
||||
@ -823,22 +819,22 @@ byterun(pTHXo_ struct bytestream bs)
|
||||
}
|
||||
case INSN_COP_LABEL: /* 108 */
|
||||
{
|
||||
pvcontents arg;
|
||||
BGET_pvcontents(arg);
|
||||
pvindex arg;
|
||||
BGET_pvindex(arg);
|
||||
cCOP->cop_label = arg;
|
||||
break;
|
||||
}
|
||||
case INSN_COP_STASHPV: /* 109 */
|
||||
{
|
||||
pvcontents arg;
|
||||
BGET_pvcontents(arg);
|
||||
pvindex arg;
|
||||
BGET_pvindex(arg);
|
||||
BSET_cop_stashpv(cCOP, arg);
|
||||
break;
|
||||
}
|
||||
case INSN_COP_FILE: /* 110 */
|
||||
{
|
||||
pvcontents arg;
|
||||
BGET_pvcontents(arg);
|
||||
pvindex arg;
|
||||
BGET_pvindex(arg);
|
||||
BSET_cop_file(cCOP, arg);
|
||||
break;
|
||||
}
|
||||
@ -891,6 +887,27 @@ byterun(pTHXo_ struct bytestream bs)
|
||||
BSET_curpad(PL_curpad, arg);
|
||||
break;
|
||||
}
|
||||
case INSN_PUSH_BEGIN: /* 118 */
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
BSET_push_begin(PL_beginav, arg);
|
||||
break;
|
||||
}
|
||||
case INSN_PUSH_INIT: /* 119 */
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
BSET_push_init(PL_initav, arg);
|
||||
break;
|
||||
}
|
||||
case INSN_PUSH_END: /* 120 */
|
||||
{
|
||||
svindex arg;
|
||||
BGET_svindex(arg);
|
||||
BSET_push_end(PL_endav, arg);
|
||||
break;
|
||||
}
|
||||
default:
|
||||
Perl_croak(aTHX_ "Illegal bytecode instruction %d\n", insn);
|
||||
/* NOTREACHED */
|
||||
|
@ -8,108 +8,120 @@
|
||||
/*
|
||||
* This file is autogenerated from bytecode.pl. Changes made here will be lost.
|
||||
*/
|
||||
struct bytestream {
|
||||
void *data;
|
||||
int (*pfgetc)(void *);
|
||||
int (*pfread)(char *, size_t, size_t, void *);
|
||||
void (*pfreadpv)(U32, void *, XPV *);
|
||||
struct byteloader_fdata {
|
||||
SV *datasv;
|
||||
int next_out;
|
||||
int idx;
|
||||
};
|
||||
|
||||
struct byteloader_state {
|
||||
struct byteloader_fdata *bs_fdata;
|
||||
SV *bs_sv;
|
||||
void **bs_obj_list;
|
||||
int bs_obj_list_fill;
|
||||
XPV bs_pv;
|
||||
int bs_iv_overflows;
|
||||
};
|
||||
|
||||
int bl_getc(struct byteloader_fdata *);
|
||||
int bl_read(struct byteloader_fdata *, char *, size_t, size_t);
|
||||
extern void byterun(pTHXo_ struct byteloader_state *);
|
||||
|
||||
enum {
|
||||
INSN_RET, /* 0 */
|
||||
INSN_LDSV, /* 1 */
|
||||
INSN_LDOP, /* 2 */
|
||||
INSN_STSV, /* 3 */
|
||||
INSN_STOP, /* 4 */
|
||||
INSN_LDSPECSV, /* 5 */
|
||||
INSN_NEWSV, /* 6 */
|
||||
INSN_NEWOP, /* 7 */
|
||||
INSN_NEWOPN, /* 8 */
|
||||
INSN_NEWPV, /* 9 */
|
||||
INSN_STPV, /* 5 */
|
||||
INSN_LDSPECSV, /* 6 */
|
||||
INSN_NEWSV, /* 7 */
|
||||
INSN_NEWOP, /* 8 */
|
||||
INSN_NEWOPN, /* 9 */
|
||||
INSN_NOP, /* 10 */
|
||||
INSN_PV_CUR, /* 11 */
|
||||
INSN_PV_FREE, /* 12 */
|
||||
INSN_SV_UPGRADE, /* 13 */
|
||||
INSN_SV_REFCNT, /* 14 */
|
||||
INSN_SV_REFCNT_ADD, /* 15 */
|
||||
INSN_SV_FLAGS, /* 16 */
|
||||
INSN_XRV, /* 17 */
|
||||
INSN_XPV, /* 18 */
|
||||
INSN_XIV32, /* 19 */
|
||||
INSN_XIV64, /* 20 */
|
||||
INSN_XNV, /* 21 */
|
||||
INSN_XLV_TARGOFF, /* 22 */
|
||||
INSN_XLV_TARGLEN, /* 23 */
|
||||
INSN_XLV_TARG, /* 24 */
|
||||
INSN_XLV_TYPE, /* 25 */
|
||||
INSN_XBM_USEFUL, /* 26 */
|
||||
INSN_XBM_PREVIOUS, /* 27 */
|
||||
INSN_XBM_RARE, /* 28 */
|
||||
INSN_XFM_LINES, /* 29 */
|
||||
INSN_XIO_LINES, /* 30 */
|
||||
INSN_XIO_PAGE, /* 31 */
|
||||
INSN_XIO_PAGE_LEN, /* 32 */
|
||||
INSN_XIO_LINES_LEFT, /* 33 */
|
||||
INSN_XIO_TOP_NAME, /* 34 */
|
||||
INSN_NEWPV, /* 11 */
|
||||
INSN_PV_CUR, /* 12 */
|
||||
INSN_PV_FREE, /* 13 */
|
||||
INSN_SV_UPGRADE, /* 14 */
|
||||
INSN_SV_REFCNT, /* 15 */
|
||||
INSN_SV_REFCNT_ADD, /* 16 */
|
||||
INSN_SV_FLAGS, /* 17 */
|
||||
INSN_XRV, /* 18 */
|
||||
INSN_XPV, /* 19 */
|
||||
INSN_XIV32, /* 20 */
|
||||
INSN_XIV64, /* 21 */
|
||||
INSN_XNV, /* 22 */
|
||||
INSN_XLV_TARGOFF, /* 23 */
|
||||
INSN_XLV_TARGLEN, /* 24 */
|
||||
INSN_XLV_TARG, /* 25 */
|
||||
INSN_XLV_TYPE, /* 26 */
|
||||
INSN_XBM_USEFUL, /* 27 */
|
||||
INSN_XBM_PREVIOUS, /* 28 */
|
||||
INSN_XBM_RARE, /* 29 */
|
||||
INSN_XFM_LINES, /* 30 */
|
||||
INSN_XIO_LINES, /* 31 */
|
||||
INSN_XIO_PAGE, /* 32 */
|
||||
INSN_XIO_PAGE_LEN, /* 33 */
|
||||
INSN_XIO_LINES_LEFT, /* 34 */
|
||||
INSN_COMMENT, /* 35 */
|
||||
INSN_XIO_TOP_GV, /* 36 */
|
||||
INSN_XIO_FMT_NAME, /* 37 */
|
||||
INSN_XIO_FMT_GV, /* 38 */
|
||||
INSN_XIO_BOTTOM_NAME, /* 39 */
|
||||
INSN_XIO_BOTTOM_GV, /* 40 */
|
||||
INSN_XIO_SUBPROCESS, /* 41 */
|
||||
INSN_XIO_TYPE, /* 42 */
|
||||
INSN_XIO_FLAGS, /* 43 */
|
||||
INSN_XCV_STASH, /* 44 */
|
||||
INSN_XCV_START, /* 45 */
|
||||
INSN_XCV_ROOT, /* 46 */
|
||||
INSN_XCV_GV, /* 47 */
|
||||
INSN_XCV_FILE, /* 48 */
|
||||
INSN_XCV_DEPTH, /* 49 */
|
||||
INSN_XCV_PADLIST, /* 50 */
|
||||
INSN_XCV_OUTSIDE, /* 51 */
|
||||
INSN_XCV_FLAGS, /* 52 */
|
||||
INSN_AV_EXTEND, /* 53 */
|
||||
INSN_AV_PUSH, /* 54 */
|
||||
INSN_XAV_FILL, /* 55 */
|
||||
INSN_XAV_MAX, /* 56 */
|
||||
INSN_XAV_FLAGS, /* 57 */
|
||||
INSN_XHV_RITER, /* 58 */
|
||||
INSN_XHV_NAME, /* 59 */
|
||||
INSN_HV_STORE, /* 60 */
|
||||
INSN_SV_MAGIC, /* 61 */
|
||||
INSN_MG_OBJ, /* 62 */
|
||||
INSN_MG_PRIVATE, /* 63 */
|
||||
INSN_MG_FLAGS, /* 64 */
|
||||
INSN_MG_PV, /* 65 */
|
||||
INSN_XMG_STASH, /* 66 */
|
||||
INSN_GV_FETCHPV, /* 67 */
|
||||
INSN_GV_STASHPV, /* 68 */
|
||||
INSN_GP_SV, /* 69 */
|
||||
INSN_GP_REFCNT, /* 70 */
|
||||
INSN_GP_REFCNT_ADD, /* 71 */
|
||||
INSN_GP_AV, /* 72 */
|
||||
INSN_GP_HV, /* 73 */
|
||||
INSN_GP_CV, /* 74 */
|
||||
INSN_GP_FILE, /* 75 */
|
||||
INSN_GP_IO, /* 76 */
|
||||
INSN_GP_FORM, /* 77 */
|
||||
INSN_GP_CVGEN, /* 78 */
|
||||
INSN_GP_LINE, /* 79 */
|
||||
INSN_GP_SHARE, /* 80 */
|
||||
INSN_XGV_FLAGS, /* 81 */
|
||||
INSN_OP_NEXT, /* 82 */
|
||||
INSN_OP_SIBLING, /* 83 */
|
||||
INSN_OP_PPADDR, /* 84 */
|
||||
INSN_OP_TARG, /* 85 */
|
||||
INSN_OP_TYPE, /* 86 */
|
||||
INSN_OP_SEQ, /* 87 */
|
||||
INSN_OP_FLAGS, /* 88 */
|
||||
INSN_OP_PRIVATE, /* 89 */
|
||||
INSN_OP_FIRST, /* 90 */
|
||||
INSN_OP_LAST, /* 91 */
|
||||
INSN_OP_OTHER, /* 92 */
|
||||
INSN_OP_CHILDREN, /* 93 */
|
||||
INSN_XIO_TOP_NAME, /* 36 */
|
||||
INSN_XIO_TOP_GV, /* 37 */
|
||||
INSN_XIO_FMT_NAME, /* 38 */
|
||||
INSN_XIO_FMT_GV, /* 39 */
|
||||
INSN_XIO_BOTTOM_NAME, /* 40 */
|
||||
INSN_XIO_BOTTOM_GV, /* 41 */
|
||||
INSN_XIO_SUBPROCESS, /* 42 */
|
||||
INSN_XIO_TYPE, /* 43 */
|
||||
INSN_XIO_FLAGS, /* 44 */
|
||||
INSN_XCV_STASH, /* 45 */
|
||||
INSN_XCV_START, /* 46 */
|
||||
INSN_XCV_ROOT, /* 47 */
|
||||
INSN_XCV_GV, /* 48 */
|
||||
INSN_XCV_FILE, /* 49 */
|
||||
INSN_XCV_DEPTH, /* 50 */
|
||||
INSN_XCV_PADLIST, /* 51 */
|
||||
INSN_XCV_OUTSIDE, /* 52 */
|
||||
INSN_XCV_FLAGS, /* 53 */
|
||||
INSN_AV_EXTEND, /* 54 */
|
||||
INSN_AV_PUSH, /* 55 */
|
||||
INSN_XAV_FILL, /* 56 */
|
||||
INSN_XAV_MAX, /* 57 */
|
||||
INSN_XAV_FLAGS, /* 58 */
|
||||
INSN_XHV_RITER, /* 59 */
|
||||
INSN_XHV_NAME, /* 60 */
|
||||
INSN_HV_STORE, /* 61 */
|
||||
INSN_SV_MAGIC, /* 62 */
|
||||
INSN_MG_OBJ, /* 63 */
|
||||
INSN_MG_PRIVATE, /* 64 */
|
||||
INSN_MG_FLAGS, /* 65 */
|
||||
INSN_MG_PV, /* 66 */
|
||||
INSN_XMG_STASH, /* 67 */
|
||||
INSN_GV_FETCHPV, /* 68 */
|
||||
INSN_GV_STASHPV, /* 69 */
|
||||
INSN_GP_SV, /* 70 */
|
||||
INSN_GP_REFCNT, /* 71 */
|
||||
INSN_GP_REFCNT_ADD, /* 72 */
|
||||
INSN_GP_AV, /* 73 */
|
||||
INSN_GP_HV, /* 74 */
|
||||
INSN_GP_CV, /* 75 */
|
||||
INSN_GP_FILE, /* 76 */
|
||||
INSN_GP_IO, /* 77 */
|
||||
INSN_GP_FORM, /* 78 */
|
||||
INSN_GP_CVGEN, /* 79 */
|
||||
INSN_GP_LINE, /* 80 */
|
||||
INSN_GP_SHARE, /* 81 */
|
||||
INSN_XGV_FLAGS, /* 82 */
|
||||
INSN_OP_NEXT, /* 83 */
|
||||
INSN_OP_SIBLING, /* 84 */
|
||||
INSN_OP_PPADDR, /* 85 */
|
||||
INSN_OP_TARG, /* 86 */
|
||||
INSN_OP_TYPE, /* 87 */
|
||||
INSN_OP_SEQ, /* 88 */
|
||||
INSN_OP_FLAGS, /* 89 */
|
||||
INSN_OP_PRIVATE, /* 90 */
|
||||
INSN_OP_FIRST, /* 91 */
|
||||
INSN_OP_LAST, /* 92 */
|
||||
INSN_OP_OTHER, /* 93 */
|
||||
INSN_OP_PMREPLROOT, /* 94 */
|
||||
INSN_OP_PMREPLROOTGV, /* 95 */
|
||||
INSN_OP_PMREPLSTART, /* 96 */
|
||||
@ -134,7 +146,10 @@ enum {
|
||||
INSN_MAIN_START, /* 115 */
|
||||
INSN_MAIN_ROOT, /* 116 */
|
||||
INSN_CURPAD, /* 117 */
|
||||
MAX_INSN = 117
|
||||
INSN_PUSH_BEGIN, /* 118 */
|
||||
INSN_PUSH_INIT, /* 119 */
|
||||
INSN_PUSH_END, /* 120 */
|
||||
MAX_INSN = 120
|
||||
};
|
||||
|
||||
enum {
|
||||
@ -151,11 +166,3 @@ enum {
|
||||
OPt_COP /* 10 */
|
||||
};
|
||||
|
||||
extern void byterun(pTHXo_ struct bytestream bs);
|
||||
|
||||
#define INIT_SPECIALSV_LIST STMT_START { \
|
||||
PL_specialsv_list[0] = Nullsv; \
|
||||
PL_specialsv_list[1] = &PL_sv_undef; \
|
||||
PL_specialsv_list[2] = &PL_sv_yes; \
|
||||
PL_specialsv_list[3] = &PL_sv_no; \
|
||||
} STMT_END
|
||||
|
@ -291,3 +291,46 @@
|
||||
to David Harris for spotting the underlying problem, contributing
|
||||
the updates to the documentation and writing DB_File::Lock (available
|
||||
on CPAN).
|
||||
|
||||
1.73 31st May 2000
|
||||
|
||||
* Added support in version.c for building with threaded Perl.
|
||||
|
||||
* Berkeley DB 3.1 has reenabled support for null keys. The test
|
||||
harness has been updated to reflect this.
|
||||
|
||||
1.74 10th December 2000
|
||||
|
||||
* A "close" call in DB_File.xs needed parenthesised to stop win32 from
|
||||
thinking it was one of its macros.
|
||||
|
||||
* Updated dbinfo to support Berkeley DB 3.1 file format changes.
|
||||
|
||||
* DB_File.pm & the test hasness now use the warnings pragma (when
|
||||
available).
|
||||
|
||||
* Included Perl core patch 7703 -- size argument for hash_cb is different
|
||||
for Berkeley DB 3.x
|
||||
|
||||
* Included Perl core patch 7801 -- Give __getBerkeleyDBInfo the ANSI C
|
||||
treatment.
|
||||
|
||||
* @a = () produced the warning 'Argument "" isn't numeric in entersub'
|
||||
This has been fixed. Thanks to Edward Avis for spotting this bug.
|
||||
|
||||
* Added note about building under Linux. Included patches.
|
||||
|
||||
* Included Perl core patch 8068 -- fix for bug 20001013.009
|
||||
When run with warnings enabled "$hash{XX} = undef " produced an
|
||||
"Uninitialized value" warning. This has been fixed.
|
||||
|
||||
1.75 17th December 2000
|
||||
|
||||
* Fixed perl core patch 7703
|
||||
|
||||
* Added suppport to allow DB_File to be built with Berkeley DB 3.2 --
|
||||
btree_compare, btree_prefix and hash_cb needed to be changed.
|
||||
|
||||
* Updated dbinfo to support Berkeley DB 3.2 file format changes.
|
||||
|
||||
|
||||
|
@ -1,8 +1,8 @@
|
||||
# DB_File.pm -- Perl 5 interface to Berkeley DB
|
||||
#
|
||||
# written by Paul Marquess (Paul.Marquess@btinternet.com)
|
||||
# last modified 16th January 2000
|
||||
# version 1.72
|
||||
# last modified 17th December 2000
|
||||
# version 1.75
|
||||
#
|
||||
# Copyright (c) 1995-2000 Paul Marquess. All rights reserved.
|
||||
# This program is free software; you can redistribute it and/or
|
||||
@ -13,6 +13,7 @@ package DB_File::HASHINFO ;
|
||||
|
||||
require 5.003 ;
|
||||
|
||||
use warnings;
|
||||
use strict;
|
||||
use Carp;
|
||||
require Tie::Hash;
|
||||
@ -104,6 +105,7 @@ sub CLEAR { my $self = shift ; $self->NotHere("CLEAR") }
|
||||
|
||||
package DB_File::RECNOINFO ;
|
||||
|
||||
use warnings;
|
||||
use strict ;
|
||||
|
||||
@DB_File::RECNOINFO::ISA = qw(DB_File::HASHINFO) ;
|
||||
@ -121,6 +123,7 @@ sub TIEHASH
|
||||
|
||||
package DB_File::BTREEINFO ;
|
||||
|
||||
use warnings;
|
||||
use strict ;
|
||||
|
||||
@DB_File::BTREEINFO::ISA = qw(DB_File::HASHINFO) ;
|
||||
@ -140,6 +143,7 @@ sub TIEHASH
|
||||
|
||||
package DB_File ;
|
||||
|
||||
use warnings;
|
||||
use strict;
|
||||
use vars qw($VERSION @ISA @EXPORT $AUTOLOAD $DB_BTREE $DB_HASH $DB_RECNO
|
||||
$db_version $use_XSLoader
|
||||
@ -147,7 +151,7 @@ use vars qw($VERSION @ISA @EXPORT $AUTOLOAD $DB_BTREE $DB_HASH $DB_RECNO
|
||||
use Carp;
|
||||
|
||||
|
||||
$VERSION = "1.72" ;
|
||||
$VERSION = "1.75" ;
|
||||
|
||||
#typedef enum { DB_BTREE, DB_HASH, DB_RECNO } DBTYPE;
|
||||
$DB_BTREE = new DB_File::BTREEINFO ;
|
||||
@ -271,7 +275,7 @@ sub TIEARRAY
|
||||
sub CLEAR
|
||||
{
|
||||
my $self = shift;
|
||||
my $key = "" ;
|
||||
my $key = 0 ;
|
||||
my $value = "" ;
|
||||
my $status = $self->seq($key, $value, R_FIRST());
|
||||
my @keys;
|
||||
@ -665,6 +669,7 @@ This example shows how to create a database, add key/value pairs to the
|
||||
database, delete keys/value pairs and finally how to enumerate the
|
||||
contents of the database.
|
||||
|
||||
use warnings ;
|
||||
use strict ;
|
||||
use DB_File ;
|
||||
use vars qw( %h $k $v ) ;
|
||||
@ -715,6 +720,7 @@ This script shows how to override the default sorting algorithm that
|
||||
BTREE uses. Instead of using the normal lexical ordering, a case
|
||||
insensitive compare function will be used.
|
||||
|
||||
use warnings ;
|
||||
use strict ;
|
||||
use DB_File ;
|
||||
|
||||
@ -783,6 +789,7 @@ There are some difficulties in using the tied hash interface if you
|
||||
want to manipulate a BTREE database with duplicate keys. Consider this
|
||||
code:
|
||||
|
||||
use warnings ;
|
||||
use strict ;
|
||||
use DB_File ;
|
||||
|
||||
@ -837,6 +844,7 @@ and the API in general.
|
||||
|
||||
Here is the script above rewritten using the C<seq> API method.
|
||||
|
||||
use warnings ;
|
||||
use strict ;
|
||||
use DB_File ;
|
||||
|
||||
@ -908,6 +916,7 @@ particular value occurred in the BTREE.
|
||||
So assuming the database created above, we can use C<get_dup> like
|
||||
this:
|
||||
|
||||
use warnings ;
|
||||
use strict ;
|
||||
use DB_File ;
|
||||
|
||||
@ -957,6 +966,7 @@ returns 0. Otherwise the method returns a non-zero value.
|
||||
|
||||
Assuming the database from the previous example:
|
||||
|
||||
use warnings ;
|
||||
use strict ;
|
||||
use DB_File ;
|
||||
|
||||
@ -995,6 +1005,7 @@ Otherwise the method returns a non-zero value.
|
||||
|
||||
Again assuming the existence of the C<tree> database
|
||||
|
||||
use warnings ;
|
||||
use strict ;
|
||||
use DB_File ;
|
||||
|
||||
@ -1039,6 +1050,7 @@ the use of the R_CURSOR flag with seq:
|
||||
In the example script below, the C<match> sub uses this feature to find
|
||||
and print the first matching key/value pair given a partial key.
|
||||
|
||||
use warnings ;
|
||||
use strict ;
|
||||
use DB_File ;
|
||||
use Fcntl ;
|
||||
@ -1143,6 +1155,7 @@ Here is a simple example that uses RECNO (if you are using a version
|
||||
of Perl earlier than 5.004_57 this example won't work -- see
|
||||
L<Extra RECNO Methods> for a workaround).
|
||||
|
||||
use warnings ;
|
||||
use strict ;
|
||||
use DB_File ;
|
||||
|
||||
@ -1232,6 +1245,7 @@ Here is a more complete example that makes use of some of the methods
|
||||
described above. It also makes use of the API interface directly (see
|
||||
L<THE API INTERFACE>).
|
||||
|
||||
use warnings ;
|
||||
use strict ;
|
||||
use vars qw(@h $H $file $i) ;
|
||||
use DB_File ;
|
||||
@ -1583,6 +1597,7 @@ the database and have them removed when you read from the database. As I'm
|
||||
sure you have already guessed, this is a problem that DBM Filters can
|
||||
fix very easily.
|
||||
|
||||
use warnings ;
|
||||
use strict ;
|
||||
use DB_File ;
|
||||
|
||||
@ -1625,6 +1640,7 @@ when reading.
|
||||
|
||||
Here is a DBM Filter that does it:
|
||||
|
||||
use warnings ;
|
||||
use strict ;
|
||||
use DB_File ;
|
||||
my %hash ;
|
||||
@ -1791,6 +1807,7 @@ Here is a snippet of code that is loosely based on Tom Christiansen's
|
||||
I<ggh> script (available from your nearest CPAN archive in
|
||||
F<authors/id/TOMC/scripts/nshist.gz>).
|
||||
|
||||
use warnings ;
|
||||
use strict ;
|
||||
use DB_File ;
|
||||
use Fcntl ;
|
||||
@ -1947,6 +1964,7 @@ You will encounter this particular error message when you have the
|
||||
C<strict 'subs'> pragma (or the full strict pragma) in your script.
|
||||
Consider this script:
|
||||
|
||||
use warnings ;
|
||||
use strict ;
|
||||
use DB_File ;
|
||||
use vars qw(%x) ;
|
||||
|
@ -3,8 +3,8 @@
|
||||
DB_File.xs -- Perl 5 interface to Berkeley DB
|
||||
|
||||
written by Paul Marquess <Paul.Marquess@btinternet.com>
|
||||
last modified 16th January 2000
|
||||
version 1.72
|
||||
last modified 17 December 2000
|
||||
version 1.75
|
||||
|
||||
All comments/suggestions/problems are welcome
|
||||
|
||||
@ -82,6 +82,14 @@
|
||||
Support for Berkeley DB 2/3's backward compatability mode.
|
||||
Rewrote push
|
||||
1.72 - No change to DB_File.xs
|
||||
1.73 - No change to DB_File.xs
|
||||
1.74 - A call to open needed parenthesised to stop it clashing
|
||||
with a win32 macro.
|
||||
Added Perl core patches 7703 & 7801.
|
||||
1.75 - Fixed Perl core patch 7703.
|
||||
Added suppport to allow DB_File to be built with
|
||||
Berkeley DB 3.2 -- btree_compare, btree_prefix and hash_cb
|
||||
needed to be changed.
|
||||
|
||||
*/
|
||||
|
||||
@ -127,6 +135,10 @@
|
||||
# include <db.h>
|
||||
#endif
|
||||
|
||||
#ifdef CAN_PROTOTYPE
|
||||
extern void __getBerkeleyDBInfo(void);
|
||||
#endif
|
||||
|
||||
#ifndef pTHX
|
||||
# define pTHX
|
||||
# define pTHX_
|
||||
@ -158,6 +170,10 @@
|
||||
# define BERKELEY_DB_1_OR_2
|
||||
#endif
|
||||
|
||||
#if DB_VERSION_MAJOR > 3 || (DB_VERSION_MAJOR == 3 && DB_VERSION_MINOR >= 2)
|
||||
# define AT_LEAST_DB_3_2
|
||||
#endif
|
||||
|
||||
/* map version 2 features & constants onto their version 1 equivalent */
|
||||
|
||||
#ifdef DB_Prefix_t
|
||||
@ -243,6 +259,7 @@ typedef db_recno_t recno_t;
|
||||
|
||||
#else /* db version 1.x */
|
||||
|
||||
#define BERKELEY_DB_1
|
||||
#define BERKELEY_DB_1_OR_2
|
||||
|
||||
typedef union INFO {
|
||||
@ -472,6 +489,19 @@ u_int flags ;
|
||||
|
||||
|
||||
static int
|
||||
#ifdef AT_LEAST_DB_3_2
|
||||
|
||||
#ifdef CAN_PROTOTYPE
|
||||
btree_compare(DB * db, const DBT *key1, const DBT *key2)
|
||||
#else
|
||||
btree_compare(db, key1, key2)
|
||||
DB * db ;
|
||||
const DBT * key1 ;
|
||||
const DBT * key2 ;
|
||||
#endif /* CAN_PROTOTYPE */
|
||||
|
||||
#else /* Berkeley DB < 3.2 */
|
||||
|
||||
#ifdef CAN_PROTOTYPE
|
||||
btree_compare(const DBT *key1, const DBT *key2)
|
||||
#else
|
||||
@ -479,6 +509,9 @@ btree_compare(key1, key2)
|
||||
const DBT * key1 ;
|
||||
const DBT * key2 ;
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
{
|
||||
#ifdef dTHX
|
||||
dTHX;
|
||||
@ -528,12 +561,27 @@ const DBT * key2 ;
|
||||
}
|
||||
|
||||
static DB_Prefix_t
|
||||
#ifdef AT_LEAST_DB_3_2
|
||||
|
||||
#ifdef CAN_PROTOTYPE
|
||||
btree_prefix(DB * db, const DBT *key1, const DBT *key2)
|
||||
#else
|
||||
btree_prefix(db, key1, key2)
|
||||
Db * db ;
|
||||
const DBT * key1 ;
|
||||
const DBT * key2 ;
|
||||
#endif
|
||||
|
||||
#else /* Berkeley DB < 3.2 */
|
||||
|
||||
#ifdef CAN_PROTOTYPE
|
||||
btree_prefix(const DBT *key1, const DBT *key2)
|
||||
#else
|
||||
btree_prefix(key1, key2)
|
||||
const DBT * key1 ;
|
||||
const DBT * key2 ;
|
||||
#endif
|
||||
|
||||
#endif
|
||||
{
|
||||
#ifdef dTHX
|
||||
@ -583,13 +631,35 @@ const DBT * key2 ;
|
||||
return (retval) ;
|
||||
}
|
||||
|
||||
|
||||
#ifdef BERKELEY_DB_1
|
||||
# define HASH_CB_SIZE_TYPE size_t
|
||||
#else
|
||||
# define HASH_CB_SIZE_TYPE u_int32_t
|
||||
#endif
|
||||
|
||||
static DB_Hash_t
|
||||
#ifdef AT_LEAST_DB_3_2
|
||||
|
||||
#ifdef CAN_PROTOTYPE
|
||||
hash_cb(const void *data, size_t size)
|
||||
hash_cb(DB * db, const void *data, u_int32_t size)
|
||||
#else
|
||||
hash_cb(db, data, size)
|
||||
DB * db ;
|
||||
const void * data ;
|
||||
HASH_CB_SIZE_TYPE size ;
|
||||
#endif
|
||||
|
||||
#else /* Berkeley DB < 3.2 */
|
||||
|
||||
#ifdef CAN_PROTOTYPE
|
||||
hash_cb(const void *data, HASH_CB_SIZE_TYPE size)
|
||||
#else
|
||||
hash_cb(data, size)
|
||||
const void * data ;
|
||||
size_t size ;
|
||||
HASH_CB_SIZE_TYPE size ;
|
||||
#endif
|
||||
|
||||
#endif
|
||||
{
|
||||
#ifdef dTHX
|
||||
@ -1265,7 +1335,7 @@ SV * sv ;
|
||||
Flags |= DB_TRUNCATE ;
|
||||
#endif
|
||||
|
||||
status = RETVAL->dbp->open(RETVAL->dbp, name, NULL, RETVAL->type,
|
||||
status = (RETVAL->dbp->open)(RETVAL->dbp, name, NULL, RETVAL->type,
|
||||
Flags, mode) ;
|
||||
/* printf("open returned %d %s\n", status, db_strerror(status)) ; */
|
||||
|
||||
|
@ -17,6 +17,7 @@ WriteMakefile(
|
||||
OBJECT => 'version$(OBJ_EXT) DB_File$(OBJ_EXT)',
|
||||
XSPROTOARG => '-noprototypes',
|
||||
DEFINE => $OS2 || "",
|
||||
INC => ($^O eq "MacOS" ? "-i ::::db:include" : "")
|
||||
);
|
||||
|
||||
sub MY::postamble {
|
||||
|
@ -4,10 +4,10 @@
|
||||
# a database file
|
||||
#
|
||||
# Author: Paul Marquess <Paul.Marquess@btinternet.com>
|
||||
# Version: 1.02
|
||||
# Date 20th August 1999
|
||||
# Version: 1.03
|
||||
# Date 17th September 2000
|
||||
#
|
||||
# Copyright (c) 1998 Paul Marquess. All rights reserved.
|
||||
# Copyright (c) 1998-2000 Paul Marquess. All rights reserved.
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the same terms as Perl itself.
|
||||
|
||||
@ -28,7 +28,8 @@ my %Data =
|
||||
4 => "Unknown",
|
||||
5 => "2.0.0 -> 2.3.0",
|
||||
6 => "2.3.1 -> 2.7.7",
|
||||
7 => "3.0.0 or greater",
|
||||
7 => "3.0.x",
|
||||
8 => "3.1.x or greater",
|
||||
}
|
||||
},
|
||||
0x061561 => {
|
||||
@ -40,14 +41,17 @@ my %Data =
|
||||
3 => "1.86",
|
||||
4 => "2.0.0 -> 2.1.0",
|
||||
5 => "2.2.6 -> 2.7.7",
|
||||
6 => "3.0.0 or greater",
|
||||
6 => "3.0.x",
|
||||
7 => "3.1.x or greater",
|
||||
}
|
||||
},
|
||||
0x042253 => {
|
||||
Type => "Queue",
|
||||
Versions =>
|
||||
{
|
||||
1 => "3.0.0 or greater",
|
||||
1 => "3.0.x",
|
||||
2 => "3.1.x",
|
||||
3 => "3.2.x or greater",
|
||||
}
|
||||
},
|
||||
) ;
|
||||
@ -86,7 +90,7 @@ else
|
||||
{ die "not a Berkeley DB database file.\n" }
|
||||
|
||||
my $type = $Data{$magic} ;
|
||||
my $magic = sprintf "%06X", $magic ;
|
||||
$magic = sprintf "%06X", $magic ;
|
||||
|
||||
my $ver_string = "Unknown" ;
|
||||
$ver_string = $type->{Versions}{$version}
|
||||
|
@ -1,8 +1,8 @@
|
||||
# typemap for Perl 5 interface to Berkeley
|
||||
#
|
||||
# written by Paul Marquess <Paul.Marquess@btinternet.com>
|
||||
# last modified 7th September 1999
|
||||
# version 1.71
|
||||
# last modified 10th December 2000
|
||||
# version 1.74
|
||||
#
|
||||
#################################### DB SECTION
|
||||
#
|
||||
@ -29,9 +29,10 @@ T_dbtkeydatum
|
||||
T_dbtdatum
|
||||
ckFilter($arg, filter_store_value, \"filter_store_value\");
|
||||
DBT_clear($var) ;
|
||||
$var.data = SvPV($arg, PL_na);
|
||||
$var.size = (int)PL_na;
|
||||
|
||||
if (SvOK($arg)) {
|
||||
$var.data = SvPV($arg, PL_na);
|
||||
$var.size = (int)PL_na;
|
||||
}
|
||||
|
||||
OUTPUT
|
||||
|
||||
|
@ -4,7 +4,7 @@
|
||||
|
||||
written by Paul Marquess <Paul.Marquess@btinternet.com>
|
||||
last modified 16th January 2000
|
||||
version 1.72
|
||||
version 1.73
|
||||
|
||||
All comments/suggestions/problems are welcome
|
||||
|
||||
@ -16,6 +16,9 @@
|
||||
1.71 - Support for Berkeley DB version 3.
|
||||
Support for Berkeley DB 2/3's backward compatability mode.
|
||||
1.72 - No change.
|
||||
1.73 - Added support for threading
|
||||
1.74 - Added Perl core patch 7801.
|
||||
|
||||
|
||||
*/
|
||||
|
||||
@ -26,8 +29,15 @@
|
||||
#include <db.h>
|
||||
|
||||
void
|
||||
#ifdef CAN_PROTOTYPE
|
||||
__getBerkeleyDBInfo(void)
|
||||
#else
|
||||
__getBerkeleyDBInfo()
|
||||
#endif
|
||||
{
|
||||
#ifdef dTHX
|
||||
dTHX;
|
||||
#endif
|
||||
SV * version_sv = perl_get_sv("DB_File::db_version", GV_ADD|GV_ADDMULTI) ;
|
||||
SV * ver_sv = perl_get_sv("DB_File::db_ver", GV_ADD|GV_ADDMULTI) ;
|
||||
SV * compat_sv = perl_get_sv("DB_File::db_185_compat", GV_ADD|GV_ADDMULTI) ;
|
||||
|
@ -9,7 +9,7 @@
|
||||
|
||||
package Data::Dumper;
|
||||
|
||||
$VERSION = '2.101';
|
||||
$VERSION = '2.102';
|
||||
|
||||
#$| = 1;
|
||||
|
||||
@ -291,8 +291,7 @@ sub _dump {
|
||||
$s->{level}++;
|
||||
$ipad = $s->{xpad} x $s->{level};
|
||||
|
||||
|
||||
if ($realtype eq 'SCALAR') {
|
||||
if ($realtype eq 'SCALAR' || $realtype eq 'REF') {
|
||||
if ($realpack) {
|
||||
$out .= 'do{\\(my $o = ' . $s->_dump($$val, "\${$name}") . ')}';
|
||||
}
|
||||
@ -685,7 +684,7 @@ the last.
|
||||
|
||||
Returns the stringified form of the values stored in the object (preserving
|
||||
the order in which they were supplied to C<new>), subject to the
|
||||
configuration options below. In an array context, it returns a list
|
||||
configuration options below. In a list context, it returns a list
|
||||
of strings corresponding to the supplied values.
|
||||
|
||||
The second form, for convenience, simply calls the C<new> method on its
|
||||
@ -701,7 +700,7 @@ dumping subroutine references.
|
||||
|
||||
Expects a anonymous hash of name => value pairs. Same rules apply for names
|
||||
as in C<new>. If no argument is supplied, will return the "seen" list of
|
||||
name => value pairs, in an array context. Otherwise, returns the object
|
||||
name => value pairs, in a list context. Otherwise, returns the object
|
||||
itself.
|
||||
|
||||
=item I<$OBJ>->Values(I<[ARRAYREF]>)
|
||||
@ -732,7 +731,7 @@ itself.
|
||||
Returns the stringified form of the values in the list, subject to the
|
||||
configuration options below. The values will be named C<$VAR>I<n> in the
|
||||
output, where I<n> is a numeric suffix. Will return a list of strings
|
||||
in an array context.
|
||||
in a list context.
|
||||
|
||||
=back
|
||||
|
||||
|
@ -584,8 +584,10 @@ DD_dump(pTHX_ SV *val, char *name, STRLEN namelen, SV *retval, HV *seenhv,
|
||||
|
||||
if (SvIOK(val)) {
|
||||
STRLEN len;
|
||||
i = SvIV(val);
|
||||
(void) sprintf(tmpbuf, "%"IVdf, (IV)i);
|
||||
if (SvIsUV(val))
|
||||
(void) sprintf(tmpbuf, "%"UVuf, SvUV(val));
|
||||
else
|
||||
(void) sprintf(tmpbuf, "%"IVdf, SvIV(val));
|
||||
len = strlen(tmpbuf);
|
||||
sv_catpvn(retval, tmpbuf, len);
|
||||
}
|
||||
@ -803,7 +805,7 @@ Data_Dumper_Dumpxs(href, ...)
|
||||
if ((svp = av_fetch(namesav, i, TRUE)))
|
||||
sv_setsv(name, *svp);
|
||||
else
|
||||
SvOK_off(name);
|
||||
(void)SvOK_off(name);
|
||||
|
||||
if (SvOK(name)) {
|
||||
if ((SvPVX(name))[0] == '*') {
|
||||
|
@ -3,11 +3,6 @@
|
||||
#include "perl.h"
|
||||
#include "XSUB.h"
|
||||
|
||||
/* For older Perls */
|
||||
#ifndef dTHR
|
||||
# define dTHR int dummy_thr
|
||||
#endif /* dTHR */
|
||||
|
||||
/*#define DBG_SUB 1 */
|
||||
/*#define DBG_TIMER 1 */
|
||||
|
||||
@ -28,6 +23,7 @@
|
||||
# define HZ ((I32)CLK_TCK)
|
||||
# define DPROF_HZ HZ
|
||||
# include <starlet.h> /* prototype for sys$gettim() */
|
||||
# include <lib$routines.h>
|
||||
# define Times(ptr) (dprof_times(aTHX_ ptr))
|
||||
#else
|
||||
# ifndef HZ
|
||||
@ -280,10 +276,6 @@ prof_mark(pTHX_ opcode ptype)
|
||||
{
|
||||
struct tms t;
|
||||
clock_t realtime, rdelta, udelta, sdelta;
|
||||
char *name, *pv;
|
||||
char *hvname;
|
||||
STRLEN len;
|
||||
SV *sv;
|
||||
U32 id;
|
||||
SV *Sub = GvSV(PL_DBsub); /* name of current sub */
|
||||
|
||||
@ -388,7 +380,6 @@ prof_mark(pTHX_ opcode ptype)
|
||||
static void
|
||||
test_time(pTHX_ clock_t *r, clock_t *u, clock_t *s)
|
||||
{
|
||||
dTHR;
|
||||
CV *cv = perl_get_cv("Devel::DProf::NONESUCH_noxs", FALSE);
|
||||
int i, j, k = 0;
|
||||
HV *oldstash = PL_curstash;
|
||||
@ -477,8 +468,6 @@ prof_record(pTHX)
|
||||
/* Now that we know the runtimes, fill them in at the recorded
|
||||
location -JH */
|
||||
|
||||
clock_t r, u, s;
|
||||
|
||||
if (g_SAVE_STACK) {
|
||||
prof_dump_until(aTHX_ g_profstack_ix);
|
||||
}
|
||||
@ -502,7 +491,7 @@ prof_record(pTHX)
|
||||
static void
|
||||
check_depth(pTHX_ void *foo)
|
||||
{
|
||||
U32 need_depth = (U32)foo;
|
||||
U32 need_depth = PTR2UV(foo);
|
||||
if (need_depth != g_depth) {
|
||||
if (need_depth > g_depth) {
|
||||
warn("garbled call depth when profiling");
|
||||
@ -547,6 +536,7 @@ XS(XS_DB_sub)
|
||||
prof_mark(aTHX_ OP_ENTERSUB);
|
||||
PUSHMARK(ORIGMARK);
|
||||
perl_call_sv(INT2PTR(SV*,SvIV(Sub)), GIMME | G_NODEBUG);
|
||||
PL_curstash = oldstash;
|
||||
prof_mark(aTHX_ OP_LEAVESUB);
|
||||
g_depth--;
|
||||
}
|
||||
|
@ -2,6 +2,7 @@ use ExtUtils::MakeMaker;
|
||||
WriteMakefile(
|
||||
NAME => "Devel::Peek",
|
||||
VERSION_FROM => 'Peek.pm',
|
||||
XSPROTOARG => '-noprototypes',
|
||||
'dist' => {
|
||||
COMPRESS => 'gzip -9f',
|
||||
SUFFIX => 'gz',
|
||||
|
@ -10,7 +10,8 @@ require Exporter;
|
||||
use XSLoader ();
|
||||
|
||||
@ISA = qw(Exporter);
|
||||
@EXPORT = qw(Dump mstat DeadCode DumpArray DumpWithOP DumpProg);
|
||||
@EXPORT = qw(Dump mstat DeadCode DumpArray DumpWithOP DumpProg
|
||||
fill_mstats mstats_fillhash mstats2hash);
|
||||
@EXPORT_OK = qw(SvREFCNT SvREFCNT_inc SvREFCNT_dec CvGV);
|
||||
%EXPORT_TAGS = ('ALL' => [@EXPORT, @EXPORT_OK]);
|
||||
|
||||
@ -58,16 +59,76 @@ C<CV>. Devel::Peek also supplies C<SvREFCNT()>, C<SvREFCNT_inc()>, and
|
||||
C<SvREFCNT_dec()> which can query, increment, and decrement reference
|
||||
counts on SVs. This document will take a passive, and safe, approach
|
||||
to data debugging and for that it will describe only the C<Dump()>
|
||||
function. For format of output of mstats() see
|
||||
L<perldebug/Using C<$ENV{PERL_DEBUG_MSTATS}>>.
|
||||
function.
|
||||
|
||||
Function C<DumpArray()> allows dumping of multiple values (useful when you
|
||||
need to analize returns of functions).
|
||||
need to analyze returns of functions).
|
||||
|
||||
The global variable $Devel::Peek::pv_limit can be set to limit the
|
||||
number of character printed in various string values. Setting it to 0
|
||||
means no limit.
|
||||
|
||||
=head2 Memory footprint debugging
|
||||
|
||||
When perl is compiled with support for memory footprint debugging
|
||||
(default with Perl's malloc()), Devel::Peek provides an access to this API.
|
||||
|
||||
Use mstat() function to emit a memory state statistic to the terminal.
|
||||
For more information on the format of output of mstat() see
|
||||
L<perldebug/Using C<$ENV{PERL_DEBUG_MSTATS}>>.
|
||||
|
||||
Three additional functions allow access to this statistic from Perl.
|
||||
First, use C<mstats_fillhash(%hash)> to get the information contained
|
||||
in the output of mstat() into %hash. The field of this hash are
|
||||
|
||||
minbucket nbuckets sbrk_good sbrk_slack sbrked_remains sbrks start_slack
|
||||
topbucket topbucket_ev topbucket_odd total total_chain total_sbrk totfree
|
||||
|
||||
Two additional fields C<free>, C<used> contain array references which
|
||||
provide per-bucket count of free and used chunks. Two other fields
|
||||
C<mem_size>, C<available_size> contain array references which provide
|
||||
the information about the allocated size and usable size of chunks in
|
||||
each bucket. Again, see L<perldebug/Using C<$ENV{PERL_DEBUG_MSTATS}>>
|
||||
for details.
|
||||
|
||||
Keep in mind that only the first several "odd-numbered" buckets are
|
||||
used, so the information on size of the "odd-numbered" buckets which are
|
||||
not used is probably meaningless.
|
||||
|
||||
The information in
|
||||
|
||||
mem_size available_size minbucket nbuckets
|
||||
|
||||
is the property of a particular build of perl, and does not depend on
|
||||
the current process. If you do not provide the optional argument to
|
||||
the functions mstats_fillhash(), fill_mstats(), mstats2hash(), then
|
||||
the information in fields C<mem_size>, C<available_size> is not
|
||||
updated.
|
||||
|
||||
C<fill_mstats($buf)> is a much cheaper call (both speedwise and
|
||||
memory-wise) which collects the statistic into $buf in
|
||||
machine-readable form. At a later moment you may need to call
|
||||
C<mstats2hash($buf, %hash)> to use this information to fill %hash.
|
||||
|
||||
All three APIs C<fill_mstats($buf)>, C<mstats_fillhash(%hash)>, and
|
||||
C<mstats2hash($buf, %hash)> are designed to allocate no memory if used
|
||||
I<the second time> on the same $buf and/or %hash.
|
||||
|
||||
So, if you want to collect memory info in a cycle, you may call
|
||||
|
||||
$#buf = 999;
|
||||
fill_mstats($_) for @buf;
|
||||
mstats_fillhash(%report, 1); # Static info too
|
||||
|
||||
foreach (@buf) {
|
||||
# Do something...
|
||||
fill_mstats $_; # Collect statistic
|
||||
}
|
||||
foreach (@buf) {
|
||||
mstats2hash($_, %report); # Preserve static info
|
||||
# Do something with %report
|
||||
}
|
||||
|
||||
=head1 EXAMPLES
|
||||
|
||||
The following examples don't attempt to show everything as that would be a
|
||||
@ -403,8 +464,9 @@ it has no prototype (C<PROTOTYPE> field is missing).
|
||||
=head1 EXPORTS
|
||||
|
||||
C<Dump>, C<mstat>, C<DeadCode>, C<DumpArray>, C<DumpWithOP> and
|
||||
C<DumpProg> by default. Additionally available C<SvREFCNT>,
|
||||
C<SvREFCNT_inc> and C<SvREFCNT_dec>.
|
||||
C<DumpProg>, C<fill_mstats>, C<mstats_fillhash>, C<mstats2hash> by
|
||||
default. Additionally available C<SvREFCNT>, C<SvREFCNT_inc> and
|
||||
C<SvREFCNT_dec>.
|
||||
|
||||
=head1 BUGS
|
||||
|
||||
|
@ -82,8 +82,6 @@ DeadCode(pTHX)
|
||||
}
|
||||
}
|
||||
else if (SvTYPE(pad[j]) >= SVt_PV && SvLEN(pad[j])) {
|
||||
int db_len = SvLEN(pad[j]);
|
||||
SV *db_sv = pad[j];
|
||||
levels++;
|
||||
levelm += SvLEN(pad[j])/SvREFCNT(pad[j]);
|
||||
/* Dump(pad[j],4); */
|
||||
@ -125,6 +123,183 @@ DeadCode(pTHX)
|
||||
PerlIO_printf(Perl_debug_log, "%s: perl not compiled with DEBUGGING_MSTATS\n",str);
|
||||
#endif
|
||||
|
||||
#if defined(PERL_DEBUGGING_MSTATS) || defined(DEBUGGING_MSTATS) \
|
||||
|| (defined(MYMALLOC) && !defined(PLAIN_MALLOC))
|
||||
|
||||
/* Very coarse overestimate, 2-per-power-of-2, one more to determine NBUCKETS. */
|
||||
# define _NBUCKETS (2*8*IVSIZE+1)
|
||||
|
||||
struct mstats_buffer
|
||||
{
|
||||
perl_mstats_t buffer;
|
||||
UV buf[_NBUCKETS*4];
|
||||
};
|
||||
|
||||
void
|
||||
_fill_mstats(struct mstats_buffer *b, int level)
|
||||
{
|
||||
dTHX;
|
||||
b->buffer.nfree = b->buf;
|
||||
b->buffer.ntotal = b->buf + _NBUCKETS;
|
||||
b->buffer.bucket_mem_size = b->buf + 2*_NBUCKETS;
|
||||
b->buffer.bucket_available_size = b->buf + 3*_NBUCKETS;
|
||||
Zero(b->buf, (level ? 4*_NBUCKETS: 2*_NBUCKETS), unsigned long);
|
||||
get_mstats(&(b->buffer), _NBUCKETS, level);
|
||||
}
|
||||
|
||||
void
|
||||
fill_mstats(SV *sv, int level)
|
||||
{
|
||||
dTHX;
|
||||
int nbuckets;
|
||||
struct mstats_buffer buf;
|
||||
|
||||
if (SvREADONLY(sv))
|
||||
croak("Cannot modify a readonly value");
|
||||
SvGROW(sv, sizeof(struct mstats_buffer)+1);
|
||||
_fill_mstats((struct mstats_buffer*)SvPVX(sv),level);
|
||||
SvCUR_set(sv, sizeof(struct mstats_buffer));
|
||||
*SvEND(sv) = '\0';
|
||||
SvPOK_only(sv);
|
||||
}
|
||||
|
||||
void
|
||||
_mstats_to_hv(HV *hv, struct mstats_buffer *b, int level)
|
||||
{
|
||||
dTHX;
|
||||
SV **svp;
|
||||
int type;
|
||||
|
||||
svp = hv_fetch(hv, "topbucket", 9, 1);
|
||||
sv_setiv(*svp, b->buffer.topbucket);
|
||||
|
||||
svp = hv_fetch(hv, "topbucket_ev", 12, 1);
|
||||
sv_setiv(*svp, b->buffer.topbucket_ev);
|
||||
|
||||
svp = hv_fetch(hv, "topbucket_odd", 13, 1);
|
||||
sv_setiv(*svp, b->buffer.topbucket_odd);
|
||||
|
||||
svp = hv_fetch(hv, "totfree", 7, 1);
|
||||
sv_setiv(*svp, b->buffer.totfree);
|
||||
|
||||
svp = hv_fetch(hv, "total", 5, 1);
|
||||
sv_setiv(*svp, b->buffer.total);
|
||||
|
||||
svp = hv_fetch(hv, "total_chain", 11, 1);
|
||||
sv_setiv(*svp, b->buffer.total_chain);
|
||||
|
||||
svp = hv_fetch(hv, "total_sbrk", 10, 1);
|
||||
sv_setiv(*svp, b->buffer.total_sbrk);
|
||||
|
||||
svp = hv_fetch(hv, "sbrks", 5, 1);
|
||||
sv_setiv(*svp, b->buffer.sbrks);
|
||||
|
||||
svp = hv_fetch(hv, "sbrk_good", 9, 1);
|
||||
sv_setiv(*svp, b->buffer.sbrk_good);
|
||||
|
||||
svp = hv_fetch(hv, "sbrk_slack", 10, 1);
|
||||
sv_setiv(*svp, b->buffer.sbrk_slack);
|
||||
|
||||
svp = hv_fetch(hv, "start_slack", 11, 1);
|
||||
sv_setiv(*svp, b->buffer.start_slack);
|
||||
|
||||
svp = hv_fetch(hv, "sbrked_remains", 14, 1);
|
||||
sv_setiv(*svp, b->buffer.sbrked_remains);
|
||||
|
||||
svp = hv_fetch(hv, "minbucket", 9, 1);
|
||||
sv_setiv(*svp, b->buffer.minbucket);
|
||||
|
||||
svp = hv_fetch(hv, "nbuckets", 8, 1);
|
||||
sv_setiv(*svp, b->buffer.nbuckets);
|
||||
|
||||
if (_NBUCKETS < b->buffer.nbuckets)
|
||||
warn("FIXME: internal mstats buffer too short");
|
||||
|
||||
for (type = 0; type < (level ? 4 : 2); type++) {
|
||||
UV *p, *p1;
|
||||
AV *av;
|
||||
int i;
|
||||
static const char *types[4] = {
|
||||
"free", "used", "mem_size", "available_size"
|
||||
};
|
||||
|
||||
svp = hv_fetch(hv, types[type], strlen(types[type]), 1);
|
||||
|
||||
if (SvOK(*svp) && !(SvROK(*svp) && SvTYPE(SvRV(*svp)) == SVt_PVAV))
|
||||
croak("Unexpected value for the key '%s' in the mstats hash", types[type]);
|
||||
if (!SvOK(*svp)) {
|
||||
av = newAV();
|
||||
SvUPGRADE(*svp, SVt_RV);
|
||||
SvRV(*svp) = (SV*)av;
|
||||
SvROK_on(*svp);
|
||||
} else
|
||||
av = (AV*)SvRV(*svp);
|
||||
|
||||
av_extend(av, b->buffer.nbuckets - 1);
|
||||
/* XXXX What is the official way to reduce the size of the array? */
|
||||
switch (type) {
|
||||
case 0:
|
||||
p = b->buffer.nfree;
|
||||
break;
|
||||
case 1:
|
||||
p = b->buffer.ntotal;
|
||||
p1 = b->buffer.nfree;
|
||||
break;
|
||||
case 2:
|
||||
p = b->buffer.bucket_mem_size;
|
||||
break;
|
||||
case 3:
|
||||
p = b->buffer.bucket_available_size;
|
||||
break;
|
||||
}
|
||||
for (i = 0; i < b->buffer.nbuckets; i++) {
|
||||
svp = av_fetch(av, i, 1);
|
||||
if (type == 1)
|
||||
sv_setiv(*svp, p[i]-p1[i]);
|
||||
else
|
||||
sv_setuv(*svp, p[i]);
|
||||
}
|
||||
}
|
||||
}
|
||||
void
|
||||
mstats_fillhash(SV *sv, int level)
|
||||
{
|
||||
struct mstats_buffer buf;
|
||||
|
||||
if (!(SvROK(sv) && SvTYPE(SvRV(sv)) == SVt_PVHV))
|
||||
croak("Not a hash reference");
|
||||
_fill_mstats(&buf, level);
|
||||
_mstats_to_hv((HV *)SvRV(sv), &buf, level);
|
||||
}
|
||||
void
|
||||
mstats2hash(SV *sv, SV *rv, int level)
|
||||
{
|
||||
if (!(SvROK(rv) && SvTYPE(SvRV(rv)) == SVt_PVHV))
|
||||
croak("Not a hash reference");
|
||||
if (!SvPOK(sv))
|
||||
croak("Undefined value when expecting mstats buffer");
|
||||
if (SvCUR(sv) != sizeof(struct mstats_buffer))
|
||||
croak("Wrong size for a value with a mstats buffer");
|
||||
_mstats_to_hv((HV *)SvRV(rv), (struct mstats_buffer*)SvPVX(sv), level);
|
||||
}
|
||||
#else /* !( defined(PERL_DEBUGGING_MSTATS) || defined(DEBUGGING_MSTATS) \ ) */
|
||||
void
|
||||
fill_mstats(SV *sv, int level)
|
||||
{
|
||||
croak("Cannot report mstats without Perl malloc");
|
||||
}
|
||||
void
|
||||
mstats_fillhash(SV *sv, int level)
|
||||
{
|
||||
croak("Cannot report mstats without Perl malloc");
|
||||
}
|
||||
void
|
||||
mstats2hash(SV *sv, SV *rv, int level)
|
||||
{
|
||||
croak("Cannot report mstats without Perl malloc");
|
||||
}
|
||||
#endif /* defined(PERL_DEBUGGING_MSTATS) || defined(DEBUGGING_MSTATS)... */
|
||||
|
||||
#define _CvGV(cv) \
|
||||
(SvROK(cv) && (SvTYPE(SvRV(cv))==SVt_PVCV) \
|
||||
? SvREFCNT_inc(CvGV((CV*)SvRV(cv))) : &PL_sv_undef)
|
||||
@ -135,6 +310,17 @@ void
|
||||
mstat(str="Devel::Peek::mstat: ")
|
||||
char *str
|
||||
|
||||
void
|
||||
fill_mstats(SV *sv, int level = 0)
|
||||
|
||||
void
|
||||
mstats_fillhash(SV *sv, int level = 0)
|
||||
PROTOTYPE: \%;$
|
||||
|
||||
void
|
||||
mstats2hash(SV *sv, SV *rv, int level = 0)
|
||||
PROTOTYPE: $\%;$
|
||||
|
||||
void
|
||||
Dump(sv,lim=4)
|
||||
SV * sv
|
||||
@ -173,7 +359,7 @@ void
|
||||
DumpProg()
|
||||
PPCODE:
|
||||
{
|
||||
warn("dumpindent is %d", PL_dumpindent);
|
||||
warn("dumpindent is %d", (int)PL_dumpindent);
|
||||
if (PL_main_root)
|
||||
op_dump(PL_main_root);
|
||||
}
|
||||
@ -195,7 +381,7 @@ PPCODE:
|
||||
|
||||
# PPCODE needed since by default it is void
|
||||
|
||||
SV *
|
||||
void
|
||||
SvREFCNT_dec(sv)
|
||||
SV * sv
|
||||
PPCODE:
|
||||
|
@ -1,4 +1,3 @@
|
||||
|
||||
use Config;
|
||||
|
||||
sub to_string {
|
||||
@ -12,7 +11,7 @@ unlink "DynaLoader.pm" if -f "DynaLoader.pm";
|
||||
open OUT, ">DynaLoader.pm" or die $!;
|
||||
print OUT <<'EOT';
|
||||
|
||||
# Generated from DynaLoader.pm.PL (resolved %Config::Config values)
|
||||
# Generated from DynaLoader.pm.PL
|
||||
|
||||
package DynaLoader;
|
||||
|
||||
@ -21,18 +20,22 @@ package DynaLoader;
|
||||
# feast like to keep their secret; for wonder makes the words of
|
||||
# praise louder.'
|
||||
|
||||
# (Quote from Tolkien sugested by Anno Siegel.)
|
||||
# (Quote from Tolkien suggested by Anno Siegel.)
|
||||
#
|
||||
# See pod text at end of file for documentation.
|
||||
# See also ext/DynaLoader/README in source tree for other information.
|
||||
#
|
||||
# Tim.Bunce@ig.co.uk, August 1994
|
||||
|
||||
$VERSION = "1.04"; # avoid typo warning
|
||||
use vars qw($VERSION *AUTOLOAD);
|
||||
|
||||
$VERSION = 1.04; # avoid typo warning
|
||||
|
||||
require AutoLoader;
|
||||
*AUTOLOAD = \&AutoLoader::AUTOLOAD;
|
||||
|
||||
use Config;
|
||||
|
||||
# The following require can't be removed during maintenance
|
||||
# releases, sadly, because of the risk of buggy code that does
|
||||
# require Carp; Carp::croak "..."; without brackets dying
|
||||
@ -40,7 +43,6 @@ require AutoLoader;
|
||||
# We'll let those bugs get found on the development track.
|
||||
require Carp if $] < 5.00450;
|
||||
|
||||
|
||||
# enable debug/trace messages from DynaLoader perl code
|
||||
$dl_debug = $ENV{PERL_DL_DEBUG} || 0 unless defined $dl_debug;
|
||||
|
||||
@ -71,52 +73,116 @@ print OUT <<'EOT';
|
||||
# (VMS support by Charles Bailey <bailey@HMIVAX.HUMGEN.UPENN.EDU>)
|
||||
# See dl_expandspec() for more details. Should be harmless but
|
||||
# inefficient to define on systems that don't need it.
|
||||
$do_expand = $Is_VMS = $^O eq 'VMS';
|
||||
$Is_VMS = $^O eq 'VMS';
|
||||
$do_expand = $Is_VMS;
|
||||
$Is_MacOS = $^O eq 'MacOS';
|
||||
|
||||
@dl_require_symbols = (); # names of symbols we need
|
||||
@dl_resolve_using = (); # names of files to link with
|
||||
@dl_library_path = (); # path to look for files
|
||||
#@dl_librefs = (); # things we have loaded
|
||||
#@dl_modules = (); # Modules we have loaded
|
||||
@dl_librefs = (); # things we have loaded
|
||||
@dl_modules = (); # Modules we have loaded
|
||||
|
||||
# This is a fix to support DLD's unfortunate desire to relink -lc
|
||||
@dl_resolve_using = dl_findfile('-lc') if $dlsrc eq "dl_dld.xs";
|
||||
|
||||
# Initialise @dl_library_path with the 'standard' library path
|
||||
# for this platform as determined by Configure
|
||||
|
||||
# push(@dl_library_path, split(' ', $Config::Config{'libpth'});
|
||||
EOT
|
||||
|
||||
print OUT "push(\@dl_library_path, split(' ', ",
|
||||
to_string($Config::Config{'libpth'}), "));\n";
|
||||
my $cfg_dl_library_path = <<'EOT';
|
||||
push(@dl_library_path, split(' ', $Config::Config{libpth}));
|
||||
EOT
|
||||
|
||||
print OUT <<'EOT';
|
||||
|
||||
# Add to @dl_library_path any extra directories we can gather
|
||||
# from environment variables.
|
||||
if ($Is_MacOS) {
|
||||
push(@dl_library_path, split(/,/, $ENV{LD_LIBRARY_PATH}))
|
||||
if exists $ENV{LD_LIBRARY_PATH};
|
||||
} else {
|
||||
push(@dl_library_path, split(/:/, $ENV{$Config::Config{ldlibpthname}}))
|
||||
if exists $Config::Config{ldlibpthname} &&
|
||||
$Config::Config{ldlibpthname} ne '' &&
|
||||
exists $ENV{$Config::Config{ldlibpthname}} ;;
|
||||
push(@dl_library_path, split(/:/, $ENV{$Config::Config{ldlibpthname}}))
|
||||
if exists $Config::Config{ldlibpthname} &&
|
||||
$Config::Config{ldlibpthname} ne '' &&
|
||||
exists $ENV{$Config::Config{ldlibpthname}} ;;
|
||||
# E.g. HP-UX supports both its native SHLIB_PATH *and* LD_LIBRARY_PATH.
|
||||
push(@dl_library_path, split(/:/, $ENV{LD_LIBRARY_PATH}))
|
||||
if exists $ENV{LD_LIBRARY_PATH};
|
||||
sub dquoted_comma_list {
|
||||
join(", ", map {qq("$_")} @_);
|
||||
}
|
||||
|
||||
# No prizes for guessing why we don't say 'bootstrap DynaLoader;' here.
|
||||
boot_DynaLoader('DynaLoader') if defined(&boot_DynaLoader) &&
|
||||
!defined(&dl_load_file);
|
||||
if ($ENV{PERL_BUILD_EXPAND_CONFIG_VARS}) {
|
||||
eval $cfg_dl_library_path;
|
||||
if (!$ENV{PERL_BUILD_EXPAND_ENV_VARS}) {
|
||||
my $dl_library_path = dquoted_comma_list(@dl_library_path);
|
||||
print OUT <<EOT;
|
||||
# The below \@dl_library_path has been expanded (%Config) in Perl build time.
|
||||
|
||||
\@dl_library_path = ($dl_library_path);
|
||||
|
||||
EOT
|
||||
}
|
||||
}
|
||||
else {
|
||||
print OUT <<EOT;
|
||||
# Initialise \@dl_library_path with the 'standard' library path
|
||||
# for this platform as determined by Configure.
|
||||
|
||||
$cfg_dl_library_path
|
||||
|
||||
EOT
|
||||
}
|
||||
|
||||
my $ldlibpthname;
|
||||
my $ldlibpthname_defined;
|
||||
my $pthsep;
|
||||
|
||||
if ($ENV{PERL_BUILD_EXPAND_CONFIG_VARS}) {
|
||||
$ldlibpthname = $Config::Config{ldlibpthname};
|
||||
$ldlibpthname_defined = defined $Config::Config{ldlibpthname} ? 1 : 0;
|
||||
$pthsep = $Config::Config{path_sep};
|
||||
}
|
||||
else {
|
||||
$ldlibpthname = q($Config::Config{ldlibpthname});
|
||||
$ldlibpthname_defined = q(defined $Config::Config{ldlibpthname});
|
||||
$pthsep = q($Config::Config{path_sep});
|
||||
print OUT <<EOT;
|
||||
my \$ldlibpthname = $ldlibpthname;
|
||||
my \$ldlibpthname_defined = $ldlibpthname_defined;
|
||||
my \$pthsep = $pthsep;
|
||||
|
||||
EOT
|
||||
}
|
||||
|
||||
my $env_dl_library_path = <<'EOT';
|
||||
if ($ldlibpthname_defined &&
|
||||
exists $ENV{$ldlibpthname}) {
|
||||
push(@dl_library_path, split(/$pthsep/, $ENV{$ldlibpthname}));
|
||||
}
|
||||
|
||||
# E.g. HP-UX supports both its native SHLIB_PATH *and* LD_LIBRARY_PATH.
|
||||
|
||||
if ($ldlibpthname_defined &&
|
||||
$ldlibpthname ne 'LD_LIBRARY_PATH' &&
|
||||
exists $ENV{LD_LIBRARY_PATH}) {
|
||||
push(@dl_library_path, split(/$pthsep/, $ENV{LD_LIBRARY_PATH}));
|
||||
}
|
||||
EOT
|
||||
|
||||
if ($ENV{PERL_BUILD_EXPAND_CONFIG_VARS} && $ENV{PERL_BUILD_EXPAND_ENV_VARS}) {
|
||||
eval $env_dl_library_path;
|
||||
}
|
||||
else {
|
||||
print OUT <<EOT;
|
||||
# Add to \@dl_library_path any extra directories we can gather from environment
|
||||
# during runtime.
|
||||
|
||||
$env_dl_library_path
|
||||
|
||||
EOT
|
||||
}
|
||||
|
||||
if ($ENV{PERL_BUILD_EXPAND_CONFIG_VARS} && $ENV{PERL_BUILD_EXPAND_ENV_VARS}) {
|
||||
my $dl_library_path = dquoted_comma_list(@dl_library_path);
|
||||
print OUT <<EOT;
|
||||
# The below \@dl_library_path has been expanded (%Config, %ENV)
|
||||
# in Perl build time.
|
||||
|
||||
\@dl_library_path = ($dl_library_path);
|
||||
|
||||
EOT
|
||||
}
|
||||
|
||||
print OUT <<'EOT';
|
||||
# No prizes for guessing why we don't say 'bootstrap DynaLoader;' here.
|
||||
# NOTE: All dl_*.xs (including dl_none.xs) define a dl_error() XSUB
|
||||
boot_DynaLoader('DynaLoader') if defined(&boot_DynaLoader) &&
|
||||
!defined(&dl_error);
|
||||
|
||||
if ($dl_debug) {
|
||||
print STDERR "DynaLoader.pm loaded (@INC, @dl_library_path)\n";
|
||||
@ -170,8 +236,8 @@ sub bootstrap {
|
||||
|
||||
print STDERR "DynaLoader::bootstrap for $module ",
|
||||
($Is_MacOS
|
||||
? "(auto/$modpname/$modfname.$dl_dlext)\n" :
|
||||
"(:auto:$modpname:$modfname.$dl_dlext)\n")
|
||||
? "(:auto:$modpname:$modfname.$dl_dlext)\n" :
|
||||
"(auto/$modpname/$modfname.$dl_dlext)\n")
|
||||
if $dl_debug;
|
||||
|
||||
foreach (@INC) {
|
||||
@ -198,7 +264,7 @@ sub bootstrap {
|
||||
croak("Can't locate loadable object for module $module in \@INC (\@INC contains: @INC)")
|
||||
unless $file; # wording similar to error from 'require'
|
||||
|
||||
$file = uc($file) if $Is_VMS && $Config{d_vms_case_sensitive_symbols};
|
||||
$file = uc($file) if $Is_VMS && $Config::Config{d_vms_case_sensitive_symbols};
|
||||
my $bootname = "boot_$module";
|
||||
$bootname =~ s/\W/_/g;
|
||||
@dl_require_symbols = ($bootname);
|
||||
@ -326,7 +392,7 @@ print OUT <<'EOT';
|
||||
# (this is a more complicated issue than it first appears)
|
||||
if (m:/: && -d $_) { push(@dirs, $_); next; }
|
||||
|
||||
# VMS: we may be using native VMS directry syntax instead of
|
||||
# VMS: we may be using native VMS directory syntax instead of
|
||||
# Unix emulation, so check this as well
|
||||
if ($Is_VMS && /[:>\]]/ && -d $_) { push(@dirs, $_); next; }
|
||||
|
||||
|
@ -37,10 +37,12 @@ print OUT ' my $dl_dlext = ', to_string($Config::Config{'dlext'}), ";\n" ;
|
||||
|
||||
print OUT <<'EOT';
|
||||
|
||||
# No prizes for guessing why we don't say 'bootstrap DynaLoader;' here.
|
||||
package DynaLoader;
|
||||
|
||||
# No prizes for guessing why we don't say 'bootstrap DynaLoader;' here.
|
||||
# NOTE: All dl_*.xs (including dl_none.xs) define a dl_error() XSUB
|
||||
boot_DynaLoader('DynaLoader') if defined(&boot_DynaLoader) &&
|
||||
!defined(&dl_load_file);
|
||||
!defined(&dl_error);
|
||||
package XSLoader;
|
||||
|
||||
1; # End of main code
|
||||
|
@ -11,6 +11,8 @@
|
||||
* on statup... It can probably be trimmed more.
|
||||
*/
|
||||
|
||||
#define PERLIO_NOT_STDIO 0
|
||||
|
||||
/*
|
||||
* @(#)dlfcn.c 1.5 revision of 93/02/14 20:14:17
|
||||
* This is an unpublished work copyright (c) 1992 Helios Software GmbH
|
||||
@ -36,6 +38,8 @@
|
||||
#include <sys/types.h>
|
||||
#include <sys/ldr.h>
|
||||
#include <a.out.h>
|
||||
#undef FREAD
|
||||
#undef FWRITE
|
||||
#include <ldfcn.h>
|
||||
|
||||
#ifdef USE_64_BIT_ALL
|
||||
@ -58,13 +62,18 @@
|
||||
/* Older AIX C compilers cannot deal with C++ double-slash comments in
|
||||
the ibmcxx and/or xlC includes. Since we only need a single file,
|
||||
be more fine-grained about what's included <hirschs@btv.ibm.com> */
|
||||
|
||||
#ifdef USE_libC /* The define comes, when it comes, from hints/aix.pl. */
|
||||
# define LOAD loadAndInit
|
||||
# define UNLOAD terminateAndUnload
|
||||
# if defined(USE_xlC_load_h)
|
||||
# include "/usr/lpp/xlC/include/load.h"
|
||||
# if defined(USE_vacpp_load_h)
|
||||
# include "/usr/vacpp/include/load.h"
|
||||
# elif defined(USE_ibmcxx_load_h)
|
||||
# include "/usr/ibmcxx/include/load.h"
|
||||
# elif defined(USE_xlC_load_h)
|
||||
# include "/usr/lpp/xlC/include/load.h"
|
||||
# elif defined(USE_load_h)
|
||||
# include "/usr/include/load.h"
|
||||
# endif
|
||||
#else
|
||||
# define LOAD load
|
||||
@ -85,12 +94,6 @@
|
||||
# define FREAD(p,s,n,ldptr) fread(p,s,n,IOPTR(ldptr))
|
||||
#endif
|
||||
|
||||
/* If using PerlIO, redefine these macros from <ldfcn.h> */
|
||||
#ifdef USE_PERLIO
|
||||
#define FSEEK(ldptr,o,p) PerlIO_seek(IOPTR(ldptr),(p==BEGINNING)?(OFFSET(ldptr)+o):o,p)
|
||||
#define FREAD(p,s,n,ldptr) PerlIO_read(IOPTR(ldptr),p,s*n)
|
||||
#endif
|
||||
|
||||
/*
|
||||
* We simulate dlopen() et al. through a call to load. Because AIX has
|
||||
* no call to find an exported symbol we read the loader section of the
|
||||
@ -116,8 +119,8 @@ typedef struct Module {
|
||||
} Module, *ModulePtr;
|
||||
|
||||
/*
|
||||
* We keep a list of all loaded modules to be able to call the fini
|
||||
* handlers at atexit() time.
|
||||
* We keep a list of all loaded modules to be able to reference count
|
||||
* duplicate dlopen's.
|
||||
*/
|
||||
static ModulePtr modList; /* XXX threaded */
|
||||
|
||||
@ -130,7 +133,7 @@ static int errvalid; /* XXX threaded */
|
||||
|
||||
static void caterr(char *);
|
||||
static int readExports(ModulePtr);
|
||||
static void terminate(void);
|
||||
static void *findMain(void);
|
||||
|
||||
static char *strerror_failed = "(strerror failed)";
|
||||
static char *strerror_r_failed = "(strerror_r failed)";
|
||||
@ -197,15 +200,15 @@ void *dlopen(char *path, int mode)
|
||||
{
|
||||
dTHX;
|
||||
register ModulePtr mp;
|
||||
static int inited; /* XXX threaded */
|
||||
static void *mainModule; /* XXX threaded */
|
||||
|
||||
/*
|
||||
* Upon the first call register a terminate handler that will
|
||||
* close all libraries.
|
||||
*/
|
||||
if (!inited) {
|
||||
inited++;
|
||||
atexit(terminate);
|
||||
if (mainModule == NULL) {
|
||||
if ((mainModule = findMain()) == NULL)
|
||||
return NULL;
|
||||
}
|
||||
/*
|
||||
* Scan the list of modules if have the module already loaded.
|
||||
@ -273,9 +276,13 @@ void *dlopen(char *path, int mode)
|
||||
/*
|
||||
* Assume anonymous exports come from the module this dlopen
|
||||
* is linked into, that holds true as long as dlopen and all
|
||||
* of the perl core are in the same shared object.
|
||||
* of the perl core are in the same shared object. Also bind
|
||||
* against the main part, in the case a perl is not the main
|
||||
* part, e.g mod_perl as DSO in Apache so perl modules can
|
||||
* also reference Apache symbols.
|
||||
*/
|
||||
if (loadbind(0, (void *)dlopen, mp->entry) == -1) {
|
||||
if (loadbind(0, (void *)dlopen, mp->entry) == -1 ||
|
||||
loadbind(0, mainModule, mp->entry)) {
|
||||
int saverrno = errno;
|
||||
|
||||
dlclose(mp);
|
||||
@ -303,7 +310,7 @@ static void caterr(char *s)
|
||||
p++;
|
||||
switch(atoi(s)) {
|
||||
case L_ERROR_TOOMANY:
|
||||
strcat(errbuf, "to many errors");
|
||||
strcat(errbuf, "too many errors");
|
||||
break;
|
||||
case L_ERROR_NOLIB:
|
||||
strcat(errbuf, "can't load library");
|
||||
@ -393,12 +400,6 @@ int dlclose(void *handle)
|
||||
return result;
|
||||
}
|
||||
|
||||
static void terminate(void)
|
||||
{
|
||||
while (modList)
|
||||
dlclose(modList);
|
||||
}
|
||||
|
||||
/* Added by Wayne Scott
|
||||
* This is needed because the ldopen system call calls
|
||||
* calloc to allocated a block of date. The ldclose call calls free.
|
||||
@ -530,11 +531,7 @@ static int readExports(ModulePtr mp)
|
||||
}
|
||||
/* This first case is a hack, since it assumes that the 3rd parameter to
|
||||
FREAD is 1. See the redefinition of FREAD above to see how this works. */
|
||||
#ifdef USE_PERLIO
|
||||
if (FREAD(ldbuf, sh.s_size, 1, ldp) != sh.s_size) {
|
||||
#else
|
||||
if (FREAD(ldbuf, sh.s_size, 1, ldp) != 1) {
|
||||
#endif
|
||||
errvalid++;
|
||||
strcpy(errbuf, "readExports: cannot read loader section");
|
||||
safefree(ldbuf);
|
||||
@ -590,6 +587,52 @@ static int readExports(ModulePtr mp)
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*
|
||||
* Find the main modules entry point. This is used as export pointer
|
||||
* for loadbind() to be able to resolve references to the main part.
|
||||
*/
|
||||
static void * findMain(void)
|
||||
{
|
||||
struct ld_info *lp;
|
||||
char *buf;
|
||||
int size = 4*1024;
|
||||
int i;
|
||||
void *ret;
|
||||
|
||||
if ((buf = safemalloc(size)) == NULL) {
|
||||
errvalid++;
|
||||
strcpy(errbuf, "findMain: ");
|
||||
strerrorcat(errbuf, errno);
|
||||
return NULL;
|
||||
}
|
||||
while ((i = loadquery(L_GETINFO, buf, size)) == -1 && errno == ENOMEM) {
|
||||
safefree(buf);
|
||||
size += 4*1024;
|
||||
if ((buf = safemalloc(size)) == NULL) {
|
||||
errvalid++;
|
||||
strcpy(errbuf, "findMain: ");
|
||||
strerrorcat(errbuf, errno);
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
if (i == -1) {
|
||||
errvalid++;
|
||||
strcpy(errbuf, "findMain: ");
|
||||
strerrorcat(errbuf, errno);
|
||||
safefree(buf);
|
||||
return NULL;
|
||||
}
|
||||
/*
|
||||
* The first entry is the main module. The entry point
|
||||
* returned by load() does actually point to the data
|
||||
* segment origin.
|
||||
*/
|
||||
lp = (struct ld_info *)buf;
|
||||
ret = lp->ldinfo_dataorg;
|
||||
safefree(buf);
|
||||
return ret;
|
||||
}
|
||||
|
||||
/* dl_dlopen.xs
|
||||
*
|
||||
* Platform: SunOS/Solaris, possibly others which use dlopen.
|
||||
@ -642,6 +685,17 @@ dl_load_file(filename, flags=0)
|
||||
else
|
||||
sv_setiv( ST(0), PTR2IV(RETVAL) );
|
||||
|
||||
int
|
||||
dl_unload_file(libref)
|
||||
void * libref
|
||||
CODE:
|
||||
DLDEBUG(1,PerlIO_printf(Perl_debug_log, "dl_unload_file(%lx):\n", libref));
|
||||
RETVAL = (dlclose(libref) == 0 ? 1 : 0);
|
||||
if (!RETVAL)
|
||||
SaveError(aTHX_ "%s", dlerror()) ;
|
||||
DLDEBUG(2,PerlIO_printf(Perl_debug_log, " retval = %d\n", RETVAL));
|
||||
OUTPUT:
|
||||
RETVAL
|
||||
|
||||
void *
|
||||
dl_find_symbol(libhandle, symbolname)
|
||||
|
@ -112,7 +112,7 @@
|
||||
SaveError("%s",dlerror()) ;
|
||||
|
||||
Note that SaveError() takes a printf format string. Use a "%s" as
|
||||
the first parameter if the error may contain and % characters.
|
||||
the first parameter if the error may contain any % characters.
|
||||
|
||||
*/
|
||||
|
||||
@ -198,7 +198,7 @@ int
|
||||
dl_unload_file(libref)
|
||||
void * libref
|
||||
CODE:
|
||||
DLDEBUG(1,PerlIO_printf(Perl_debug_log, "dl_unload_file(%lx):\n", libref));
|
||||
DLDEBUG(1,PerlIO_printf(Perl_debug_log, "dl_unload_file(%lx):\n", PTR2ul(libref)));
|
||||
RETVAL = (dlclose(libref) == 0 ? 1 : 0);
|
||||
if (!RETVAL)
|
||||
SaveError(aTHX_ "%s", dlerror()) ;
|
||||
|
@ -2,9 +2,13 @@
|
||||
use Config;
|
||||
if ($Config{libs} =~ /-lC/ && -f '/lib/libC.a') {
|
||||
$self->{CCFLAGS} = $Config{ccflags} . ' -DUSE_libC';
|
||||
if (-f '/usr/ibmcxx/include/load.h') {
|
||||
if (-f '/usr/vacpp/include/load.h') {
|
||||
$self->{CCFLAGS} .= ' -DUSE_vacpp_load_h';
|
||||
} elsif (-f '/usr/ibmcxx/include/load.h') {
|
||||
$self->{CCFLAGS} .= ' -DUSE_ibmcxx_load_h';
|
||||
} elsif (-f '/usr/lpp/xlC/include/load.h') {
|
||||
$self->{CCFLAGS} .= ' -DUSE_xlC_load_h';
|
||||
} elsif (-f '/usr/include/load.h') {
|
||||
$self->{CCFLAGS} .= ' -DUSE_load_h';
|
||||
}
|
||||
}
|
||||
|
@ -1,3 +1,8 @@
|
||||
Change 171 on 2000-09-12 by <calle@lysator.liu.se> (Calle Dybedahl)
|
||||
|
||||
- Fixed filename-extracting regexp to allow whitespace between
|
||||
"#" and "line", which the cpp on Unicos 9 produces.
|
||||
|
||||
Change 170 on 1998/07/05 by <gbarr@pobox.com> (Graham Barr)
|
||||
|
||||
Fixed three problems reported by Hans Mulder for NeXT
|
||||
|
@ -29,6 +29,14 @@ sub process_file {
|
||||
warn "Cannot open '$file'";
|
||||
return;
|
||||
}
|
||||
} elsif ($Config{gccversion} ne '') {
|
||||
# With the -dM option, gcc outputs every #define it finds
|
||||
my $ccopts = "-E -dM ";
|
||||
$ccopts .= "-traditional-cpp " if $^O eq 'darwin';
|
||||
unless(open(FH,"$Config{cc} $ccopts $file |")) {
|
||||
warn "Cannot open '$file'";
|
||||
return;
|
||||
}
|
||||
} else {
|
||||
unless(open(FH,"< $file")) {
|
||||
# This file could be a temporary file created by cppstdin
|
||||
@ -37,11 +45,19 @@ sub process_file {
|
||||
return;
|
||||
}
|
||||
}
|
||||
while(<FH>) {
|
||||
$err{$1} = 1
|
||||
if /^\s*#\s*define\s+(E\w+)\s+/;
|
||||
}
|
||||
close(FH);
|
||||
|
||||
if ($^O eq 'MacOS') {
|
||||
while(<FH>) {
|
||||
$err{$1} = $2
|
||||
if /^\s*#\s*define\s+(E\w+)\s+(\d+)/;
|
||||
}
|
||||
} else {
|
||||
while(<FH>) {
|
||||
$err{$1} = 1
|
||||
if /^\s*#\s*define\s+(E\w+)\s+/;
|
||||
}
|
||||
}
|
||||
close(FH);
|
||||
}
|
||||
|
||||
my $cppstdin;
|
||||
@ -79,6 +95,18 @@ sub get_files {
|
||||
} elsif ($^O eq 'vmesa') {
|
||||
# OS/390 C compiler doesn't generate #file or #line directives
|
||||
$file{'../../vmesa/errno.h'} = 1;
|
||||
} elsif ($Config{archname} eq 'epoc') {
|
||||
# Watch out for cross compiling for EPOC (usually done on linux)
|
||||
$file{'/usr/local/epoc/include/libc/sys/errno.h'} = 1;
|
||||
} elsif ($^O eq 'linux') {
|
||||
# Some Linuxes have weird errno.hs which generate
|
||||
# no #file or #line directives
|
||||
$file{'/usr/include/errno.h'} = 1;
|
||||
} elsif ($^O eq 'MacOS') {
|
||||
# note that we are only getting the GUSI errno's here ...
|
||||
# we might miss out on compiler-specific ones
|
||||
$file{"$ENV{GUSI}include:sys:errno.h"} = 1;
|
||||
|
||||
} else {
|
||||
open(CPPI,"> errno.c") or
|
||||
die "Cannot open errno.c";
|
||||
@ -102,7 +130,7 @@ sub get_files {
|
||||
$pat = '^/\*\s+(.+)\s+\d+\s*:\s+\*/';
|
||||
}
|
||||
else {
|
||||
$pat = '^#(?:line)?\s*\d+\s+"([^"]+)"';
|
||||
$pat = '^#\s*(?:line)?\s*\d+\s+"([^"]+)"';
|
||||
}
|
||||
while(<CPPO>) {
|
||||
if ($^O eq 'os2' or $^O eq 'MSWin32') {
|
||||
@ -141,31 +169,33 @@ sub write_errno_pm {
|
||||
|
||||
close(CPPI);
|
||||
|
||||
unless ($^O eq 'MacOS') { # trust what we have
|
||||
# invoke CPP and read the output
|
||||
|
||||
if ($^O eq 'VMS') {
|
||||
my $cpp = "$Config{cppstdin} $Config{cppflags} $Config{cppminus}";
|
||||
$cpp =~ s/sys\$input//i;
|
||||
open(CPPO,"$cpp errno.c |") or
|
||||
die "Cannot exec $Config{cppstdin}";
|
||||
} elsif ($^O eq 'MSWin32') {
|
||||
open(CPPO,"$Config{cpprun} $Config{cppflags} errno.c |") or
|
||||
die "Cannot run '$Config{cpprun} $Config{cppflags} errno.c'";
|
||||
} else {
|
||||
my $cpp = default_cpp();
|
||||
open(CPPO,"$cpp < errno.c |")
|
||||
or die "Cannot exec $cpp";
|
||||
}
|
||||
if ($^O eq 'VMS') {
|
||||
my $cpp = "$Config{cppstdin} $Config{cppflags} $Config{cppminus}";
|
||||
$cpp =~ s/sys\$input//i;
|
||||
open(CPPO,"$cpp errno.c |") or
|
||||
die "Cannot exec $Config{cppstdin}";
|
||||
} elsif ($^O eq 'MSWin32') {
|
||||
open(CPPO,"$Config{cpprun} $Config{cppflags} errno.c |") or
|
||||
die "Cannot run '$Config{cpprun} $Config{cppflags} errno.c'";
|
||||
} else {
|
||||
my $cpp = default_cpp();
|
||||
open(CPPO,"$cpp < errno.c |")
|
||||
or die "Cannot exec $cpp";
|
||||
}
|
||||
|
||||
%err = ();
|
||||
%err = ();
|
||||
|
||||
while(<CPPO>) {
|
||||
my($name,$expr);
|
||||
next unless ($name, $expr) = /"(.*?)"\s*\[\s*\[\s*(.*?)\s*\]\s*\]/;
|
||||
next if $name eq $expr;
|
||||
$err{$name} = eval $expr;
|
||||
while(<CPPO>) {
|
||||
my($name,$expr);
|
||||
next unless ($name, $expr) = /"(.*?)"\s*\[\s*\[\s*(.*?)\s*\]\s*\]/;
|
||||
next if $name eq $expr;
|
||||
$err{$name} = eval $expr;
|
||||
}
|
||||
close(CPPO);
|
||||
}
|
||||
close(CPPO);
|
||||
|
||||
# Write Errno.pm
|
||||
|
||||
|
@ -33,13 +33,6 @@
|
||||
--AD October 16, 1995
|
||||
*/
|
||||
|
||||
static int
|
||||
not_here(char *s)
|
||||
{
|
||||
croak("%s not implemented on this architecture", s);
|
||||
return -1;
|
||||
}
|
||||
|
||||
static double
|
||||
constant(char *name, int arg)
|
||||
{
|
||||
|
@ -45,3 +45,5 @@ Revision history for Perl extension File::Glob
|
||||
- Add support for either \ or / as separators on DOSISH systems
|
||||
- Limit effect of \ as a quoting operator on DOSISH systems to
|
||||
when it precedes one of []{}-~\ (to minimise backslashitis).
|
||||
0.992 Tue Mar 20 09:25:48 2001
|
||||
- Add alphabetic sorting for csh compatibility (GLOB_ALPHASORT)
|
||||
|
@ -11,10 +11,15 @@ require AutoLoader;
|
||||
|
||||
@ISA = qw(Exporter AutoLoader);
|
||||
|
||||
# NOTE: The glob() export is only here for compatibility with 5.6.0.
|
||||
# csh_glob() should not be used directly, unless you know what you're doing.
|
||||
|
||||
@EXPORT_OK = qw(
|
||||
csh_glob
|
||||
bsd_glob
|
||||
glob
|
||||
GLOB_ABEND
|
||||
GLOB_ALPHASORT
|
||||
GLOB_ALTDIRFUNC
|
||||
GLOB_BRACE
|
||||
GLOB_CSH
|
||||
@ -33,6 +38,7 @@ require AutoLoader;
|
||||
%EXPORT_TAGS = (
|
||||
'glob' => [ qw(
|
||||
GLOB_ABEND
|
||||
GLOB_ALPHASORT
|
||||
GLOB_ALTDIRFUNC
|
||||
GLOB_BRACE
|
||||
GLOB_CSH
|
||||
@ -47,6 +53,7 @@ require AutoLoader;
|
||||
GLOB_QUOTE
|
||||
GLOB_TILDE
|
||||
glob
|
||||
bsd_glob
|
||||
) ],
|
||||
);
|
||||
|
||||
@ -99,7 +106,13 @@ sub GLOB_ERROR {
|
||||
return constant('GLOB_ERROR', 0);
|
||||
}
|
||||
|
||||
sub GLOB_CSH () { GLOB_BRACE() | GLOB_NOMAGIC() | GLOB_QUOTE() | GLOB_TILDE() }
|
||||
sub GLOB_CSH () {
|
||||
GLOB_BRACE()
|
||||
| GLOB_NOMAGIC()
|
||||
| GLOB_QUOTE()
|
||||
| GLOB_TILDE()
|
||||
| GLOB_ALPHASORT()
|
||||
}
|
||||
|
||||
$DEFAULT_FLAGS = GLOB_CSH();
|
||||
if ($^O =~ /^(?:MSWin32|VMS|os2|dos|riscos|MacOS)$/) {
|
||||
@ -108,12 +121,18 @@ if ($^O =~ /^(?:MSWin32|VMS|os2|dos|riscos|MacOS)$/) {
|
||||
|
||||
# Autoload methods go after =cut, and are processed by the autosplit program.
|
||||
|
||||
sub glob {
|
||||
sub bsd_glob {
|
||||
my ($pat,$flags) = @_;
|
||||
$flags = $DEFAULT_FLAGS if @_ < 2;
|
||||
return doglob($pat,$flags);
|
||||
}
|
||||
|
||||
# File::Glob::glob() is deprecated because its prototype is different from
|
||||
# CORE::glob() (use bsd_glob() instead)
|
||||
sub glob {
|
||||
goto &bsd_glob;
|
||||
}
|
||||
|
||||
## borrowed heavily from gsar's File::DosGlob
|
||||
my %iter;
|
||||
my %entries;
|
||||
@ -127,6 +146,9 @@ sub csh_glob {
|
||||
$pat = $_ unless defined $pat;
|
||||
|
||||
# extract patterns
|
||||
$pat =~ s/^\s+//; # Protect against empty elements in
|
||||
$pat =~ s/\s+$//; # things like < *.c> and <*.c >.
|
||||
# These alone shouldn't trigger ParseWords.
|
||||
if ($pat =~ /\s/) {
|
||||
# XXX this is needed for compatibility with the csh
|
||||
# implementation in Perl. Need to support a flag
|
||||
@ -177,13 +199,13 @@ File::Glob - Perl extension for BSD glob routine
|
||||
=head1 SYNOPSIS
|
||||
|
||||
use File::Glob ':glob';
|
||||
@list = glob('*.[ch]');
|
||||
$homedir = glob('~gnat', GLOB_TILDE | GLOB_ERR);
|
||||
@list = bsd_glob('*.[ch]');
|
||||
$homedir = bsd_glob('~gnat', GLOB_TILDE | GLOB_ERR);
|
||||
if (GLOB_ERROR) {
|
||||
# an error occurred reading $homedir
|
||||
}
|
||||
|
||||
## override the core glob (core glob() does this automatically
|
||||
## override the core glob (CORE::glob() does this automatically
|
||||
## by default anyway, since v5.6.0)
|
||||
use File::Glob ':globally';
|
||||
my @sources = <*.{c,h,y}>
|
||||
@ -198,19 +220,27 @@ File::Glob - Perl extension for BSD glob routine
|
||||
|
||||
=head1 DESCRIPTION
|
||||
|
||||
File::Glob implements the FreeBSD glob(3) routine, which is a superset
|
||||
of the POSIX glob() (described in IEEE Std 1003.2 "POSIX.2"). The
|
||||
glob() routine takes a mandatory C<pattern> argument, and an optional
|
||||
File::Glob::bsd_glob() implements the FreeBSD glob(3) routine, which is
|
||||
a superset of the POSIX glob() (described in IEEE Std 1003.2 "POSIX.2").
|
||||
bsd_glob() takes a mandatory C<pattern> argument, and an optional
|
||||
C<flags> argument, and returns a list of filenames matching the
|
||||
pattern, with interpretation of the pattern modified by the C<flags>
|
||||
variable. The POSIX defined flags are:
|
||||
variable.
|
||||
|
||||
Since v5.6.0, Perl's CORE::glob() is implemented in terms of bsd_glob().
|
||||
Note that they don't share the same prototype--CORE::glob() only accepts
|
||||
a single argument. Due to historical reasons, CORE::glob() will also
|
||||
split its argument on whitespace, treating it as multiple patterns,
|
||||
whereas bsd_glob() considers them as one pattern.
|
||||
|
||||
The POSIX defined flags for bsd_glob() are:
|
||||
|
||||
=over 4
|
||||
|
||||
=item C<GLOB_ERR>
|
||||
|
||||
Force glob() to return an error when it encounters a directory it
|
||||
cannot open or read. Ordinarily glob() continues to find matches.
|
||||
Force bsd_glob() to return an error when it encounters a directory it
|
||||
cannot open or read. Ordinarily bsd_glob() continues to find matches.
|
||||
|
||||
=item C<GLOB_MARK>
|
||||
|
||||
@ -220,18 +250,18 @@ appended.
|
||||
=item C<GLOB_NOCASE>
|
||||
|
||||
By default, file names are assumed to be case sensitive; this flag
|
||||
makes glob() treat case differences as not significant.
|
||||
makes bsd_glob() treat case differences as not significant.
|
||||
|
||||
=item C<GLOB_NOCHECK>
|
||||
|
||||
If the pattern does not match any pathname, then glob() returns a list
|
||||
If the pattern does not match any pathname, then bsd_glob() returns a list
|
||||
consisting of only the pattern. If C<GLOB_QUOTE> is set, its effect
|
||||
is present in the pattern returned.
|
||||
|
||||
=item C<GLOB_NOSORT>
|
||||
|
||||
By default, the pathnames are sorted in ascending ASCII order; this
|
||||
flag prevents that sorting (speeding up glob()).
|
||||
flag prevents that sorting (speeding up bsd_glob()).
|
||||
|
||||
=back
|
||||
|
||||
@ -266,7 +296,7 @@ Expand patterns that start with '~' to user name home directories.
|
||||
=item C<GLOB_CSH>
|
||||
|
||||
For convenience, C<GLOB_CSH> is a synonym for
|
||||
C<GLOB_BRACE | GLOB_NOMAGIC | GLOB_QUOTE | GLOB_TILDE>.
|
||||
C<GLOB_BRACE | GLOB_NOMAGIC | GLOB_QUOTE | GLOB_TILDE | GLOB_ALPHASORT>.
|
||||
|
||||
=back
|
||||
|
||||
@ -275,9 +305,21 @@ extensions C<GLOB_ALTDIRFUNC>, and C<GLOB_MAGCHAR> flags have not been
|
||||
implemented in the Perl version because they involve more complex
|
||||
interaction with the underlying C structures.
|
||||
|
||||
The following flag has been added in the Perl implementation for
|
||||
compatibility with common flavors of csh:
|
||||
|
||||
=over 4
|
||||
|
||||
=item C<GLOB_ALPHASORT>
|
||||
|
||||
If C<GLOB_NOSORT> is not in effect, sort filenames is alphabetical
|
||||
order (case does not matter) rather than in ASCII order.
|
||||
|
||||
=back
|
||||
|
||||
=head1 DIAGNOSTICS
|
||||
|
||||
glob() returns a list of matching paths, possibly zero length. If an
|
||||
bsd_glob() returns a list of matching paths, possibly zero length. If an
|
||||
error occurred, &File::Glob::GLOB_ERROR will be non-zero and C<$!> will be
|
||||
set. &File::Glob::GLOB_ERROR is guaranteed to be zero if no error occurred,
|
||||
or one of the following values otherwise:
|
||||
@ -294,12 +336,12 @@ The glob was stopped because an error was encountered.
|
||||
|
||||
=back
|
||||
|
||||
In the case where glob() has found some matching paths, but is
|
||||
interrupted by an error, glob() will return a list of filenames B<and>
|
||||
In the case where bsd_glob() has found some matching paths, but is
|
||||
interrupted by an error, it will return a list of filenames B<and>
|
||||
set &File::Glob::ERROR.
|
||||
|
||||
Note that glob() deviates from POSIX and FreeBSD glob(3) behaviour by
|
||||
not considering C<ENOENT> and C<ENOTDIR> as errors - glob() will
|
||||
Note that bsd_glob() deviates from POSIX and FreeBSD glob(3) behaviour
|
||||
by not considering C<ENOENT> and C<ENOTDIR> as errors - bsd_glob() will
|
||||
continue processing despite those errors, unless the C<GLOB_ERR> flag is
|
||||
set.
|
||||
|
||||
@ -311,10 +353,10 @@ Be aware that all filenames returned from File::Glob are tainted.
|
||||
|
||||
=item *
|
||||
|
||||
If you want to use multiple patterns, e.g. C<glob "a* b*">, you should
|
||||
probably throw them in a set as in C<glob "{a*,b*}>. This is because
|
||||
the argument to glob isn't subjected to parsing by the C shell. Remember
|
||||
that you can use a backslash to escape things.
|
||||
If you want to use multiple patterns, e.g. C<bsd_glob "a* b*">, you should
|
||||
probably throw them in a set as in C<bsd_glob "{a*,b*}">. This is because
|
||||
the argument to bsd_glob() isn't subjected to parsing by the C shell.
|
||||
Remember that you can use a backslash to escape things.
|
||||
|
||||
=item *
|
||||
|
||||
@ -334,14 +376,32 @@ Win32 users should use the real slash. If you really want to use
|
||||
backslashes, consider using Sarathy's File::DosGlob, which comes with
|
||||
the standard Perl distribution.
|
||||
|
||||
=item *
|
||||
|
||||
Mac OS (Classic) users should note a few differences. Since
|
||||
Mac OS is not Unix, when the glob code encounters a tilde glob (e.g.
|
||||
~user/foo) and the C<GLOB_TILDE> flag is used, it simply returns that
|
||||
pattern without doing any expansion.
|
||||
|
||||
Glob on Mac OS is case-insensitive by default (if you don't use any
|
||||
flags). If you specify any flags at all and still want glob
|
||||
to be case-insensitive, you must include C<GLOB_NOCASE> in the flags.
|
||||
|
||||
The path separator is ':' (aka colon), not '/' (aka slash). Mac OS users
|
||||
should be careful about specifying relative pathnames. While a full path
|
||||
always begins with a volume name, a relative pathname should always
|
||||
begin with a ':'. If specifying a volume name only, a trailing ':' is
|
||||
required.
|
||||
|
||||
=back
|
||||
|
||||
=head1 AUTHOR
|
||||
|
||||
The Perl interface was written by Nathan Torkington E<lt>gnat@frii.comE<gt>,
|
||||
and is released under the artistic license. Further modifications were
|
||||
made by Greg Bacon E<lt>gbacon@cs.uah.eduE<gt> and Gurusamy Sarathy
|
||||
E<lt>gsar@activestate.comE<gt>. The C glob code has the
|
||||
made by Greg Bacon E<lt>gbacon@cs.uah.eduE<gt>, Gurusamy Sarathy
|
||||
E<lt>gsar@activestate.comE<gt>, and Thomas Wegner
|
||||
E<lt>wegner_thomas@yahoo.comE<gt>. The C glob code has the
|
||||
following copyright:
|
||||
|
||||
Copyright (c) 1989, 1993 The Regents of the University of California.
|
||||
|
@ -4,16 +4,9 @@
|
||||
|
||||
#include "bsd_glob.h"
|
||||
|
||||
/* XXX: need some thread awareness */
|
||||
static int GLOB_ERROR = 0;
|
||||
|
||||
static int
|
||||
not_here(char *s)
|
||||
{
|
||||
croak("%s not implemented on this architecture", s);
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
||||
static double
|
||||
constant(char *name, int arg)
|
||||
{
|
||||
@ -27,6 +20,12 @@ constant(char *name, int arg)
|
||||
return GLOB_ABEND;
|
||||
#else
|
||||
goto not_there;
|
||||
#endif
|
||||
if (strEQ(name, "GLOB_ALPHASORT"))
|
||||
#ifdef GLOB_ALPHASORT
|
||||
return GLOB_ALPHASORT;
|
||||
#else
|
||||
goto not_there;
|
||||
#endif
|
||||
if (strEQ(name, "GLOB_ALTDIRFUNC"))
|
||||
#ifdef GLOB_ALTDIRFUNC
|
||||
|
@ -57,6 +57,9 @@ static char sccsid[] = "@(#)glob.c 8.3 (Berkeley) 10/13/93";
|
||||
* expand {1,2}{a,b} to 1a 1b 2a 2b
|
||||
* gl_matchc:
|
||||
* Number of matches in the current invocation of glob.
|
||||
* GLOB_ALPHASORT:
|
||||
* sort alphabetically like csh (case doesn't matter) instead of in ASCII
|
||||
* order
|
||||
*/
|
||||
|
||||
#include <EXTERN.h>
|
||||
@ -76,8 +79,11 @@ static char sccsid[] = "@(#)glob.c 8.3 (Berkeley) 10/13/93";
|
||||
#ifndef MAXPATHLEN
|
||||
# ifdef PATH_MAX
|
||||
# define MAXPATHLEN PATH_MAX
|
||||
# else
|
||||
# define MAXPATHLEN 1024
|
||||
# ifdef MACOS_TRADITIONAL
|
||||
# define MAXPATHLEN 255
|
||||
# else
|
||||
# define MAXPATHLEN 1024
|
||||
# endif
|
||||
# endif
|
||||
#endif
|
||||
|
||||
@ -90,7 +96,11 @@ static char sccsid[] = "@(#)glob.c 8.3 (Berkeley) 10/13/93";
|
||||
#define BG_QUOTE '\\'
|
||||
#define BG_RANGE '-'
|
||||
#define BG_RBRACKET ']'
|
||||
#define BG_SEP '/'
|
||||
#ifdef MACOS_TRADITIONAL
|
||||
# define BG_SEP ':'
|
||||
#else
|
||||
# define BG_SEP '/'
|
||||
#endif
|
||||
#ifdef DOSISH
|
||||
#define BG_SEP2 '\\'
|
||||
#endif
|
||||
@ -448,6 +458,12 @@ glob0(const Char *pattern, glob_t *pglob)
|
||||
int c, err, oldflags, oldpathc;
|
||||
Char *bufnext, patbuf[MAXPATHLEN+1];
|
||||
|
||||
#ifdef MACOS_TRADITIONAL
|
||||
if ( (*pattern == BG_TILDE) && (pglob->gl_flags & GLOB_TILDE) ) {
|
||||
return(globextend(pattern, pglob));
|
||||
}
|
||||
#endif
|
||||
|
||||
qpat = globtilde(pattern, patbuf, pglob);
|
||||
qpatnext = qpat;
|
||||
oldflags = pglob->gl_flags;
|
||||
@ -531,7 +547,8 @@ glob0(const Char *pattern, glob_t *pglob)
|
||||
else if (!(pglob->gl_flags & GLOB_NOSORT))
|
||||
qsort(pglob->gl_pathv + pglob->gl_offs + oldpathc,
|
||||
pglob->gl_pathc - oldpathc, sizeof(char *),
|
||||
(pglob->gl_flags & GLOB_NOCASE) ? ci_compare : compare);
|
||||
(pglob->gl_flags & (GLOB_ALPHASORT|GLOB_NOCASE))
|
||||
? ci_compare : compare);
|
||||
pglob->gl_flags = oldflags;
|
||||
return(0);
|
||||
}
|
||||
@ -541,13 +558,17 @@ ci_compare(const void *p, const void *q)
|
||||
{
|
||||
const char *pp = *(const char **)p;
|
||||
const char *qq = *(const char **)q;
|
||||
int ci;
|
||||
while (*pp && *qq) {
|
||||
if (tolower(*pp) != tolower(*qq))
|
||||
break;
|
||||
++pp;
|
||||
++qq;
|
||||
}
|
||||
return (tolower(*pp) - tolower(*qq));
|
||||
ci = tolower(*pp) - tolower(*qq);
|
||||
if (ci == 0)
|
||||
return compare(p, q);
|
||||
return ci;
|
||||
}
|
||||
|
||||
static int
|
||||
@ -653,7 +674,7 @@ glob3(Char *pathbuf, Char *pathend, Char *pattern,
|
||||
* and dirent.h as taking pointers to differently typed opaque
|
||||
* structures.
|
||||
*/
|
||||
Direntry_t *(*readdirfunc)();
|
||||
Direntry_t *(*readdirfunc)(DIR*);
|
||||
|
||||
*pathend = BG_EOS;
|
||||
errno = 0;
|
||||
@ -689,7 +710,7 @@ glob3(Char *pathbuf, Char *pathend, Char *pattern,
|
||||
|
||||
/* Search directory for matching names. */
|
||||
if (pglob->gl_flags & GLOB_ALTDIRFUNC)
|
||||
readdirfunc = pglob->gl_readdir;
|
||||
readdirfunc = (Direntry_t *(*)(DIR *))pglob->gl_readdir;
|
||||
else
|
||||
readdirfunc = my_readdir;
|
||||
while ((dp = (*readdirfunc)(dirp))) {
|
||||
@ -853,10 +874,15 @@ g_opendir(register Char *str, glob_t *pglob)
|
||||
{
|
||||
char buf[MAXPATHLEN];
|
||||
|
||||
if (!*str)
|
||||
if (!*str) {
|
||||
#ifdef MACOS_TRADITIONAL
|
||||
strcpy(buf, ":");
|
||||
#else
|
||||
strcpy(buf, ".");
|
||||
else
|
||||
#endif
|
||||
} else {
|
||||
g_Ctoc(str, buf);
|
||||
}
|
||||
|
||||
if (pglob->gl_flags & GLOB_ALTDIRFUNC)
|
||||
return((*pglob->gl_opendir)(buf));
|
||||
|
@ -72,6 +72,7 @@ typedef struct {
|
||||
#define GLOB_QUOTE 0x0400 /* Quote special chars with \. */
|
||||
#define GLOB_TILDE 0x0800 /* Expand tilde names from the passwd file. */
|
||||
#define GLOB_NOCASE 0x1000 /* Treat filenames without regard for case. */
|
||||
#define GLOB_ALPHASORT 0x2000 /* Alphabetic, not ASCII sort, like csh. */
|
||||
|
||||
#define GLOB_NOSPACE (-1) /* Malloc call failed. */
|
||||
#define GLOB_ABEND (-2) /* Unignored error. */
|
||||
|
@ -40,6 +40,7 @@ L<perl(1)>, L<DB_File(3)>, L<perldbmfilter>.
|
||||
package GDBM_File;
|
||||
|
||||
use strict;
|
||||
use warnings;
|
||||
our($VERSION, @ISA, @EXPORT, $AUTOLOAD);
|
||||
|
||||
require Carp;
|
||||
@ -53,13 +54,14 @@ use XSLoader ();
|
||||
GDBM_FAST
|
||||
GDBM_INSERT
|
||||
GDBM_NEWDB
|
||||
GDBM_NOLOCK
|
||||
GDBM_READER
|
||||
GDBM_REPLACE
|
||||
GDBM_WRCREAT
|
||||
GDBM_WRITER
|
||||
);
|
||||
|
||||
$VERSION = "1.03";
|
||||
$VERSION = "1.05";
|
||||
|
||||
sub AUTOLOAD {
|
||||
my($constname);
|
||||
|
@ -42,12 +42,14 @@ typedef datum datum_value ;
|
||||
|
||||
typedef void (*FATALFUNC)();
|
||||
|
||||
#ifndef GDBM_FAST
|
||||
static int
|
||||
not_here(char *s)
|
||||
{
|
||||
croak("GDBM_File::%s not implemented on this architecture", s);
|
||||
return -1;
|
||||
}
|
||||
#endif
|
||||
|
||||
/* GDBM allocates the datum with system malloc() and expects the user
|
||||
* to free() it. So we either have to free() it immediately, or have
|
||||
@ -56,7 +58,7 @@ not_here(char *s)
|
||||
static void
|
||||
output_datum(pTHX_ SV *arg, char *str, int size)
|
||||
{
|
||||
#if !defined(MYMALLOC) || (defined(MYMALLOC) && defined(PERL_POLLUTE_MALLOC))
|
||||
#if !defined(MYMALLOC) || (defined(MYMALLOC) && defined(PERL_POLLUTE_MALLOC) && !defined(LEAKTEST))
|
||||
sv_usepvn(arg, str, size);
|
||||
#else
|
||||
sv_setpvn(arg, str, size);
|
||||
@ -121,6 +123,12 @@ constant(char *name, int arg)
|
||||
return GDBM_NEWDB;
|
||||
#else
|
||||
goto not_there;
|
||||
#endif
|
||||
if (strEQ(name, "GDBM_NOLOCK"))
|
||||
#ifdef GDBM_NOLOCK
|
||||
return GDBM_NOLOCK;
|
||||
#else
|
||||
goto not_there;
|
||||
#endif
|
||||
if (strEQ(name, "GDBM_READER"))
|
||||
#ifdef GDBM_READER
|
||||
@ -214,7 +222,7 @@ gdbm_TIEHASH(dbtype, name, read_write, mode, fatal_func = (FATALFUNC)croak)
|
||||
GDBM_FILE dbp ;
|
||||
|
||||
RETVAL = NULL ;
|
||||
if (dbp = gdbm_open(name, GDBM_BLOCKSIZE, read_write, mode, fatal_func)) {
|
||||
if ((dbp = gdbm_open(name, GDBM_BLOCKSIZE, read_write, mode, fatal_func))) {
|
||||
RETVAL = (GDBM_File)safemalloc(sizeof(GDBM_File_type)) ;
|
||||
Zero(RETVAL, 1, GDBM_File_type) ;
|
||||
RETVAL->dbp = dbp ;
|
||||
|
@ -19,8 +19,14 @@ T_DATUM_K
|
||||
$var.dsize = (int)PL_na;
|
||||
T_DATUM_V
|
||||
ckFilter($arg, filter_store_value, \"filter_store_value\");
|
||||
$var.dptr = SvPV($arg, PL_na);
|
||||
$var.dsize = (int)PL_na;
|
||||
if (SvOK($arg)) {
|
||||
$var.dptr = SvPV($arg, PL_na);
|
||||
$var.dsize = (int)PL_na;
|
||||
}
|
||||
else {
|
||||
$var.dptr = \"\";
|
||||
$var.dsize = 0;
|
||||
}
|
||||
OUTPUT
|
||||
T_DATUM_K
|
||||
output_datum(aTHX_ $arg, $var.dptr, $var.dsize);
|
||||
|
@ -136,18 +136,23 @@ io_blocking(InputStream f, int block)
|
||||
|
||||
MODULE = IO PACKAGE = IO::Seekable PREFIX = f
|
||||
|
||||
SV *
|
||||
void
|
||||
fgetpos(handle)
|
||||
InputStream handle
|
||||
CODE:
|
||||
if (handle) {
|
||||
Fpos_t pos;
|
||||
if (
|
||||
#ifdef PerlIO
|
||||
PerlIO_getpos(handle, &pos);
|
||||
PerlIO_getpos(handle, &pos)
|
||||
#else
|
||||
fgetpos(handle, &pos);
|
||||
fgetpos(handle, &pos)
|
||||
#endif
|
||||
ST(0) = sv_2mortal(newSVpv((char*)&pos, sizeof(Fpos_t)));
|
||||
) {
|
||||
ST(0) = &PL_sv_undef;
|
||||
} else {
|
||||
ST(0) = sv_2mortal(newSVpv((char*)&pos, sizeof(Fpos_t)));
|
||||
}
|
||||
}
|
||||
else {
|
||||
ST(0) = &PL_sv_undef;
|
||||
@ -176,7 +181,7 @@ fsetpos(handle, pos)
|
||||
|
||||
MODULE = IO PACKAGE = IO::File PREFIX = f
|
||||
|
||||
SV *
|
||||
void
|
||||
new_tmpfile(packname = "IO::File")
|
||||
char * packname
|
||||
PREINIT:
|
||||
|
@ -71,7 +71,7 @@ corresponding built-in functions:
|
||||
$io->printf ( FMT, [ARGS] )
|
||||
$io->stat
|
||||
$io->sysread ( BUF, LEN, [OFFSET] )
|
||||
$io->syswrite ( BUF, LEN, [OFFSET] )
|
||||
$io->syswrite ( BUF, [LEN, [OFFSET]] )
|
||||
$io->truncate ( LEN )
|
||||
|
||||
See L<perlvar> for complete descriptions of each of the following
|
||||
@ -110,18 +110,19 @@ or a file descriptor number.
|
||||
|
||||
=item $io->opened
|
||||
|
||||
Returns true if the object is currently a valid file descriptor.
|
||||
Returns true if the object is currently a valid file descriptor, false
|
||||
otherwise.
|
||||
|
||||
=item $io->getline
|
||||
|
||||
This works like <$io> described in L<perlop/"I/O Operators">
|
||||
except that it's more readable and can be safely called in an
|
||||
array context but still returns just one line.
|
||||
except that it's more readable and can be safely called in a
|
||||
list context but still returns just one line.
|
||||
|
||||
=item $io->getlines
|
||||
|
||||
This works like <$io> when called in an array context to
|
||||
read all the remaining lines in a file, except that it's more readable.
|
||||
This works like <$io> when called in a list context to read all
|
||||
the remaining lines in a file, except that it's more readable.
|
||||
It will also croak() if accidentally called in a scalar context.
|
||||
|
||||
=item $io->ungetc ( ORD )
|
||||
@ -139,31 +140,37 @@ called C<format_write>.
|
||||
=item $io->error
|
||||
|
||||
Returns a true value if the given handle has experienced any errors
|
||||
since it was opened or since the last call to C<clearerr>.
|
||||
since it was opened or since the last call to C<clearerr>, or if the
|
||||
handle is invalid. It only returns false for a valid handle with no
|
||||
outstanding errors.
|
||||
|
||||
=item $io->clearerr
|
||||
|
||||
Clear the given handle's error indicator.
|
||||
Clear the given handle's error indicator. Returns -1 if the handle is
|
||||
invalid, 0 otherwise.
|
||||
|
||||
=item $io->sync
|
||||
|
||||
C<sync> synchronizes a file's in-memory state with that on the
|
||||
physical medium. C<sync> does not operate at the perlio api level, but
|
||||
operates on the file descriptor, this means that any data held at the
|
||||
perlio api level will not be synchronized. To synchronize data that is
|
||||
buffered at the perlio api level you must use the flush method. C<sync>
|
||||
is not implemented on all platforms. See L<fsync(3c)>.
|
||||
operates on the file descriptor (similar to sysread, sysseek and
|
||||
systell). This means that any data held at the perlio api level will not
|
||||
be synchronized. To synchronize data that is buffered at the perlio api
|
||||
level you must use the flush method. C<sync> is not implemented on all
|
||||
platforms. Returns "0 but true" on success, C<undef> on error, C<undef>
|
||||
for an invalid handle. See L<fsync(3c)>.
|
||||
|
||||
=item $io->flush
|
||||
|
||||
C<flush> causes perl to flush any buffered data at the perlio api level.
|
||||
Any unread data in the buffer will be discarded, and any unwritten data
|
||||
will be written to the underlying file descriptor.
|
||||
will be written to the underlying file descriptor. Returns "0 but true"
|
||||
on success, C<undef> on error.
|
||||
|
||||
=item $io->printflush ( ARGS )
|
||||
|
||||
Turns on autoflush, print ARGS and then restores the autoflush status of the
|
||||
C<IO::Handle> object.
|
||||
C<IO::Handle> object. Returns the return value from print.
|
||||
|
||||
=item $io->blocking ( [ BOOL ] )
|
||||
|
||||
@ -183,11 +190,18 @@ C<IO::Handle::setbuf> and C<IO::Handle::setvbuf> set the buffering
|
||||
policy for an IO::Handle. The calling sequences for the Perl functions
|
||||
are the same as their C counterparts--including the constants C<_IOFBF>,
|
||||
C<_IOLBF>, and C<_IONBF> for setvbuf()--except that the buffer parameter
|
||||
specifies a scalar variable to use as a buffer. WARNING: A variable
|
||||
used as a buffer by C<setbuf> or C<setvbuf> must not be modified in any
|
||||
way until the IO::Handle is closed or C<setbuf> or C<setvbuf> is called
|
||||
again, or memory corruption may result! Note that you need to import
|
||||
the constants C<_IOFBF>, C<_IOLBF>, and C<_IONBF> explicitly.
|
||||
specifies a scalar variable to use as a buffer. You should only
|
||||
change the buffer before any I/O, or immediately after calling flush.
|
||||
|
||||
WARNING: A variable used as a buffer by C<setbuf> or C<setvbuf> B<must not
|
||||
be modified> in any way until the IO::Handle is closed or C<setbuf> or
|
||||
C<setvbuf> is called again, or memory corruption may result! Remember that
|
||||
the order of global destruction is undefined, so even if your buffer
|
||||
variable remains in scope until program termination, it may be undefined
|
||||
before the file IO::Handle is closed. Note that you need to import the
|
||||
constants C<_IOFBF>, C<_IOLBF>, and C<_IONBF> explicitly. Like C, setbuf
|
||||
returns nothing. setvbuf returns "0 but true", on success, C<undef> on
|
||||
failure.
|
||||
|
||||
Lastly, there is a special method for working under B<-T> and setuid/gid
|
||||
scripts:
|
||||
@ -199,7 +213,8 @@ scripts:
|
||||
Marks the object as taint-clean, and as such data read from it will also
|
||||
be considered taint-clean. Note that this is a very trusting action to
|
||||
take, and appropriate consideration for the data source and potential
|
||||
vulnerability should be kept in mind.
|
||||
vulnerability should be kept in mind. Returns 0 on success, -1 if setting
|
||||
the taint-clean flag failed. (eg invalid handle)
|
||||
|
||||
=back
|
||||
|
||||
@ -425,8 +440,11 @@ sub write {
|
||||
|
||||
sub syswrite {
|
||||
@_ >= 2 && @_ <= 4 or croak 'usage: $io->syswrite(BUF [, LEN [, OFFSET]])';
|
||||
$_[2] = length($_[1]) unless defined $_[2];
|
||||
syswrite($_[0], $_[1], $_[2], $_[3] || 0);
|
||||
if (defined($_[2])) {
|
||||
syswrite($_[0], $_[1], $_[2], $_[3] || 0);
|
||||
} else {
|
||||
syswrite($_[0], $_[1]);
|
||||
}
|
||||
}
|
||||
|
||||
sub stat {
|
||||
|
@ -1,3 +1,4 @@
|
||||
|
||||
# IO::Poll.pm
|
||||
#
|
||||
# Copyright (c) 1997-8 Graham Barr <gbarr@pobox.com>. All rights reserved.
|
||||
@ -12,28 +13,31 @@ use Exporter ();
|
||||
our(@ISA, @EXPORT_OK, @EXPORT, $VERSION);
|
||||
|
||||
@ISA = qw(Exporter);
|
||||
$VERSION = "0.01";
|
||||
$VERSION = "0.05";
|
||||
|
||||
@EXPORT = qw(poll);
|
||||
@EXPORT = qw( POLLIN
|
||||
POLLOUT
|
||||
POLLERR
|
||||
POLLHUP
|
||||
POLLNVAL
|
||||
);
|
||||
|
||||
@EXPORT_OK = qw(
|
||||
POLLIN
|
||||
POLLPRI
|
||||
POLLOUT
|
||||
POLLRDNORM
|
||||
POLLWRNORM
|
||||
POLLRDBAND
|
||||
POLLWRBAND
|
||||
POLLNORM
|
||||
POLLERR
|
||||
POLLHUP
|
||||
POLLNVAL
|
||||
);
|
||||
);
|
||||
|
||||
# [0] maps fd's to requested masks
|
||||
# [1] maps fd's to returned masks
|
||||
# [2] maps fd's to handles
|
||||
sub new {
|
||||
my $class = shift;
|
||||
|
||||
my $self = bless [{},{}], $class;
|
||||
my $self = bless [{},{},{}], $class;
|
||||
|
||||
$self;
|
||||
}
|
||||
@ -42,20 +46,21 @@ sub mask {
|
||||
my $self = shift;
|
||||
my $io = shift;
|
||||
my $fd = fileno($io);
|
||||
if(@_) {
|
||||
if (@_) {
|
||||
my $mask = shift;
|
||||
$self->[0]{$fd} ||= {};
|
||||
if($mask) {
|
||||
$self->[0]{$fd}{$io} = $mask;
|
||||
}
|
||||
else {
|
||||
$self->[0]{$fd}{$io} = $mask; # the error events are always returned
|
||||
$self->[1]{$fd} = 0; # output mask
|
||||
$self->[2]{$io} = $io; # remember handle
|
||||
} else {
|
||||
delete $self->[0]{$fd}{$io};
|
||||
delete $self->[1]{$fd} unless %{$self->[0]{$fd}};
|
||||
delete $self->[2]{$io};
|
||||
}
|
||||
}
|
||||
elsif(exists $self->[0]{$fd}{$io}) {
|
||||
|
||||
return unless exists $self->[0]{$fd} and exists $self->[0]{$fd}{$io};
|
||||
return $self->[0]{$fd}{$io};
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@ -64,13 +69,13 @@ sub poll {
|
||||
|
||||
$self->[1] = {};
|
||||
|
||||
my($fd,$ref);
|
||||
my($fd,$mask,$iom);
|
||||
my @poll = ();
|
||||
|
||||
while(($fd,$ref) = each %{$self->[0]}) {
|
||||
my $events = 0;
|
||||
map { $events |= $_ } values %{$ref};
|
||||
push(@poll,$fd, $events);
|
||||
while(($fd,$iom) = each %{$self->[0]}) {
|
||||
$mask = 0;
|
||||
$mask |= $_ for values(%$iom);
|
||||
push(@poll,$fd => $mask);
|
||||
}
|
||||
|
||||
my $ret = @poll ? _poll(defined($timeout) ? $timeout * 1000 : -1,@poll) : 0;
|
||||
@ -80,8 +85,7 @@ sub poll {
|
||||
|
||||
while(@poll) {
|
||||
my($fd,$got) = splice(@poll,0,2);
|
||||
$self->[1]{$fd} = $got
|
||||
if $got;
|
||||
$self->[1]{$fd} = $got if $got;
|
||||
}
|
||||
|
||||
return $ret;
|
||||
@ -91,9 +95,8 @@ sub events {
|
||||
my $self = shift;
|
||||
my $io = shift;
|
||||
my $fd = fileno($io);
|
||||
|
||||
exists $self->[1]{$fd} && exists $self->[0]{$fd}{$io}
|
||||
? $self->[1]{$fd} & $self->[0]{$fd}{$io}
|
||||
exists $self->[1]{$fd} and exists $self->[0]{$fd}{$io}
|
||||
? $self->[1]{$fd} & ($self->[0]{$fd}{$io}|POLLHUP|POLLERR|POLLNVAL)
|
||||
: 0;
|
||||
}
|
||||
|
||||
@ -105,20 +108,16 @@ sub remove {
|
||||
|
||||
sub handles {
|
||||
my $self = shift;
|
||||
|
||||
return map { keys %$_ } values %{$self->[0]}
|
||||
unless(@_);
|
||||
return values %{$self->[2]} unless @_;
|
||||
|
||||
my $events = shift || 0;
|
||||
my($fd,$ev,$io,$mask);
|
||||
my @handles = ();
|
||||
|
||||
while(($fd,$ev) = each %{$self->[1]}) {
|
||||
if($ev & $events) {
|
||||
while(($io,$mask) = each %{$self->[0][$fd]}) {
|
||||
push(@handles, $io)
|
||||
if $events & $mask;
|
||||
}
|
||||
while (($io,$mask) = each %{$self->[0]{$fd}}) {
|
||||
$mask |= POLLHUP|POLLERR|POLLNVAL; # must allow these
|
||||
push @handles,$self->[2]{$io} if ($ev & $mask) & $events;
|
||||
}
|
||||
}
|
||||
return @handles;
|
||||
@ -138,8 +137,8 @@ IO::Poll - Object interface to system poll call
|
||||
|
||||
$poll = new IO::Poll;
|
||||
|
||||
$poll->mask($input_handle => POLLRDNORM | POLLIN | POLLHUP);
|
||||
$poll->mask($output_handle => POLLWRNORM);
|
||||
$poll->mask($input_handle => POLLIN);
|
||||
$poll->mask($output_handle => POLLOUT);
|
||||
|
||||
$poll->poll($timeout);
|
||||
|
||||
|
@ -18,19 +18,69 @@ C<IO::Seekable> does not have a constructor of its own as it is intended to
|
||||
be inherited by other C<IO::Handle> based objects. It provides methods
|
||||
which allow seeking of the file descriptors.
|
||||
|
||||
If the C functions fgetpos() and fsetpos() are available, then
|
||||
C<$io-E<lt>getpos> returns an opaque value that represents the
|
||||
current position of the IO::File, and C<$io-E<gt>setpos(POS)> uses
|
||||
that value to return to a previously visited position.
|
||||
=over 4
|
||||
|
||||
=item $io->getpos
|
||||
|
||||
Returns an opaque value that represents the current position of the
|
||||
IO::File, or C<undef> if this is not possible (eg an unseekable stream such
|
||||
as a terminal, pipe or socket). If the fgetpos() function is available in
|
||||
your C library it is used to implements getpos, else perl emulates getpos
|
||||
using C's ftell() function.
|
||||
|
||||
=item $io->setpos
|
||||
|
||||
Uses the value of a previous getpos call to return to a previously visited
|
||||
position. Returns "0 but true" on success, C<undef> on failure.
|
||||
|
||||
=back
|
||||
|
||||
See L<perlfunc> for complete descriptions of each of the following
|
||||
supported C<IO::Seekable> methods, which are just front ends for the
|
||||
corresponding built-in functions:
|
||||
|
||||
$io->seek( POS, WHENCE )
|
||||
$io->sysseek( POS, WHENCE )
|
||||
$io->tell
|
||||
=over 4
|
||||
|
||||
=item $io->setpos ( POS, WHENCE )
|
||||
|
||||
Seek the IO::File to position POS, relative to WHENCE:
|
||||
|
||||
=over 8
|
||||
|
||||
=item WHENCE=0 (SEEK_SET)
|
||||
|
||||
POS is absolute position. (Seek relative to the start of the file)
|
||||
|
||||
=item WHENCE=1 (SEEK_CUR)
|
||||
|
||||
POS is an offset from the current position. (Seek relative to current)
|
||||
|
||||
=item WHENCE=1 (SEEK_END)
|
||||
|
||||
POS is an offset from the end of the file. (Seek relative to end)
|
||||
|
||||
=back
|
||||
|
||||
The SEEK_* constants can be imported from the C<Fcntl> module if you
|
||||
don't wish to use the numbers C<0> C<1> or C<2> in your code.
|
||||
|
||||
Returns C<1> upon success, C<0> otherwise.
|
||||
|
||||
=item $io->sysseek( POS, WHENCE )
|
||||
|
||||
Similar to $io->seek, but sets the IO::File's position using the system
|
||||
call lseek(2) directly, so will confuse most perl IO operators except
|
||||
sysread and syswrite (see L<perlfunc> for full details)
|
||||
|
||||
Returns the new position, or C<undef> on failure. A position
|
||||
of zero is returned as the string C<"0 but true">
|
||||
|
||||
=item $io->tell
|
||||
|
||||
Returns the IO::File's current position, or -1 on error.
|
||||
|
||||
=back
|
||||
|
||||
=head1 SEE ALSO
|
||||
|
||||
L<perlfunc>,
|
||||
|
@ -56,6 +56,7 @@ sub exists
|
||||
sub _fileno
|
||||
{
|
||||
my($self, $f) = @_;
|
||||
return unless defined $f;
|
||||
$f = $f->[0] if ref($f) eq 'ARRAY';
|
||||
($f =~ /^\d+$/) ? $f : fileno($f);
|
||||
}
|
||||
@ -300,9 +301,9 @@ Return an array of all registered handles.
|
||||
=item can_read ( [ TIMEOUT ] )
|
||||
|
||||
Return an array of handles that are ready for reading. C<TIMEOUT> is
|
||||
the maximum amount of time to wait before returning an empty list. If
|
||||
C<TIMEOUT> is not given and any handles are registered then the call
|
||||
will block.
|
||||
the maximum amount of time to wait before returning an empty list, in
|
||||
seconds, possibly fractional. If C<TIMEOUT> is not given and any
|
||||
handles are registered then the call will block.
|
||||
|
||||
=item can_write ( [ TIMEOUT ] )
|
||||
|
||||
|
@ -361,7 +361,7 @@ perform the system call C<accept> on the socket and return a new object. The
|
||||
new object will be created in the same class as the listen socket, unless
|
||||
C<PKG> is specified. This object can be used to communicate with the client
|
||||
that was trying to connect. In a scalar context the new socket is returned,
|
||||
or undef upon failure. In an array context a two-element array is returned
|
||||
or undef upon failure. In a list context a two-element array is returned
|
||||
containing the new socket and the peer address; the list will
|
||||
be empty upon failure.
|
||||
|
||||
|
@ -34,6 +34,7 @@ sub new {
|
||||
|
||||
sub _sock_info {
|
||||
my($addr,$port,$proto) = @_;
|
||||
my $origport = $port;
|
||||
my @proto = ();
|
||||
my @serv = ();
|
||||
|
||||
@ -59,14 +60,14 @@ sub _sock_info {
|
||||
my $defport = $1 || undef;
|
||||
my $pnum = ($port =~ m,^(\d+)$,)[0];
|
||||
|
||||
if ($port =~ m,\D,) {
|
||||
unless (@serv = getservbyname($port, $proto[0] || "")) {
|
||||
$@ = "Bad service '$port'";
|
||||
return;
|
||||
}
|
||||
}
|
||||
@serv = getservbyname($port, $proto[0] || "")
|
||||
if ($port =~ m,\D,);
|
||||
|
||||
$port = $pnum || $serv[2] || $defport || undef;
|
||||
unless (defined $port) {
|
||||
$@ = "Bad service '$origport'";
|
||||
return;
|
||||
}
|
||||
|
||||
$proto = (getprotobyname($serv[3]))[2] || undef
|
||||
if @serv && !$proto;
|
||||
@ -150,11 +151,16 @@ sub configure {
|
||||
$sock->socket(AF_INET, $type, $proto) or
|
||||
return _error($sock, $!, "$!");
|
||||
|
||||
if ($arg->{Reuse}) {
|
||||
if ($arg->{Reuse} || $arg->{ReuseAddr}) {
|
||||
$sock->sockopt(SO_REUSEADDR,1) or
|
||||
return _error($sock, $!, "$!");
|
||||
}
|
||||
|
||||
if ($arg->{ReusePort}) {
|
||||
$sock->sockopt(SO_REUSEPORT,1) or
|
||||
return _error($sock, $!, "$!");
|
||||
}
|
||||
|
||||
if($lport || ($laddr ne INADDR_ANY) || exists $arg->{Listen}) {
|
||||
$sock->bind($lport || 0, $laddr) or
|
||||
return _error($sock, $!, "$!");
|
||||
@ -301,7 +307,9 @@ C<IO::Socket::INET> provides.
|
||||
Proto Protocol name (or number) "tcp" | "udp" | ...
|
||||
Type Socket type SOCK_STREAM | SOCK_DGRAM | ...
|
||||
Listen Queue size for listen
|
||||
Reuse Set SO_REUSEADDR before binding
|
||||
ReuseAddr Set SO_REUSEADDR before binding
|
||||
Reuse Set SO_REUSEADDR before binding (deprecated, prefer ReuseAddr)
|
||||
ReusePort Set SO_REUSEPORT before binding
|
||||
Timeout Timeout value for various operations
|
||||
MultiHomed Try all adresses for multi-homed hosts
|
||||
|
||||
|
@ -37,7 +37,7 @@ sub configure {
|
||||
$sock->bind($addr) or
|
||||
return undef;
|
||||
}
|
||||
if(exists $arg->{Listen}) {
|
||||
if(exists $arg->{Listen} && $type != SOCK_DGRAM) {
|
||||
$sock->listen($arg->{Listen} || 5) or
|
||||
return undef;
|
||||
}
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user