public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* Re: libtool / GCC 3.2 question and patch
@ 2002-07-11 14:32 Steve Ellcey
  2002-08-13 19:43 ` Alexandre Oliva
  0 siblings, 1 reply; 9+ messages in thread
From: Steve Ellcey @ 2002-07-11 14:32 UTC (permalink / raw)
  To: aoliva; +Cc: binutils, dave, gcc-patches, mark

> Hmm...  Sorry, I have missed the need for that.  Might I perhaps ask
> you to prepare patches, one to be installed in the GCC repo, and one
> to be installed in s.r.c., so that they look the way you want,
> collecting the corresponding ChangeLog entries so as to give credit
> where it is due?

Here is the exact libtool patch I sent to binutils, I just applied it to
my local copy of the gcc libtool to make sure it worked and after
applying it it brought libtool.m4, ltcf-c.sh, and ltconfig into an exact
match with binutils.  ltcf-cxx.sh and ltcf-gcj.sh already match.

If you apply this patch to GCC the only difference between binutils and
GCC versions of libtool will be in ltmain.sh where Loren Rittle made a
change in the GCC version of ltmain.sh that is not reflected in the
binutils version.

Steve Ellcey
sje@cup.hp.com


2002-01-22  Steve Ellcey <sje@cup.hp.com>
        * libtool.m4 (HPUX_IA64_MODE): Set to 32 or 64 based on ABI.
        (lt_cv_deplibs_check_method, lt_cv_file_magic_cmd,
        lt_cv_file_magic_test_file): Set to appropriate values for HP-UX IA64.
        * ltcf-c.sh (archive_cmds, hardcode_*): Ditto.
        * ltconfig (shlibpath_*, dynamic_linker, library_names_spec,
        soname_spec, sys_lib_search_path_spec): Ditto.


*** src.orig/libtool.m4	Tue Jan 22 15:40:53 2002
--- src/libtool.m4	Tue Jan 22 15:40:28 2002
*************** case $host in
*** 159,164 ****
--- 159,180 ----
    rm -rf conftest*
    ;;
  
+ ia64-*-hpux*)
+   # Find out which ABI we are using.
+   echo 'int i;' > conftest.$ac_ext
+   if AC_TRY_EVAL(ac_compile); then
+     case "`/usr/bin/file conftest.o`" in
+     *ELF-32*)
+       HPUX_IA64_MODE="32"
+       ;;
+     *ELF-64*)
+       HPUX_IA64_MODE="64"
+       ;;
+     esac
+   fi
+   rm -rf conftest*
+   ;;
+ 
  *-*-sco3.2v5*)
    # On SCO OpenServer 5, we need -belf to get full-featured binaries.
    SAVE_CFLAGS="$CFLAGS"
*************** gnu*)
*** 568,576 ****
    ;;
  
  hpux10.20*|hpux11*)
!   lt_cv_deplibs_check_method=['file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library']
!   lt_cv_file_magic_cmd=/usr/bin/file
!   lt_cv_file_magic_test_file=/usr/lib/libc.sl
    ;;
  
  irix5* | irix6*)
--- 584,601 ----
    ;;
  
  hpux10.20*|hpux11*)
!   case $host_cpu in
!   hppa*)
!     [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library']
!     lt_cv_file_magic_cmd=/usr/bin/file
!     lt_cv_file_magic_test_file=/usr/lib/libc.sl
!     ;;
!   ia64*)
!     [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64']
!     lt_cv_file_magic_cmd=/usr/bin/file
!     lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
!     ;;
!   esac
    ;;
  
  irix5* | irix6*)
*** src.orig/ltcf-c.sh	Tue Jan 22 15:41:03 2002
--- src/ltcf-c.sh	Tue Jan 22 15:40:39 2002
*************** else
*** 417,439 ****
      ;;
  
    hpux9* | hpux10* | hpux11*)
!     if test $with_gcc = yes; then
!       case "$host_os" in
!       hpux9*) archive_cmds='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' ;;
!       *) archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;;
!       esac
!     else
!       case $host_os in
!       hpux9*) archive_cmds='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' ;;
!       *) archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' ;;
!       esac
!     fi
!     hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
!     hardcode_libdir_separator=:
!     hardcode_direct=yes
!     hardcode_minus_L=yes # Not in the search PATH, but as the default
! 			 # location of the library.
      export_dynamic_flag_spec='${wl}-E'
      ;;
  
    irix5* | irix6*)
--- 417,448 ----
      ;;
  
    hpux9* | hpux10* | hpux11*)
!     case "$host_cpu" in
!     ia64*)
!       hardcode_direct=no
!       hardcode_shlibpath_var=no
!       archive_cmds='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags'
!       hardcode_libdir_flag_spec='-L$libdir' ;;
!     *)
!       if test $with_gcc = yes; then
!         case "$host_os" in
!         hpux9*) archive_cmds='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' ;;
!         *) archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;;
!         esac
!       else
!         case $host_os in
!         hpux9*) archive_cmds='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' ;;
!         *) archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' ;;
!         esac
!       fi
!       hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
!       hardcode_libdir_separator=:
!       hardcode_minus_L=yes # Not in the search PATH, but as the default
! 			   # location of the library.
!       ;;
!     esac
      export_dynamic_flag_spec='${wl}-E'
+     hardcode_direct=yes
      ;;
  
    irix5* | irix6*)
*** src.orig/ltconfig	Tue Jan 22 15:40:57 2002
--- src/ltconfig	Tue Jan 22 15:40:34 2002
*************** gnu*)
*** 1155,1168 ****
  hpux9* | hpux10* | hpux11*)
    # Give a soname corresponding to the major version so that dld.sl refuses to
    # link against other versions.
-   dynamic_linker="$host_os dld.sl"
    version_type=sunos
    need_lib_prefix=no
    need_version=no
!   shlibpath_var=SHLIB_PATH
!   shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
!   library_names_spec='${libname}${release}.sl$versuffix ${libname}${release}.sl$major $libname.sl'
!   soname_spec='${libname}${release}.sl$major'
    # HP-UX runs *really* slowly unless shared libraries are mode 555.
    postinstall_cmds='chmod 555 $lib'
    ;;
--- 1155,1186 ----
  hpux9* | hpux10* | hpux11*)
    # Give a soname corresponding to the major version so that dld.sl refuses to
    # link against other versions.
    version_type=sunos
    need_lib_prefix=no
    need_version=no
!   case "$host_cpu" in
!   ia64*)
!     dynamic_linker="$host_os dld.so"
!     shlibpath_var=LD_LIBRARY_PATH
!     library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
!     soname_spec='${libname}${release}.so$major'
!     shlibpath_var=LD_LIBRARY_PATH
!     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
!     if test "X$HPUX_IA64_MODE" = X32; then
!       sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32/usr/local/lib"
!     else
!       sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
!     fi
!     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
!     ;;
!   *)
!     dynamic_linker="$host_os dld.sl"
!     shlibpath_var=SHLIB_PATH
!     shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
!     library_names_spec='${libname}${release}.sl$versuffix ${libname}${release}.sl$major $libname.sl'
!     soname_spec='${libname}${release}.sl$major'
!     ;;
!   esac
    # HP-UX runs *really* slowly unless shared libraries are mode 555.
    postinstall_cmds='chmod 555 $lib'
    ;;

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: libtool / GCC 3.2 question and patch
  2002-07-11 14:32 libtool / GCC 3.2 question and patch Steve Ellcey
@ 2002-08-13 19:43 ` Alexandre Oliva
  0 siblings, 0 replies; 9+ messages in thread
