public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
* Configuring GCC 10.3 on PPC Mac OS X 10.4.11/Tiger for build reveals flaws in configure scripts
@ 2022-11-25 10:19 Peter Dyballa
  2022-11-25 11:22 ` Jonathan Wakely
  0 siblings, 1 reply; 11+ messages in thread
From: Peter Dyballa @ 2022-11-25 10:19 UTC (permalink / raw)
  To: gcc-help

Hello!

I am just showing the faults and the code causing them, no cure, when building with MacPorts:

----------------------
Configuring stage 1 in ./isl

..../gcc10-bootstrap/work/gcc-10.3.0/isl/configure: line 1: cd: /opt/local/libexec/gcc10-bootstrap: No such file or directory
checking for powerpc-apple-darwin8.11.0-gcc...

checking whether we are using the GNU C compiler... (cached) yes
..../gcc10-bootstrap/work/gcc-10.3.0/isl/configure: line 5363: test: =: unary operator expected
checking whether ..../gcc10-bootstrap/work/bins/gcc accepts -g... yes

 5333	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
 5334	$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
 5335	if ${ac_cv_c_compiler_gnu+:} false; then :
 5336	  $as_echo_n "(cached) " >&6
 5337	else
 5338	  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 5339	/* end confdefs.h.  */
 5340	
 5341	int
 5342	main ()
 5343	{
 5344	#ifndef __GNUC__
 5345	       choke me
 5346	#endif
 5347	
 5348	  ;
 5349	  return 0;
 5350	}
 5351	_ACEOF
 5352	if ac_fn_c_try_compile "$LINENO"; then :
 5353	  ac_compiler_gnu=yes
 5354	else
 5355	  ac_compiler_gnu=no
 5356	fi
 5357	rm -f core conftest.err conftest.$ac_build_objext conftest.$ac_ext
 5358	ac_cv_c_compiler_gnu=$ac_compiler_gnu
 5359	
 5360	fi
 5361	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
 5362	$as_echo "$ac_cv_c_compiler_gnu" >&6; }
 5363	if test $ac_compiler_gnu = yes; then
 5364	  GCC_FOR_BUILD=yes
 5365	else
 5366	  GCC_FOR_BUILD=
 5367	fi
 5368	ac_test_CFLAGS=${CFLAGS_FOR_BUILD+set}
 5369	ac_save_CFLAGS=$CFLAGS_FOR_BUILD
 5370	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC_FOR_BUILD accepts -g" >&5
 5371	$as_echo_n "checking whether $CC_FOR_BUILD accepts -g... " >&6; }
----------------------

Configuring stage 2 in ./isl
configure: creating cache ./config.cache
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... ..../gcc10-bootstrap/work/gcc-10.3.0/isl/./install-sh -c -d
checking for gawk... awk
checking whether ..../gcc10-bootstrap/work/bins/make sets $(MAKE)... yes
checking whether ..../gcc10-bootstrap/work/bins/make supports nested variables... yes
checking whether ..../gcc10-bootstrap/work/bins/make supports nested variables... (cached) yes
..../gcc10-bootstrap/work/gcc-10.3.0/isl/configure: line 1: cd: /opt/local/libexec/gcc10-bootstrap: No such file or directory
checking for powerpc-apple-darwin8.11.0-gcc...

checking whether we are using the GNU C compiler... (cached) yes
..../gcc10-bootstrap/work/gcc-10.3.0/isl/configure: line 5363: test: =: unary operator expected
checking whether  ..../gcc10-bootstrap/work/build/./prev-gcc/xgcc -B..../gcc10-bootstrap/work/build/./prev-gcc/ -B/opt/local/libexec/gcc10-bootstrap/powerpc-apple-darwin8.11.0/bin/ -B/opt/local/libexec/gcc10-bootstrap/powerpc-apple-darwin8.11.0/bin/ -B/opt/local/libexec/gcc10-bootstrap/powerpc-apple-darwin8.11.0/lib/ -isystem /opt/local/libexec/gcc10-bootstrap/powerpc-apple-darwin8.11.0/include -isystem /opt/local/libexec/gcc10-bootstrap/powerpc-apple-darwin8.11.0/sys-include   -fno-checking accepts -g... yes
----------------------

Configuring stage 3 in ./isl
configure: creating cache ./config.cache
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... ..../gcc10-bootstrap/work/gcc-10.3.0/isl/./install-sh -c -d
checking for gawk... awk
checking whether ..../gcc10-bootstrap/work/bins/make sets $(MAKE)... yes
checking whether ..../gcc10-bootstrap/work/bins/make supports nested variables... yes
checking whether ..../gcc10-bootstrap/work/bins/make supports nested variables... (cached) yes
..../gcc10-bootstrap/work/gcc-10.3.0/isl/configure: line 1: cd: /opt/local/libexec/gcc10-bootstrap: No such file or directory
checking for powerpc-apple-darwin8.11.0-gcc...

checking whether we are using the GNU C compiler... (cached) yes
..../gcc10-bootstrap/work/gcc-10.3.0/isl/configure: line 5363: test: =: unary operator expected
checking whether  ..../gcc10-bootstrap/work/build/./prev-gcc/xgcc -B..../gcc10-bootstrap/work/build/./prev-gcc/ -B/opt/local/libexec/gcc10-bootstrap/powerpc-apple-darwin8.11.0/bin/ -B/opt/local/libexec/gcc10-bootstrap/powerpc-apple-darwin8.11.0/bin/ -B/opt/local/libexec/gcc10-bootstrap/powerpc-apple-darwin8.11.0/lib/ -isystem /opt/local/libexec/gcc10-bootstrap/powerpc-apple-darwin8.11.0/include -isystem /opt/local/libexec/gcc10-bootstrap/powerpc-apple-darwin8.11.0/sys-include   -fchecking=1 accepts -g... yes
==================================

Configuring stage 1 in ./libbacktrace

checking for objcopy... no
checking for readelf... readelf
checking whether objcopy supports debuglink... ..../gcc10-bootstrap/work/gcc-10.3.0/libbacktrace/configure: line 13557: --add-gnu-debuglink=x: command not found
no
checking whether tests can run... yes

13553	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether objcopy supports debuglink" >&5
13554	$as_echo_n "checking whether objcopy supports debuglink... " >&6; }
13555	if ${libbacktrace_cv_objcopy_debuglink+:} false; then :
13556	  $as_echo_n "(cached) " >&6
13557	else
13558	  if test -n "${with_target_subdir}"; then
13559	  libbacktrace_cv_objcopy_debuglink=no
13560	elif ${OBJCOPY} --add-gnu-debuglink=x /bin/ls /tmp/ls$$; then
13561	  rm -f /tmp/ls$$
13562	  libbacktrace_cv_objcopy_debuglink=yes
13563	else
13564	  libbacktrace_cv_objcopy_debuglink=no
13565	fi
13566	fi
13567	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libbacktrace_cv_objcopy_debuglink" >&5
13568	$as_echo "$libbacktrace_cv_objcopy_debuglink" >&6; }
13569	 if test "$libbacktrace_cv_objcopy_debuglink" = yes; then
13570	  HAVE_OBJCOPY_DEBUGLINK_TRUE=
13571	  HAVE_OBJCOPY_DEBUGLINK_FALSE='#'
13572	else
13573	  HAVE_OBJCOPY_DEBUGLINK_TRUE='#'
13574	  HAVE_OBJCOPY_DEBUGLINK_FALSE=
13575	fi
----------------------

Configuring stage 2 in ./libbacktrace

checking for readelf... readelf
checking whether objcopy supports debuglink... ..../gcc10-bootstrap/work/gcc-10.3.0/libbacktrace/configure: line 13557: --add-gnu-debuglink=x: command not found
no
checking whether tests can run... yes
==================================


Configuring stage 2 in powerpc-apple-darwin8.11.0/libstdc++-v3

checking for uchar.h... no
no
checking for int64_t... yes

-- I am not sure, if this is really the correct configure script file, gcc-10.3.0/libstdc++-v3/configure? (Maybe I checked one stage too late…)

19101	  # Test uchar.h.
19102	  for ac_header in uchar.h
19103	do :
19104	  ac_fn_c_check_header_mongrel "$LINENO" "uchar.h" "ac_cv_header_uchar_h" "$ac_includes_default"
19105	if test "x$ac_cv_header_uchar_h" = xyes; then :
19106	  cat >>confdefs.h <<_ACEOF
19107	#define HAVE_UCHAR_H 1
19108	_ACEOF
19109	 ac_has_uchar_h=yes
19110	else
19111	  ac_has_uchar_h=no
19112	fi
19113	
19114	done
19115	
19116	
19117	
19118	  ac_ext=cpp
19119	ac_cpp='$CXXCPP $CPPFLAGS'
19120	ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
19121	ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
19122	ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
19123	
19124	  ac_save_CXXFLAGS="$CXXFLAGS"
19125	  CXXFLAGS="$CXXFLAGS -std=c++11"
19126	
19127	  if test x"$ac_has_uchar_h" = x"yes"; then
19128	    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ISO C11 support for <uchar.h>" >&5
19129	$as_echo_n "checking for ISO C11 support for <uchar.h>... " >&6; }
19130	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19131	/* end confdefs.h.  */
19132	#include <uchar.h>
19133			    #ifdef __STDC_UTF_16__
19134			    long i = __STDC_UTF_16__;
19135			    #endif
19136			    #ifdef __STDC_UTF_32__
19137			    long j = __STDC_UTF_32__;
19138			    #endif
19139			    namespace test
19140			    {
19141			      using ::c16rtomb;
19142			      using ::c32rtomb;
19143			      using ::mbrtoc16;
19144			      using ::mbrtoc32;
19145			    }
19146	
19147	int
19148	main ()
19149	{
19150	
19151	  ;
19152	  return 0;
19153	}
19154	_ACEOF
19155	if ac_fn_cxx_try_compile "$LINENO"; then :
19156	  ac_c11_uchar_cxx11=yes
19157	else
19158	  ac_c11_uchar_cxx11=no
19159	fi
19160	rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19161	  else
19162	    ac_c11_uchar_cxx11=no
19163	  fi
19164	  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_c11_uchar_cxx11" >&5
19165	$as_echo "$ac_c11_uchar_cxx11" >&6; }
19166	  if test x"$ac_c11_uchar_cxx11" = x"yes"; then
19167	
19168	$as_echo "#define _GLIBCXX_USE_C11_UCHAR_CXX11 1" >>confdefs.h
19169	
19170	  fi
19171	
19172	  CXXFLAGS="$ac_save_CXXFLAGS"
19173	  ac_ext=c
19174	ac_cpp='$CPP $CPPFLAGS'
19175	ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
19176	ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
19177	ac_compiler_gnu=$ac_cv_c_compiler_gnu
==================================


Configuring stage 2 in ./gcc

checking linker --sysroot support... no
checking __stack_chk_fail in target C library... checking for __stack_chk_fail... no
no __stack_chk_fail on this target
no
checking sys/sdt.h in the target C library... no

30110	# Test for stack protector support in target C library.
30111	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking __stack_chk_fail in target C library" >&5
30112	$as_echo_n "checking __stack_chk_fail in target C library... " >&6; }
30113	if ${gcc_cv_libc_provides_ssp+:} false; then :
30114	  $as_echo_n "(cached) " >&6
30115	else
30116	  gcc_cv_libc_provides_ssp=no
30117	  if test "x$enable_libssp" = "xno"; then
30118	    gcc_cv_libc_provides_ssp=yes
30119	  elif test "x$enable_libssp" = "xyes"; then
30120	    gcc_cv_libc_provides_ssp=no
30121	  else
30122	    case "$target" in
30123	       *-*-musl*)
30124		 # All versions of musl provide stack protector
30125		 gcc_cv_libc_provides_ssp=yes;;
30126	       *-*-linux* | *-*-kfreebsd*-gnu)
30127	      # glibc 2.4 and later provides __stack_chk_fail and
30128	      # either __stack_chk_guard, or TLS access to stack guard canary.
30129	
30130	if test $glibc_version_major -gt 2 \
30131	  || ( test $glibc_version_major -eq 2 && test $glibc_version_minor -ge 4 ); then :
30132	  gcc_cv_libc_provides_ssp=yes
30133	else
30134	
30135	      if test -f $target_header_dir/features.h \
30136		 && $EGREP '^[ 	]*#[ 	]*define[ 	]+__GNU_LIBRARY__[ 	]+([1-9][0-9]|[6-9])' \
30137		    $target_header_dir/features.h > /dev/null; then
30138		if $EGREP '^[ 	]*#[ 	]*define[ 	]+__UCLIBC__[ 	]+1' \
30139		     $target_header_dir/features.h > /dev/null && \
30140		     test -f $target_header_dir/bits/uClibc_config.h && \
30141		     $EGREP '^[ 	]*#[ 	]*define[ 	]+__UCLIBC_HAS_SSP__[ 	]+1' \
30142		     $target_header_dir/bits/uClibc_config.h > /dev/null; then
30143		  gcc_cv_libc_provides_ssp=yes
30144		fi
30145	      # all versions of Bionic support stack protector
30146	      elif test -f $target_header_dir/sys/cdefs.h \
30147	        && $EGREP '^[  ]*#[    ]*define[       ]+__BIONIC__[   ]+1' \
30148	           $target_header_dir/sys/cdefs.h > /dev/null; then
30149	         gcc_cv_libc_provides_ssp=yes
30150	      fi
30151	fi
30152		;;
30153	       *-*-gnu*)
30154		 # Avoid complicated tests (see
30155		 # <http://gcc.gnu.org/ml/gcc/2008-10/msg00130.html>) and for now
30156		 # simply assert that glibc does provide this, which is true for all
30157		 # realistically usable GNU/Hurd configurations.
30158		 # All supported versions of musl provide it as well
30159		 gcc_cv_libc_provides_ssp=yes;;
30160	       *-*-darwin* | *-*-freebsd* | *-*-netbsd*)
30161		 ac_fn_cxx_check_func "$LINENO" "__stack_chk_fail" "ac_cv_func___stack_chk_fail"
30162	if test "x$ac_cv_func___stack_chk_fail" = xyes; then :
30163	  gcc_cv_libc_provides_ssp=yes
30164	else
30165	  echo "no __stack_chk_fail on this target"
30166	fi
30167	
30168	        ;;
30169	       *) gcc_cv_libc_provides_ssp=no ;;
30170	    esac
30171	  fi
30172	fi
30173	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_libc_provides_ssp" >&5
30174	$as_echo "$gcc_cv_libc_provides_ssp" >&6; }
30175	
30176	if test x$gcc_cv_libc_provides_ssp = xyes; then
30177	
30178	$as_echo "#define TARGET_LIBC_PROVIDES_SSP 1" >>confdefs.h
30179	
30180	fi
30181	
30182	# Check whether --enable-default-ssp was given.
30183	# Check whether --enable-default-ssp was given.
30184	if test "${enable_default_ssp+set}" = set; then :
30185	  enableval=$enable_default_ssp;
30186	if test x$gcc_cv_libc_provides_ssp = xyes; then
30187	  case "$target" in
30188	    ia64*-*-*) enable_default_ssp=no ;;
30189	    *) enable_default_ssp=$enableval ;;
30190	  esac
30191	else
30192	  enable_default_ssp=no
30193	fi
30194	else
30195	  enable_default_ssp=no
30196	fi
30197	
30198	if test x$enable_default_ssp = xyes ; then
30199	
30200	$as_echo "#define ENABLE_DEFAULT_SSP 1" >>confdefs.h
30201	
30202	fi
30203	
30204	
30205	# Test for <sys/sdt.h> on the target.
30206	
30207	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking sys/sdt.h in the target C library" >&5
30208	$as_echo_n "checking sys/sdt.h in the target C library... " >&6; }
30209	have_sys_sdt_h=no
30210	if test -f $target_header_dir/sys/sdt.h; then
30211	  have_sys_sdt_h=yes
30212	
30213	$as_echo "#define HAVE_SYS_SDT_H 1" >>confdefs.h
30214	
30215	fi
30216	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_sys_sdt_h" >&5
30217	$as_echo "$have_sys_sdt_h" >&6; }

--

Greetings

  Pete

Theory and practice are the same, in theory, but, in practice, they are different.


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

* Re: Configuring GCC 10.3 on PPC Mac OS X 10.4.11/Tiger for build reveals flaws in configure scripts
  2022-11-25 10:19 Configuring GCC 10.3 on PPC Mac OS X 10.4.11/Tiger for build reveals flaws in configure scripts Peter Dyballa
@ 2022-11-25 11:22 ` Jonathan Wakely
  2022-11-25 11:29   ` Jonathan Wakely
                     ` (2 more replies)
  0 siblings, 3 replies; 11+ messages in thread
