[Bioperl-l] Spankin' new (alpha) build system for Bioperl-Run

Mark A. Jensen maj at fortinbras.us
Tue Sep 30 03:41:33 UTC 2014

All (esp. George)-

My work on Issue #11 (https://github.com/bioperl/bioperl-run/issues/11) 
has metastasized.

The proximate problem was tests that fail because of once-local 
prerequisites. The ultimate
problems are

- Why should I have to install every single wrapper when I only want X?
- Why should I care about any test that doesn't deal with X?
- Why doesn't X bring along its own prereq metadata (including Bio 
   rather than tag along with the distro and hope for the best?

(And I think these are the ultimate problems across BioPerl in terms of 

My solution was

- Add to the distro real, manually prepared metadata on prerequisites 
for all
   the tools
- Add an interactive selector that allows a user to pick their desired 
tools at
   perl Build.PL-time
- Have Module::Build check only (and ALL) the prereqs of the desired 
tools, and
   inform user of missing ones at perl Build.PL-time
- Make use of the persistence of the config information to skip/run .t 
files as
- Update ALL the tests to check whether to skip based on user selection
- Make M::B install only the relevant distro modules and documentation, 
not everything,
   at ./Build install-time

This is ready for brave alpha-testers at 
Just do 'perl Build.PL'.

Pod below has some more details-- comments very welcome


     Bio::Tools::Run::Build - Instrument the build for features



     Bio::Tools::Run::Build is a subclass of Module::Build that allows 
     author to offer users the ability to select and install 
     subsets of modules that are packaged in a single large M::B-based

     Grouping and selection of distro modules is driven by the optional
     features concept as defined in CPAN::Meta::Spec and used by

     The subclass provides the following:

     *   Author specification of features and their prereqs

         The build author develops metadata files in json that follow
         "optional_features" in CPAN::Meta::Spec to group distribution
         modules and dependencies as selectable features.

     *   Interactive user selection of features

         The user can be presented with an interactive selector during
         Build.PL runs.

     *   Prereq checking of user selected features only

         M::B only checks for the presence of selected feature 

     *   Build-persistent recording of user selections

         The build object records the selection of features in the
         $build->feature field. This can be used in test files to 
         whether tests should be skipped (and not failed). See

     *   Installation only of selected feature modules

         Bio::Tools::Run::Build adds a build action, "deselect", which 
         after the "code" and "docs" actions. "deselect" removes 
         modules from the blib/lib directory and unneeded documentation 
         the blib/libdoc directory. This keeps the "install" action from
         installing unwanted files.

     The BioPerl-Run distribution contains a large variety of wrappers 
     parsers that handle the execution and output of many different
     bioinformatics tools. It has been provided as a large distro that
     installs and attempts to test all of its modules. Many users need 
only a
     small fraction of the functionality BioPerl-Run provides, relevant 
     to the tools they have installed. On the other hand, managing many
     different packages is unwieldy and uninviting for volunteer 

     The system described here is a compromise that enables a user to 
     test and install only those modules that meet the need, yet reduces 
     maintenance effort to the management of a set of metadata files in 
     single distribution.


More information about the Bioperl-l mailing list