Skip to content

Conversation

@rajendra-desai-ni
Copy link

@rajendra-desai-ni rajendra-desai-ni commented Mar 3, 2025

The following perl ptests:

  • dist/ExtUtils-ParseXS/t/001-basic
  • dist/ExtUtils-ParseXS/t/002-more
  • dist/ExtUtils-ParseXS/t/003-usage
  • cpan/ExtUtils-Constant/t/Constant
  • cpan/ExtUtils-MakeMaker/t/02-xsdynamic

are erroring out with:
| /usr/lib/perl/ptest/perl_langinfo.h:8:10: fatal error: xconfig.h: No such file or directory
| 8 | #include "xconfig.h"

xconfig.h contains references to the build host architecture and was removed by commit 2e0f30c ("perl: do not install files that contain build host specific data")

However, it is still included from various other places including these tests, and we are still depending on build host architecture data by including the patches from perl-cross recipe, a dependency to perl recipe.

xconfig.h was added back as a copy step in the commit f90922c ("update 5.36.1 -> 5.38.0") but was not added back in perl-ptest include file.

Borrowed the logic from the above commit to make a copy of config.h that is specific to the target architecture. The changes in this commit fixes the test failures.


(AB#2990669 for reference)

Created this PR as I wanted to get the changes reviewed by the team before I could submit a patch upstream.

@rajendra-desai-ni rajendra-desai-ni requested review from a team and gratian March 3, 2025 09:35
Copy link

@chaitu236 chaitu236 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we intend to submit this fix upstream?

@rajendra-desai-ni rajendra-desai-ni changed the title perl: do not remove files that contain build host specific data perl-ptest: copy xconfig data from perl source directory Mar 10, 2025
Copy link

@chaitu236 chaitu236 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Can be submitted upstream.

Probably not required as we're just copying another change that's already upstream but I'm curious if you happened to test (as per https://docs.yoctoproject.org/5.0.7/test-manual/reproducible-builds.html#can-i-test-my-layer-or-recipes) if this keeps the build reproducible.

The following perl ptests:

  - dist/ExtUtils-ParseXS/t/001-basic
  - dist/ExtUtils-ParseXS/t/002-more
  - dist/ExtUtils-ParseXS/t/003-usage
  - cpan/ExtUtils-Constant/t/Constant
  - cpan/ExtUtils-MakeMaker/t/02-xsdynamic

are erroring out with:
| /usr/lib/perl/ptest/perl_langinfo.h:8:10: fatal error:
xconfig.h: No such file or directory
|     8 | #include "xconfig.h"

xconfig.h contains references to the build host architecture and was
removed by commit 2e0f30c ("perl: do not install files that contain
build host specific data")

However, it is still included from various other places including these
tests, and we are still depending on build host architecture data by
including the patches from perl-cross recipe, a dependency to perl recipe.

xconfig.h was added back as a copy step in the commit f90922c
("update 5.36.1 -> 5.38.0") but was not added back in perl-ptest include
file.

Borrowed the logic from the above commit to make a copy of config.h
that is specific to the target architecture. The changes in this commit
fixes the test failures.

Signed-off-by: Rajendra Desai <[email protected]>
@rajendra-desai-ni
Copy link
Author

Looks good. Can be submitted upstream.

Probably not required as we're just copying another change that's already upstream but I'm curious if you happened to test (as per https://docs.yoctoproject.org/5.0.7/test-manual/reproducible-builds.html#can-i-test-my-layer-or-recipes) if this keeps the build reproducible.

@chaitu236 , The QA Issue that I was getting was because I had added the copy step after build host references removal step due to which some build host specific references in xconfig.h file were left unremoved. I have fixed and tested this, and I am no more getting QA Issue with the new changes. Please let me know about the new changes.

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

Successfully merging this pull request may close these issues.

2 participants