From: Jonathan Wakely @ 2022-11-25 11:22 UTC (permalink / raw)
  To: Peter Dyballa; +Cc: gcc-help

On Fri, 25 Nov 2022 at 10:20, Peter Dyballa via Gcc-help
<gcc-help@gcc.gnu.org> wrote:
>
> Hello!
>
> I am just showing the faults and the code causing them, no cure, when building with MacPorts:
>
> ----------------------
> Configuring stage 1 in ./isl
>
> ..../gcc10-bootstrap/work/gcc-10.3.0/isl/configure: line 1: cd: /opt/local/libexec/gcc10-bootstrap: No such file or directory
> checking for powerpc-apple-darwin8.11.0-gcc...
>
> checking whether we are using the GNU C compiler... (cached) yes
> ..../gcc10-bootstrap/work/gcc-10.3.0/isl/configure: line 5363: test: =: unary operator expected

isl is not part of GCC, and I don't see this error in the version of
isl that gcc-10.3.0/contrib/download_prerequisites uses.

Using isl is optional anyway, you can just leave it out if you want.
Either way, this seems to be a problem with the version of isl that
MacPorts uses, not a GCC problem.

> Configuring stage 1 in ./libbacktrace
>
> checking for objcopy... no
> checking for readelf... readelf
> checking whether objcopy supports debuglink... ..../gcc10-bootstrap/work/gcc-10.3.0/libbacktrace/configure: line 13557: --add-gnu-debuglink=x: command not found

