GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
Module::Install::XSUtil(3) User Contributed Perl Documentation Module::Install::XSUtil(3)
 

Module::Install::XSUtil - Utility functions for XS modules

This document describes Module::Install::XSUtil version 0.45.

    # in Makefile.PL
    use inc::Module::Install;
    # Enables C compiler warnings
    cc_warnings;
    # Uses ppport.h
    # No need to include it. It's created here.
    use_ppport 3.19;
    # Sets C pre-processor macros.
    cc_define q{-DUSE_SOME_FEATURE=42};
    # Sets paths for header files
    cc_include_paths 'include'; # all the header files are in include/
    # Sets paths for source files
    cc_src_paths 'src'; # all the XS and C source files are in src/
    # Installs header files
    install_headers; # all the header files in @cc_include_paths

Module::Install::XSUtil provides a set of utilities to setup distributions which include or depend on XS module.
See XS::MRO::Compat and Method::Cumulative for example.

Returns true if a C compiler is available. YOU DO NOT NEED TO CALL THIS FUNCTION YOURSELF: it will be called for you when this module is initialized, and your Makefile.PL process will exit with 0 status. Only explicitly call if you need to do some esoteric handling when no compiler is available (for example, when you have a pure perl alternative)

Returns true if a C compiler is available and it supports C99 features.

Returns true if the user asked for the XS version or pure perl version of the module.
Will return true if "--xs" is explicitly specified as the argument to Makefile.PL, and false if "--pp" is specified. If neither is explicitly specified, will return the value specified by $default. If you do not specify the value of $default, then it will be true.

Creates ppport.h using "Devel::PPPort::WriteFile()".
This command calls "configure_requires 'Devel::PPPort' => $version" and adds "-DUSE_PPPORT" to "MakeMaker"'s "DEFINE".

Create s xshelper.h, which is a helper header file to include EXTERN.h, perl.h, XSUB.h and ppport.h, and defines some portability stuff which are not supported by ppport.h.
Optional argument "-clean" and "-realclean" set "clean_files" or "realclean_files" to the generated file xshelper.h respectably.
This command includes "use_ppport".

Enables C compiler warnings.

Sets "cpp" macros as compiler options.

Sets source file directories which include *.xs or *.c.

Sets include paths for a C compiler.

This was an alias to "cc_include_paths", but from 0.42, this is "Module::Install::Compiler::cc_inc_paths", which replaces the EUMM's "INC" parameter.
Don't use this function. Use "cc_include_paths" instead.

Sets "MakeMaker"'s "LIBS". If a name starts "-", it will be interpreted as is. Otherwise prefixed "-l".
e.g.:
    cc_libs -lfoo;
    cc_libs  'foo'; # ditto.
    cc_libs qw(-L/path/to/libs foo bar); # with library paths

Checks if the given C library is installed via Devel::CheckLib. Takes exactly what Devel::CheckLib takes. Note that you must pass the path names explicitly.

Tells the build system to use C99 features.

Tells the build system to use C++ language.

Declares providing header files, extracts functions from these header files, and adds these functions to "MakeMaker"'s "FUNCLIST".
If @header_files are omitted, all the header files in include paths will be installed.

Low level API.

Low level API.

Low level API.

Low level API.

Under the control of this module, Makefile.PL accepts "-g" option, which sets "MakeMaker"'s "OPTIMIE" "-g" (or something like). It will disable optimization and enable some debugging features.

Perl 5.5.3 or later.

In Makefile.PL, you might want to use "author_requires", which is provided by "Module::Install::AuthorReauires", in order to tell co-developers that they need to install this plugin.
    author_requires 'Module::Install::XSUtil';

No bugs have been reported.
Please report any bugs or feature requests to the author.

Thanks to Taro Nishino for the test reports.
Tanks to lestrrat for the suggestions and patches.

Goro Fuji (gfx) <gfuji(at)cpan.org>.

ExtUtils::Depends.
Module::Install.
Module::Install::CheckLib.
Devel::CheckLib.
ExtUtils::MakeMaker.

Copyright (c) 2009-2010, Goro Fuji (gfx). All rights reserved.
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
2014-01-30 perl v5.28.1

Search for    or go to Top of page |  Section 3 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.