A few years back I asked about compiling a 64-bit Perl on SPARC Solaris. Since then it looks like steps have been taken to make this a lot easier as I just did it with Perl 5.8.7 on Solaris 8. But just in case some are still having trouble here is how I built it. Things under /opt/sfw are from SUN's Software Companion CD and things in /usr/local are usually GNU utilities that I compiled earlier. You will want to replace the target paths with something appropriate to your environment (I am planning on installing everything I compile with gcc 4.0.2 under /usr/local402). I'll post config.sh as a reply since it is so long.

gcc -v

Using built-in specs. Target: sparc-sun-solaris2.8 Configured with: /export2/build/gcc402/gcc-4.0.2/configure --prefix=/u +sr/local402 --enable-__cxa_atexit --enable-threads=posix --enable-sha +red --enable-PIC --with-as=/usr/ccs/bin/as --with-ld=/usr/ccs/bin/ld +--with-ar=/usr/local/bin/ar --with-sed=/opt/sfw/bin/gsed Thread model: posix gcc version 4.0.2

perl -V

Summary of my perl5 (revision 5 version 8 subversion 7) configuration: Platform: osname=solaris, osvers=2.8, archname=sun4-solaris-thread-multi-64 uname='sunos searay 5.8 generic_108528-17 sun4u sparc sunw,sun-fir +e-880 ' config_args='-d' hint=previous, useposix=true, d_sigaction=define usethreads=define use5005threads=undef useithreads=define usemulti +plicity=define useperlio=define d_sfio=undef uselargefiles=define usesocks=undef use64bitint=define use64bitall=define uselongdouble=undef usemymalloc=n, bincompat5005=undef Compiler: cc='/usr/local402/bin/gcc', ccflags ='-m64 -D_REENTRANT -fno-stric +t-aliasing -pipe -I/usr/local/include -mcpu=v9 -m64 -Wa,-xarch=v9 -D_ +LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64', optimize='-O3', cppflags='-m64 -D_REENTRANT -fno-strict-aliasing -pipe -I/usr/loca +l/include -m64 -D_REENTRANT -fno-strict-aliasing -pipe -I/usr/local/i +nclude -mcpu=v9 -m64 -Wa,-xarch=v9 -D_LARGEFILE_SOURCE -D_FILE_OFFSET +_BITS=64' ccversion='', gccversion='4.0.2', gccosandvers='' intsize=4, longsize=8, ptrsize=8, doublesize=8, byteorder=87654321 d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=1 +6 ivtype='long', ivsize=8, nvtype='double', nvsize=8, Off_t='off_t', + lseeksize=8 alignbytes=8, prototype=define Linker and Libraries: ld='/usr/local402/bin/gcc', ldflags ='-m64 -L/usr/local/lib -m64 ' libpth=/usr/local402/lib /usr/local/lib /usr/lib /usr/ccs/lib libs=-lsocket -lnsl -ldl -lm -lpthread -lc perllibs=-lsocket -lnsl -ldl -lm -lpthread -lc libc=/usr/lib/sparcv9/libc.so, so=so, useshrplib=false, libperl=li +bperl.a gnulibc_version='' Dynamic Linking: dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags=' ' cccdlflags='-fPIC', lddlflags=' -G -m64 -L/usr/local/lib' Characteristics of this binary (from libperl): Compile-time options: MULTIPLICITY USE_ITHREADS USE_64_BIT_INT USE_64_BIT_ALL USE_LARGE_FILES PERL_IMPLICIT_CONTEXT Built under solaris Compiled at Jan 19 2006 15:43:47 @INC: /usr/local402/lib/5.8.7/sun4-solaris-thread-multi-64 /usr/local402/lib/5.8.7 /usr/local402/lib/site_perl/5.8.7/sun4-solaris-thread-multi-64 /usr/local402/lib/site_perl/5.8.7 /usr/local402/lib/site_perl

2006-01-21 Retitled by planetscape, as per Monastery guidelines
Original title: '64-bit Perl on SPARC Solaris'


In reply to config.sh, as promised (Re: 64-bit Perl on SPARC Solaris) by Argel

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.