[comp.sys.amiga.tech] WARNING! Major Manx Gotcha with 2.0!

usenet@ames.arc.nasa.gov (USENET Administration) (07/20/90)

Distribution:  world
Organization:  NASA Ames Research Center, Mtn Vw CA 94035
Keywords: skeleton, house, car 
From: smithwik@pioneer.arc.nasa.gov (R. Michael Smithwick -- FSN)
Path: pioneer.arc.nasa.gov!smithwik

["Hey, I thought it was a bowling ball!"]

I finally got Manx to work with the new 2.0 includes and library calls,
but with some effort, thanks to a bug. I'm currently using 5.0a, so it
might be fixed in 5.0b, but I haven't received it yet.

The problem appears to deal with a fixed-sized table to support the
#pragmas amicalls. With all of the new libraries, this table overflows
(giving no warning of course). 

What seems to be happening is that when the compiler is reading in the
pragma.h, it will stuff earch xxxxBase label into an array for use 
later on when it comes across a lib call. Trouble is, the table is
limited to 20 entries (since 1.3 needed only a dozen or so).
The new pragmas define 29 library bases. 

Part of the code that amicall should produce is something like (don't have
my assembly listing here so I may have this slightly wrong) :

		 move.l   _FooBase#,a6

However, if the amicall uses a library-base label beyond the end of the
table the code is :

		 move.l   _#,a6

This will cause an undefined symbol error.

This was a bitch to track down.

The workaround if this isn't fixed in 5.0b, is to simply strip out 
9 unneeded library references in pragmas.h.

*****************

On another point, the cia_lib.fd file is missing the line at the top:

		  ##base _CIABase


*****************

When you unpack the includes, alot of the files have a line as :

		 #endif !EXEC_TYPES_H

Manx pukes at this, so strip all of the extra non-comments.

*****************

all_protos.h is missing "input_protos.h"


*****************



                                       >> mike smithwick <<

Any opinions are my own since nobody else would ever want them.

"The real world serves only to illustrate mathematics"

barrett@jhunix.HCF.JHU.EDU (Dan Barrett) (07/21/90)

In article <54348@ames.arc.nasa.gov> smithwik@pioneer.arc.nasa.gov (R. Michael Smithwick -- FSN) writes:
>When you unpack the includes, alot of the files have a line as :
>
>		 #endif !EXEC_TYPES_H
>
>Manx pukes at this, so strip all of the extra non-comments.

	I'm positive that the compiler has a command-line option to
allow preprocessor directives such as #else and #endif to have text
afterwards.  Check the docs.

                                                        Dan

 //////////////////////////////////////\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\
| Dan Barrett, Department of Computer Science      Johns Hopkins University |
| INTERNET:   barrett@cs.jhu.edu           |                                |
| COMPUSERVE: >internet:barrett@cs.jhu.edu | UUCP:   barrett@jhunix.UUCP    |
 \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\/////////////////////////////////////