This line number doesn't match what's shown below, as it's coming from
line 13560 below (which is line 13496 in my copy of the gcc-10.30
sources, so maybe MacPorts patched it?)

> no
> checking whether tests can run... yes
>
> 13553   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether objcopy supports debuglink" >&5
> 13554   $as_echo_n "checking whether objcopy supports debuglink... " >&6; }
> 13555   if ${libbacktrace_cv_objcopy_debuglink+:} false; then :
> 13556     $as_echo_n "(cached) " >&6
> 13557   else
> 13558     if test -n "${with_target_subdir}"; then
> 13559     libbacktrace_cv_objcopy_debuglink=no
> 13560   elif ${OBJCOPY} --add-gnu-debuglink=x /bin/ls /tmp/ls$$; then
> 13561     rm -f /tmp/ls$$
> 13562     libbacktrace_cv_objcopy_debuglink=yes
> 13563   else
> 13564     libbacktrace_cv_objcopy_debuglink=no
> 13565   fi
> 13566   fi
> 13567   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libbacktrace_cv_objcopy_debuglink" >&5
> 13568   $as_echo "$libbacktrace_cv_objcopy_debuglink" >&6; }
> 13569    if test "$libbacktrace_cv_objcopy_debuglink" = yes; then
> 13570     HAVE_OBJCOPY_DEBUGLINK_TRUE=
> 13571     HAVE_OBJCOPY_DEBUGLINK_FALSE='#'
> 13572   else
> 13573     HAVE_OBJCOPY_DEBUGLINK_TRUE='#'
> 13574     HAVE_OBJCOPY_DEBUGLINK_FALSE=
> 13575   fi
> ----------------------
>
> Configuring stage 2 in ./libbacktrace
>
> checking for readelf... readelf
> checking whether objcopy supports debuglink... ..../gcc10-bootstrap/work/gcc-10.3.0/libbacktrace/configure: line 13557: --add-gnu-debuglink=x: command not found
> no
> checking whether tests can run... yes
> ==================================
>
>
> Configuring stage 2 in powerpc-apple-darwin8.11.0/libstdc++-v3
>
> checking for uchar.h... no
> no

This is harmless, but I see the problem and will fix it.

> checking for int64_t... yes

> Configuring stage 2 in ./gcc
>
> checking linker --sysroot support... no
> checking __stack_chk_fail in target C library... checking for __stack_chk_fail... no
> no __stack_chk_fail on this target
> no
> checking sys/sdt.h in the target C library... no


I'll see if I can find this one too. Also harmless though.

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

