Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister

Problem Compiling Data::Swap

by HuckinFappy (Pilgrim)
on Jun 15, 2014 at 04:29 UTC ( #1089918=perlquestion: print w/replies, xml ) Need Help??

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

We've developed some code using KiokuDB, and I needed to get it running on windows this week. So I went out and grabbed Strawberry Perl, and started using CPAN to get all the modules I need up and running.

It all went well until satisfying the KiokuDB dependencies, at which point it choked on Data::Swap:

g++.exe -o blib\arch\auto\Data\Swap\Swap.xs.dll -Wl,--base-file -Wl,dl +l.base -mdll -s -L"C:\perl\5.20.0\perl\lib\CORE" -L"C:\perl\5.20.0\c\ +lib" Swap.o c:\perl\5.20.0\perl\lib\CORE\libperl520.a -lmoldname - +lkernel32 -luser32 -lgdi32 -lwinspool -lcomdlg32 -ladvapi32 -lshell32 + -lole32 -loleaut32 -lnetapi32 -luuid -lws2_32 -lmpr -lwinmm -lversio +n -lodbc32 -lodbccp32 -lcomctl32 dll.exp Swap.o:Swap.c:(.text+0xb8): undefined reference to `__imp_Perl_hv_back +references_p' Swap.o:Swap.c:(.text+0xd5): undefined reference to `__imp_Perl_hv_back +references_p' C:/perl/5.20.0/c/bin/../lib/gcc/x86_64-w64-mingw32/4.8.2/../../../../x +86_64-w64-mingw32/bin/ld.exe: Swap.o: bad reloc address 0x0 in sectio +n `.pdata' C:/perl/5.20.0/c/bin/../lib/gcc/x86_64-w64-mingw32/4.8.2/../../../../x +86_64-w64-mingw32/bin/ld.exe: final link failed: Invalid operation collect2.exe: error: ld returned 1 exit status dmake: Error code 129, while making 'blib\arch\auto\Data\Swap\Swap.xs +.dll'
I've found bug reports going back to 2009 on this, and I went back as far as perl 5.10, and it won't compile there either. I'm pretty bummed KiokuyDB has such an out-of-date core dependency, but besides that, i can't imagine the pain of redoing all the KiokuDB work manually myself. Any hints how I can get this compiled?

Replies are listed 'Best First'.
Re: Problem Compiling Data::Swap ( embed.fnc not exported symbol hv_backreferences_p)
by Anonymous Monk on Jun 15, 2014 at 09:19 UTC

    See Re: Devel::BeginLift make problem and Re^4: perl-5.18.0 install problem - Part 2 (

    Its the same problem, Perl_hv_backreferences_p is not an part of the public api, its not exported symbol

    You can get at it by recompiling perl after editing the "embed.fnc" entry for to add an A

    - poM |AV** |hv_backreferences_p |NN HV *hv + ApoM |AV** |hv_backreferences_p |NN HV *hv

    After that you should be able to compile Data::Swap without problems

    Yes, theoretically you could through some clever copy/pasting inline a working hv_backreferences_p, but thats like c programming ... its not easy :)

Re: Problem Compiling Data::Swap
by wjw (Priest) on Jun 15, 2014 at 06:42 UTC

    I did a cpanm install on my Linux laptop using Perl perl-5.20.0 successfully. I don't have a Windows machine to try it on, so this is probably not all that helpful. I gotta admit though, 19 distributions being installed surprised me!

    Best of luck to you!

    ...the majority is always wrong, and always the last to know about it...

    Insanity: Doing the same thing over and over again and expecting different results...

    A solution is nothing more than a clearly stated problem...otherwise, the problem is not a problem, it is a facct

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://1089918]
Approved by kevbot
Front-paged by kevbot
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others chanting in the Monastery: (1)
As of 2023-06-04 05:09 GMT
Find Nodes?
    Voting Booth?
    How often do you go to conferences?

    Results (17 votes). Check out past polls.