Can't Build Perl 5.6.1, need help

Gray Fox

Registered
Greetings,

I have a new Mac running MacOS X 10.1.3 and the Developer Dec 11 Tools.

I downloaded the stable version of perl 5.6.1. I tried following the recipe
given in the earlier thread "How-to: Compile Perl 5.6.1"

The result was a disaster!

During the preprocessing their were complaints about MASK being redefined.
Compilation seems to go OK.

When ever a link is done, it hits the fan:
cc -o libperl.dylib -L/usr/local/lib -dynamiclib -compatibility_version 1 -current_version 5.0 -image_base 0x4be00000 -install_name /System/Library/Perl/darwin/CORE/libperl.dylib perl.o gv.o toke.o perly.o op.o regcomp.o dump.o util.o mg.o hv.o av.o run.o pp_hot.o sv.o pp.o scope.o pp_ctl.o pp_sys.o doop.o doio.o regexec.o utf8.o taint.o deb.o universal.o xsutils.o globals.o perlio.o perlapi.o
rm -f opmini.c
cp op.c opmini.c
`sh cflags libperl.dylib opmini.o` -DPERL_EXTERNAL_GLOB opmini.c
CCCMD = cc -DPERL_CORE -c -pipe -fno-common -DHAS_TELLDIR_PROTOTYPE -fno-strict-aliasing -O3
rm -f opmini.c
DYLD_LIBRARY_PATH=/Users/jerry/perl-5.6.1 cc -L/usr/local/lib -o miniperl \
miniperlmain.o opmini.o libperl.dylib -ldl -lm -lc

Many many line like below...


/usr/bin/ld: warning multiple definitions of symbol _Perl_ck_bitop
opmini.o definition of _Perl_ck_bitop in section (__TEXT,__text)
libperl.dylib(op.o) definition of _Perl_ck_bitop
/usr/bin/ld: warning multiple definitions of symbol _Perl_ck_anoncode
opmini.o definition of _Perl_ck_anoncode in section (__TEXT,__text)
libperl.dylib(op.o) definition of _Perl_ck_anoncode
/usr/bin/ld: warning multiple definitions of symbol _Perl_apply_attrs_string
opmini.o definition of _Perl_apply_attrs_string in section (__TEXT,__text)
libperl.dylib(op.o) definition of _Perl_apply_attrs_string
/usr/bin/ld: warning multiple definitions of symbol _Perl_utilize
opmini.o definition of _Perl_utilize in section (__TEXT,__text)
libperl.dylib(op.o) definition of _Perl_utilize
/usr/bin/ld: warning multiple definitions of symbol _Perl_scope
opmini.o definition of _Perl_scope in section (__TEXT,__text)
libperl.dylib(op.o) definition of _Perl_scope
/usr/bin/ld: warning multiple definitions of symbol _Perl_scalar
opmini.o definition of _Perl_scalar in section (__TEXT,__text)
libperl.dylib(op.o) definition of _Perl_scalar
/usr/bin/ld: warning multiple definitions of symbol _Perl_sawparens
opmini.o definition of _Perl_sawparens in section (__TEXT,__text)
libperl.dylib(op.o) definition of _Perl_sawparens
/usr/bin/ld: warning multiple definitions of symbol _Perl_ref
opmini.o definition of _Perl_ref in section (__TEXT,__text)
libperl.dylib(op.o) definition of _Perl_ref
/usr/bin/ld: warning multiple definitions of symbol _Perl_prepend_elem
opmini.o definition of _Perl_prepend_elem in section (__TEXT,__text)
libperl.dylib(op.o) definition of _Perl_prepend_elem
/usr/bin/ld: warning multiple definitions of symbol _Perl_pmruntime
oplibperl.dylib(op.o) definition of _Perl_newSVOP
/usr/bin/ld: warning multiple definitions of symbol _Perl_newSUB
opmini.o definition of _Perl_newSUB in section (__TEXT,__text)
libperl.dylib(op.o) definition of _Perl_newSUB
DYLD_LIBRARY_PATH=/Users/jerry/perl-5.6.1 ./miniperl -w -Ilib -MExporter -e '<?>' || make minitest
Can't load module File::Glob, dynamic loading not available in this perl.
(You may need to build a new perl executable which either supports
dynamic loading or has the File::Glob module statically linked into it.)
at -e line 1
Compilation failed in require at -e line 1.
BEGIN failed--compilation aborted at -e line 1.
You may see some irrelevant test failures if you have been unable
to build lib/Config.pm.
cd t && (rm -f perl; /bin/ln -s ../miniperl perl) \
&& DYLD_LIBRARY_PATH=/Users/jerry/perl-5.6.1 ./perl TEST base/*.t comp/*.t cmd/*.t run/*.t io/*.t op/*.t pragma/*.t </dev/tty
base/cond............ok
base/if..............ok
base/lex.............ok
base/pat.............ok
base/rs..............ok
base/term............Can't locate Config.pm in @INC (@INC contains: ../lib) at base/term.t line 10.
BEGIN failed--compilation aborted at base/term.t line 10.
FAILED at test 0
Failed a basic test--cannot continue.
make[1]: [minitest] Error 2 (ignored)
make: [extra.pods] Error 1 (ignored)
DYLD_LIBRARY_PATH=/Users/jerry/perl-5.6.1 ./miniperl configpm configpm.tmp
sh mv-if-diff configpm.tmp lib/Config.pm
AutoSplitting perl library
DYLD_LIBRARY_PATH=/Users/jerry/perl-5.6.1 ./miniperl -Ilib -e 'use AutoSplit; \
autosplit_lib_modules(@ARGV)' lib/*.pm lib/*/*.pm
AutoSplitting lib/Getopt/Long.pm (lib/auto/Getopt/Long)
DYLD_LIBRARY_PATH=/Users/jerry/perl-5.6.1 ./miniperl minimod.pl > minimod.tmp
sh mv-if-diff minimod.tmp lib/ExtUtils/Miniperl.pm
sh writemain lib/auto/DynaLoader/DynaLoader.a > writemain.tmp
sh mv-if-diff writemain.tmp perlmain.c
File perlmain.c not changed.
`sh cflags libperl.dylib perlmain.o` perlmain.c
CCCMD = cc -DPERL_CORE -c -pipe -fno-common -DHAS_TELLDIR_PROTOTYPE -fno-strict-aliasing -O3