* Re: Configuring GCC 10.3 on PPC Mac OS X 10.4.11/Tiger for build reveals flaws in configure scripts
  2022-11-25 11:22 ` Jonathan Wakely
@ 2022-11-25 11:29   ` Jonathan Wakely
  2022-11-25 11:39     ` Jonathan Wakely
  2022-11-25 11:30   ` Peter Dyballa
  2022-11-25 15:56   ` Segher Boessenkool
  2 siblings, 1 reply; 11+ messages in thread
From: Jonathan Wakely @ 2022-11-25 11:29 UTC (permalink / raw)
  To: Peter Dyballa; +Cc: gcc-help

On Fri, 25 Nov 2022 at 11:22, Jonathan Wakely wrote:
>
> On Fri, 25 Nov 2022 at 10:20, Peter Dyballa via Gcc-help
> <gcc-help@gcc.gnu.org> wrote:
> > Configuring stage 2 in ./gcc
> >
> > checking linker --sysroot support... no
> > checking __stack_chk_fail in target C library... checking for __stack_chk_fail... no
> > no __stack_chk_fail on this target
> > no
> > checking sys/sdt.h in the target C library... no
>
>
> I'll see if I can find this one too. Also harmless though.

gcc/configure.ac has:

# Test for stack protector support in target C library.
AC_CACHE_CHECK(__stack_chk_fail in target C library,
...
       *-*-darwin* | *-*-freebsd* | *-*-netbsd*)
     AC_CHECK_FUNC(__stack_chk_fail,[gcc_cv_libc_provides_ssp=yes],
           [echo "no __stack_chk_fail on this target"])
        ;;

That AC_CHECK_FUNC comes after the earlier message which hasn't
printed its result yet, so the output of the two gets muddled. Then
the echo makes it even worse, by adding a third message inside the
other two.

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

* Re: Configuring GCC 10.3 on PPC Mac OS X 10.4.11/Tiger for build reveals flaws in configure scripts
  2022-11-25 11:22 ` Jonathan Wakely
  2022-11-25 11:29   ` Jonathan Wakely
@ 2022-11-25 11:30   ` Peter Dyballa
  2022-11-25 15:56   ` Segher Boessenkool
  2 siblings, 0 replies; 11+ messages in thread
From: Peter Dyballa @ 2022-11-25 11:30 UTC (permalink / raw)
  To: Jonathan Wakely; +Cc: gcc-help


> Am 25.11.2022 um 12:22 schrieb Jonathan Wakely <jwakely.gcc@gmail.com>:
> 
> This line number doesn't match what's shown below, as it's coming from
> line 13560 below (which is line 13496 in my copy of the gcc-10.30
> sources, so maybe MacPorts patched it?)

Yes:

	patching file Makefile.def
	patching file Makefile.in
	patching file Makefile.tpl
	patching file configure
	patching file configure.ac
	patching file gcc/collect2.c
	patching file gcc/config.in
	patching file gcc/config/darwin.h
	patching file gcc/configure
	patching file gcc/configure.ac
	patching file gcc/exec-tool.in
	patching file gcc/gcc.c
	patching file gcc/config/darwin.h
	patching file gcc/gcc.c
	patching file gcc/config.gcc
	patching file gcc/config/darwin-driver.c
	patching file gcc/config/darwin.h
	patching file gcc/config/darwin.opt
	patching file configure
	patching file configure.ac
	patching file fixincludes/config.h.in
	patching file fixincludes/configure
	patching file gcc/aclocal.m4
	patching file gcc/config/darwin.h
	patching file gcc/configure
	patching file gcc/configure.ac
	patching file libatomic/Makefile.am
	patching file libatomic/Makefile.in
	patching file libatomic/configure
===>	patching file libbacktrace/configure	<===
	patching file libcc1/Makefile.am
	patching file libcc1/Makefile.in
	patching file libcc1/configure
	patching file libffi/Makefile.am
	patching file libffi/Makefile.in
	patching file libffi/configure
	patching file libgcc/config.host
	patching file libgcc/config/t-darwin-rpath
	patching file libgcc/config/t-slibgcc-darwin
	patching file libgfortran/Makefile.am
	patching file libgfortran/Makefile.in
	patching file libgfortran/configure
	patching file libgfortran/configure.ac
	patching file libgomp/Makefile.am
	patching file libgomp/Makefile.in
	patching file libgomp/configure
	patching file libhsail-rt/configure
	patching file libitm/Makefile.am
	patching file libitm/Makefile.in
	patching file libitm/configure
	patching file libobjc/configure
	patching file libobjc/configure.ac
	patching file liboffloadmic/configure
	patching file liboffloadmic/plugin/Makefile.in
	patching file liboffloadmic/plugin/aclocal.m4
	patching file liboffloadmic/plugin/configure
	patching file libphobos/configure
	patching file libphobos/libdruntime/Makefile.am
	patching file libphobos/libdruntime/Makefile.in
	patching file libphobos/src/Makefile.am
	patching file libphobos/src/Makefile.in
	patching file libquadmath/Makefile.am
	patching file libquadmath/Makefile.in
	patching file libquadmath/configure
	patching file libquadmath/configure.ac
	patching file libsanitizer/asan/Makefile.am
	patching file libsanitizer/asan/Makefile.in
	patching file libsanitizer/configure
	patching file libsanitizer/lsan/Makefile.am
	patching file libsanitizer/lsan/Makefile.in
	patching file libsanitizer/tsan/Makefile.am
	patching file libsanitizer/tsan/Makefile.in
	patching file libsanitizer/ubsan/Makefile.am
	patching file libsanitizer/ubsan/Makefile.in
	patching file libssp/Makefile.am
	patching file libssp/Makefile.in
	patching file libssp/configure
	patching file libstdc++-v3/configure
	patching file libstdc++-v3/src/Makefile.am
	patching file libstdc++-v3/src/Makefile.in
	patching file libtool.m4
	patching file libvtv/configure
	patching file zlib/configure
	patching file gcc/ada/gcc-interface/Makefile.in
	patching file configure
	patching file configure.ac
	patching file libiberty/simple-object-mach-o.c
	patching file gcc/config/darwin-driver.c
	patching file gcc/config/darwin.c
	patching file gcc/config/darwin.h
	patching file gcc/config/darwin.opt
	patching file gcc/config/i386/darwin.h
	patching file gcc/config/i386/darwin32-biarch.h
	patching file gcc/config/i386/darwin64-biarch.h
	patching file gcc/testsuite/gcc.dg/torture/fp-int-convert-timode-3.c
	patching file gcc/testsuite/gcc.dg/torture/fp-int-convert-timode-4.c
	patching file libgcc/config.host
	patching file libgcc/config/i386/darwin-lib.h
	patching file libgcc/config/i386/libgcc-darwin.10.4.ver
	patching file libgcc/config/i386/libgcc-darwin.10.5.ver
	patching file libgcc/config/i386/libgcc-darwin.ver
	patching file libgcc/config/i386/t-darwin
	patching file libgcc/config/libgcc-libsystem.ver
	patching file libgcc/config/rs6000/libgcc-darwin.10.4.ver
	patching file libgcc/config/rs6000/libgcc-darwin.10.5.ver
	patching file libgcc/config/t-darwin
	patching file libgcc/config/t-darwin-noeh
	patching file libgcc/config/t-slibgcc-darwin
	patching file libgcc/emutls.c
	patching file gcc/config/darwin.c
	patching file gcc/config/darwin.h
	patching file gcc/config/darwin.c
	patching file gcc/config/darwin-protos.h
	patching file gcc/config/darwin.c
	patching file gcc/config/darwin.h
	patching file gcc/doc/tm.texi
	patching file gcc/doc/tm.texi.in
	patching file gcc/dwarf2out.c
	patching file gcc/target.def
	patching file gcc/configure
	patching file gcc/configure.ac
	patching file gcc/Makefile.in
	patching file gcc/c-family/c.opt
	patching file gcc/config.in
	patching file gcc/configure
	patching file gcc/configure.ac
	patching file gcc/cp/g++spec.c
	patching file gcc/cppdefault.c
	patching file gcc/cppdefault.h
	patching file gcc/doc/invoke.texi
	patching file gcc/incpath.c
	patching file libgcc/config.host
	patching file libgcc/config/t-darwin
	patching file libgcc/config/t-darwin-min-1
	patching file libgcc/config/t-darwin-min-4
	patching file libgcc/config/t-darwin-min-5
	patching file libgcc/config/t-darwin-min-8
	patching file libgcc/config/t-darwin-rpath
	patching file gcc/config/aarch64/aarch64.md
	patching file gcc/config/aarch64/predicates.md
	patching file gcc/config/aarch64/aarch64.md
	patching file gcc/testsuite/gcc.target/aarch64/adds3.c
	patching file gcc/testsuite/gcc.target/aarch64/cmp.c
	patching file gcc/testsuite/gcc.target/aarch64/extend-syntax.c
	patching file gcc/testsuite/gcc.target/aarch64/subs3.c
	patching file gcc/testsuite/gcc.target/aarch64/subsp.c
	patching file gcc/fortran/trans-stmt.c
	patching file gcc/testsuite/gfortran.dg/coarray_fail_st.f90
	patching file gcc/fortran/trans-types.c
	patching file gcc/fortran/resolve.c
	patching file gcc/fortran/trans-types.c
	patching file config.guess
	patching file config.sub
	patching file gcc/config/aarch64/aarch64.md
	patching file gcc/config/darwin.h
	patching file gcc/config/aarch64/falkor-tag-collision-avoidance.c
	patching file gcc/config/aarch64/aarch64.c
	patching file gcc/c/c-lang.c
	patching file gcc/config/aarch64/aarch64.c
	patching file gcc/config/i386/darwin.h
	patching file gcc/fortran/f95-lang.c
	patching file gcc/fortran/trans-expr.c
	patching file gcc/fortran/trans.c
	patching file configure
	patching file configure.ac
	patching file gcc/config/darwin-driver.c
	patching file gcc/config/darwin.c
	patching file gcc/config/darwin.h
	patching file gcc/config.gcc
	patching file gcc/config/aarch64/aarch64-builtins.c
	patching file gcc/config/aarch64/aarch64-c.c
	patching file gcc/config/aarch64/aarch64-protos.h
	patching file gcc/config/aarch64/aarch64.c
	patching file gcc/config/aarch64/aarch64.h
	patching file gcc/config/aarch64/aarch64.md
	patching file gcc/config/aarch64/aarch64.opt
	patching file gcc/config/aarch64/darwin.h
	patching file gcc/config/aarch64/t-aarch64-darwin
	patching file gcc/config/aarch64/aarch64.c
	patching file gcc/config/aarch64/darwin.h
	patching file libgcc/config.host
	patching file libgcc/config/aarch64/lse.S
	patching file libgcc/config/aarch64/t-darwin
	patching file gcc/config/aarch64/darwin.h
	patching file libgcc/config.host
	patching file gcc/config.host
	patching file gcc/config/aarch64/host-aarch64-darwin.c
	patching file gcc/config/aarch64/x-darwin
	patching file gcc/ada/gcc-interface/Make-lang.in
	patching file gcc/ada/sigtramp-ios.c
	patching file libitm/config/aarch64/sjlj.S
	patching file libitm/configure.tgt
	patching file libgfortran/config/fpu-aarch64.h
	patching file libgfortran/configure.host
	patching file gcc/config/aarch64/aarch64.c
	patching file gcc/config/aarch64/aarch64.c
	patching file gcc/config/aarch64/aarch64.h
	patching file gcc/config/aarch64/aarch64.c
	patching file gcc/config/aarch64/aarch64.c
	patching file gcc/calls.c
	patching file gcc/config/aarch64/aarch64.c
	patching file gcc/function.c
	patching file gcc/function.h
	patching file gcc/config/aarch64/aarch64.c
	patching file gcc/config/aarch64/aarch64.c
	patching file gcc/config/aarch64/aarch64.h
	patching file gcc/config/aarch64/aarch64.c
	patching file gcc/calls.c
	patching file gcc/calls.h
	patching file gcc/function.c
	patching file gcc/function.h
	patching file gcc/config/aarch64/aarch64.c
	patching file gcc/config/aarch64/aarch64.md
	patching file gcc/config/aarch64/aarch64.c
	patching file gcc/config/aarch64/aarch64.c
	patching file gcc/config/darwin.h
	patching file gcc/testsuite/g++.target/aarch64/sve/aarch64-sve.exp
	patching file gcc/testsuite/g++.target/aarch64/sve/acle/aarch64-sve-acle-asm.exp
	patching file gcc/testsuite/g++.target/aarch64/sve/acle/aarch64-sve-acle.exp
	patching file gcc/testsuite/g++.target/aarch64/sve2/acle/aarch64-sve2-acle-asm.exp
	patching file gcc/testsuite/gcc.target/aarch64/sve/aarch64-sve.exp
	patching file gcc/testsuite/gcc.target/aarch64/sve/acle/aarch64-sve-acle-asm.exp
	patching file gcc/testsuite/gcc.target/aarch64/sve/acle/aarch64-sve-acle.exp
	patching file gcc/testsuite/gcc.target/aarch64/sve/pcs/aarch64-sve-pcs.exp
	patching file gcc/testsuite/gcc.target/aarch64/sve2/aarch64-sve2.exp
	patching file gcc/testsuite/gcc.target/aarch64/sve2/acle/aarch64-sve2-acle-asm.exp
	patching file gcc/testsuite/gcc.target/aarch64/sve2/acle/aarch64-sve2-acle.exp
	patching file gcc/testsuite/g++.dg/pch/pch.exp
	patching file gcc/testsuite/gcc.dg/pch/pch.exp
	patching file gcc/testsuite/objc.dg/pch/pch.exp
	patching file gcc/testsuite/g++.dg/abi/aarch64_guard1.C
	patching file gcc/testsuite/g++.dg/abi/arm_va_list.C
	patching file gcc/testsuite/g++.dg/torture/darwin-cfstring-3.C
	patching file gcc/testsuite/gcc.dg/torture/darwin-cfstring-3.c
	patching file gcc/testsuite/obj-c++.dg/torture/strings/const-cfstring-4.mm
	patching file gcc/testsuite/objc.dg/torture/strings/const-cfstring-4.m
	patching file gcc/testsuite/gcc.dg/darwin-segaddr.c
	patching file gcc/testsuite/gcc.dg/pubtypes-2.c
	patching file gcc/testsuite/gcc.dg/pubtypes-3.c
	patching file gcc/testsuite/gcc.dg/pubtypes-4.c
	patching file gcc/testsuite/g++.dg/abi/aarch64_guard1.C
	patching file gcc/testsuite/gcc.target/aarch64/aapcs64/aapcs64.exp
	patching file gcc/testsuite/g++.dg/ext/arm-bf16/bf16-mangle-aarch64-1.C
	patching file gcc/testsuite/objc.dg/torture/strings/const-str-10.m
	patching file gcc/testsuite/objc.dg/torture/strings/const-str-11.m
	patching file gcc/testsuite/objc.dg/torture/strings/const-str-9.m
	patching file gcc/testsuite/obj-c++.dg/gnu-api-2-class-meta.mm
	patching file gcc/testsuite/obj-c++.dg/gnu-api-2-class.mm
	patching file gcc/testsuite/objc.dg/gnu-api-2-class-meta.m
	patching file gcc/testsuite/objc.dg/gnu-api-2-class.m
	patching file gcc/testsuite/obj-c++.dg/torture/strings/const-str-10.mm
	patching file gcc/testsuite/obj-c++.dg/torture/strings/const-str-11.mm
	patching file gcc/testsuite/obj-c++.dg/torture/strings/const-str-9.mm
	patching file gcc/testsuite/g++.target/aarch64/no_unique_address_1.C
	patching file gcc/testsuite/g++.target/aarch64/no_unique_address_2.C
	patching file gcc/testsuite/gcc.target/aarch64/advsimd-intrinsics/bfcvt-compile.c
	patching file gcc/testsuite/gcc.target/aarch64/advsimd-intrinsics/bfcvt-nosimd.c
	patching file gcc/testsuite/gcc.target/aarch64/advsimd-intrinsics/bfcvtnq2-untied.c
	patching file gcc/testsuite/gcc.target/aarch64/advsimd-intrinsics/bfdot-1.c
	patching file gcc/testsuite/gcc.target/aarch64/advsimd-intrinsics/bfdot-2.c
	patching file gcc/testsuite/gcc.target/aarch64/advsimd-intrinsics/bfmlalbt-compile.c
	patching file gcc/testsuite/gcc.target/aarch64/advsimd-intrinsics/bfmmla-compile.c
	patching file gcc/testsuite/gcc.target/aarch64/advsimd-intrinsics/vdot-3-1.c
	patching file gcc/testsuite/gcc.target/aarch64/advsimd-intrinsics/vdot-3-2.c
	patching file gcc/testsuite/gcc.target/aarch64/bfloat16_scalar_1.c
	patching file gcc/testsuite/gcc.target/aarch64/bfloat16_scalar_2.c
	patching file gcc/testsuite/gcc.target/aarch64/bfloat16_scalar_3.c
	patching file gcc/testsuite/gcc.target/aarch64/bfloat16_simd_1.c
	patching file gcc/testsuite/gcc.target/aarch64/bfloat16_simd_2.c
	patching file gcc/testsuite/gcc.target/aarch64/bfloat16_simd_3.c
	patching file gcc/testsuite/gcc.target/aarch64/movk_2.c
	patching file gcc/testsuite/gcc.target/aarch64/pr92424-1.c
	patching file gcc/testsuite/gcc.target/aarch64/pr94697.c
	patching file gcc/testsuite/gcc.target/aarch64/torture/simd-abi-9.c
	patching file gcc/testsuite/gcc.target/aarch64/vect_mixed_sizes_14.c
	patching file gcc/config/aarch64/aarch64.opt
	patching file gcc/config/aarch64/aarch64.c
	patching file gcc/config/aarch64/aarch64-protos.h
	patching file gcc/config/aarch64/aarch64.c
	patching file gcc/config/aarch64/aarch64.md
	patching file gcc/config/aarch64/constraints.md
	patching file gcc/config/aarch64/predicates.md
	--->  Applying patch-iains-ppc.diff


--
Greetings

  Pete

The day Microsoft makes something that doesn't suck is the day they start selling vacuum cleaners.
				– Ernest Jan Plugge


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

* Re: Configuring GCC 10.3 on PPC Mac OS X 10.4.11/Tiger for build reveals flaws in configure scripts
  2022-11-25 11:29   ` Jonathan Wakely