From: Alexandre Oliva @ 2002-08-13 19:43 UTC (permalink / raw)
  To: Steve Ellcey; +Cc: binutils, dave, gcc-patches, mark

On Jul 11, 2002, Steve Ellcey <sje@cup.hp.com> wrote:

> 2002-01-22  Steve Ellcey <sje@cup.hp.com>
>         * libtool.m4 (HPUX_IA64_MODE): Set to 32 or 64 based on ABI.
>         (lt_cv_deplibs_check_method, lt_cv_file_magic_cmd,
>         lt_cv_file_magic_test_file): Set to appropriate values for HP-UX IA64.
>         * ltcf-c.sh (archive_cmds, hardcode_*): Ditto.
>         * ltconfig (shlibpath_*, dynamic_linker, library_names_spec,
>         soname_spec, sys_lib_search_path_spec): Ditto.

Thanks, I've finally checked this in.  Sorry about the exceedingly
long delay.

-- 
Alexandre Oliva   Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer                 aoliva@{redhat.com, gcc.gnu.org}
CS PhD student at IC-Unicamp        oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist                Professional serial bug killer

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: libtool / GCC 3.2 question and patch
  2002-07-10 13:40 Steve Ellcey
@ 2002-07-10 20:50 ` Alexandre Oliva
  0 siblings, 0 replies; 9+ messages in thread
From: Alexandre Oliva @ 2002-07-10 20:50 UTC (permalink / raw)
  To: sje; +Cc: binutils, dave, gcc-patches, mark

On Jul 10, 2002, Steve Ellcey <sje@cup.hp.com> wrote:

> I need the changes that are already in the binutils versions of
> libtool.m4, ltcf-c.sh, ltconfig, and ltmain.sh to be brought over to GCC
> in order to get HP-UX IA64 working.  I suppose ltcf-gcj.sh should be
> copied over too in order to be consistent.

Hmm...  Sorry, I have missed the need for that.  Might I perhaps ask
you to prepare patches, one to be installed in the GCC repo, and one
to be installed in s.r.c., so that they look the way you want,
collecting the corresponding ChangeLog entries so as to give credit
where it is due?

Thanks in advance,

-- 
Alexandre Oliva   Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer                  aoliva@{cygnus.com, redhat.com}
CS PhD student at IC-Unicamp        oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist                Professional serial bug killer

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: libtool / GCC 3.2 question and patch
@ 2002-07-10 13:40 Steve Ellcey
  2002-07-10 20:50 ` Alexandre Oliva
  0 siblings, 1 reply; 9+ messages in thread
