Opened 2 years ago

Closed 2 years ago

#66144 closed defect (fixed)

tinyxml2 fails to build on 10.6.8 when building with gcc-4.2 as arch powerpc: error: integer constant is too large for ‘long’ type

Reported by: barracuda156 Owned by: crowell (Jeffrey Crowell)
Priority: Normal Milestone:
Component: ports Version: 2.8.0
Keywords: snowleopard Cc:
Port: tinyxml2

Description

/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_textproc_tinyxml2/tinyxml2/work/tinyxml2-9.0.0/xmltest.cpp:810: error: integer constant is too large for ‘long’ type
/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_textproc_tinyxml2/tinyxml2/work/tinyxml2-9.0.0/xmltest.cpp:811: error: integer constant is too large for ‘long’ type
make[2]: *** [CMakeFiles/xmltest.dir/xmltest.cpp.o] Error 1
make[2]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_textproc_tinyxml2/tinyxml2/work/build'
make[1]: *** [CMakeFiles/xmltest.dir/all] Error 2
make[1]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_textproc_tinyxml2/tinyxml2/work/build'
make: *** [all] Error 2

Attachments (1)

main.log (89.6 KB) - added by barracuda156 2 years ago.

Download all attachments as: .zip

Change History (11)

Changed 2 years ago by barracuda156

Attachment: main.log added

comment:1 Changed 2 years ago by barracuda156

Summary: tinyxml2 fails to build on 10.6.8:tinyxml2 fails to build on 10.6.8: error: integer constant is too large for ‘long’ type

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

Summary: tinyxml2 fails to build on 10.6.8: error: integer constant is too large for ‘long’ typetinyxml2 fails to build on 10.6.8 when building with gcc-4.2 as arch powerpc: error: integer constant is too large for ‘long’ type

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

macports standard builds on 10.6.8 build just fine, both 32&64 bit

https://ports.macports.org/port/tinyxml2/builds/

comment:5 in reply to:  4 Changed 2 years ago by barracuda156

Replying to kencu:

macports standard builds on 10.6.8 build just fine, both 32&64 bit

https://ports.macports.org/port/tinyxml2/builds/

Yes, thank you, I just updated ports and checked it on 10.6.8 x86_64. Likely gonna fail on Leopard PPC too. Cannot check right now.

UPD. gcc12 builds it fine on Rosetta.

Last edited 2 years ago by barracuda156 (previous) (diff)

comment:6 in reply to:  2 Changed 2 years ago by barracuda156

Replying to kencu:

relevant, likely:

https://stackoverflow.com/questions/8640689/gcc-4-1-2-error-integer-constant-is-too-large-for-long-type

Preferable to try make it compile with gcc-4.2 rather than blacklisting it for platform powerpc?

comment:7 Changed 2 years ago by kencu (Ken)

it’s possible it may not build with gcc-4.2 on any platform in any arch… have to do some checking to know for sure.

comment:8 in reply to:  7 Changed 2 years ago by barracuda156

Replying to kencu:

it’s possible it may not build with gcc-4.2 on any platform in any arch… have to do some checking to know for sure.

I confirmed it to build with gcc-4.2 for x86_64 on 10.6.8. Let me try for i386.

UPD. It fails for i386. Let us blacklist *gcc-4.* on 32-bit platforms.

Last edited 2 years ago by barracuda156 (previous) (diff)

comment:9 Changed 2 years ago by kencu (Ken)

Or just blacklist *gcc-3.* *gcc-4.* on all systems all the time, for consistency. Sure, that sounds like a fine PR.

comment:10 Changed 2 years ago by barracuda156

Resolution: fixed
Status: assignedclosed

In 0fdfccb24814eb0887b7026d530865425a68643b/macports-ports (master):

tinyxml2: blacklist compilers which fail to build consistently (https://github.com/macports/macports-ports/pull/16560)

very old compilers fail to build this for some arches, notably 32bit.

closes: #66144

Note: See TracTickets for help on using tickets.