@ 2022-11-25 11:39     ` Jonathan Wakely
  0 siblings, 0 replies; 11+ messages in thread
From: Jonathan Wakely @ 2022-11-25 11:39 UTC (permalink / raw)
  To: Peter Dyballa; +Cc: gcc-help

On Fri, 25 Nov 2022 at 11:29, Jonathan Wakely wrote:
>
> On Fri, 25 Nov 2022 at 11:22, Jonathan Wakely wrote:
> >
> > On Fri, 25 Nov 2022 at 10:20, Peter Dyballa via Gcc-help
> > <gcc-help@gcc.gnu.org> wrote:
> > > Configuring stage 2 in ./gcc
> > >
> > > checking linker --sysroot support... no
> > > checking __stack_chk_fail in target C library... checking for __stack_chk_fail... no
> > > no __stack_chk_fail on this target
> > > no
> > > checking sys/sdt.h in the target C library... no
> >
> >
> > I'll see if I can find this one too. Also harmless though.
>
> gcc/configure.ac has:
>
> # Test for stack protector support in target C library.
> AC_CACHE_CHECK(__stack_chk_fail in target C library,
> ...
>        *-*-darwin* | *-*-freebsd* | *-*-netbsd*)
>      AC_CHECK_FUNC(__stack_chk_fail,[gcc_cv_libc_provides_ssp=yes],
>            [echo "no __stack_chk_fail on this target"])
>         ;;
>
> That AC_CHECK_FUNC comes after the earlier message which hasn't
> printed its result yet, so the output of the two gets muddled. Then
> the echo makes it even worse, by adding a third message inside the
> other two.


I've opened https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107869 for this.

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

* Re: Configuring GCC 10.3 on PPC Mac OS X 10.4.11/Tiger for build reveals flaws in configure scripts
  2022-11-25 11:22 ` Jonathan Wakely
  2022-11-25 11:29   ` Jonathan Wakely
  2022-11-25 11:30   ` Peter Dyballa
