Perl / perl5

🐪 The Perl programming language
https://dev.perl.org/perl5/
Other
1.91k stars 542 forks source link

skip t/porting/extrefs.t when cross-compiling #13380

Closed p5pRT closed 10 years ago

p5pRT commented 10 years ago

Migrated from rt.perl.org#120398 (status was 'resolved')

Searchable as RT120398$

p5pRT commented 10 years ago

From @fperrad

Created by @fperrad

The toolchain is not installed on the target when cross-compiling. So\, this test must be skipped\, see patch below. (same problem as RT#119769)

[PATCH] skip t/porting/extrefs.t when cross-compiling

Signed-off-by​: Francois Perrad \francois\.perrad@​gadz\.org

Index​: b/t/porting/extrefs.t

--- a/t/porting/extrefs.t +++ b/t/porting/extrefs.t @​@​ -23\,8 +23\,13 @​@​ use Config; use File​::Path 'rmtree'; use Cwd; +use IPC​::Cmd qw(can_run);

-plan(tests => 1); +if ($Config{'usecrosscompile'} && !can_run($Config{'cc'})) { + skip_all("compiler not available (cross-compiling)"); +} else { + plan(tests => 1); +}

my $VERBOSE = grep {$_ eq '-v'} @​ARGV;

--

Perl Info ``` Flags: category=core severity=low Site configuration information for perl 5.18.1: Configured by user at Mon Oct 28 15:34:14 CET 2013. Summary of my perl5 (revision 5 version 18 subversion 1) configuration: Platform: osname=linux, osvers=3.2.0-55-generic, archname=i686-linux uname='linux ubuntu 3.2.0-55-generic #85-ubuntu smp wed oct 2 13:43:27 utc 2013 i686 i686 i386 gnulinux ' config_args='-de -Dprefix=/home/user/perl5/perlbrew/perls/perl-5.18.1 -Aeval:scriptdir=/home/user/perl5/perlbrew/perls/perl-5.18.1/bin' hint=recommended, useposix=true, d_sigaction=define useithreads=undef, usemultiplicity=undef useperlio=define, d_sfio=undef, uselargefiles=define, usesocks=undef use64bitint=undef, use64bitall=undef, uselongdouble=undef usemymalloc=n, bincompat5005=undef Compiler: cc='cc', ccflags ='-fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64', optimize='-O2', cppflags='-fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include' ccversion='', gccversion='4.6.3', gccosandvers='' intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=1234 d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=12 ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='off_t', lseeksize=8 alignbytes=4, prototype=define Linker and Libraries: ld='cc', ldflags =' -fstack-protector -L/usr/local/lib' libpth=/usr/local/lib /lib/i386-linux-gnu /lib/../lib /usr/lib/i386-linux-gnu /usr/lib/../lib /lib /usr/lib libs=-lnsl -ldl -lm -lcrypt -lutil -lc perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc libc=, so=so, useshrplib=false, libperl=libperl.a gnulibc_version='2.15' Dynamic Linking: dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-Wl,-E' cccdlflags='-fPIC', lddlflags='-shared -O2 -L/usr/local/lib -fstack-protector' Locally applied patches: @INC for perl 5.18.1: /home/user/perl5/perlbrew/perls/perl-5.18.1/lib/site_perl/5.18.1/i686-linux /home/user/perl5/perlbrew/perls/perl-5.18.1/lib/site_perl/5.18.1 /home/user/perl5/perlbrew/perls/perl-5.18.1/lib/5.18.1/i686-linux /home/user/perl5/perlbrew/perls/perl-5.18.1/lib/5.18.1 . Environment for perl 5.18.1: HOME=/home/user LANG=en_US.UTF-8 LANGUAGE=en_US:en LD_LIBRARY_PATH (unset) LOGDIR (unset) PATH=/home/user/perl5/perlbrew/bin:/home/user/perl5/perlbrew/perls/perl-5.18.1/bin:/usr/lib/lightdm/lightdm:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games PERLBREW_BASHRC_VERSION=0.66 PERLBREW_HOME=/home/user/.perlbrew PERLBREW_MANPATH=/home/user/perl5/perlbrew/perls/perl-5.18.1/man PERLBREW_PATH=/home/user/perl5/perlbrew/bin:/home/user/perl5/perlbrew/perls/perl-5.18.1/bin PERLBREW_PERL=perl-5.18.1 PERLBREW_ROOT=/home/user/perl5/perlbrew PERLBREW_VERSION=0.66 PERL_BADLANG (unset) SHELL=/bin/bash ```
p5pRT commented 10 years ago

From @cpansprout

On Mon Oct 28 11​:18​:15 2013\, fperrad wrote​:

This is a bug report for perl from francois.perrad@​gadz.org\, generated with the help of perlbug 1.39 running under perl 5.18.1.

----------------------------------------------------------------- [Please describe your issue here]

The toolchain is not installed on the target when cross-compiling. So\, this test must be skipped\, see patch below. (same problem as RT#119769)

[PATCH] skip t/porting/extrefs.t when cross-compiling

Signed-off-by​: Francois Perrad \francois\.perrad@​gadz\.org

Index​: b/t/porting/extrefs.t

--- a/t/porting/extrefs.t +++ b/t/porting/extrefs.t @​@​ -23\,8 +23\,13 @​@​ use Config; use File​::Path 'rmtree'; use Cwd; +use IPC​::Cmd qw(can_run);

-plan(tests => 1); +if ($Config{'usecrosscompile'} && !can_run($Config{'cc'})) { + skip_all("compiler not available (cross-compiling)"); +} else { + plan(tests => 1); +}

my $VERBOSE = grep {$_ eq '-v'} @​ARGV;

Thank you. Applied as 38321b6. --

Father Chrysostomos

p5pRT commented 10 years ago

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

p5pRT commented 10 years ago

@cpansprout - Status changed from 'open' to 'resolved'