ingydotnet / yaml-libyaml-pm

Perl Binding to libyaml
http://search.cpan.org/dist/YAML-LibYAML/
33 stars 37 forks source link

Please create a Build.pod or some "build from git" documentation #92

Closed pmorch closed 3 years ago

pmorch commented 5 years ago

I've checked out the code from git with:

git clone https://github.com/ingydotnet/yaml-libyaml-pm.git

How do I build from a such a git checkout? Hmm..... No Makefile.PL.

The cpan .tar.gz has a Makefile.PL that says:

# This file was automatically generated by Dist::Zilla::Plugin::MakeMaker v6.012.

( I now want to scream. The Dist::Zilla documentation is horrible if all you want to do is build a module from source that somebody else has written. Turns out the magic is dzil build.)

But this is not a Dist::Zilla based but Zilla::Dist based I discover after reading About. So I try to:

That last step has this output:

» zild make dist
rm -fr blib cpan .build .inline YAML-LibYAML-0.77_001.tar.gz YAML-LibYAML-0.77_001
find . -type d | grep '\.testml' | xargs rm -fr
***** Creating the `cpan/` directory
zild-make-cpan
+ add-standard-files
+ cp Changes cpan
+ /usr/bin/perl -S zild-render-template Contributing cpan/CONTRIBUTING
+ '[' -e bin ']'
+ '[' -e eg ']'
+ cp -r lib cpan
+ '[' -e share ']'
+ fix-hashbangs
++ echo 'cpan/bin/*'
+ '[' 'cpan/bin/*' '!=' 'cpan/bin/*' ']'
+ add-test
+ '[' -d test ']'
+ cp -r test cpan/t
+ '[' -d cpan/t/extra ']'
+ '[' -d cpan/t/devel ']'
+ rm -fr cpan/t/misc cpan/t/fail
+ add-test-000
++ /usr/bin/perl -S zild meta =zild/test-000
+ '[' require == require ']'
+ /usr/bin/perl -S zild-render-template test/000-require-modules.t cpan/t/000-require-modules.t
+ add-dist-ini
+ /usr/bin/perl -S zild-render-template dist.ini cpan/dist.ini
+ swim --to=pod --meta=Meta --pod-cpan doc/YAML/LibYAML.swim
+ swim --to=pod --meta=Meta --pod-cpan doc/YAML/XS.swim
***** Creating new dist: YAML-LibYAML-0.77_001.tar.gz
(cd cpan; dzil build)
[DZ] beginning to build YAML-LibYAML
Test::Base repo missing or not in right state at /home/peter/junk/yaml/locallib/lib/perl5/Dist/Zilla/Plugin/TestBaseIncluder.pm line 47, <DATA> line 108.
/home/peter/junk/yaml/locallib/lib/perl5/auto/share/dist/Zilla-Dist/Makefile:173: recipe for target 'dist' failed
make: *** [dist] Error 2
'make -f /home/peter/junk/yaml/locallib/lib/perl5/auto/share/dist/Zilla-Dist/Makefile dist' failed: No such file or directory

And I have no idea what "Test::Base repo missing or not in right state" means. Looking in TestBaseIncluder.pm reveals that a ../.git or ../../.git is expected to exist but no hint as to why or what to do now.

So:

How do I build from a git checkout?

perlpunk commented 5 years ago

Just a quick note from lunchbreak - yeah, it's complicated :-/ For Test::Base to work, you have to clone https://github.com/ingydotnet/test-base-pm parallel to the yaml-libyaml-pm repo. If I work on YAML::XS, I do zild distdir, then YAML-LibYAML-0.xy will be created which looks like the CPAN tarball, and I do a git init in this subdirectory and work there. If everythings fine, I copy the changed stuff one level up to the original git directory

perlpunk commented 5 years ago

I created a CONTRIBUTING.md file. Hope this helps!

perlpunk commented 3 years ago

No further feedback, closing