@ 2022-11-25 15:56   ` Segher Boessenkool
  2022-11-25 16:50     ` Peter Dyballa
                       ` (2 more replies)
  2 siblings, 3 replies; 11+ messages in thread
From: Segher Boessenkool @ 2022-11-25 15:56 UTC (permalink / raw)
  To: Jonathan Wakely; +Cc: Peter Dyballa, gcc-help

On Fri, Nov 25, 2022 at 11:22:15AM +0000, Jonathan Wakely via Gcc-help wrote:
> On Fri, 25 Nov 2022 at 10:20, Peter Dyballa via Gcc-help
> <gcc-help@gcc.gnu.org> wrote:
> > ..../gcc10-bootstrap/work/gcc-10.3.0/isl/configure: line 1: cd: /opt/local/libexec/gcc10-bootstrap: No such file or directory
> > checking for powerpc-apple-darwin8.11.0-gcc...
> >
> > checking whether we are using the GNU C compiler... (cached) yes
> > ..../gcc10-bootstrap/work/gcc-10.3.0/isl/configure: line 5363: test: =: unary operator expected
> 
> isl is not part of GCC, and I don't see this error in the version of
> isl that gcc-10.3.0/contrib/download_prerequisites uses.
> 
> Using isl is optional anyway, you can just leave it out if you want.
> Either way, this seems to be a problem with the version of isl that
> MacPorts uses, not a GCC problem.

Yup.  Also, GCC 10.4 was released over a month ago, please use that?
Any problem in previous minor releases might already be fixed (I doubt
it in this case, but :-) )


Segher

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

* Re: Configuring GCC 10.3 on PPC Mac OS X 10.4.11/Tiger for build reveals flaws in configure scripts
  2022-11-25 15:56   ` Segher Boessenkool
@ 2022-11-25 16:50     ` Peter Dyballa
  2022-11-25 19:43       ` Segher Boessenkool
  2022-11-28 22:05     ` Peter Dyballa
  2022-11-30 23:09     ` Peter Dyballa
  2 siblings, 1 reply; 11+ messages in thread
From: Peter Dyballa @ 2022-11-25 16:50 UTC (permalink / raw)
  To: Segher Boessenkool; +Cc: Jonathan Wakely, gcc-help


> Am 25.11.2022 um 16:56 schrieb Segher Boessenkool <segher@kernel.crashing.org>:
> 
> Also, GCC 10.4 was released over a month ago, please use that?
> Any problem in previous minor releases might already be fixed

I can try. I was asked to try to build the MacPorts package, or "port", gcc10-bootstrap to help solve another problem on PPC Tiger/Mac OS X 10.4.11 I've seen that GCC 10.4 was out and I now know that MacPorts supports this version too:

	gcc10                          @10.4.0         lang/gcc10
	libgcc10                       @10.4.0         lang/gcc10
	gcc10-libcxx                   @10.4.0         lang/gcc10
	gcc10-bootstrap                @10.3.0         lang/gcc10-bootstrap

They have dependencies:

	Full Name: gcc10 @10.4.0_4+stdlib_flag
	Extract Dependencies: xz
	Build Dependencies:   texinfo
	Library Dependencies: cctools, gmp, isl, ld64, libiconv, libmpc, mpfr, zlib, zstd
	Runtime Dependencies: gcc_select, libgcc10, gcc10-libcxx
	--
	Full Name: libgcc10 @10.4.0_4+stdlib_flag
	Extract Dependencies: xz
	Build Dependencies:   texinfo, cctools, gmp, isl, ld64, libiconv, libmpc, mpfr, zlib, zstd
	Library Dependencies: 
	Runtime Dependencies: libgcc11
	--
	Full Name: gcc10-libcxx @10.4.0_5+clang14
	Extract Dependencies: 
	Build Dependencies:   clang-14
	Library Dependencies: 
	Runtime Dependencies: 

The only port that I might be able to build is "libgcc10" which has a dependency of "libgcc11", and this a dependency to "libgcc":

	Full Name: gcc11 @11.3.0_5+stdlib_flag
	Extract Dependencies: xz
	Build Dependencies:   texinfo
	Library Dependencies: cctools, gmp, isl, ld64, libiconv, libmpc, mpfr, zlib, zstd
	Runtime Dependencies: gcc_select, libgcc11, gcc11-libcxx
	--
	Full Name: libgcc11 @11.3.0_5+stdlib_flag
	Extract Dependencies: xz
	Build Dependencies:   texinfo, cctools, gmp, isl, ld64, libiconv, libmpc, mpfr, zlib, zstd
	Library Dependencies: 
	Runtime Dependencies: libgcc
	--
	Full Name: gcc11-libcxx @11.3.0_6+clang14
	Extract Dependencies: 
	Build Dependencies:   clang-14
	Library Dependencies: 
	Runtime Dependencies: 
	--
	Full Name: libgcc @6.0_0
	Library Dependencies: libgcc12

I do not understand this scheme, honestly! Very old software, that depends on software that will be created in some future? But – "libgcc12" is very easy to build:

	Full Name: libgcc12 @12.2.0_2+stdlib_flag
	Extract Dependencies: xz
	Build Dependencies:   texinfo, cctools, gmp, isl, ld64, libmpc, mpfr, zstd
	Library Dependencies: zlib, libiconv
	Runtime Dependencies: 

Next month, if my internal disk will find enough empty space (remember: my PowerBook G4 is almost 20 years old, and then a 100 GB disk was no usual gadget, not even in a Mac). (It might be possible to create "private" versions on an external disk.) Before I have to find the cause why a particular port, boost, uses '-Wl,-rpath ...' which cannot work on Tiger. (It's OK with later OS versions.) It works, with other ports, when '-Wl,' is not there, because then it's a no-op or gets neglected.

Manual builds will take longer. Because they might needed patches *I* would have to provide – you've the seen the list I gave Jonathan?

--
Greetings

  Pete

I wouldn't recommend sex, drugs or insanity for everyone, but they've always worked for me.
				– Hunter S. Thompson


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

* Re: Configuring GCC 10.3 on PPC Mac OS X 10.4.11/Tiger for build reveals flaws in configure scripts
  2022-11-25 16:50     ` Peter Dyballa
@ 2022-11-25 19:43       ` Segher Boessenkool
  0 siblings, 0 replies; 11+ messages in thread
From: Segher Boessenkool @ 2022-11-25 19:43 UTC (permalink / raw)
  To: Peter Dyballa; +Cc: Jonathan Wakely, gcc-help

On Fri, Nov 25, 2022 at 05:50:56PM +0100, Peter Dyballa wrote:
> > Am 25.11.2022 um 16:56 schrieb Segher Boessenkool <segher@kernel.crashing.org>:
> > Also, GCC 10.4 was released over a month ago, please use that?
> > Any problem in previous minor releases might already be fixed
> 
> I can try. I was asked to try to build the MacPorts package, or "port", gcc10-bootstrap to help solve another problem on PPC Tiger/Mac OS X 10.4.11 I've seen that GCC 10.4 was out and I now know that MacPorts supports this version too:

Ah.  I don't know what modifications they make, but our compilers should
work without any of that.  You could try with what we distribute, and
get help from us ;-)

