Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"carton fatpack" not working #276

Open
geira opened this issue Mar 15, 2021 · 2 comments
Open

"carton fatpack" not working #276

geira opened this issue Mar 15, 2021 · 2 comments

Comments

@geira
Copy link

geira commented Mar 15, 2021

So, having used Carton for bootstrapping since 2016 with great success (hope you enjoyed the Aquavit), I just stumbled on a problem when porting our codebase to a new OS release. Suddenly our old fatpack started choking on modules which were building fine earlier, like Text::MultiMarkdown and Feed::Find. To reproduce this I made a simple test:

$ bin/carton -v
carton v1.0.22

$ cat cpanfile 
requires 'Text::MultiMarkdown', 0;

$ bin/carton install
Installing modules using /home/geira/scratch/foo/cpanfile
[...]
! Configure failed for Text-MultiMarkdown-1.000035. See /home/geira/.cpanm/work/1615836447.105886/build.log for details.
! Installing the dependencies failed: Module 'Text::MultiMarkdown' is not installed
! Bailing out the installation for /home/geira/scratch/foo/.
Installing modules failed

After a lot of head scratching I though maybe it could be a Carton bug, so I upgraded to the latest version:

$ cpanm -S Carton
[...]
Building and testing Carton-v1.0.34 ... OK
Successfully installed Carton-v1.0.34
23 distributions installed

$ carton install
Installing modules using /home/geira/scratch/foo/cpanfile
[...]
Successfully installed Text-MultiMarkdown-1.000035
20 distributions installed
Complete! Modules were installed into /home/geira/scratch/foo/local

Success! Now all I needed to do was to make a new fatpack so that the CI build system can bootstrap itself. This doesn't seem to work however:

$ carton fatpack
Couldn't find install metadata for Carton at /usr/local/share/perl/5.30.0/Carton/Packer.pm line 75.

Yes, I've read the warning in Fatpack.pod but not sure if that applies here. We can't require installing Carton from CPAN on target since the complete build is going into a Debian package, and I'd rather not have the Ubuntu Carton package as a dependency, even though it is currently version 1.0.34.

@Grinnz
Copy link
Contributor

Grinnz commented Sep 28, 2021

Not specific to this issue, but in case it helps, I haven't needed to use carton fatpack since bundling creates an index so the target system only needs cpanm (which has a fatpacked script available from https://cpanmin.us).

@miyagawa
Copy link
Contributor

miyagawa commented May 7, 2022

Right, i think the fatpack command doesn't work in many environments and the same thing can be achieved via carton bundle and the use of standalone cpanm. I consider deprecating the fatpack command.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants