Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failure in ARM-Linux cross compile #8741

Open
p5pRT opened this issue Jan 16, 2007 · 5 comments
Open

Failure in ARM-Linux cross compile #8741

p5pRT opened this issue Jan 16, 2007 · 5 comments

Comments

@p5pRT
Copy link

p5pRT commented Jan 16, 2007

Migrated from rt.perl.org#41275 (status was 'open')

Searchable as RT41275$

@p5pRT
Copy link
Author

p5pRT commented Jan 16, 2007

From liu.wu@intel.com

Dear Sir,

I want to port perl to embedded Linux . my environment is : ARM-Linux
,use xscale_be-gcc C compile .

I according to the steps in "Cross-compilation" section in INSTALL in
~/perl-5.8.8

Like this :

  sh ./Configure -des -Dusecrosscompile \

  -Dtargethost=*.*.*.*\

  -Dtargetdir=/tar/get/dir \

  -Dtargetuser=wuliu \

  -Dtargetarch=arm-linux \

  -Dcc=xscale_be-gcc \

  -Dusrinc=/opt/Perl_install/usr/local/include\

  -Dincpth=/opt/Perl_install/usr/local/include \

  -Dlibpth=/opt/Perl_install/usr/local/lib \

  -D...

Our host that running redhat 's ip address is *.*.*.*

But this is can't run success

The error :

I've tried to compile and run the following simple program​:

#include <stdio.h>

int main() { printf("Ok\n"); return(0); }

I used the command​:

  xscale_be-gcc -o try -O2 -DOVR_DBL_DIG=14 try.c

  /home/roger/Perl/perl-5.8.8/Cross/run-ssh ./try

and I got the following output​:

Permission denied, please try again.

bash​: line 1​: ././try​: cannot execute binary file

The program compiled OK, but exited with status 126.

You have a problem. Shall I abort Configure [y]

Ok. Stopping Configure.

I don't know what is wrong ,

Our target machine that my program run on it and host machine that my
program compile and build on it should be connect use SSH?

Thank you

Wu Liu

cubical​:PD3-2II-B11

email​:liu.wu@​intel.com

phone​:86-21-387-37917

@p5pRT
Copy link
Author

p5pRT commented May 25, 2012

From @jkeenan

On Mon Jan 15 19​:01​:43 2007, liu.wu@​intel.com wrote​:

Dear Sir,

I want to port perl to embedded Linux . my environment is : ARM-Linux
,use xscale_be-gcc C compile .

I according to the steps in "Cross-compilation" section in INSTALL in
~/perl-5.8.8

Like this :

sh \./Configure \-des \-Dusecrosscompile \\

    \-Dtargethost=\*\.\*\.\*\.\*\\

    \-Dtargetdir=/tar/get/dir \\

    \-Dtargetuser=wuliu \\

    \-Dtargetarch=arm\-linux \\

    \-Dcc=xscale\_be\-gcc \\

    \-Dusrinc=/opt/Perl\_install/usr/local/include\\

    \-Dincpth=/opt/Perl\_install/usr/local/include \\

    \-Dlibpth=/opt/Perl\_install/usr/local/lib \\

    \-D\.\.\.

Our host that running redhat 's ip address is *.*.*.*

But this is can't run success

The error :

I've tried to compile and run the following simple program​:

#include <stdio.h>

int main() { printf("Ok\n"); return(0); }

I used the command​:

    xscale\_be\-gcc \-o try \-O2 \-DOVR\_DBL\_DIG=14 try\.c

    /home/roger/Perl/perl\-5\.8\.8/Cross/run\-ssh \./try

and I got the following output​:

Permission denied, please try again.

bash​: line 1​: ././try​: cannot execute binary file

The program compiled OK, but exited with status 126.

You have a problem. Shall I abort Configure [y]

Ok. Stopping Configure.

I don't know what is wrong ,

Our target machine that my program run on it and host machine that my
program compile and build on it should be connect use SSH?

Thank you

Wu Liu

Do we have anyone familiar with cross-compilation issues who could take
a look at this ticket?

Thank you very much.
Jim Keenan

@p5pRT
Copy link
Author

p5pRT commented May 25, 2012

The RT System itself - Status changed from 'new' to 'open'

@p5pRT
Copy link
Author

p5pRT commented Sep 13, 2013

From @jkeenan

On Thu May 24 18​:38​:52 2012, jkeenan wrote​:

On Mon Jan 15 19​:01​:43 2007, liu.wu@​intel.com wrote​:

Dear Sir,

I want to port perl to embedded Linux . my environment is : ARM-Linux
,use xscale_be-gcc C compile .

I according to the steps in "Cross-compilation" section in INSTALL in
~/perl-5.8.8

Like this :

sh \./Configure \-des \-Dusecrosscompile \\

    \-Dtargethost=\*\.\*\.\*\.\*\\

    \-Dtargetdir=/tar/get/dir \\

    \-Dtargetuser=wuliu \\

    \-Dtargetarch=arm\-linux \\

    \-Dcc=xscale\_be\-gcc \\

    \-Dusrinc=/opt/Perl\_install/usr/local/include\\

    \-Dincpth=/opt/Perl\_install/usr/local/include \\

    \-Dlibpth=/opt/Perl\_install/usr/local/lib \\

    \-D\.\.\.

Our host that running redhat 's ip address is *.*.*.*

But this is can't run success

The error :

I've tried to compile and run the following simple program​:

#include <stdio.h>

int main() { printf("Ok\n"); return(0); }

I used the command​:

    xscale\_be\-gcc \-o try \-O2 \-DOVR\_DBL\_DIG=14 try\.c

    /home/roger/Perl/perl\-5\.8\.8/Cross/run\-ssh \./try

and I got the following output​:

Permission denied, please try again.

bash​: line 1​: ././try​: cannot execute binary file

The program compiled OK, but exited with status 126.

You have a problem. Shall I abort Configure [y]

Ok. Stopping Configure.

I don't know what is wrong ,

Our target machine that my program run on it and host machine that my
program compile and build on it should be connect use SSH?

Thank you

Wu Liu

Do we have anyone familiar with cross-compilation issues who could take
a look at this ticket?

Thank you very much.
Jim Keenan

Re-posing the question 15 months later​: Is there someone familiar with
cross-compilation issues who could take a look at this ticket?

Thank you very much.
Jim Keenan

@p5pRT
Copy link
Author

p5pRT commented Sep 17, 2013

From @Hugmeir

On Thu, Sep 12, 2013 at 9​:50 PM, James E Keenan via RT <
perlbug-followup@​perl.org> wrote​:

On Thu May 24 18​:38​:52 2012, jkeenan wrote​:

On Mon Jan 15 19​:01​:43 2007, liu.wu@​intel.com wrote​:

Dear Sir,

I want to port perl to embedded Linux . my environment is : ARM-Linux
,use xscale_be-gcc C compile .

I according to the steps in "Cross-compilation" section in INSTALL in
~/perl-5.8.8

It's been quite a long time, but if you're still interested in
cross-compiling perl, the first recommendation would be to use castaway's
branch​:
https://github.com/castaway/perl/tree/jrobinson/configure-for-cross
Since that simplifies the process considerably.

Like this :

sh \./Configure \-des \-Dusecrosscompile \\

    \-Dtargethost=\*\.\*\.\*\.\*\\

    \-Dtargetdir=/tar/get/dir \\

    \-Dtargetuser=wuliu \\

    \-Dtargetarch=arm\-linux \\

    \-Dcc=xscale\_be\-gcc \\

    \-Dusrinc=/opt/Perl\_install/usr/local/include\\

    \-Dincpth=/opt/Perl\_install/usr/local/include \\

    \-Dlibpth=/opt/Perl\_install/usr/local/lib \\

    \-D\.\.\.

Our host that running redhat 's ip address is *.*.*.*

Hm, unless I'm reading this wrong, it sounds like you used that IP address
in -Dtargethost, rather than setting it to the target's IP? This sounds
like a "did you turn it off and on again" sort of question, but it's worth
checking.

But this is can't run success

The error :

I've tried to compile and run the following simple program​:

#include <stdio.h>

int main() { printf("Ok\n"); return(0); }

I used the command​:

    xscale\_be\-gcc \-o try \-O2 \-DOVR\_DBL\_DIG=14 try\.c

    /home/roger/Perl/perl\-5\.8\.8/Cross/run\-ssh \./try

and I got the following output​:

Permission denied, please try again.

bash​: line 1​: ././try​: cannot execute binary file

The program compiled OK, but exited with status 126.

It's possible that the user you're connecting to the device with doesn't
have the necessary permissions for the targetdir you specified? Even if you
do have the permissions, can you try creating a simple shell script, giving
it an execute bit, and trying to run it manually? Some OSs have partitions
mounted with the no-exec bit set (hello, Android's /sdcard), which trumps
everything else.

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

No branches or pull requests

2 participants