8.85. ExtUtils::MM_UnixProvides methods for MakeMaker to handle portability issues. You never need to require this module, but you might want to if you are working on improving MakeMaker's portability Provides methods for both Unix and non-Unix systems; on non-Unix systems, they can be overridden by methods defined in other MM_* modules. The methods are the following.
catdir list Concatenates a list of directory names to form a complete path ending with a directory. On Unix, joins the names with /.
catfile list Concatenates one or more directory names and a filename to form a complete path ending with a filename. On Unix, joins the names with /.
dir_target array Takes an array of required directory names and returns a Makefile entry to create an .exists file in the directories. Returns nothing if the entry has already been processed.
file_name_is_absolute filename Takes a path as argument and returns true if it is an absolute path.
find_perl version, \names, \dirs, trace Searches for an executable Perl. Takes the following arguments:
guess_name Guesses the name of the package based on the working directory's name. Called only if the NAME attribute is missing.
has_link_code Returns true if there are C, XS, MYEXTLIB, or similar objects in this object that need a compiler. Does not descend into subdirectories.
libscan filename Uses init_dirscan to find a file; returns false if the file should not be included in the library. Used primarily to keep revision-control directories from being installed.
lsdir dir, regexp Returns all entries in the specified directory that match the regular expression. Takes the following arguments:
maybe_command filename Returns true if filename is likely to be a command.
maybe_command_in_dirs For future use.
needs_linking Returns true if the module needs linking. Searches subdirectories.
nicetext target The MM_Unix version returns the argument with no processing.
path Returns PATH environment variable as an array.
perl_script filename Returns true if filename is likely to be a Perl script. With MM_Unix, this is true for any ordinary, readable file.
prefixify attrname, oldprefix, newprefix Processes a path attribute in $self->{ attrname }. Looks up the attribute in %Config if it doesn't have a value. Takes the following arguments:
replace_manpage_separator filename Takes the filename of a package and replaces the subdirectory delimiter (/ in Unix) with ::. Returns the altered name. 8.85.1. Methods to Produce the MakefileExtUtils::MM_Unix has some additional methods that are called in sequence to produce a Makefile. The list of methods is specified in the array @ExtUtils::MakeMaker::MM_Sections, one method per section. The routines are all called the same way and so are just listed here. Each method returns the string to be put into its section of the Makefile. The methods are called in the order that they are listed in the following table, reading down the columns:
Finally, there are two special methods: post_initialize and postamble. They each return an empty string by default and can be defined in Makefile.PL to insert customized text near the beginning or end of the Makefile. Copyright © 2002 O'Reilly & Associates. All rights reserved. |
|