Skip to content

Commit 7f39214

Browse files
committed
Merge branch 'doc-fixes'
This improves the documentation of Module::Build::Compat and dynamic_config
2 parents 1432245 + 7ecae7e commit 7f39214

File tree

2 files changed

+22
-7
lines changed

2 files changed

+22
-7
lines changed

lib/Module/Build/API.pod

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -356,17 +356,16 @@ L</module_name>.
356356
[version 0.07]
357357

358358
A boolean flag indicating whether the F<Build.PL> file must be
359-
executed, or whether this module can be built, tested and installed
359+
executed to determine prerequisites, or whether they can be determined
360360
solely from consulting its metadata file. The main reason to set this
361-
to a true value is that your module performs some dynamic
362-
configuration as part of its build/install process. If the flag is
363-
omitted, the F<META.yml> spec says that installation tools should
364-
treat it as 1 (true), because this is a safer way to behave.
361+
to a true value is that your module adds or removes prerequisites
362+
dynamically in F<Build.PL>. If the flag is omitted, it will be treated
363+
as 1 (true), because this is a safer way to behave.
365364

366365
Currently C<Module::Build> doesn't actually do anything with this flag
367366
- it's up to higher-level tools like C<CPAN.pm> to do something useful
368-
with it. It can potentially bring lots of security, packaging, and
369-
convenience improvements.
367+
with it. It can also be very helpful for static analysis. See
368+
L<CPAN::Meta::Spec/dynamic_config> for details on the metadata field.
370369

371370
=item extra_compiler_flags
372371

lib/Module/Build/Compat.pm

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -477,6 +477,13 @@ F<Makefile.PL> for you, in one of several different styles.
477477
C<Module::Build::Compat> also provides some code that helps out the
478478
F<Makefile.PL> at runtime.
479479
480+
=head1 WARNING
481+
482+
Note that C<Module::Build::Compat> more often causes installation issues
483+
than solves them, and each of the three F<Makefile.PL> generation styles
484+
has unique compatibility or functionality issues that are unlikely to be
485+
fixed. Thus, the use of this module and C<create_makefile_pl> is
486+
discouraged.
480487
481488
=head1 METHODS
482489
@@ -506,6 +513,8 @@ You don't want to use this style if during the C<perl Build.PL> stage
506513
you ask the user questions, or do some auto-sensing about the user's
507514
environment, or if you subclass C<Module::Build> to do some
508515
customization, because the vanilla F<Makefile.PL> won't do any of that.
516+
Many standard C<Module::Build> features such as C<test_requires> are also
517+
not supported.
509518
510519
=item small
511520
@@ -514,6 +523,13 @@ through to the F<Build.PL> script in the same directory. The user must
514523
already have C<Module::Build> installed in order to use this, or else
515524
they'll get a module-not-found error.
516525
526+
This style attempts (with varying success) to translate the F<Makefile.PL>
527+
protocol to F<Build.PL>, and is unnecessary on any modern toolchain that
528+
recognizes C<configure_requires> metadata described below, as F<Build.PL>
529+
will be run by default in this case. See
530+
L<https://rt.cpan.org/Public/Bug/Display.html?id=75936> for an example of
531+
the issues it may cause.
532+
517533
=item passthrough (DEPRECATED)
518534
519535
This is just like the C<small> option above, but if C<Module::Build> is

0 commit comments

Comments
 (0)