Created attachment 462436 [details] dev-perl:Digest-GOST-0.60.0:20170204-134408.log >>> Test phase: dev-perl/Digest-GOST-0.60.0 * Test::Harness Jobs=3 make -j3 test TEST_VERBOSE=0 Running Mkbootstrap for Digest::GOST () chmod 644 "GOST.bs" PERL_DL_NONLAZY=1 "/usr/bin/perl" "-MExtUtils::Command::MM" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; test_harness(0, 'blib/lib', 'blib/arch')" t /*.t ^M===( 1;0 1/? 0/? 0/? )========================================= # Failed test 'use Digest::GOST;' # at t/00_load.t line 5. # Tried to use 'Digest::GOST'. # Error: Can't load '/var/tmp/portage/dev-perl/Digest-GOST-0.60.0/work/Digest-GOST-0.06/blib/arch/auto/Digest/GOST/GOST.so' for module Digest::GOST: /var/ tmp/portage/dev-perl/Digest-GOST-0.60.0/work/Digest-GOST-0.06/blib/arch/auto/Digest/GOST/GOST.so: undefined symbol: rhash_u32_swap_copy at /usr/lib/perl5/5.22. 3/hppa2.0-linux-thread-multi/DynaLoader.pm line 193. # ^@ at t/00_load.t line 5. # Compilation failed in require at t/00_load.t line 5. # BEGIN failed--compilation aborted at t/00_load.t line 5. # Failed test 'use Digest::GOST::CryptoPro;' # at t/00_load.t line 6. # Tried to use 'Digest::GOST::CryptoPro'. # Error: Attempt to reload Digest/GOST.pm aborted. # Compilation failed in require at /usr/lib/perl5/5.22.3/parent.pm line 20. # BEGIN failed--compilation aborted at /var/tmp/portage/dev-perl/Digest-GOST-0.60.0/work/Digest-GOST-0.06/blib/lib/Digest/GOST/CryptoPro.pm line 5. # Compilation failed in require at t/00_load.t line 6. # BEGIN failed--compilation aborted at t/00_load.t line 6. # Testing Digest::GOST 0.06 # Looks like you failed 2 tests of 2. and so on.
[ebuild R *] dev-perl/Digest-GOST-0.60.0::gentoo USE="{test}" 0 KiB
I reproduced this on big endian ppc and ppc64 as well.
confirmed with upcoming perl-5.24 on ppc64
Tripped over it on ppc64 again: Failed 2/2 subtests ===( 2;0 0/? 0/? 0/? )=========================================Can't load '/dev/shm/portage/dev-perl/Digest-GOST-0.60.0/work/Digest-GOST-0.06/blib/arch/auto/Digest/GOST/GOST.so' for module Digest::GOST: /dev/shm/portage/dev-perl/Digest-GOST-0.60.0/work/Digest-GOST-0.06/blib/arch/auto/Digest/GOST/GOST.so: undefined symbol: rhash_u32_swap_copy at /usr/lib64/perl5/5.24.3/po werpc64-linux/DynaLoader.pm line 193. rhash_u32_swap_copy() is a function local to this package: # LANG=C fgrep -R rhash_u32_swap_copy '/dev/shm/portage/dev-perl/Digest-GOST-0.60.0/work/Digest-GOST-0.06' | sed -e 's@/dev/shm/portage/dev-perl/Digest-GOST-0.60.0/work/Digest-GOST-0.06/@@g' Binary file GOST.o matches Binary file blib/arch/auto/Digest/GOST/GOST.so matches src/byte_order.h:void rhash_u32_swap_copy(void* to, int index, const void* from, size_t length); src/byte_order.h:# define le32_copy(to, index, from, length) rhash_u32_swap_copy((to), (index), (from), (length)) src/byte_order.h:# define be32_copy(to, index, from, length) rhash_u32_swap_copy((to), (index), (from), (length)) src/byte_order.c:void rhash_u32_swap_copy(void* to, int index, const void* from, size_t length) Does plugin fail to build byte_order.c and link it into final GOST.so?
It looks like module does include ".c" files directly into GOST.c: GOST.c:#include "src/gost.c" GOST.xs:#include "src/gost.c" but not "byte_order.c". The following workaround makes dev-perl/Digest-GOST build and pass tests on ppc64: # cat /etc/portage/patches/dev-perl/Digest-GOST/Digest-GOST-0.06.patch diff --git a/GOST.xs b/GOST.xs index 1dfd33c..4ea6f35 100644 --- a/GOST.xs +++ b/GOST.xs @@ -7,4 +7,5 @@ #include "src/gost.c" +#include "src/byte_order.c"
Created attachment 498826 [details, diff] 0001-Fix-link-failure-on-big-endian-platforms.patch Attaching the patch with commit message.
Sent pull request upstream as: https://github.com/gray/digest-gost/pull/1
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a63a99f38ca651a6a266369a360eda0189f1d116 commit a63a99f38ca651a6a266369a360eda0189f1d116 Author: Kent Fredric <kentnl@gentoo.org> AuthorDate: 2017-10-16 22:30:54 +0000 Commit: Kent Fredric <kentnl@gentoo.org> CommitDate: 2017-10-16 22:34:08 +0000 dev-perl/Digest-GOST: Fix broken linking on BigEndian bug #608214 -r1 bump because people who previously built this withour running tests have a silently broken install. Closes: https://bugs.gentoo.org/608214 Package-Manager: Portage-2.3.8, Repoman-2.3.3 ...-0.60.0.ebuild => Digest-GOST-0.60.0-r1.ebuild} | 1 + .../files/Digest-GOST-0.60.0-bigendian-link.patch | 43 ++++++++++++++++++++++ 2 files changed, 44 insertions(+)