develooper Front page | perl.perl5.porters | Postings from May 2016

[perl #128295] Strange bug with -Dprefix=/usr and -Dversiononly

Thread Previous
From:
Father Chrysostomos
Date:
May 30, 2016 21:30
Subject:
[perl #128295] Strange bug with -Dprefix=/usr and -Dversiononly
Message ID:
rt-4.0.18-23770-1464643818-1149.128295-75-0@perl.org
# New Ticket Created by  Father Chrysostomos 
# Please include the string:  [perl #128295]
# in the subject line of all future correspondence about this issue. 
# <URL: https://rt.perl.org/Ticket/Display.html?id=128295 >


I have tried installing perl 5.24.0 on an old PPC machine, with the configuration below, but it installed the perl binary and the scripts in /bin, even though I specified a prefix of /usr.

I don’t know exactly which option is responsible for the bug, but I do find it really strange.

This is what is *really* unhelpful:

$ which cpan5.24.0
/bin/cpan5.24.0
$ cpan5.24.0
-bash: /bin/cpan5.24.0: /usr/bin/perl5.24.0: bad interpreter: No such file or directory
$ head -3 `which cpan5.24.0`
#!/usr/bin/perl5.24.0
    eval 'exec /usr/bin/perl5.24.0 -S $0 ${1+"$@"}'
	if $running_under_some_shell;

So the #! line is correct in using /usr/bin/, which is what I asked for, but every got plopped in /bin instead, so nothing5.24.0 works.  I have to use perl5.24.0 -S whatever5.24.0.  Grrr!!!

More info follows.  Also attached are config.sh and Policy.sh.

$ which perl5.24.0
/bin/perl5.24.0
$ perl5.24.0 -V
Summary of my perl5 (revision 5 version 24 subversion 0) configuration:
   
  Platform:
    osname=darwin, osvers=9.7.0, archname=darwin-2level
    uname='darwin treebeard.local 9.7.0 darwin kernel version 9.7.0: tue mar 31 22:54:29 pdt 2009; root:xnu-1228.12.14~1release_ppc power macintosh '
    config_args='-de -Dprefix=/usr -Doptimize=-O3 -Accflags=-DNO_MATHOMS -Dversiononly'
    hint=recommended, useposix=true, d_sigaction=define
    useithreads=undef, usemultiplicity=undef
    use64bitint=undef, use64bitall=undef, uselongdouble=undef
    usemymalloc=n, bincompat5005=undef
  Compiler:
    cc='cc', ccflags ='-fno-common -DPERL_DARWIN -DNO_MATHOMS -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -D_FORTIFY_SOURCE=2 -DPERL_USE_SAFE_PUTENV',
    optimize='-O3',
    cppflags='-fno-common -DPERL_DARWIN -DNO_MATHOMS -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include'
    ccversion='', gccversion='4.0.1 (Apple Inc. build 5465)', gccosandvers=''
    intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=4321, doublekind=4
    d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=16, longdblkind=6
    ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='off_t', lseeksize=8
    alignbytes=8, prototype=define
  Linker and Libraries:
    ld='env MACOSX_DEPLOYMENT_TARGET=10.3 cc', ldflags =' -fstack-protector -L/usr/local/lib'
    libpth=/usr/local/lib /usr/lib
    libs=-lpthread -ldbm -ldl -lm -lutil -lc
    perllibs=-lpthread -ldl -lm -lutil -lc
    libc=, so=dylib, useshrplib=false, libperl=libperl.a
    gnulibc_version=''
  Dynamic Linking:
    dlsrc=dl_dlopen.xs, dlext=bundle, d_dlsymun=undef, ccdlflags=' '
    cccdlflags=' ', lddlflags=' -bundle -undefined dynamic_lookup -L/usr/local/lib -fstack-protector'


Characteristics of this binary (from libperl): 
  Compile-time options: HAS_TIMES NO_MATHOMS PERLIO_LAYERS PERL_COPY_ON_WRITE
                        PERL_DONT_CREATE_GVSV
                        PERL_HASH_FUNC_ONE_AT_A_TIME_HARD PERL_MALLOC_WRAP
                        PERL_PRESERVE_IVUV PERL_USE_SAFE_PUTENV
                        USE_LARGE_FILES USE_LOCALE USE_LOCALE_COLLATE
                        USE_LOCALE_CTYPE USE_LOCALE_NUMERIC USE_LOCALE_TIME
                        USE_PERLIO USE_PERL_ATOF
  Built under darwin
  Compiled at May 26 2016 13:38:00
  @INC:
    /Library/Perl/5.24.0/darwin-2level
    /Library/Perl/5.24.0
    /Network/Library/Perl/5.24.0/darwin-2level
    /Network/Library/Perl/5.24.0
    /System/Library/Perl/5.24.0/darwin-2level
    /System/Library/Perl/5.24.0
    /Library/Perl
    /Network/Library/Perl
    .


-- 

Father Chrysostomos

Thread Previous


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About