Allow runtime to be built with C++ on AIX (mono/mono#17672)
authorCalvin Buckley <calvin@cmpct.info>
Sun, 24 Nov 2019 22:08:19 +0000 (18:08 -0400)
committerRyan Lucia <rylucia@microsoft.com>
Sun, 24 Nov 2019 22:08:19 +0000 (17:08 -0500)
commita1ef30c676bc03579eff20014e296521de74250b
tree171cbf76e1d2dae9ece35a13a7834cc4b40575e8
parent44ae994e22e66146b3f157757fc4fbd9a86a54b5
Allow runtime to be built with C++ on AIX (mono/mono#17672)

* Allow runtime to be built with C++ on AIX

Many AIX/PPC/BE specific codepaths didn't do casting properly,
since C++ is much stricter than C about pointer typing.

Also specify the C99 format macros early as possible, since
inttypes may get included before eglib gets a chance to set the
macros.

Also explicitly use -pthread, since not using it is the cause of
many libstdc++ crashes on AIX.

* Oops, should have been that define instead

* Suggested changes from Jay on style

* Remove unneeded cast

Commit migrated from https://github.com/mono/mono/commit/a3f4def8b6951fed5c248bd1875e90a7ab748d15
14 files changed:
src/mono/configure.ac
src/mono/mono/arch/ppc/ppc-codegen.h
src/mono/mono/eglib/giconv.c
src/mono/mono/metadata/sre-encode.c
src/mono/mono/metadata/threads.c
src/mono/mono/metadata/w32file-unix.c
src/mono/mono/metadata/w32process-unix-default.c
src/mono/mono/metadata/w32process-unix.c
src/mono/mono/mini/exceptions-ppc.c
src/mono/mono/mini/mini-ppc.c
src/mono/mono/mini/mini-runtime.c
src/mono/mono/mini/tramp-ppc.c
src/mono/mono/utils/mono-context.c
src/mono/mono/utils/mono-threads-aix.c