From: Steve Ellcey @ 2002-07-10 13:40 UTC (permalink / raw)
  To: aoliva; +Cc: binutils, dave, gcc-patches, mark

Alexandre,

I see you checked my change to ltcf-cxx.sh into binutils and gcc, were
you also going to update gcc with the other libtool files from binutils?

I need the changes that are already in the binutils versions of
libtool.m4, ltcf-c.sh, ltconfig, and ltmain.sh to be brought over to GCC
in order to get HP-UX IA64 working.  I suppose ltcf-gcj.sh should be
copied over too in order to be consistent.

I saw that Dave Anglin has made changes to libtool for hppa64 so it
might be better to check his changes into binutils first and then copy
them over to GCC.  I don't think any changes have gone into the GCC
libtool that aren't also in binutils.

Steve Ellcey
sje@cup.hp.com

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: libtool / GCC 3.2 question and patch
  2002-06-14  9:02     ` Mark Mitchell
@ 2002-07-04 17:52       ` Alexandre Oliva
  0 siblings, 0 replies; 9+ messages in thread
From: Alexandre Oliva @ 2002-07-04 17:52 UTC (permalink / raw)
  To: Mark Mitchell; +Cc: sje, binutils, gcc-patches

On Jun 14, 2002, Mark Mitchell <mark@codesourcery.com> wrote:

>> This would be tricky, because IIRC a newer libtool would require a
>> newer autoconf and a newer automake.  I've started playing with them
>> in the context of GCC a few weeks ago, ran into some problems but
>> never got as far as fixing them, so, let's go with Steve's patches for
>> now.

> Will you please install them?

I'm doing this now.  Apologies for the delay.

-- 
Alexandre Oliva   Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer                  aoliva@{cygnus.com, redhat.com}
CS PhD student at IC-Unicamp        oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist                Professional serial bug killer

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: libtool / GCC 3.2 question and patch
  2002-06-14  2:11   ` Alexandre Oliva
@ 2002-06-14  9:02     ` Mark Mitchell
  2002-07-04 17:52       ` Alexandre Oliva
  0 siblings, 1 reply; 9+ messages in thread
From: Mark Mitchell @ 2002-06-14  9:02 UTC (permalink / raw)
  To: Alexandre Oliva; +Cc: sje, binutils, gcc-patches

> This would be tricky, because IIRC a newer libtool would require a
> newer autoconf and a newer automake.  I've started playing with them
> in the context of GCC a few weeks ago, ran into some problems but
> never got as far as fixing them, so, let's go with Steve's patches for
> now.

Will you please install them?

-- 
Mark Mitchell                mark@codesourcery.com
CodeSourcery, LLC            http://www.codesourcery.com

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: libtool / GCC 3.2 question and patch
  2002-06-13 12:53 ` Mark Mitchell
@ 2002-06-14  2:11   ` Alexandre Oliva
  2002-06-14  9:02     ` Mark Mitchell
  0 siblings, 1 reply; 9+ messages in thread
From: Alexandre Oliva @ 2002-06-14  2:11 UTC (permalink / raw)
  To: Mark Mitchell; +Cc: sje, binutils, gcc-patches

On Jun 13, 2002, Mark Mitchell <mark@codesourcery.com> wrote:

> --On Thursday, June 13, 2002 12:13:46 PM -0700 Steve Ellcey
> <sje@cup.hp.com> wrote:

>> Since the deadline for "big changes" is coming up on GCC 3.2, can I
>> assume that the libtools used for GCC 3.2 is not going to be updated to
>> use the libtools top of tree?

> I'd rather we move to the newer libtool, if we can, but I'll let Alexandre
> make a decision on this one.

This would be tricky, because IIRC a newer libtool would require a
newer autoconf and a newer automake.  I've started playing with them
in the context of GCC a few weeks ago, ran into some problems but
never got as far as fixing them, so, let's go with Steve's patches for
now.

-- 
Alexandre Oliva   Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer                  aoliva@{cygnus.com, redhat.com}
CS PhD student at IC-Unicamp        oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist                Professional serial bug killer

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: libtool / GCC 3.2 question and patch
  2002-06-13 12:13 Steve Ellcey
