Hi!

----

I just did some experiments with a 64bit version of ksh93 on Solaris 8
(I have attached the build script as "buildksh93_64bit_sparcv9.ksh"). So
far this seems to be working - but I found a serious issue with the AST
include files in /usr/include/ast/. It seems the generated parts of the
includes differ between 64bit and 32bit builds (see attached
"ksh93_sparc_32bit_arch_vs_64bit_arch.diff.txt.gz") of the same
ksh93/libast version on the same OS, making it difficult to ship one set
of include files for both 32bit and 64bit executables which depend on
libast/libshell/libdll and libcmd.
For now I can work around that issue in OpenSolaris since I am using a
static configuration and can manually place #ifdef/#else/#endif around
the differences - but IMO it would be better when the public libast
include files could be really static on one OS (e.g. Solaris) -
otherwise we would need at least four different sets of include files -
one for 32bit i386, one for AMD64, one for 32bit SPARC and one for 64bit
SPARCv9 (and if gcc builds require modifications (the current builds
were all done with Sun Workshop/Forte/Studio) then we need eight
different sets... ;-().

Comments/suggestions/etc. welcome...

----

Bye,
Roland

-- 
  __ .  . __
 (o.\ \/ /.o) roland.mainz at nrubsig.org
  \__\/\/__/  MPEG specialist, C&&JAVA&&Sun&&Unix programmer
  /O /==\ O\  TEL +49 641 7950090
 (;O/ \/ \O;)
-------------- next part --------------
#!/usr/bin/ksh
# modified for 64bit builds 20060329

set -e -x

IGNORE=""
CCFLAGS="-KPIC -g -xs -Xa -xstrconst -z combreloc -xildoff $IGNORE"
HOSTTYPE=sol8.sun4
CC="/opt/studio/SOS10/SUNWspro/bin/cc -xarch=v9 -KPIC"
export CCFLAGS CC HOSTTYPE

bin/package make

root=$(echo ${PWD}/arch/sol8.sun4)
test -d $root || exit 1
log=${root}/lib/package/gen/make.out

test -s $log || exit 1
# libcmd cannot be dynamically for now as there is a squatter in solaris
for lib in libast libdll libshell ; do
    test $? -eq 0 || exit 1
    case "$lib" in
    libshell)
        base=lib/
        vers=1
        link="-L${root}/lib/ -lcmd -ldll -last -lm"
        ;;
    *)
        base=src/lib/$lib
        vers=1
        link=""
        ;;
    esac

    (
    cd ${root}/${base}
    ${CC} -G ${CCFLAGS} -o ${root}/lib/${lib}.so.${vers} ${lib}.a  
-Wl,-zallextract -Wl,-zmuldefs $link
    
    #rm ${lib}.a
    mv ${lib}.a disabled_${lib}.ax
    
    cd ${root}/lib
    ln -sf ${lib}.so.${vers} ${lib}.so
    )
done

(
  base=src/cmd/ksh93
  cd ${root}/${base}
  rm -f ${root}/lib/libshell.a
  rm -f ${root}/lib/libdll.a
  rm -f ${root}/lib/libast.a
  
  # uhm... this only works for a full build... ;-(
  ${CC} ${CCFLAGS} -L${root}/lib/ -o ksh pmain.o -lshell -lcmd -ldll -last -lm 
-lsecdb
)

# EOF.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ksh93_sparc_32bit_arch_vs_64bit_arch.diff.txt.gz
Type: application/x-gzip
Size: 13839 bytes
Desc: not available
URL: 
<http://mail.opensolaris.org/pipermail/ksh93-integration-discuss/attachments/20060330/7e22e467/attachment.bin>

Reply via email to