Making DynaLoader (static)
Can't load module File::Glob, dynamic loading not available in this perl.
(You may need to build a new perl executable which either supports
dynamic loading or has the File::Glob module statically linked into it.)
Compilation failed in require at (eval 70) line 7.
BEGIN failed--compilation aborted at (eval 70) line 7.
at ../../lib/ExtUtils/MakeMaker.pm line 507
Warning: No Makefile!
make[1]: *** No rule to make target `config'. Stop.
make config failed, continuing anyway...
make[1]: *** No rule to make target `all'. Stop.
make: *** [lib/auto/DynaLoader/DynaLoader.a] Error 2
[jerry@macjerry ~/perl-5.6.1] :


Help!
 
OK, I went back and did a make realclean and deleted the config.sh
files, changed from bash to tcsh and reconfiged with the suggested
flags, did a make and got all of the way through. ( Still had the
complaints about MASK being redefined.)

This time I ran make test and got:
.
.
.pragma/warnings......PROG:
# pp_hot.c [pp_print]
use warnings 'io' ;
print STDIN "anc";
print <STDOUT>;
print <STDERR>;
open(FOO, ">&STDOUT") and print <FOO>;
print getc(STDERR);
print getc(FOO);
####################################################################
# The next test is known to fail on some systems (Linux+old glibc, #
# old *BSDs, and NeXT, among others. #
# We skip it for now (on the grounds that it is "just" a warning). #
####################################################################
#read(FOO,$_,1);
no warnings 'io' ;
print STDIN "anc";
EXPECTED:
Filehandle STDIN opened only for input at - line 3.
Filehandle STDOUT opened only for output at - line 4.
Filehandle STDERR opened only for output at - line 5.
Filehandle FOO opened only for output at - line 6.
Filehandle STDERR opened only for output at - line 7.
Filehandle FOO opened only for output at - line 8.
GOT:
Filehandle STDIN opened only for input at - line 3.
Filehandle STDOUT opened only for output at - line 4.
Filehandle STDERR opened only for output at - line 5.
Filehandle STDERR opened only for output at - line 7.
FAILED at test 303
lib/abbrev...........ok
lib/ansicolor........ok
lib/anydbm...........ok
lib/attrs............ok
lib/autoloader.......ok
lib/b................ok
lib/basename.........ok
lib/bigfloat.........ok
lib/bigfltpm.........ok
lib/bigint...........ok
lib/bigintpm.........ok
lib/cgi-esc..........ok
lib/cgi-form.........ok
lib/cgi-function.....ok
lib/cgi-html.........ok
lib/cgi-pretty.......ok
lib/cgi-request......ok
lib/charnames........ok
lib/checktree........ok
lib/class-struct.....ok
lib/complex..........ok
lib/db-btree.........FAILED at test 0
lib/db-hash..........ok
lib/db-recno.........#
# Some older versions of Berkeley DB version 1 will fail tests 51,
# 53 and 55.
#
# You can safely ignore the errors if you're never going to use the
# broken functionality (recno databases with a modified bval).
# Otherwise you'll have to upgrade your DB library.
#
# If you want to use Berkeley DB version 1, then 1.85 and 1.86 are the
# last versions that were released. Berkeley DB version 2 is continually
# being updated -- Check out http://www.sleepycat.com/ for more details.
#
FAILED at test 51
.
.
.
lib/ph...............ok
lib/posix............FAILED at test 11
lib/safe1............ok
...
lib/trig.............ok
Failed 4 test scripts out of 251, 98.41% okay.
### Since not all tests were successful, you may want to run some
### of them individually and examine any diagnostic messages they
### produce. See the INSTALL document's section on "make test".
### If you are testing the compiler, then ignore this message
### and run
### ./perl harness
### in the directory ./t.
###
### Since most tests were successful, you have a good chance to
### get information with better granularity by running
### ./perl harness
### in directory ./t.
u=0.68 s=0 cu=42.8 cs=10.37 scripts=251 tests=12791
make: *** [test] Error 1
[macjerry:~/perl-5.6.1] jerry%

******************************************
Question: Are these the "known" errors, is it safe to install?

I used to make Perl a long time ago, seems like I had to run
some program h2ph(?) on all of the header files in order to get
many modules to compile.

Any suggestions on postinstallation cleanup?

Thanks,

--Jerry ( AKA Gray Fox)
 
Ok,

I have been browsing the /System/Library/Perl directory...

It contains a buncho Apache "Stuff". Will installing Perl over the
top of the existing Perl wipe out or invalidate the existing Apache
module stuff?

Don't want to try rebuilding Apache till my feet get used to the
water :)

Thanks

Gray Fox
 
Back
Top