GCC 9 (Retro68) fork - compiler targeting PowerPC Windows NT (with PASM.EXE assembler and VC4.x linker)
Go to file
2025-02-28 17:59:07 +00:00
config Initial commit 2025-02-23 21:55:55 +00:00
contrib Initial commit 2025-02-23 21:55:55 +00:00
fixincludes Initial commit 2025-02-23 21:55:55 +00:00
gcc Initial commit 2025-02-23 21:55:55 +00:00
gnattools Initial commit 2025-02-23 21:55:55 +00:00
gotools Initial commit 2025-02-23 21:55:55 +00:00
include Initial commit 2025-02-23 21:55:55 +00:00
INSTALL Initial commit 2025-02-23 21:55:55 +00:00
intl Initial commit 2025-02-23 21:55:55 +00:00
libada Initial commit 2025-02-23 21:55:55 +00:00
libatomic Initial commit 2025-02-23 21:55:55 +00:00
libbacktrace Initial commit 2025-02-23 21:55:55 +00:00
libcc1 Initial commit 2025-02-23 21:55:55 +00:00
libcpp Initial commit 2025-02-23 21:55:55 +00:00
libdecnumber Initial commit 2025-02-23 21:55:55 +00:00
libffi Initial commit 2025-02-23 21:55:55 +00:00
libgcc Initial commit 2025-02-23 21:55:55 +00:00
libgfortran Initial commit 2025-02-23 21:55:55 +00:00
libgo Initial commit 2025-02-23 21:55:55 +00:00
libgomp Initial commit 2025-02-23 21:55:55 +00:00
libhsail-rt Initial commit 2025-02-23 21:55:55 +00:00
libiberty Initial commit 2025-02-23 21:55:55 +00:00
libitm Initial commit 2025-02-23 21:55:55 +00:00
libobjc Initial commit 2025-02-23 21:55:55 +00:00
liboffloadmic Initial commit 2025-02-23 21:55:55 +00:00
libphobos Initial commit 2025-02-23 21:55:55 +00:00
libquadmath Initial commit 2025-02-23 21:55:55 +00:00
libsanitizer Initial commit 2025-02-23 21:55:55 +00:00
libssp Initial commit 2025-02-23 21:55:55 +00:00
libstdc++-v3 Initial commit 2025-02-23 21:55:55 +00:00
libvtv Initial commit 2025-02-23 21:55:55 +00:00
lto-plugin Initial commit 2025-02-23 21:55:55 +00:00
maintainer-scripts Initial commit 2025-02-23 21:55:55 +00:00
newlib Initial commit 2025-02-23 21:55:55 +00:00
zlib Initial commit 2025-02-23 21:55:55 +00:00
.dir-locals.el Initial commit 2025-02-23 21:55:55 +00:00
.gitattributes Initial commit 2025-02-23 21:55:55 +00:00
.gitignore Initial commit 2025-02-23 21:55:55 +00:00
ABOUT-NLS Initial commit 2025-02-23 21:55:55 +00:00
ar-lib Initial commit 2025-02-23 21:55:55 +00:00
ChangeLog Initial commit 2025-02-23 21:55:55 +00:00
ChangeLog.jit Initial commit 2025-02-23 21:55:55 +00:00
ChangeLog.tree-ssa Initial commit 2025-02-23 21:55:55 +00:00
compile Initial commit 2025-02-23 21:55:55 +00:00
config-ml.in Initial commit 2025-02-23 21:55:55 +00:00
config.guess Initial commit 2025-02-23 21:55:55 +00:00
config.rpath Initial commit 2025-02-23 21:55:55 +00:00
config.sub Initial commit 2025-02-23 21:55:55 +00:00
configure Initial commit 2025-02-23 21:55:55 +00:00
configure.ac Initial commit 2025-02-23 21:55:55 +00:00
COPYING Initial commit 2025-02-23 21:55:55 +00:00
COPYING3 Initial commit 2025-02-23 21:55:55 +00:00
COPYING3.LIB Initial commit 2025-02-23 21:55:55 +00:00
COPYING.LIB Initial commit 2025-02-23 21:55:55 +00:00
COPYING.RUNTIME Initial commit 2025-02-23 21:55:55 +00:00
depcomp Initial commit 2025-02-23 21:55:55 +00:00
install-sh Initial commit 2025-02-23 21:55:55 +00:00
libtool-ldflags Initial commit 2025-02-23 21:55:55 +00:00
libtool.m4 Initial commit 2025-02-23 21:55:55 +00:00
lt~obsolete.m4 Initial commit 2025-02-23 21:55:55 +00:00
ltgcc.m4 Initial commit 2025-02-23 21:55:55 +00:00
ltmain.sh Initial commit 2025-02-23 21:55:55 +00:00
ltoptions.m4 Initial commit 2025-02-23 21:55:55 +00:00
ltsugar.m4 Initial commit 2025-02-23 21:55:55 +00:00
ltversion.m4 Initial commit 2025-02-23 21:55:55 +00:00
MAINTAINERS Initial commit 2025-02-23 21:55:55 +00:00
Makefile.def Initial commit 2025-02-23 21:55:55 +00:00
Makefile.in Initial commit 2025-02-23 21:55:55 +00:00
Makefile.tpl Initial commit 2025-02-23 21:55:55 +00:00
MD5SUMS Initial commit 2025-02-23 21:55:55 +00:00
missing Initial commit 2025-02-23 21:55:55 +00:00
mkdep Initial commit 2025-02-23 21:55:55 +00:00
mkinstalldirs Initial commit 2025-02-23 21:55:55 +00:00
move-if-change Initial commit 2025-02-23 21:55:55 +00:00
multilib.am Initial commit 2025-02-23 21:55:55 +00:00
NEWS Initial commit 2025-02-23 21:55:55 +00:00
README_gcc Initial commit 2025-02-23 21:55:55 +00:00
README.md readme: fix another typo 2025-02-28 17:59:07 +00:00
symlink-tree Initial commit 2025-02-23 21:55:55 +00:00
test-driver Initial commit 2025-02-23 21:55:55 +00:00
ylwrap Initial commit 2025-02-23 21:55:55 +00:00

