Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

XS.c: loadable library and perl binaries are mismatched (got handshake key 0xc100000, needed 0xc180000)

by rgren925 (Sexton)
on Jul 29, 2020 at 00:16 UTC ( #11119926=perlquestion: print w/replies, xml ) Need Help??

rgren925 has asked for the wisdom of the Perl Monks concerning the following question:

My Dear Monks,

I have tried over and over to make this work.

I've combed this site and others and see many folks have run into this same issue but I just don't see how to resolve it. I've successfully installed perl 5.20 on this system but am told I need to upgrade to 5.30 for security reasons. My installation almost couldn't be simpler. I'm installing perl 5.30.3 on RHEL 4 Nahant. My Configure looks like this:

./Configure -des -Dprefix=/home/rg8239/perl -Dcc=gcc

The perl works fine. Here's the "perl -V" output:

Summary of my perl5 (revision 5 version 30 subversion 3) configuration +: Platform: osname=linux osvers=2.6.9-34.elsmp archname=x86_64-linux uname='linux gcp4al16 2.6.9-34.elsmp #1 smp fri feb 24 16:56:28 es +t 2006 x86_64 x86_64 x86_64 gnulinux ' config_args='-des -Dprefix=/home/rg8239/perl -Dcc=gcc' hint=recommended useposix=true d_sigaction=define useithreads=undef usemultiplicity=undef use64bitint=define use64bitall=define uselongdouble=undef usemymalloc=n default_inc_excludes_dot=define bincompat5005=undef Compiler: cc='gcc' ccflags ='-fno-strict-aliasing -pipe -I/usr/local/include -D_LARGE +FILE_SOURCE -D_FILE_OFFSET_BITS=64' optimize='-O2' cppflags='-fno-strict-aliasing -pipe -I/usr/local/include' ccversion='' gccversion='3.4.5 20051201 (Red Hat 3.4.5-2)' gccosandvers='' intsize=4 longsize=8 ptrsize=8 doublesize=8 byteorder=12345678 doublekind=3 d_longlong=define longlongsize=8 d_longdbl=define longdblsize=16 longdblkind=3 ivtype='long' ivsize=8 nvtype='double' nvsize=8 Off_t='off_t' lseeksize=8 alignbytes=8 prototype=define Linker and Libraries: ld='gcc' ldflags =' -L/usr/local/lib' libpth=/usr/local/lib /usr/lib /lib /lib64 /usr/lib64 /usr/local/l +ib64 libs=-lpthread -lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc libc=libc-2.3.4.so so=so useshrplib=false libperl=libperl.a gnulibc_version='2.3.4' Dynamic Linking: dlsrc=dl_dlopen.xs dlext=so d_dlsymun=undef ccdlflags='-Wl,-E' cccdlflags='-fPIC' lddlflags='-shared -O2 -L/usr/local/lib' Characteristics of this binary (from libperl): Compile-time options: HAS_TIMES PERLIO_LAYERS PERL_COPY_ON_WRITE PERL_DONT_CREATE_GVSV PERL_MALLOC_WRAP PERL_OP_PARENT PERL_PRESERVE_IVUV USE_64_BIT_ALL USE_64_BIT_INT USE_LARGE_FILES USE_LOCALE USE_LOCALE_COLLATE USE_LOCALE_CTYPE USE_LOCALE_NUMERIC USE_LOCALE_TIME USE_PERLIO USE_PERL_ATOF Built under linux Compiled at Jun 18 2020 02:25:18 @INC: /home/rg8239/perl/lib/site_perl/5.30.3/x86_64-linux /home/rg8239/perl/lib/site_perl/5.30.3 /home/rg8239/perl/lib/5.30.3/x86_64-linux /home/rg8239/perl/lib/5.30.3

Now I try to install my first module, List::MoreUtils It fails with :

XS.c: loadable library and perl binaries are mismatched (got handshake + key 0xc100000, needed 0xc180000)

Here's the cpan install output (redundant lines and most comments omitted):

Reading '/home/rg8239/.cpan/Metadata' Database was generated on Fri, 19 Jun 2020 20:17:02 GMT Running install for module 'List::MoreUtils' Checksum for /home/rg8239/.cpan/sources/authors/id/R/RE/REHSACK/List-M +oreUtils-0.428.tar.gz ok /bin/tar: Read 6144 bytes from - 'YAML' not installed, will not store persistent state Configuring R/RE/REHSACK/List-MoreUtils-0.428.tar.gz with Makefile.PL Checking whether pureperl is required... no Checking for cc... gcc Checking for cc... (cached) gcc Checking whether perlapi is accessible... Warning: prerequisite Export +er::Tiny 0.038 not found. Warning: prerequisite List::MoreUtils::XS 0.426 not found. yes Checking if your kit is complete... Looks good Generating a Unix-style Makefile Writing Makefile for List::MoreUtils Writing MYMETA.yml and MYMETA.json REHSACK/List-MoreUtils-0.428.tar.gz /home/rg8239/perl/bin/perl Makefile.PL -- OK Running make for R/RE/REHSACK/List-MoreUtils-0.428.tar.gz ---- Unsatisfied dependencies detected during ---- ---- REHSACK/List-MoreUtils-0.428.tar.gz ---- Exporter::Tiny [requires] List::MoreUtils::XS [requires] Test::LeakTrace [build_requires] Running install for module 'Exporter::Tiny' Checksum for /home/rg8239/.cpan/sources/authors/id/T/TO/TOBYINK/Export +er-Tiny-1.002002.tar.gz ok /bin/tar: Read 1536 bytes from - Configuring T/TO/TOBYINK/Exporter-Tiny-1.002002.tar.gz with Makefile.P +L Checking if your kit is complete... Looks good Generating a Unix-style Makefile Writing Makefile for Exporter::Tiny Writing MYMETA.yml and MYMETA.json TOBYINK/Exporter-Tiny-1.002002.tar.gz /home/rg8239/perl/bin/perl Makefile.PL -- OK Running make for T/TO/TOBYINK/Exporter-Tiny-1.002002.tar.gz ---- Unsatisfied dependencies detected during ---- ---- TOBYINK/Exporter-Tiny-1.002002.tar.gz ---- Test::Fatal [build_requires,optional] Test::Warnings [build_requires,optional] cp lib/Exporter/Tiny.pm blib/lib/Exporter/Tiny.pm cp lib/Exporter/Shiny.pm blib/lib/Exporter/Shiny.pm cp lib/Exporter/Tiny/Manual/Etc.pod blib/lib/Exporter/Tiny/Manual/Etc. +pod cp lib/Exporter/Tiny/Manual/Importing.pod blib/lib/Exporter/Tiny/Manua +l/Importing.pod cp lib/Exporter/Tiny/Manual/QuickStart.pod blib/lib/Exporter/Tiny/Manu +al/QuickStart.pod cp lib/Exporter/Tiny/Manual/Exporting.pod blib/lib/Exporter/Tiny/Manua +l/Exporting.pod Manifying 6 pod documents TOBYINK/Exporter-Tiny-1.002002.tar.gz /usr/bin/make -- OK Running make test for TOBYINK/Exporter-Tiny-1.002002.tar.gz PERL_DL_NONLAZY=1 "/home/rg8239/perl/bin/perl" "-MExtUtils::Command::M +M" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; tes t_harness(0, 'inc', 'blib/lib', 'blib/arch')" t/*.t # Perl 5.030003 t/01basic.t .............. ok t/02renaming.t ........... ok t/03generators.t ......... ok t/04into.t ............... ok t/05shiny.t .............. ok t/06notwant.t ............ ok t/07regexp.t ............. ok t/08tags.t ............... ok t/09warnings.t ........... skipped: test requires Test::Warnings and T +est::Fatal t/10no.t ................. ok t/11noncode.t ............ ok t/12noncodegenerators.t .. ok t/13doesntexist.t ........ ok All tests successful. Files=13, Tests=64, 1 wallclock secs ( 0.07 usr 0.03 sys + 1.21 cus +r 0.20 csys = 1.51 CPU) Result: PASS TOBYINK/Exporter-Tiny-1.002002.tar.gz /usr/bin/make test -- OK Running make install for TOBYINK/Exporter-Tiny-1.002002.tar.gz Manifying 6 pod documents Installing /home/rg8239/perl/lib/site_perl/5.30.3/Exporter/Shiny.pm Installing /home/rg8239/perl/lib/site_perl/5.30.3/Exporter/Tiny.pm Installing /home/rg8239/perl/lib/site_perl/5.30.3/Exporter/Tiny/Manual +/Exporting.pod Installing /home/rg8239/perl/lib/site_perl/5.30.3/Exporter/Tiny/Manual +/QuickStart.pod Installing /home/rg8239/perl/lib/site_perl/5.30.3/Exporter/Tiny/Manual +/Etc.pod Installing /home/rg8239/perl/lib/site_perl/5.30.3/Exporter/Tiny/Manual +/Importing.pod Installing /home/rg8239/perl/man/man3/Exporter::Tiny::Manual::Exportin +g.3 Installing /home/rg8239/perl/man/man3/Exporter::Tiny::Manual::Etc.3 Installing /home/rg8239/perl/man/man3/Exporter::Tiny.3 Installing /home/rg8239/perl/man/man3/Exporter::Tiny::Manual::QuickSta +rt.3 Installing /home/rg8239/perl/man/man3/Exporter::Shiny.3 Installing /home/rg8239/perl/man/man3/Exporter::Tiny::Manual::Importin +g.3 Appending installation info to /home/rg8239/perl/lib/5.30.3/x86_64-lin +ux/perllocal.pod TOBYINK/Exporter-Tiny-1.002002.tar.gz /usr/bin/make install -- OK Running install for module 'Test::Warnings' Checksum for /home/rg8239/.cpan/sources/authors/id/E/ET/ETHER/Test-War +nings-0.030.tar.gz ok /bin/tar: Read 2048 bytes from - Configuring E/ET/ETHER/Test-Warnings-0.030.tar.gz with Makefile.PL Checking if your kit is complete... Looks good Generating a Unix-style Makefile Writing Makefile for Test::Warnings Writing MYMETA.yml and MYMETA.json ETHER/Test-Warnings-0.030.tar.gz /home/rg8239/perl/bin/perl Makefile.PL -- OK Running make for E/ET/ETHER/Test-Warnings-0.030.tar.gz cp lib/Test/Warnings.pm blib/lib/Test/Warnings.pm Manifying 1 pod document ETHER/Test-Warnings-0.030.tar.gz /usr/bin/make -- OK Running make test for ETHER/Test-Warnings-0.030.tar.gz PERL_DL_NONLAZY=1 "/home/rg8239/perl/bin/perl" "-MExtUtils::Command::M +M" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; tes t_harness(0, 'blib/lib', 'blib/arch')" t/*.t # # Versions for all modules listed in MYMETA.json (including optional o +nes): # REST OF COMMENTS REMOVED FOR BREVITY # t/00-report-prereqs.t ................. ok t/01-basic.t .......................... ok t/02-done_testing.t ................... ok t/03-subtest.t ........................ ok t/04-no-tests.t ....................... ok t/05-no-end-block.t ................... ok t/06-skip-all.t ....................... skipped: Need Does::Not::Exist +::627351373042078 to continue! t/07-no_plan.t ........................ ok t/08-use-if.t ......................... ok t/09-warnings-contents.t .............. ok t/10-no-done_testing.t ................ ok t/11-double-use.t ..................... ok t/12-no-newline.t ..................... ok t/13-propagate-warnings.t ............. ok t/14-propagate-subname.t .............. ok t/15-propagate-default.t .............. ok t/16-propagate-ignore.t ............... ok t/17-propagate-subname-colons.t ....... ok t/18-propagate-subname-package.t ...... ok t/19-propagate-nonexistent-subname.t .. ok t/20-propagate-stub.t ................. ok t/21-fail-on-warning.t ................ ok t/22-warnings-bareword.t .............. ok t/23-report-warnings.t ................ ok t/zzz-check-breaks.t .................. ok All tests successful. Files=25, Tests=81, 4 wallclock secs ( 0.13 usr 0.04 sys + 3.00 cus +r 0.53 csys = 3.70 CPU) Result: PASS ETHER/Test-Warnings-0.030.tar.gz /usr/bin/make test -- OK Running make install for ETHER/Test-Warnings-0.030.tar.gz Manifying 1 pod document Installing /home/rg8239/perl/lib/site_perl/5.30.3/Test/Warnings.pm Installing /home/rg8239/perl/man/man3/Test::Warnings.3 Appending installation info to /home/rg8239/perl/lib/5.30.3/x86_64-lin +ux/perllocal.pod ETHER/Test-Warnings-0.030.tar.gz /usr/bin/make install -- OK Running install for module 'Test::Fatal' Checksum for /home/rg8239/.cpan/sources/authors/id/R/RJ/RJBS/Test-Fata +l-0.014.tar.gz ok Configuring R/RJ/RJBS/Test-Fatal-0.014.tar.gz with Makefile.PL Warning: prerequisite Try::Tiny 0.07 not found. Checking if your kit is complete... Looks good Generating a Unix-style Makefile Writing Makefile for Test::Fatal Writing MYMETA.yml and MYMETA.json RJBS/Test-Fatal-0.014.tar.gz /home/rg8239/perl/bin/perl Makefile.PL -- OK Running make for R/RJ/RJBS/Test-Fatal-0.014.tar.gz ---- Unsatisfied dependencies detected during ---- ---- RJBS/Test-Fatal-0.014.tar.gz ---- Try::Tiny [requires] Running install for module 'Try::Tiny' Checksum for /home/rg8239/.cpan/sources/authors/id/E/ET/ETHER/Try-Tiny +-0.30.tar.gz ok Configuring E/ET/ETHER/Try-Tiny-0.30.tar.gz with Makefile.PL Checking if your kit is complete... Looks good Generating a Unix-style Makefile Writing Makefile for Try::Tiny Writing MYMETA.yml and MYMETA.json ETHER/Try-Tiny-0.30.tar.gz /home/rg8239/perl/bin/perl Makefile.PL -- OK Running make for E/ET/ETHER/Try-Tiny-0.30.tar.gz cp lib/Try/Tiny.pm blib/lib/Try/Tiny.pm Manifying 1 pod document ETHER/Try-Tiny-0.30.tar.gz /usr/bin/make -- OK Running make test for ETHER/Try-Tiny-0.30.tar.gz PERL_DL_NONLAZY=1 "/home/rg8239/perl/bin/perl" "-MExtUtils::Command::M +M" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; tes t_harness(0, 'blib/lib', 'blib/arch')" t/*.t # # Versions for all modules listed in MYMETA.json (including optional o +nes): # # === Configure Requires === # # Module Want Have # ------------------- ---- ---- # ExtUtils::MakeMaker any 7.34 # # REST OF COMMENTS REMOVED FOR BREVITY # t/00-report-prereqs.t .......... ok t/basic.t ...................... ok t/context.t .................... ok t/erroneous_usage.t ............ ok t/finally.t .................... ok t/given_when.t ................. skipped: Tests skipped on perl 5.27.7 ++, pending resolution of smartmatch changes t/global_destruction_forked.t .. ok t/global_destruction_load.t .... skipped: Capture::Tiny 0.12 required t/named.t ...................... ok t/when.t ....................... skipped: Tests skipped on perl 5.27.7 ++, pending resolution of smartmatch changes t/zzz-check-breaks.t ........... ok All tests successful. Files=11, Tests=97, 2 wallclock secs ( 0.06 usr 0.03 sys + 1.43 cus +r 0.20 csys = 1.72 CPU) Result: PASS ETHER/Try-Tiny-0.30.tar.gz /usr/bin/make test -- OK Running make install for ETHER/Try-Tiny-0.30.tar.gz Manifying 1 pod document Installing /home/rg8239/perl/lib/site_perl/5.30.3/Try/Tiny.pm Installing /home/rg8239/perl/man/man3/Try::Tiny.3 Appending installation info to /home/rg8239/perl/lib/5.30.3/x86_64-lin +ux/perllocal.pod ETHER/Try-Tiny-0.30.tar.gz /usr/bin/make install -- OK RJBS/Test-Fatal-0.014.tar.gz Has already been unwrapped into directory /home/rg8239/.cpan/build/T +est-Fatal-0.014-2 RJBS/Test-Fatal-0.014.tar.gz Has already been prepared Running make for R/RJ/RJBS/Test-Fatal-0.014.tar.gz cp lib/Test/Fatal.pm blib/lib/Test/Fatal.pm Manifying 1 pod document RJBS/Test-Fatal-0.014.tar.gz /usr/bin/make -- OK Running make test for RJBS/Test-Fatal-0.014.tar.gz PERL_DL_NONLAZY=1 "/home/rg8239/perl/bin/perl" "-MExtUtils::Command::M +M" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; tes t_harness(0, 'blib/lib', 'blib/arch')" t/*.t # # Versions for all modules listed in MYMETA.json (including optional o +nes): # # REST OF COMMENTS REMOVED FOR BREVITY # t/00-report-prereqs.t .. ok t/basic.t .............. ok t/like-exception.t ..... ok t/todo.t ............... ok All tests successful. Files=4, Tests=16, 1 wallclock secs ( 0.05 usr 0.02 sys + 0.68 cusr + 0.10 csys = 0.85 CPU) Result: PASS RJBS/Test-Fatal-0.014.tar.gz /usr/bin/make test -- OK Running make install for RJBS/Test-Fatal-0.014.tar.gz Manifying 1 pod document Installing /home/rg8239/perl/lib/site_perl/5.30.3/Test/Fatal.pm Installing /home/rg8239/perl/man/man3/Test::Fatal.3 Appending installation info to /home/rg8239/perl/lib/5.30.3/x86_64-lin +ux/perllocal.pod RJBS/Test-Fatal-0.014.tar.gz /usr/bin/make install -- OK Running install for module 'List::MoreUtils::XS' Checksum for /home/rg8239/.cpan/sources/authors/id/R/RE/REHSACK/List-M +oreUtils-XS-0.428.tar.gz ok /bin/tar: Read 7680 bytes from - Configuring R/RE/REHSACK/List-MoreUtils-XS-0.428.tar.gz with Makefile. +PL Checking whether pureperl is required... no Checking for cc... gcc Checking for cc... (cached) gcc Checking whether perlapi is accessible... yes Checking for stdlib.h... yes Checking for stdarg.h... yes Checking for string.h... yes Checking for float.h... yes Checking for assert.h... yes Checking for ctype.h... yes Checking for errno.h... yes Checking for limits.h... yes Checking for locale.h... yes Checking for math.h... yes Checking for setjmp.h... yes Checking for signal.h... yes Checking for stddef.h... yes Checking for stdio.h... yes Checking for time.h... yes Checking for sys/types.h... yes Checking for sys/stat.h... yes Checking for memory.h... yes Checking for strings.h... yes Checking for inttypes.h... yes Checking for stdint.h... yes Checking for unistd.h... yes Checking for time.h... (cached) yes Checking for sys/time.h... yes Checking for time... yes Checking for size_t... yes Checking for ssize_t... yes Checking for builtin expect... no Checking for statement expression feature... no Checking if your kit is complete... Looks good Generating a Unix-style Makefile Writing Makefile for List::MoreUtils::XS Writing MYMETA.yml and MYMETA.json REHSACK/List-MoreUtils-XS-0.428.tar.gz /home/rg8239/perl/bin/perl Makefile.PL -- OK Running make for R/RE/REHSACK/List-MoreUtils-XS-0.428.tar.gz ---- Unsatisfied dependencies detected during ---- ---- REHSACK/List-MoreUtils-XS-0.428.tar.gz ---- Test::LeakTrace [build_requires,optional] cp lib/List/MoreUtils/XS.pm blib/lib/List/MoreUtils/XS.pm Running Mkbootstrap for XS () chmod 644 "XS.bs" "/home/rg8239/perl/bin/perl" -MExtUtils::Command::MM -e 'cp_nonempty' +-- XS.bs blib/arch/auto/List/MoreUtils/XS/XS.bs 644 "/home/rg8239/perl/bin/perl" "/home/rg8239/perl/lib/5.30.3/ExtUtils/xs +ubpp" -typemap '/home/rg8239/perl/lib/5.30.3/ExtUtils/typemap ' XS.xs > XS.xsc mv XS.xsc XS.c gcc -c -I. -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFI +LE_SOURCE -D_FILE_OFFSET_BITS=64 -O2 -DVERSION=\"0.428\" -DX S_VERSION=\"0.428\" -fPIC "-I/home/rg8239/perl/lib/5.30.3/x86_64-linux +/CORE" XS.c rm -f blib/arch/auto/List/MoreUtils/XS/XS.so gcc -shared -O2 -L/usr/local/lib XS.o -o blib/arch/auto/List/MoreUt +ils/XS/XS.so \ \ chmod 755 blib/arch/auto/List/MoreUtils/XS/XS.so Manifying 1 pod document REHSACK/List-MoreUtils-XS-0.428.tar.gz /usr/bin/make -- OK Running make test for REHSACK/List-MoreUtils-XS-0.428.tar.gz "/home/rg8239/perl/bin/perl" -MExtUtils::Command::MM -e 'cp_nonempty' +-- XS.bs blib/arch/auto/List/MoreUtils/XS/XS.bs 644 PERL_DL_NONLAZY=1 "/home/rg8239/perl/bin/perl" "-MExtUtils::Command::M +M" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; tes t_harness(0, 'blib/lib', 'blib/arch')" t/*.t t/xs/*.t xt/*.t XS.c: loadable library and perl binaries are mismatched (got handshake + key 0xc100000, needed 0xc180000) t/xs/after.t ................ Dubious, test returned 1 (wstat 256, 0x100) No subtests run XS.c: loadable library and perl binaries are mismatched (got handshake + key 0xc100000, needed 0xc180000) t/xs/after_incl.t ........... Dubious, test returned 1 (wstat 256, 0x100) No subtests run XS.c: loadable library and perl binaries are mismatched (got handshake + key 0xc100000, needed 0xc180000) t/xs/all.t .................. Dubious, test returned 1 (wstat 256, 0x100) No subtests run Test Summary Report ------------------- t/xs/after.t (Wstat: 256 Tests: 0 Failed: 0) Non-zero exit status: 1 Parse errors: No plan found in TAP output t/xs/after_incl.t (Wstat: 256 Tests: 0 Failed: 0) Non-zero exit status: 1 Parse errors: No plan found in TAP output t/xs/all.t (Wstat: 256 Tests: 0 Failed: 0) Non-zero exit status: 1 Parse errors: No plan found in TAP output t/xs/zip6.t (Wstat: 256 Tests: 0 Failed: 0) Non-zero exit status: 1 Parse errors: No plan found in TAP output Files=59, Tests=0, 2 wallclock secs ( 0.21 usr 0.13 sys + 0.90 cusr + 0.34 csys = 1.58 CPU) Result: FAIL Failed 59/59 test programs. 0/0 subtests failed. make: *** [test_dynamic] Error 1 REHSACK/List-MoreUtils-XS-0.428.tar.gz /usr/bin/make test -- NOT OK //hint// to see the cpan-testers results for installing this module, t +ry: reports REHSACK/List-MoreUtils-XS-0.428.tar.gz Running install for module 'Test::LeakTrace' Checksum for /home/rg8239/.cpan/sources/authors/id/L/LE/LEEJO/Test-Lea +kTrace-0.16.tar.gz ok Configuring L/LE/LEEJO/Test-LeakTrace-0.16.tar.gz with Makefile.PL Checking if your kit is complete... Looks good Generating a Unix-style Makefile Writing Makefile for Test::LeakTrace Writing MYMETA.yml and MYMETA.json LEEJO/Test-LeakTrace-0.16.tar.gz /home/rg8239/perl/bin/perl Makefile.PL -- OK Running make for L/LE/LEEJO/Test-LeakTrace-0.16.tar.gz cp lib/Test/LeakTrace/Script.pm blib/lib/Test/LeakTrace/Script.pm cp lib/Test/LeakTrace.pm blib/lib/Test/LeakTrace.pm cp lib/Test/LeakTrace/JA.pod blib/lib/Test/LeakTrace/JA.pod Running Mkbootstrap for LeakTrace () chmod 644 "LeakTrace.bs" "/home/rg8239/perl/bin/perl" "-Iinc" -MExtUtils::Command::MM -e 'cp_no +nempty' -- LeakTrace.bs blib/arch/auto/Test/LeakTrace/LeakTrac e.bs 644 "/home/rg8239/perl/bin/perl" "-Iinc" "/home/rg8239/perl/lib/5.30.3/Ext +Utils/xsubpp" -typemap '/home/rg8239/perl/lib/5.30.3/ExtUtils /typemap' LeakTrace.xs > LeakTrace.xsc mv LeakTrace.xsc LeakTrace.c gcc -c -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_ +SOURCE -D_FILE_OFFSET_BITS=64 -O2 -DVERSION=\"0.16\" -DXS_VE RSION=\"0.16\" -fPIC "-I/home/rg8239/perl/lib/5.30.3/x86_64-linux/CORE +" LeakTrace.c rm -f blib/arch/auto/Test/LeakTrace/LeakTrace.so gcc -shared -O2 -L/usr/local/lib LeakTrace.o -o blib/arch/auto/Test +/LeakTrace/LeakTrace.so \ \ chmod 755 blib/arch/auto/Test/LeakTrace/LeakTrace.so Manifying 3 pod documents LEEJO/Test-LeakTrace-0.16.tar.gz /usr/bin/make -- OK Running make test for LEEJO/Test-LeakTrace-0.16.tar.gz "/home/rg8239/perl/bin/perl" "-Iinc" -MExtUtils::Command::MM -e 'cp_no +nempty' -- LeakTrace.bs blib/arch/auto/Test/LeakTrace/LeakTrac e.bs 644 PERL_DL_NONLAZY=1 "/home/rg8239/perl/bin/perl" "-MExtUtils::Command::M +M" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; tes t_harness(0, 'inc', 'blib/lib', 'blib/arch')" t/*.t # Testing Test::LeakTrace/0.16 t/00_compile.t ..... ok t/01_info.t ........ ok t/02_refs.t ........ ok t/03_count.t ....... ok t/04_test_funcs.t .. ok t/05_script.t ...... ok t/06_threads.t ..... skipped: require threads t/07_eval.t ........ ok t/08_leaktrace.t ... ok t/09_info_more.t ... ok t/10_bad_use.t ..... ok t/11_logfp.t ....... ok t/12_padstale.t .... ok t/13_do.t .......... ok All tests successful. Files=14, Tests=126, 3 wallclock secs ( 0.10 usr 0.04 sys + 2.10 cu +sr 0.33 csys = 2.57 CPU) Result: PASS LEEJO/Test-LeakTrace-0.16.tar.gz /usr/bin/make test -- OK Running make install for LEEJO/Test-LeakTrace-0.16.tar.gz "/home/rg8239/perl/bin/perl" "-Iinc" -MExtUtils::Command::MM -e 'cp_no +nempty' -- LeakTrace.bs blib/arch/auto/Test/LeakTrace/LeakTrac e.bs 644 Manifying 3 pod documents Files found in blib/arch: installing files in blib/lib into architectu +re dependent library tree Installing /home/rg8239/perl/lib/site_perl/5.30.3/x86_64-linux/auto/Te +st/LeakTrace/LeakTrace.so Installing /home/rg8239/perl/lib/site_perl/5.30.3/x86_64-linux/Test/Le +akTrace.pm Installing /home/rg8239/perl/lib/site_perl/5.30.3/x86_64-linux/Test/Le +akTrace/Script.pm Installing /home/rg8239/perl/lib/site_perl/5.30.3/x86_64-linux/Test/Le +akTrace/JA.pod Installing /home/rg8239/perl/man/man3/Test::LeakTrace.3 Installing /home/rg8239/perl/man/man3/Test::LeakTrace::Script.3 Installing /home/rg8239/perl/man/man3/Test::LeakTrace::JA.3 Appending installation info to /home/rg8239/perl/lib/5.30.3/x86_64-lin +ux/perllocal.pod LEEJO/Test-LeakTrace-0.16.tar.gz /usr/bin/make install -- OK REHSACK/List-MoreUtils-0.428.tar.gz Has already been unwrapped into directory /home/rg8239/.cpan/build/L +ist-MoreUtils-0.428-4 REHSACK/List-MoreUtils-0.428.tar.gz Has already been prepared Running make for R/RE/REHSACK/List-MoreUtils-0.428.tar.gz Warning: Prerequisite 'List::MoreUtils::XS => 0.426' for 'REHSACK/List +-MoreUtils-0.428.tar.gz' failed when processing 'REHSACK/List- MoreUtils-XS-0.428.tar.gz' with 'make_test => NO'. Continuing, but cha +nces to succeed are limited. cp lib/List/MoreUtils.pm blib/lib/List/MoreUtils.pm cp lib/List/MoreUtils/PP.pm blib/lib/List/MoreUtils/PP.pm cp lib/List/MoreUtils/Contributing.pod blib/lib/List/MoreUtils/Contrib +uting.pod Manifying 3 pod documents REHSACK/List-MoreUtils-0.428.tar.gz /usr/bin/make -- OK Running make test for REHSACK/List-MoreUtils-0.428.tar.gz PERL_DL_NONLAZY=1 "/home/rg8239/perl/bin/perl" "-MExtUtils::Command::M +M" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; tes t_harness(0, 'blib/lib', 'blib/arch')" t/*.t t/pureperl/*.t t/xs/*.t x +t/*.t t/pureperl/after.t ................ ok t/pureperl/after_incl.t ........... ok t/pureperl/all.t .................. ok t/pureperl/all_u.t ................ ok t/pureperl/any.t .................. ok t/pureperl/any_u.t ................ ok t/pureperl/apply.t ................ ok t/pureperl/arrayify.t ............. ok t/pureperl/before.t ............... ok t/pureperl/before_incl.t .......... ok t/pureperl/binsert.t .............. ok t/pureperl/bremove.t .............. ok t/pureperl/bsearch.t .............. ok t/pureperl/bsearchidx.t ........... ok t/pureperl/duplicates.t ........... ok t/pureperl/each_array.t ........... ok t/pureperl/equal_range.t .......... ok t/pureperl/false.t ................ ok t/pureperl/firstidx.t ............. ok t/pureperl/firstres.t ............. ok t/pureperl/firstval.t ............. ok t/pureperl/frequency.t ............ ok t/pureperl/Import.t ............... ok t/pureperl/indexes.t .............. ok t/pureperl/insert_after.t ......... ok t/pureperl/insert_after_string.t .. ok t/pureperl/lastidx.t .............. ok t/pureperl/lastres.t .............. ok t/pureperl/lastval.t .............. ok t/pureperl/listcmp.t .............. ok t/pureperl/lower_bound.t .......... ok t/pureperl/mesh.t ................. ok t/pureperl/minmax.t ............... ok t/pureperl/minmaxstr.t ............ ok t/pureperl/mode.t ................. ok t/pureperl/natatime.t ............. ok t/pureperl/none.t ................. ok t/pureperl/none_u.t ............... ok t/pureperl/notall.t ............... ok t/pureperl/notall_u.t ............. ok t/pureperl/occurrences.t .......... ok t/pureperl/one.t .................. ok t/pureperl/one_u.t ................ ok t/pureperl/onlyidx.t .............. ok t/pureperl/onlyres.t .............. ok t/pureperl/onlyval.t .............. ok t/pureperl/pairwise.t ............. ok t/pureperl/part.t ................. ok t/pureperl/qsort.t ................ skipped: It's insane to use a pure +-perl qsort t/pureperl/reduce_0.t ............. ok t/pureperl/reduce_1.t ............. ok t/pureperl/reduce_u.t ............. ok t/pureperl/samples.t .............. ok t/pureperl/singleton.t ............ ok t/pureperl/true.t ................. ok t/pureperl/uniq.t ................. ok t/pureperl/upper_bound.t .......... ok t/pureperl/XS.t ................... ok t/pureperl/zip6.t ................. ok Can't locate List/MoreUtils/XS.pm in @INC (you may need to install the + List::MoreUtils::XS module) (@INC contains: /home/rg8239/.cpan/build +/List-MoreUtils-0.428-4/blib/lib /home/rg8239/.cpan/build/List-MoreUt +ils-0.428-4/blib/arch /home/rg8239/perl/lib/site_perl/5. 30.3/x86_64-linux /home/rg8239/perl/lib/site_perl/5.30.3 /home/rg8239/ +perl/lib/5.30.3/x86_64-linux /home/rg8239/perl/lib/5.30.3 .) a t /home/rg8239/.cpan/build/List-MoreUtils-0.428-4/blib/lib/List/MoreUt +ils.pm line 14. BEGIN failed--compilation aborted at /home/rg8239/.cpan/build/List-Mor +eUtils-0.428-4/blib/lib/List/MoreUtils.pm line 20.

I really need some expert guidance here! Thanks very much, Rick

  • Comment on XS.c: loadable library and perl binaries are mismatched (got handshake key 0xc100000, needed 0xc180000)
  • Select or Download Code

Replies are listed 'Best First'.
Re: XS.c: loadable library and perl binaries are mismatched (got handshake key 0xc100000, needed 0xc180000)
by syphilis (Bishop) on Jul 29, 2020 at 01:02 UTC
    Hi,

    That looks quite different to what I see on Ubuntu when I cpan -i List::MoreUtils.

    I've just noticed gccversion='3.4.5 20051201 (Red Hat 3.4.5-2)'
    That is an ancient version of gcc, but I don't know whether that would be the problem.
    If gcc-3.4.5 was ok for perl-5.20, I'd guess it should be ok for perl-5.30. (Did perl -V:gccversion report the same with perl-5.20 ?)

    Other thoughts:
    Why is Test-LeakTrace being built and installed after List-MoreUtils ?
    Maybe check which cpan utility is being loaded (which cpan).

    I'd probably next try building List-MoreUtils the old fashioned way, just to see what happens:
    1) cd into the top level folder of a freshly unpacked List-MoreUtils-0.428.tar.gz;
    2) run in sequence, perl Makefile.PL followed by make test;
    3) run make install (but only if make test passed).

    Is any of that helpful ?

    Cheers,
    Rob
      I've just noticed gccversion='3.4.5 20051201 (Red Hat 3.4.5-2)' That is an ancient version of gcc

      Well, rgren925 did say, "I'm installing perl 5.30.3 on RHEL 4 Nahant". That's an O/S from 2005 (and now more than 8 years past EoL) so it is only to be expected that there might be one or two problems compiling and installing something so modern on there. It might not be the entire cause of the problem but is certainly a factor to consider.


      🦛

        ..it is only to be expected that there might be one or two problems compiling and installing something so modern on there

        Yes - but then rgren925 did say that perl-5.30.3 itself was fine. And I assume that means that perl-5.30.0 tested flawlessly. (Perhaps I assume too much :-)

        My first thoughts were along the lines of bliako's suggestion - that there was some remnant of the earlier perl version being found.
        But the @INC directories all include the string "5.30.3" and I don't think it likely that anything from perl-5.20.x would have ended up in a directory that included "5.30.3" as part of its name.

        I think we need a bit more feedback from rgren925.

        Cheers,
        Rob
Re: XS.c: loadable library and perl binaries are mismatched (got handshake key 0xc100000, needed 0xc180000)
by bliako (Monsignor) on Jul 29, 2020 at 06:31 UTC

    there must be remains of another Perl installation - libraries specifically - in the system.

    Compilation of module is successful which denotes that gcc is looking for libraries at the correct places and with the correct order - if there was any need re:-shared. What fails is running the module. Because it was compiled as "shared" which means it must look for and link with the Perl libraries during runtime. And this is where it fails, not because it can't find any libraries but because it (i.e. the operating system's linker responsible for finding shared components at runtime) finds the wrong versions (the handshake mismatch, btw it is cool of perl to make its own checks for its library versions).

    I suggest you make a thorough search of old-version Perl libraries in your system. Also, run this: echo $LD_LIBRARY_PATH to tell you the linker's search path, although it can be empty meaning it follows a default which most likely is not aware of your local installation at /home/rg8239. In fact, it looks weird to me that you installed Perl in your home dir but its libraries are searched, by Perl's Makefiles, in a system dir. The guess is that older Perl is installed in system dir and you tried to install a newer version in your homedir. This will mess up Perl for you. Don't worry, this being Linux, unless you installed as root, your system Perl is safe. Which possibly means, another guess, that you did not upgrade the system Perl but you installed a newer version in your homedir. This is tricky when you do it without the help of something like perlbrew. This will enable root-free multiple/parallel Perl versions in a system. You should use it if you want to have Perl in your home dir. This is preferred than upgrading as root the system Perl. Leave the system Perl to the system and install a "user" Perl in your homedir via perlbrew

    Edit: to make it clear: your problem is not with compiling. Compilation succeeded. Running (the tests) failed because system runtime linker links to a different Perl library. Perl detects that and complains (handshake failed).

    bw, biako

      This is one of the many instances where strace can be your friend. You can use something along the lines of strace -e open,stat,lstat to prefix your perl blah blah invocation and see exactly what files it's trying to open as well as actually opening and then work back from there.

      The cake is a lie.
      The cake is a lie.
      The cake is a lie.

        yep

      LD_LIBRARY_PATH was set to /usr/lib. I set the following:

      PERL5LIB=/home/rg8239/perl/lib/site_perl/5.30.3:/home/rg8239/perl/lib/ +site_perl/5.30.3/x86_64-linux:/home/rg8239/perl/lib/5.30.3:/home/rg82 +39/perl/lib/5.30.3/x86_64-linux LD_LIBRARY_PATH=/home/rg8239/perl/lib/site_perl/5.30.3:/home/rg8239/pe +rl/lib/site_perl/5.30.3/x86_64-linux:/home/rg8239/perl/lib/5.30.3:/ho +me/rg8239/perl/lib/5.30.3/x86_64-linux

      Then I reinstalled perl 5.30.3 and tried to use cpan to install List::MoreUtils. No change. Still get the mismatch.

        I think you are convoluting the problem and your system even more. I would go the opposite direction and blank out both env vars you set.

        If you have not installed 5.30 as root just erase it from your home dir including all additional packages it installed and make sure about that. Then use perlbrew to re-install perl 5.30. Then ask perlbrew to use 5.30 as the default perl for your account. Then install additional packages. Perhaps starting with cpanm. And report back if there is a problem. perlbrew will make sure that one perl's libraries and packages do not pollute another's.

        If you have installed 5.30 as root, your problems are only surfacing now... I hope you are able to remove it and all its packages and restore the system perl and its packages.

        If you want to investigate further before a re-install then use strace as Fletch suggested to see which libraries are causing the bad handshake.

        you did neither of these

        btw, it seems you posted already this to stackoverflow with very poor answers. None-the-less perhaps you could edit this post to notify us of it.

        None of those paths should be in PERL5LIB.

        None of those paths should be in LD_LIBRARY_PATH.

        Unset both.

Re: XS.c: loadable library and perl binaries are mismatched (got handshake key 0xc100000, needed 0xc180000)
by bulk88 (Priest) on Aug 03, 2020 at 20:29 UTC
    I wrote that binary mismatch code. Since its 0xFFFF0000 region that is the problem I know the size of the interp struct is not the same between the XS lib and perl interp binary.. The high digits come from, config.h and -D flags passed to gcc. Sometimes various makefile.pl are dumb and do $CCFLAGS = '-DMY_ENHANCED_MODE'; instead of $CCFLAGS = $CCFLAGS.' -DMY_ENHANCED_MODE'; and that error happens if you do long double, or 64 bit stat or 64 bit time or 64 bit who knows what OS API struct special build flag to Configure and that non-default -D is lost between Makefile.PL and command line args to GCC.
      doing a "make myxs.i" and inside ur custom build "make sv.i" then C source code formatter, strip #line directives, then a diff between the two .i files, will reveal will C members are different. Then you can reverse which #ifdef in intrpvar.h is different between an external XS lib and perl core interp.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://11119926]
Approved by kcott
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (4)
As of 2021-10-22 18:35 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My first memorable Perl project was:







    Results (85 votes). Check out past polls.

    Notices?