[Slapt-get-user] cpan2tgz bug

Jason Woodward woodwardj at jaos.org
Thu Feb 13 20:53:06 EST 2014


Hi Steve,

> I have found what I believe to be a bug in cpan2tgz. When it
comes time
> to
> "install" the newly built module into a package
directory, the
> script
> looks for the existence of a "Build" file in the
build
> directory
> (evidence of the Module::Build mechanism) and if it
finds that it
> issues
> the following command:
> 
> ./Build install
destdir=$dest_dir
> 
> where
> $dest_dir is the package directory.
> 
>
This works fine unless the module
> happens to be using
>
Module::Build::Tiny, as opposed to the regular
> Module::Build. In the
>
former case, the destdir option is not seen because
> in must be presented
> as --destdir=$dest_dir. That format should work fine
> with the regular
>
Module::Build case as well.
> 
> So I propose the following
> patch:
> 
>
--- cpan2tgz.old      2014-02-13 15:12:35.564745008 -0600
> +++
> cpan2tgz 
  2014-02-13 15:13:21.708761120 -0600
> @@ -233,7 +233,7 @@
> 
>    #
>
install to the package build dir
>    if ( -f "$pack_dir/Build" ) {
> -   
system("cd $pack_dir && ./Build install
> destdir=$dest_dir");
> +   
system("cd $pack_dir && ./Build
> install --destdir=$dest_dir");
>    }
else {
>      system("cd
> $pack_dir && make install DESTDIR=$dest_dir");
>
   }
> 

Looks reasonable.  Would you like to send a git patch over that I
can apply?  If not I can make the change.


take care,
jason
--
Jason
Woodward


More information about the Slapt-get-user mailing list