Compiler for Windows NT PowerPC

This is a fork of Retro68's GCC 9.1, heavily modified to emit asm that the official NTPPC assembler PAS.EXE (aka cross-assembler PASM.EXE as included in old VC6-era Windows CE 2.x for PowerPC toolchain) can build. Combine with VC++4.x's linker (any later will not work) to make a full toolchain.

Known bugs

  • -O2 and higher is broken, without disabling problematic optimisations: at least -fno-align-functions -fno-align-labels -fno-align-jumps -fno-align-loops
  • No SEH support
  • Function prologues + epilogues / stack frames are technically not correct for PPC NT, this only really causes issues with some exceptions in kernel mode leading to PANIC_STACK_SWITCH bugcheck (instead of the correct one) due to exception handling related code in NT itself raising an exception
  • C++ support is completely untested.
  • No libgcc, if you need math related functions from there use arith64.c (or manually use Rtl* functions from ntdll/etc)

There may be other issues.

Building

git clone https://github.com/Wack0/peppc
mkdir peppc-build
mkdir peppc-build/gcc-build
mkdir peppc-build/toolchain
cd peppc-build/gcc-build
../../peppc/configure --target=powerpcle-pe-winnt --prefix=$PWD/../toolchain --enable-languages=c,c++ --disable-libssp --disable-lto --src=../../peppc MAKEINFO=missing
make # add -j as appropriate
# libgcc build will fail, this is expected.
cd gcc
make install

Usage

Compile, assemble, link like so:

powerpcle-pe-winnt-gcc -S -O1 -o - file.c | powerpcle-pe-winnt-cpp - -P -w -o file.asm # add compiler switches as appropriate
pasm.exe -o file.obj file.asm # ran through wine if needed
link.exe /OUT:file.exe file.obj libs... # ran through wine if needed