The wrong system call numbers are being selected because the code in
/usr/lib/perl/5.8.8/asm/unistd.ph decides to require the x86-64, instead
of i386, version of unistd.ph. This code appears to make its decision
based on whether _h2ph_pre.ph defines __x86_64__, but my _h2ph_pre.ph
does not. And yet the x86-64 path is taken.


A hack solution until the actual problem is resolved is to disable the x86-64 
path; update your asm/unistd.ph to this:

require '_h2ph_pre.ph';

no warnings 'redefine';

unless(defined(&__ASM_STUB_UNISTD_H)) {
    eval 'sub __ASM_STUB_UNISTD_H () {1;}' unless defined(&__ASM_STUB_UNISTD_H);
# Commented out to disable x86-64 path:
#    if(defined (defined(&__x86_64__) ? &__x86_64__ : 0)) {
#       require 'asm-x86_64/unistd.ph';
#    }
# elsif(defined (defined(&__i386__) ? &__i386__ : 0)) {
 if(defined (defined(&__i386__) ? &__i386__ : 0)) {
        require 'asm-i386/unistd.ph';
    } else {
        warn("This\ machine\ appears\ to\ be\ neither\ x86_64\ nor\ i386\.");
    }
}
1;

-- 
Feisty: perl syscall.ph has wrong syscall numbers on IA32
https://bugs.launchpad.net/bugs/112371
You received this bug notification because you are a member of Ubuntu
Bugs, which is the bug contact for Ubuntu.

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to