summaryrefslogtreecommitdiff
path: root/Porting/pod_lib.pl
Commit message (Collapse)AuthorAgeFilesLines
* Remove spurious executable bit from Porting/pod_lib.plDagfinn Ilmari Mannsåker2016-11-171-0/+0
|
* Account for possibility of DOS file endings.James E Keenan2016-11-161-1/+1
| | | | | | | | | Although our source code (including this file) is supposed to have only Unix line endings, cloning, etc., can result in particular users having DOS line endings. Let's allow '\r\n' to avoid spurious testing or installation problems. For: RT #130088, as recommended by Mark E Renzulli (UTRC).
* RT#129229: move sort_manifest() into its own libraryAaron Crane2016-10-241-29/+0
| | | | | | This means that the MANIFEST.srt target in the Makefile no longer needs to load a library that depends on Cwd (and other potentially-dynamic modules). That in turn fixes a missing-dependency bug in the Makefile.
* change manisort to produce a more intuitive orderYves Orton2016-06-221-0/+29
| | | | | | | | | | | | | | | | | | | | Dictionary sort order on filenames is very counter-intuitive, and produces surprising sort orders. What this patch does is sort things so that the following should always be true: 1. Case insensitive textual order Eg: Foo and foo and FOO should sort together in ascibetical order 2. Shorter dirs go before longer dirs with a common prefix Eg: lib/Foo/ should go before lib/Foo-Thing/ 3. Base filename goes before dir of the same name Eg: lib/Foo.pm should sort before lib/Foo/Bar.pm This also refactors the MANIFEST sort code in Porting/manisort and Porting/pod_rules.pm files into Porting/pod_lib.pl
* Replace common Emacs file-local variables with dir-localsDagfinn Ilmari Mannsåker2015-03-221-5/+0
| | | | | | | | | | | | | | | | An empty cpan/.dir-locals.el stops Emacs using the core defaults for code imported from CPAN. Committer's work: To keep t/porting/cmp_version.t and t/porting/utils.t happy, $VERSION needed to be incremented in many files, including throughout dist/PathTools. perldelta entry for module updates. Add two Emacs control files to MANIFEST; re-sort MANIFEST. For: RT #124119.
* x2p is gone, do not install its pod.Jarkko Hietaniemi2014-06-021-2/+0
|
* Amend pod_lib.pl to work with miniperl (no dynamic loading)Jess Robinson2013-12-181-1/+13
| | | | | This is to allow cross-compilation builds to run installperl using a host miniperl instead of the built Perl binary.
* Move process() from Porting/pod_rules.pl to Porting/pod_lib.plNicholas Clark2013-07-241-0/+72
| | | | And document it.
* Move verify_contiguous() from Porting/pod_rules.pl to Porting/pod_lib.plNicholas Clark2013-07-241-0/+42
| | | | And document it.
* typo fixes for porting scriptsDavid Steinbrunner2013-05-241-1/+1
|
* Provide file and subroutine-level documentation in POD format.James E Keenan2013-04-141-2/+220
| | | | | | | Incorporate Nicholas Clark's suggestions. Correct pod formatting errors. For: RT #117003
* Reinstate dummy ignoredpods functionalityRafael Garcia-Suarez2012-03-311-6/+4
| | | | | | The stub manpages (perlboot, perltoot, etc.) are listed in perl.pod, so they don't need to be ignored by buildtoc. They weren't ignored anyway, since the %ignoredpods hash was, well, ignored.
* Add perltodo in the list of ignored podsRafael Garcia-Suarez2012-03-311-1/+1
| | | | (like the other obsolete manpage placeholders)
* is_duplicate_pod() and get_pod_metadata() in pod_lib.pl modified $_smoke-me/bleadNicholas Clark2012-02-071-0/+2
| | | | | | | Reported by Reini Urban in RT #110078, installperl generated a warning and failed to install CORE.pod, because is_duplicate_pod() modified $_ is_duplicate_pod() and get_pod_metadata() now both localise $_, to ensure that they don't corrupt any caller's state.
* Add x2p/a2p.pod to the 'master' array returned by get_pod_metadata().Nicholas Clark2011-12-241-0/+2
| | | | | | | | | | This makes installman install it correctly. Flagging it as 'toc_omit' means that everything else ignores it. This eliminates the last remaining use of the "pod =" feature of utils.lst, permitting related code to be removed from installperl and installman. This change has the possibly unfortunate cosmetic side effect of installman now installing a2p.1 first, before perl.1
* In pods_to_install(), use $File::Find::prune to skip t/ directories.Nicholas Clark2011-12-241-1/+5
| | | | | | | We don't want to install anything within a t/ directory. Previously the code was determining this based on pattern matching the path. Instead of rejecting what we find, it's more efficient to avoid scanning the directory tree in the first place.
* Move the common Pod scanning code from installman and buildtoc to pod_lib.plNicholas Clark2011-12-241-0/+31
| | | | | | | The unified code to scan lib/ for Pod is now in pods_to_install(). It returns found Pods partitioned into 'MODULE' and 'PRAGMA', as buildtoc needs this distinction. installman installs Pods in the same order as before, as 'PRAGMA' sort lexically after 'MODULE'.
* Re-order entries in the 'master' array returned by get_pod_metadata().Nicholas Clark2011-12-211-7/+7
| | | | Now it returns just the pod's name, its filename, and the flags (if any).
* Prune unused entries from the 'master' array returned by get_pod_metadata().Nicholas Clark2011-12-211-6/+5
| | | | | | | | | | | The description is only used to generate MANIFEST entries now from 'readmes' and 'pods'. now that perl.pod is the master and is no longer generated from pod.lst The leafname/podname distinction is only used by is_duplicate_pod(), so can be replaced by simple flag, 'dual'. Replace the now-unused entries with undef to preserve the indices.
* Rationalise use of the Pod metadata structure returned by get_pod_metadata().Nicholas Clark2011-12-211-10/+4
| | | | | | | | | | | | | | | | Nothing uses the entries in the 'master' array for the for the elements flagged as 'aux', so don't generate them. Only buildtoc uses the the 'aux' hash, and only the keys in sorted order, so replace the hash with a sorted array. All entries in the 'master' array are now defined, and references to 5 element arrays, so remove code that checks for this. Likewise, as the 'aux' flag is no longer used, remove code related to it. When generating the entries for README files in %our_pods in the consistency checking code in get_pod_metadata, $_->[4] and $_->[1] will always be equal, as no READMEs are copied from dual life modules. So use $_->[1] instead, as this permits a future simplification.
* Eliminate pod.lst. pod/perl.pod is now the master file for Pod metadata.Nicholas Clark2011-12-211-58/+85
| | | | | | | | perl.pod already contained virtually all the information in pod.lst. Add the remainder as =begin and =for Pod blocks. As perl.pod no longer needs to be regenerated, remove the redundant code from Porting/pod_rules.pl. Update (nearly) all references to pod.lst.
* Some pod_lib.pl cleanups.Nicholas Clark2011-12-191-7/+6
| | | | | Eliminate the file-scoped lexical %Readmepods. Use slurp_or_die() instead of coding it longhand.
* Prime the duplicate Pod cache the first time is_duplicate_pod() is called.Nicholas Clark2011-12-191-16/+24
| | | | | | | | | | | | Previously it was primed when get_pod_metadata() was called. This removes the undocumented assumption that is_duplicate_pod() will only be called after get_pod_metadata(), and avoids reading 14 Pod files to calculate their MD5s unless actually necessary. This change means that the array references in @{$state{master}} are being accessed much later during runtime. This reveals that podset() in buildtoc had been clobbering its callers $_, which happened to be an alias to the current element of @{$state{master}}.
* In pod_lib.pl, split out the code that initialises %state from pod.lstNicholas Clark2011-12-191-23/+27
| | | | It's now extracted from get_pod_metadata() into __prime_state().
* Change get_pod_metadata() to take a callback to report consistency errors.Nicholas Clark2011-12-191-1/+5
| | | | | | Using the callback to report errors instead of passing the 'inconsistent' arrayref back in the state means that get_pod_metadata() doesn't even need to calculate this information if it's not going to be used.
* Move the pod de-duplication logic from buildtoc to pod_lib.plNicholas Clark2011-12-191-0/+20
| | | | | is_duplicate_pod() moves. register_duplicate_pod() can be inlined into get_pod_metadata().
* Porting/pod_rules.pl should not warn about files that it is rebuilding.Nicholas Clark2011-11-181-12/+21
| | | | | Previously it would generate warnings about inconsistencies in files, even if it was about to rewrite the file to be consistent.
* Add Porting/new-perldelta.pl, which automates adding a new perldelta.Nicholas Clark2011-11-181-2/+21
| | | | | | Strictly, "mostly automates", as it doesn't run `git add`, or test that the build is clean. However, it simplifies a gnarly step in the release manager's guide, so it's progress.
* Flag to get_pod_metadata() whether generated files are expected.Nicholas Clark2011-11-181-2/+13
| | | | | This permits Porting/pod_rules.pl to be run from a clean checkout without warning, which simplifies updating perl's version.
* Refactor pod_lib.pl's get_pod_metadata() to remove a temporary array.Nicholas Clark2011-11-181-8/+7
| | | | | | | | The intermediate array @cpanpods can be avoided by generating the lookup hashes directly. Rename %cpanpods_short to %cpanpods_leaf and $shortname to $leafname, as this makes it clearer that each deals with leafnames.
* In pod_lib.pl's get_pod_metadata(), generate lookup hashes directly.Nicholas Clark2011-11-181-12/+5
| | | | | | | | | | Previously the code was structured to build arrays for various categories of files, then generate hashes from those arrays. However, the arrays had no other purpose, and the values in the hashes were only needed for truth tests, so it's better to generate the lookup hashes directly. @disk_pods hasn't actually been used since commit d5e2eea989a69524 refactored pod/buildtoc to no longer chdir to the pod/ directory.
* Extract from buildtoc the code that processes pod.lst, MANIFEST and perl.podNicholas Clark2011-11-181-0/+208
This will permit splitting pod/buildtoc into two - one script used during the build process to build pod/perltoc.pod, and used by maintainers to regenerate sections of various Makefiles.