Opened 3 years ago

Last modified 19 months ago

#64609 new defect

OpenSP failure for ppc with gcc-4.2: configure: error: cannot compute sizeof (size_t)

Reported by: barracuda156 Owned by:
Priority: Normal Milestone:
Component: ports Version: 2.7.1
Keywords: powerpc, leopard, snowleopard, rosetta Cc:
Port: OpenSP

Description

checking size of size_t... configure: error: in `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_textproc_opensp/opensp/work/OpenSP-1.5.2':
configure: error: cannot compute sizeof (size_t)
See `config.log' for more details
Command failed:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_textproc_opensp/opensp/work/OpenSP-1.5.2" && ./configure --prefix=/opt/local --enable-http --disable-dependency-tracking --enable-default-catalog=/opt/local/share/sgml/catalog --mandir=/opt/local/share/man --disable-doc-build 
Exit code: 77
Error: Failed to configure opensp: consult /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_textproc_opensp/opensp/work/OpenSP-1.5.2/config.log

Attachments (2)

config.log (170.2 KB) - added by barracuda156 3 years ago.
10.5.8_main.log (77.2 KB) - added by barracuda156 3 years ago.
Attempt to build on 10.5.8 fails too.

Download all attachments as: .zip

Change History (17)

Changed 3 years ago by barracuda156

Attachment: config.log added

comment:1 Changed 3 years ago by barracuda156

This time adding correct triple to port file did not help:

checking size of size_t... configure: error: in `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_textproc_opensp/opensp/work/OpenSP-1.5.2':
configure: error: cannot compute sizeof (size_t)
See `config.log' for more details
Command failed:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_textproc_opensp/opensp/work/OpenSP-1.5.2" && ./configure --prefix=/opt/local --enable-http --disable-dependency-tracking --enable-default-catalog=/opt/local/share/sgml/catalog --mandir=/opt/local/share/man --disable-doc-build CFLAGS_FOR_BUILD="-arch ppc -m32" CXXFLAGS_FOR_BUILD="-arch ppc -m32" --build=powerpc-apple-darwin10 --host=powerpc-apple-darwin10 --target=powerpc-apple-darwin10 
Exit code: 77
Error: Failed to configure opensp: consult /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_textproc_opensp/opensp/work/OpenSP-1.5.2/config.log
Error: Failed to configure opensp: configure failure: command execution failed
Error: See /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_textproc_opensp/opensp/main.log for details.
Error: Follow https://guide.macports.org/#project.tickets if you believe there is a
bug.

comment:2 Changed 3 years ago by barracuda156

The same error occurs on 10.5.8:

checking size of size_t... configure: error: in `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_textproc_opensp/opensp/work/OpenSP-1.5.2':
configure: error: cannot compute sizeof (size_t)
See `config.log' for more details
Command failed:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_textproc_opensp/opensp/work/OpenSP-1.5.2" && ./configure --prefix=/opt/local --disable-dependency-tracking --enable-http --disable-dependency-tracking --enable-default-catalog=/opt/local/share/sgml/catalog --mandir=/opt/local/share/man --disable-doc-build 
Exit code: 77
Error: Failed to configure opensp: consult /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_textproc_opensp/opensp/work/OpenSP-1.5.2/config.log
Error: Failed to configure opensp: configure failure: command execution failed
Error: See /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_textproc_opensp/opensp/main.log for details.
Error: Follow https://guide.macports.org/#project.tickets if you believe there
is a bug.
Error: Processing of port opensp failed

Changed 3 years ago by barracuda156

Attachment: 10.5.8_main.log added

Attempt to build on 10.5.8 fails too.

comment:3 Changed 3 years ago by barracuda156

Keywords: leopard added
Summary: OpenSP failure for ppc on 10.6.8: configure: error: cannot compute sizeof (size_t)OpenSP failure for ppc: configure: error: cannot compute sizeof (size_t)

comment:4 Changed 3 years ago by kencu (Ken)

you’d have to look in that config.log to see exactly what error is stopping it

comment:5 Changed 3 years ago by kencu (Ken)

it looks to me like the main issue might be this:

cc1plus: error: unrecognized command line option "-std=c++03"

try pulling that out and see what happens

comment:6 Changed 3 years ago by kencu (Ken)

the buildbot farm currently builds everything with clang as the default compiler. The oldest clang used is the one from 10.7.

So there is no testing of ports done against gcc of any version, in particular the crusty old gcc-4.2….many issues are likely to arise.

The best approach might be to force builds to use gcc7 as a first step for failures, as that often works and is very easy to do.

If that doesn’t work, then it’s surely harder to fix the issue, and might be impossible.

comment:7 in reply to:  5 ; Changed 3 years ago by barracuda156

Replying to kencu:

it looks to me like the main issue might be this:

cc1plus: error: unrecognized command line option "-std=c++03"

try pulling that out and see what happens

How do I prevent a flag from being added?

comment:8 in reply to:  7 ; Changed 3 years ago by kencu (Ken)

Replying to barracuda156:

How do I prevent a flag from being added?

patch the build files

comment:9 in reply to:  8 Changed 3 years ago by barracuda156

Replying to kencu:

Replying to barracuda156:

How do I prevent a flag from being added?

patch the build files

Got it! (I thought it might be done via port file, that’s why asked. I can handle the patching.)

comment:10 Changed 3 years ago by ryandesign (Ryan Carsten Schmidt)

Is -std=c++03 valid in some compiler? I thought C++ 2003 support was enabled by specifying -std=c++0x. That might be the default in g++-4.2 anyway.

comment:11 in reply to:  6 Changed 3 years ago by barracuda156

Replying to kencu:

the buildbot farm currently builds everything with clang as the default compiler. The oldest clang used is the one from 10.7.

So there is no testing of ports done against gcc of any version, in particular the crusty old gcc-4.2….many issues are likely to arise.

The best approach might be to force builds to use gcc7 as a first step for failures, as that often works and is very easy to do.

If that doesn’t work, then it’s surely harder to fix the issue, and might be impossible.

Yeah, OpenSP has built with macports-gcc-11 instead of gcc-4.2. No need to patch configure, we can just ban gcc =< 4.2 for PowerPC.

comment:12 Changed 3 years ago by barracuda156

Summary: OpenSP failure for ppc: configure: error: cannot compute sizeof (size_t)OpenSP failure for ppc with gcc-4.2: configure: error: cannot compute sizeof (size_t)

comment:13 in reply to:  10 ; Changed 19 months ago by ryandesign (Ryan Carsten Schmidt)

Replying to ryandesign:

Is -std=c++03 valid in some compiler? I thought C++ 2003 support was enabled by specifying -std=c++0x. That might be the default in g++-4.2 anyway.

Not sure how I wrote that. I should know that c++0x was the preliminary name of c++11.

Has duplicate #67301 wherein we found that changing c++03 to c++98 works.

comment:14 in reply to:  13 Changed 19 months ago by barracuda156

Replying to ryandesign:

Has duplicate #67301 wherein we found that changing c++03 to c++98 works.

I should have checked for the ticket. After 15 months this was totally forgotten.

Note: See TracTickets for help on using tickets.