[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
AIX 4 libtool configuration
From: |
David Edelsohn |
Subject: |
AIX 4 libtool configuration |
Date: |
Thu, 09 Nov 2000 16:43:04 -0500 |
I have committed the following patches to improve libtool support for AIX
to build libstdc++-v3.
David
* ltcf-c.sh (aix4): Improve shared library configuration; require
exporting symbols.
* ltcf-cxx.sh (aix4): Define.
* ltconfig (aix4): Define library and soname specs appropriate for
AIX. Define command to create export symbols list.
Index: ltcf-c.sh
===================================================================
RCS file: /cvs/gcc/egcs/ltcf-c.sh,v
retrieving revision 1.3
diff -c -p -r1.3 ltcf-c.sh
*** ltcf-c.sh 2000/09/06 13:59:29 1.3
--- ltcf-c.sh 2000/11/09 21:33:43
*************** else
*** 277,289 ****
hardcode_direct=yes
fi
allow_undefined_flag=' ${wl}-berok'
! archive_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs
$deplibs $compiler_flags ${wl}-bexpall ${wl}-bnoentry${allow_undefined_flag}'
! archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname
$libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols
${wl}-bnoentry${allow_undefined_flag}'
! case "$host_os" in aix4.[01]|aix4.[01].*)
! # According to Greg Wooledge, -bexpall is only supported from AIX 4.2 on
! always_export_symbols=yes ;;
! esac
! ;;
amigaos*)
archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME
$libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >>
$output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >>
$output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >>
$output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd
$output_objdir && a2ixlibrary -32)'
--- 277,289 ----
hardcode_direct=yes
fi
allow_undefined_flag=' ${wl}-berok'
! archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname
$libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols
${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS
$output_objdir/$libname$release.a $output_objdir/$soname'
! # -bexpall does not export symbols beginning with underscore (_)
! always_export_symbols=yes
! # Exported symbols can be pulled into shared objects from archives
! whole_archive_flag_spec=' '
! build_libtool_need_lc=yes
! ;;
amigaos*)
archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME
$libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >>
$output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >>
$output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >>
$output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd
$output_objdir && a2ixlibrary -32)'
Index: ltcf-cxx.sh
===================================================================
RCS file: /cvs/gcc/egcs/ltcf-cxx.sh,v
retrieving revision 1.4
diff -c -p -r1.4 ltcf-cxx.sh
*** ltcf-cxx.sh 2000/09/30 06:02:57 1.4
--- ltcf-cxx.sh 2000/11/09 21:33:43
*************** case "$host_os" in
*** 135,142 ****
ld_shlibs=no
;;
aix4*)
! # FIXME: insert proper C++ library support
! ld_shlibs=no
;;
chorus*)
case "$cc_basename" in
--- 135,146 ----
ld_shlibs=no
;;
aix4*)
! archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname
$libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols
${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS
$output_objdir/$libname$release.a $output_objdir/$soname'
! # -bexpall does not export symbols beginning with underscore (_)
! always_export_symbols=yes
! # Exported symbols can be pulled into shared objects from archives
! whole_archive_flag_spec=' '
! build_libtool_need_lc=yes
;;
chorus*)
case "$cc_basename" in
Index: ltconfig
===================================================================
RCS file: /cvs/gcc/egcs/ltconfig,v
retrieving revision 1.10
diff -c -p -r1.10 ltconfig
*** ltconfig 2000/09/30 06:02:57 1.10
--- ltconfig 2000/11/09 21:33:44
*************** aix4*)
*** 949,956 ****
# collect2, so additional links can be useful in future.
# We preserve .a as extension for shared libraries though AIX4.2
# and later linker supports .so
! library_names_spec='${libname}${release}.so$versuffix
${libname}${release}.so$major $libname.a'
shlibpath_var=LIBPATH
;;
amigaos*)
--- 949,958 ----
# collect2, so additional links can be useful in future.
# We preserve .a as extension for shared libraries though AIX4.2
# and later linker supports .so
! library_names_spec='${libname}${release}.a $libname.a'
shlibpath_var=LIBPATH
+ soname_spec='${libname}${release}.so$major.o'
+ export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2
== "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print
\$3 } }'\'' | sort -u > $export_symbols'
;;
amigaos*)
- AIX 4 libtool configuration,
David Edelsohn <=