@ 2002-06-13 12:53 ` Mark Mitchell
  2002-06-14  2:11   ` Alexandre Oliva
  0 siblings, 1 reply; 9+ messages in thread
From: Mark Mitchell @ 2002-06-13 12:53 UTC (permalink / raw)
  To: sje, binutils, gcc-patches



--On Thursday, June 13, 2002 12:13:46 PM -0700 Steve Ellcey 
<sje@cup.hp.com> wrote:

> Since the deadline for "big changes" is coming up on GCC 3.2, can I
> assume that the libtools used for GCC 3.2 is not going to be updated to
> use the libtools top of tree?

I'd rather we move to the newer libtool, if we can, but I'll let Alexandre
make a decision on this one.

-- 
Mark Mitchell                mark@codesourcery.com
CodeSourcery, LLC            http://www.codesourcery.com

^ permalink raw reply	[flat|nested] 9+ messages in thread

* libtool / GCC 3.2 question and patch
@ 2002-06-13 12:13 Steve Ellcey
  2002-06-13 12:53 ` Mark Mitchell
  0 siblings, 1 reply; 9+ messages in thread
From: Steve Ellcey @ 2002-06-13 12:13 UTC (permalink / raw)
  To: binutils, gcc-patches

Since the deadline for "big changes" is coming up on GCC 3.2, can I
assume that the libtools used for GCC 3.2 is not going to be updated to
use the libtools top of tree?

If so I would like to make a change in the libtool we are using for GCC
top-of-tree to support the IA64 HP-UX platform.  Most of the changes I
need are already in the binutils libtool but I don't think those changes
have been propagated over to GCC from binutils.  In addition to the
changes already in binutils I need one more change (attached) to
ltcf-cxx.sh.  This change wasn't needed for binutils since binutils
doesn't use C++ so it didn't get checked in with the other changes.  I
have attached a patch and am sending this to binutils and gcc-patches
because I think the way this works is to get the change checked into
binutils and then someone can copy over all the libtool files to GCC.
Is that correct?  Can it be done this way or is there some other process
that needs to happen?

I have no write permission to either binutils or gcc.

Steve Ellcey
sje@cup.hp.com


2002-06-13  Steve Ellcey  <sje@cup.hp.com>
	* ltcf-cxx.sh (hpux*):  Modify to support ia64-*-hpux*


*** src.orig/ltcf-cxx.sh	Thu Jun 13 11:31:24 2002
--- src/ltcf-cxx.sh	Thu Jun 13 11:32:00 2002
*************** case $host_os in
*** 250,260 ****
      ;;
    hpux*)
      if test $with_gnu_ld = no; then
!       hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
        hardcode_libdir_separator=:
        export_dynamic_flag_spec='${wl}-E'
      fi
-     hardcode_direct=yes
      hardcode_minus_L=yes # Not in the search PATH, but as the default
  			 # location of the library.
  
--- 250,266 ----
      ;;
    hpux*)
      if test $with_gnu_ld = no; then
!       case "$host_cpu" in
! 	ia64*)
! 	  hardcode_libdir_flag_spec='-L$libdir'
! 	  hardcode_shlibpath_var=no ;;
! 	*)
! 	  hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' ;;
!       esac
!       hardcode_direct=yes
        hardcode_libdir_separator=:
        export_dynamic_flag_spec='${wl}-E'
      fi
      hardcode_minus_L=yes # Not in the search PATH, but as the default
  			 # location of the library.
  
*************** case $host_os in
*** 283,289 ****
  	  if test $with_gnu_ld = no; then
  	    case "$host_os" in
  	    hpux9*) archive_cmds='$rm $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' ;;
! 	    *) archive_cmds='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;;
  	    esac
  	  fi
  	else
--- 289,302 ----
  	  if test $with_gnu_ld = no; then
  	    case "$host_os" in
  	    hpux9*) archive_cmds='$rm $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' ;;
! 	    *)
! 	      case "$host_cpu" in
! 		ia64*)
! 		  archive_cmds='$LD -b +h $soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' ;;
! 		*)
! 		  archive_cmds='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;;
! 	      esac
! 	      ;;
  	    esac
  	  fi
  	else

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2002-08-14  2:43 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-07-11 14:32 libtool / GCC 3.2 question and patch Steve Ellcey
2002-08-13 19:43 ` Alexandre Oliva
  -- strict thread matches above, loose matches on Subject: below --
2002-07-10 13:40 Steve Ellcey
2002-07-10 20:50 ` Alexandre Oliva
2002-06-13 12:13 Steve Ellcey
2002-06-13 12:53 ` Mark Mitchell
2002-06-14  2:11   ` Alexandre Oliva
2002-06-14  9:02     ` Mark Mitchell
2002-07-04 17:52       ` Alexandre Oliva

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).