The problems you encountered with the modified source code you tried
might happen with unmodified code just the same, but it is hard to know
for sure unless you try, and support is much harder than needed with
unknown modified code :-(


Segher

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

* Re: Configuring GCC 10.3 on PPC Mac OS X 10.4.11/Tiger for build reveals flaws in configure scripts
  2022-11-25 15:56   ` Segher Boessenkool
  2022-11-25 16:50     ` Peter Dyballa
@ 2022-11-28 22:05     ` Peter Dyballa
  2022-11-30 23:09     ` Peter Dyballa
  2 siblings, 0 replies; 11+ messages in thread
From: Peter Dyballa @ 2022-11-28 22:05 UTC (permalink / raw)
  To: Segher Boessenkool; +Cc: Jonathan Wakely, gcc-help


> Am 25.11.2022 um 16:56 schrieb Segher Boessenkool <segher@kernel.crashing.org>:
> 
> Also, GCC 10.4 was released over a month ago, please use that?

MacPorts tells me:

	Error: gcc10 10.4.0 is not supported on Darwin 8 powerpc
	Error: Failed to fetch libgcc10: incompatible macOS version
	
	Error: gcc11 11.3.0 is not supported on Darwin 8
	Error: Failed to fetch libgcc11: incompatible macOS version

So I have to try to build manually…

--
Greetings

  Pete

Atheism is a non prophet organisation.


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

* Re: Configuring GCC 10.3 on PPC Mac OS X 10.4.11/Tiger for build reveals flaws in configure scripts
  2022-11-25 15:56   ` Segher Boessenkool
  2022-11-25 16:50     ` Peter Dyballa
  2022-11-28 22:05     ` Peter Dyballa
@ 2022-11-30 23:09     ` Peter Dyballa
  2022-12-01  8:22       ` Jonathan Wakely
  2 siblings, 1 reply; 11+ messages in thread
From: Peter Dyballa @ 2022-11-30 23:09 UTC (permalink / raw)
  To: Segher Boessenkool; +Cc: Jonathan Wakely, gcc-help

Hello!

Here is my evaluation from building GCC 10.4 on PPC Mac OS X 10.4.11, Tiger, with modern tools with 40 hours. I am using in the first, leftmost column, line numbers from compile log in GNU Emacs which quantify when one of the many steps is taken. It might help classify and explain some differences between building GCC 10.3 and GCC 10.4 I encountered.

   10:Configuring stage 1 in ./intl
  134:Configuring stage 1 in ./gcc
  620:Configuring stage 1 in ./libiberty
        configure: target_header_dir =                          <=== no title here
 1367:Configuring in build-powerpc-apple-darwin8.11.0/libiberty
        configure: target_header_dir =                          <=== no title here
 2110:Configuring in build-powerpc-apple-darwin8.11.0/fixincludes
 2232:Configuring in build-powerpc-apple-darwin8.11.0/libcpp
 2397:Configuring stage 1 in ./libbacktrace
        checking for readelf... readelf
        checking whether objcopy supports debuglink... ..../gcc-10.4.0/libbacktrace/configure: line 13493: --add-gnu-debuglink=x: command not found
        no
        checking whether tests can run... yes
 2598:Configuring stage 1 in ./libcpp
 2766:Configuring stage 1 in ./libdecnumber
        checking target system type... powerpc-apple-darwin8.11.0
        checking for decimal floating point... configure: WARNING: decimal float is not supported for this target, ignored
 ==>    dpd
        checking whether byte ordering is bigendian... yes
 4128:Configuring stage 1 in powerpc-apple-darwin8.11.0/libgcc
 5263:Configuring stage 1 in powerpc-apple-darwin8.11.0/libgomp
 5588:Configuring stage 1 in powerpc-apple-darwin8.11.0/libstdc++-v3
        configure: Debug build flags set to -gdwarf-4 -g3 -O0 -D_GLIBCXX_ASSERTIONS
...
        checking uchar.h usability... no
        checking uchar.h presence... no
        checking for uchar.h... no2
==>     no
        checking for int64_t... yes
        checking for int64_t as long... checking for int64_t as long long... yes
...
        checking for local stylesheet directory... yes
        configure:                                              <=== no comment here
        checking for docbook stylesheets for documentation creation... yes
...
        Running configure in multilib subdir ppc64
...
        configure: Debug build flags set to -gdwarf-4 -g3 -O0 -D_GLIBCXX_ASSERTIONS  /* for orientation */
...
        checking uchar.h usability... no
        checking uchar.h presence... no
        checking for uchar.h... no
==>     no
        checking for int64_t... yes
        checking for int64_t as long... checking for int64_t as long long... yes
...
        checking for local stylesheet directory... yes
        configure:                                              <=== no comment here
        checking for docbook stylesheets for documentation creation... yes
 8500:Configuring stage 2 in ./intl
 8626:Configuring stage 2 in ./gcc
        checking __stack_chk_fail in target C library... checking for __stack_chk_fail... no
        no __stack_chk_fail on this target
==>     no
        checking sys/sdt.h in the target C library... no
...
        checking for otool64... otool64
        checking for -single_module linker flag... warning: no debug map in executable (-arch ppc)
        yes
        checking for -exported_symbols_list linker flag... yes
        checking for -force_load linker flag... warning: no debug map in executable (-arch ppc)
        no
        checking for dlfcn.h... yes
 9116:Configuring stage 2 in ./libiberty
        checking whether to install libiberty headers and static library... no
        configure: target_header_dir = 
        checking for powerpc-apple-darwin8.11.0-gcc...  ..../feddich/./prev-gcc/xgcc -B..../feddich/./prev-gcc/ -B/usr/local/powerpc-apple-darwin8.11.0/bin/ -B/usr/local/powerpc-apple-darwin8.11.0/bin/ -B/usr/local/powerpc-apple-darwin8.11.0/lib/ -isystem /usr/local/powerpc-apple-darwin8.11.0/include -isystem /usr/local/powerpc-apple-darwin8.11.0/sys-include   -fno-checking
 9888:Configuring stage 2 in ./libbacktrace
        checking whether objcopy supports debuglink... ..../gcc-10.4.0/libbacktrace/configure: line 13493: --add-gnu-debuglink=x: command not found
        no
        checking whether tests can run... yes
10096:Configuring stage 2 in ./libcpp
10266:Configuring stage 2 in ./libdecnumber
        checking target system type... powerpc-apple-darwin8.11.0
        checking for decimal floating point... configure: WARNING: decimal float is not supported for this target, ignored
==>     dpd
        checking whether byte ordering is bigendian... yes
34397:Configuring stage 2 in powerpc-apple-darwin8.11.0/libgcc
35532:Configuring stage 2 in powerpc-apple-darwin8.11.0/libgomp
35857:Configuring stage 2 in powerpc-apple-darwin8.11.0/libstdc++-v3
        configure: Debug build flags set to -gdwarf-4 -g3 -O0 -D_GLIBCXX_ASSERTIONS
...
        checking uchar.h usability... no
        checking uchar.h presence... no
        checking for uchar.h... no
==>     no
        checking for int64_t... yes
        checking for int64_t as long... checking for int64_t as long long... yes
...
        checking for local stylesheet directory... yes
        configure:                                              <=== no comment here
        checking for docbook stylesheets for documentation creation... yes
...
Running configure in multilib subdir ppc64
...
        configure: Debug build flags set to -gdwarf-4 -g3 -O0 -D_GLIBCXX_ASSERTIONS
...
        checking uchar.h usability... no
        checking uchar.h presence... no
        checking for uchar.h... no
==>     no
        checking for int64_t... yes
        checking for int64_t as long... checking for int64_t as long long... yes
...
        checking for shared library run path origin... done
        checking for iconv... no, consider installing GNU libiconv      <=== libiconv and /opt/local/bin/iconv are installed, other tests (stage3 stdc++) find it
        looking for a compliant stdint.h in stdint.h, checking for uintmax_t... yes
...
        checking for local stylesheet directory... yes
        configure:                                              <=== no comment here
        checking for docbook stylesheets for documentation creation... yes
38769:Configuring stage 3 in ./intl
38895:Configuring stage 3 in ./gcc
        checking __stack_chk_fail in target C library... checking for __stack_chk_fail... no
        no __stack_chk_fail on this target
==>     no
        checking sys/sdt.h in the target C library... no
39383:Configuring stage 3 in ./libiberty
40155:Configuring stage 3 in ./libbacktrace
        checking output filetype... 
        configure: WARNING: could not determine output file type        <=== happens three times during build
        looking for a compliant stdint.h in stdint.h, checking for uintmax_t... yes
...
        checking for readelf... readelf
        checking whether objcopy supports debuglink... ..../gcc-10.4.0/libbacktrace/configure: line 13493: --add-gnu-debuglink=x: command not found
        no
        checking whether tests can run... yes
40361:Configuring stage 3 in ./libcpp
40531:Configuring stage 3 in ./libdecnumber
        checking target system type... powerpc-apple-darwin8.11.0
        checking for decimal floating point... configure: WARNING: decimal float is not supported for this target, ignored
==>     dpd
        checking whether byte ordering is bigendian... yes
64662:Configuring stage 3 in powerpc-apple-darwin8.11.0/libgcc
65797:Configuring stage 3 in powerpc-apple-darwin8.11.0/libgomp
66122:Configuring stage 3 in powerpc-apple-darwin8.11.0/libstdc++-v3
        checking uchar.h usability... no
        checking uchar.h presence... no
        checking for uchar.h... no
==>     no
        checking for int64_t... yes
        checking for int64_t as long... checking for int64_t as long long... yes
...
        checking for local stylesheet directory... yes
        configure:                                              <=== no comment here
        checking for docbook stylesheets for documentation creation... yes
...
Running configure in multilib subdir ppc64
...
        configure: Debug build flags set to -gdwarf-4 -g3 -O0 -D_GLIBCXX_ASSERTIONS
...
        checking uchar.h usability... no
        checking uchar.h presence... no
        checking for uchar.h... no
==>     no
        checking for int64_t... yes
        checking for int64_t as long... checking for int64_t as long long... yes
...
        checking for local stylesheet directory... yes
        configure:                                              <=== no comment here
        checking for docbook stylesheets for documentation creation... yes
69046:Configuring in ./fixincludes
69175:Configuring in ./libcc1
checking for gethostbyname... yes
                                                                <=== empty line
checking for exported symbols... yes
69307:Configuring in powerpc-apple-darwin8.11.0/libssp
69784:Configuring in powerpc-apple-darwin8.11.0/libquadmath
Running configure in multilib subdir ppc64
        checking for egrep... /opt/local/bin/ggrep -E
        checking for ANSI C header files... rm: conftest.dSYM: is a directory
==>     rm: conftest.dSYM: is a directory                       <=== complains twice
        yes
        checking for sys/types.h... yes
70158:Configuring in powerpc-apple-darwin8.11.0/libobjc
70851:Configuring in powerpc-apple-darwin8.11.0/libitm
71440:Configuring in powerpc-apple-darwin8.11.0/libatomic


GCC 10.3 was built with old system's tools and utilities, while for GCC 10.4 I could use modernised versions. This might explain a few differences. Particularly the following:

  134:Configuring stage 1 in ./gcc
	  524:checking assembler for -mmacosx-version-min option... no
	  537:checking assembler for compressed debug sections... 0
	  549:checking linker for compressed debug sections... 0

Presumingly the old as is better integrated in Mac OS X and configure finds in GCC 10.3:

	checking assembler for -mmacosx-version-min option... yes
	checking assembler for compressed debug sections... 2
	checking linker for compressed debug sections... 0

Is this difference intended?


Three times configure finds:

 2509:configure: WARNING: could not determine output file type
10005:configure: WARNING: could not determine output file type
40270:configure: WARNING: could not determine output file type

while it finds 45 times:

	checking for C compiler default output file name... a.out

Is this difference intended?


Another (intended?) difference is this:

10.3:
	checking whether a program can dlopen itself... yes
	checking whether a statically linked program can dlopen itself... yes
	checking whether a program can dlopen itself... cross
	checking whether a program can dlopen itself... yes
	checking whether a statically linked program can dlopen itself... yes
	checking whether a program can dlopen itself... cross
	checking whether a program can dlopen itself... yes
	checking whether a statically linked program can dlopen itself... yes
	checking whether a program can dlopen itself... cross
	
10.4:
	 5673:checking whether a program can dlopen itself... no
	 6244:checking whether a program can dlopen itself... cross
	35942:checking whether a program can dlopen itself... no
	36513:checking whether a program can dlopen itself... cross
	66207:checking whether a program can dlopen itself... no
	66778:checking whether a program can dlopen itself... cross


A bit disturbing is this, finding yes and no for the same item, __int128 (because libquadmath supports this data type?):

	 5698:checking for ISO/IEC TR 24733 ... no
	 5699:checking for __int128... no
	 5700:checking for __float128... no
	 6269:checking for ISO/IEC TR 24733 ... no
	 6270:checking for __int128... yes
	 6271:checking for __float128... no
	35967:checking for ISO/IEC TR 24733 ... no
	35968:checking for __int128... no
	35969:checking for __float128... no
	36538:checking for ISO/IEC TR 24733 ... no
	36539:checking for __int128... yes
	36540:checking for __float128... no
	66232:checking for ISO/IEC TR 24733 ... no
	66233:checking for __int128... no
	66234:checking for __float128... no
	66803:checking for ISO/IEC TR 24733 ... no
	66804:checking for __int128... yes
	66805:checking for __float128... no


(Disk space used after building: almost 5 GB.)

--
Greetings

  Pete

A designer knows he has arrived at perfection not when there is no longer anything to add, but when there is no longer anything to take away.
				– Antoine de Saint-Exupéry


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

* Re: Configuring GCC 10.3 on PPC Mac OS X 10.4.11/Tiger for build reveals flaws in configure scripts
  2022-11-30 23:09     ` Peter Dyballa
@ 2022-12-01  8:22       ` Jonathan Wakely
  0 siblings, 0 replies; 11+ messages in thread
From: Jonathan Wakely @ 2022-12-01  8:22 UTC (permalink / raw)
  To: Peter Dyballa; +Cc: Segher Boessenkool, gcc-help

[-- Attachment #1: Type: text/plain, Size: 1940 bytes --]

On Wed, 30 Nov 2022, 23:09 Peter Dyballa, <Peter_Dyballa@web.de> wrote:

> Hello!
>
> Here is my evaluation from building GCC 10.4
>


It's unlikely anybody is very interested in gcc-10 as there will only be
one more release from that branch, and most of these are just harmless
cases of unclear output. The configure script works correctly, it just
prints jumbled output.



>
> A bit disturbing is this, finding yes and no for the same item, __int128
> (because libquadmath supports this data type?):
>


This is perfectly normal, __int128 is supported when building 64-bit
libraries and not when building 32-bit libraries.

Libquadmath provides routines for working with 128-bit floating-point
types, not integers.


>          5698:checking for ISO/IEC TR 24733 ... no
>          5699:checking for __int128... no
>          5700:checking for __float128... no
>          6269:checking for ISO/IEC TR 24733 ... no
>          6270:checking for __int128... yes
>          6271:checking for __float128... no
>         35967:checking for ISO/IEC TR 24733 ... no
>         35968:checking for __int128... no
>         35969:checking for __float128... no
>         36538:checking for ISO/IEC TR 24733 ... no
>         36539:checking for __int128... yes
>         36540:checking for __float128... no
>         66232:checking for ISO/IEC TR 24733 ... no
>         66233:checking for __int128... no
>         66234:checking for __float128... no
>         66803:checking for ISO/IEC TR 24733 ... no
>         66804:checking for __int128... yes
>         66805:checking for __float128... no
>
>
> (Disk space used after building: almost 5 GB.)
>
> --
> Greetings
>
>   Pete
>
> A designer knows he has arrived at perfection not when there is no longer
> anything to add, but when there is no longer anything to take away.
>                                 – Antoine de Saint-Exupéry
>
>

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

end of thread, other threads:[~2022-12-01  8:22 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-11-25 10:19 Configuring GCC 10.3 on PPC Mac OS X 10.4.11/Tiger for build reveals flaws in configure scripts Peter Dyballa
2022-11-25 11:22 ` Jonathan Wakely
2022-11-25 11:29   ` Jonathan Wakely
2022-11-25 11:39     ` Jonathan Wakely
2022-11-25 11:30   ` Peter Dyballa
2022-11-25 15:56   ` Segher Boessenkool
2022-11-25 16:50     ` Peter Dyballa
2022-11-25 19:43       ` Segher Boessenkool
2022-11-28 22:05     ` Peter Dyballa
2022-11-30 23:09     ` Peter Dyballa
2022-12-01  8:22       ` Jonathan Wakely

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).