Hi!<div><br></div><div>Thank you for your answer.</div><div>Let me start by saying that this project is just for my own amusement.</div><div><br></div><div>Well, what I&#39;m trying to do is to use openfirmware as firmware for qemu-system-ppc(64).</div>

<div><br></div><div>The far-far end of this project is trying to get AIX to boot somehow ...</div><div>(Really doubt it myself, but anyway ...)</div><div><br></div><div><br></div><div>After doing extreme amounts of violence on wrapper.c,</div>
<div>(there is some sort of mixup with AIX - macros)</div><div>i got forth to compile cleanly on AIX 32-bits.</div><div><br></div><div>Unfortunately, now the build process bails out with:</div><div><br></div><div><div>./build basefw.dic</div>
<div>--- Rebuilding kernel.dic</div><div>--- Cmd: ${HOSTDIR}/forth ${HOSTDIR}/../build/builder.dic ../kernel.bth</div><div>${BP}/forth/kernel/meta1.fth:62: tag-file ?</div><div>${BP}/forth/kernel/meta1.fth:62: tag-file ?</div>
<div>${BP}/forth/kernel/meta1.fth:64: tag-file ?</div><div>${BP}/cpu/ppc/metainit.fth:27: Undefined word encountered </div><div>make: *** [basefw.dic] Error 1</div><div><br></div><div>HOSTDIR is ~/openfirmware/cpu/ppc/AIX, which contains the forth-binary.</div>
<div><br></div><div>Any ideas what can cause this?</div><div><br></div><div>//Br</div><div><br></div></div><div><br></div><div><br></div><div><br></div><div><br></div><div>//Br<br>
<br><div class="gmail_quote">2009/11/16 Mitch Bradley <span dir="ltr">&lt;<a href="mailto:wmb@laptop.org" target="_blank">wmb@laptop.org</a>&gt;</span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">


The last time I got anywhere near a 64-bit PPC machine was something like 13 years ago, so I&#39;m afraid I know almost nothing at all about how things work on powerpc64-*-linux.<br>
<br>
You might try gdb to see where it&#39;s dying.<br>
<br>
I&#39;m not surprised that it doesn&#39;t work.  I&#39;m not sure the OFW build system for PPC has ever been adapted to 64-bit Linux.  When FirmWorks was last working with 64 bit PPC machines, the customer was using AIX.  PPC Linux only came out towards the end of that project, and probably didn&#39;t run on 64-bit systems, as few were available then.<br>



<br>
If I recall correctly, on 64-bit systems like the 620 processor, we ran OFW with 32-bit stacks, with the ability to access data in the 64-bit address space.  If powerpc64-suse-linux is a full 64-bit execution environment, that&#39;s probably not going to play well with a 32-bit Forth kernel.  The ppc kernel code appears to be parameterized so it could be extended to 64-bit stacks with some effort (as was the SPARC kernel), but I don&#39;t see any evidence in my archived source trees that a 64-bit PPC Forth kernel was ever built.<br>



<br>
Apple and IBM made it pretty difficult for FirmWorks to make any money in the PowerPC market, by either giving away or bundle-licensing their own internally-developed OFW implementations.  As a result, FirmWorks had to abandon the PPC market and focus on other processors.  FirmWorks&#39; core OFW implementation on PowerPC had reached a high level of stability by that point, but since then there has been very little further development, especially in the area of support for more current build environments.  We did port the builder to mklinux, for use in an embedded project that targeted MPC823, but development sort of stalled after that.<br>



<br>
What is your intended application?  If this is a project with commercial implications, I am available for consulting help.  If it&#39;s just for curiosity, I can perhaps give you some pointers, but can&#39;t spend a lot of time on it.<br>



<br>
Mitch Bradley<br>
<br>
<br>
Christian Johansson wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div></div><div>
Hi!<br>
I&#39;m trying to compile of, rev. 1484 on Linux-ppc64, but after &#39;forth&#39; has been built,<br>
it segfaults when running &quot;./build basefw.dic&quot;<br>
<br>
First try, i got:<br>
<br>
Can&#39;t find environment variable HOSTDIR in ${HOSTDIR}/../build/builder.dic<br>
forth: Can&#39;t open dictionary file ${HOSTDIR}/../build/builder.dic<br>
make: *** [basefw.dic] Error 1<br>
<br>
So I&#39;d set HOSTDIR=$HOME/of2/openfirmware/cpu/ppc/Linux<br>
<br>
After this, I&#39;m just getting:<br>
./build basefw.dic<br>
forth: Segmentation fault<br>
make: *** [basefw.dic] Quit<br>
<br>
When running make in $HOME/of2/openfirmware/cpu/ppc/build<br>
<br>
I&#39;m using:<br>
 chjo@op5p1:~/of/of2/openfirmware/cpu/ppc/build&gt; gcc --v<br>
Using built-in specs.<br>
Target: powerpc64-suse-linux<br>
Configured with: ../configure --enable-threads=posix --prefix=/usr --with-local-prefix=/usr/local --infodir=/usr/share/info --mandir=/usr/share/man --libdir=/usr/lib --libexecdir=/usr/lib --enable-languages=c,c++,objc,fortran,obj-c++,java,ada --enable-checking=release --with-gxx-include-dir=/usr/include/c++/4.2.1 --enable-ssp --disable-libssp --disable-libgcj --with-slibdir=/lib --with-system-zlib --enable-shared --enable-__cxa_atexit --enable-libstdcxx-allocator=new --disable-libstdcxx-pch --program-suffix=-4.2 --enable-version-specific-runtime-libs --without-system-libunwind --with-cpu=default32 --enable-secureplt --with-long-double-128 --host=powerpc64-suse-linux<br>



Thread model: posix<br>
gcc version 4.2.1 (SUSE Linux)<br>
<br>
Any advice how to proceed?<br>
<br>
//Br<br></div></div>
------------------------------------------------------------------------<div><br>
<br>
_______________________________________________<br>
openfirmware mailing list<br>
<a href="mailto:openfirmware@openfirmware.info" target="_blank">openfirmware@openfirmware.info</a><br>
<a href="https://openfirmware.info/mailman/listinfo/openfirmware" target="_blank">https://openfirmware.info/mailman/listinfo/openfirmware</a><br>
  <br>
</div></blockquote>
</blockquote></div><br></div>