Ultimate Amiga

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1] 2   Go Down

Author Topic: AmosPro Turbo Plus Extension V 2.15 and Compilation  (Read 12500 times)

0 Members and 2 Guests are viewing this topic.

gibs

  • A600
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 35
AmosPro Turbo Plus Extension V 2.15 and Compilation
« on: April 14, 2014, 08:49:19 PM »

Hello,
Is it possible to compile with Turbo Plus Extesion ? each time I try to compile, I get an error message:

Compilation Cancelled
Disk Error : Object Not Found

Thx
Logged

bruceuncle

  • AMOS Dev
  • A500
  • *****
  • Karma: 6
  • Offline Offline
  • Gender: Male
  • Posts: 425
  • WINUAE Amiga User
Re: AmosPro Turbo Plus Extension V 2.15 and Compilation
« Reply #1 on: April 15, 2014, 05:41:18 AM »

I haven't looked at the compiler yet as I want to get AMOS Pro and its documentation bug-free first.  And I don't want to get too distracted or I won't know where to stop  ;D .

However, a few quick searches through the compiler source shows that the error you quote means that it can't find a file.  The reality is that the eror message itself may not be correct.  If you're getting the "Compilation Cancelled" message (the original compiler config uses "Compilation aborted", are you sure that's the exact wording?) you should also, usually, be getting a line number for where the error is.  As you don't show a line number, I would suspect that maybe something's going wrong in initialisation or some section of the compiler's code is running wild.  Do you get any other messages at all when this happens?

A few other questions for future reference:
  • Does this happen when compiling every program that uses the Turbo extension's instructions or just for some?
  • When you have the Turbo extension registered in the Interpreter config, does it happen for any programs that don't use any Turbo instructions?
  • If you remove the Turbo extension (remove it from the Interpreter config) do you ever get this message when compiling other programs?
  • I'm assuming you're using AMOS Pro V2.00.  What version is the Turbo extension you're using?  ("AMOS/About Loaded Extensions" from the AMOS Pro menu.)

I know that's not much help, but if it's any consolation I get compiler errors completely unrelated to what the actual error might be.  If your code is working okay in the interpreter, it should, in theory, compile.  However, it often doesn't!  The fact that incorrect error messages sometimes pop up would seem to indicate that there's something "running amok" in the compiler code.  So I can't be much more help until I get around to finding the compiler's problems and fixing them.  Which is some way off yet...
Logged
Repeat after me ...  "The AMOS Pro architecture is complex but it is not complicated."

gibs

  • A600
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 35
Re: AmosPro Turbo Plus Extension V 2.15 and Compilation
« Reply #2 on: April 15, 2014, 07:29:09 AM »

Hello,
Thanks for the quick answer :)
-Yes once the Extension is installed I get the error message
-I don't know if it's registered, this is the one I get here (2.15). How to check ? Is it still possible to register ? (even compiling a single "cls" instruction).
-No I get the error once I install the Turbo Plus Extension (even 1.0 did the same).
-Yes AmosPro 2.0 (Extension 2.15 and also 1.0).

Thanks again.
Logged

gibs

  • A600
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 35
Re: AmosPro Turbo Plus Extension V 2.15 and Compilation
« Reply #3 on: April 15, 2014, 06:57:33 PM »

The full message is :
Compilation progress panel

Compilation Cancelled !
Unnamed.AMOS
Disk Error : Object Not Found

But it also doesn't want to let me compile a .AMOS from the compiler (without using the editor).
Logged

bruceuncle

  • AMOS Dev
  • A500
  • *****
  • Karma: 6
  • Offline Offline
  • Gender: Male
  • Posts: 425
  • WINUAE Amiga User
Re: AmosPro Turbo Plus Extension V 2.15 and Compilation
« Reply #4 on: April 16, 2014, 09:09:20 AM »

Thanks for the feedback.  That nails it as the extension being at fault. 

To save confusion, I'll use the term "library" instead of "extension", as all the AMOS instructions reside in libraries.  The core ones come supplied, the extension libraries just add on to that.  AMOS makes no distinction when it loads them.  (Not quite true as the main AMOSPro.Lib does get some special attention, but it doesn't affect what happens with the rest.)

Many libraries make use of the "initialisation code" feature for libraries.  Each library's "initialisation code" is run after the interpreter has loaded all registered libraries.  ("Registered" just means that you've told the interpreter's config file what libraries to expect and what their library slot number is.  Turbo is in slot 12.  It's what you do in the editor when you add an extension library.)  The code usually does things like allocating storage and initialising data.

That seems to be where it's failing.  I don't know why the compiler should complain at that point unless it runs any initialisation code (which to me wouldn't make sense, but I haven't pulled the compiler apart yet so I may well be talking rubbish :) ).  Another possibility is that the structure of the library is not quite correct and that's upsetting the compiler.  It's interesting that it's only happening with this extension library loaded - it gives a nice clear-cut case of "It don't work - ever!" to look at.

With the Turbo extension library, from just a quick read through the docs, it also looks likely that it may be stepping outside the amos.library functions and data structures to do what it advertises.  That may also cause a bit of strife with the compiler.

Oh well, that's probably not all that much use to you.  It just reminds me how much work there is ahead when we finally get into cleaning up extensions!  (After the bug-free and documented AMOS Pro V2.xx and the AGA AMOS Pro V3.xx projects are completed.  So not next week then...   ;) ).
Logged
Repeat after me ...  "The AMOS Pro architecture is complex but it is not complicated."

gibs

  • A600
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 35
Re: AmosPro Turbo Plus Extension V 2.15 and Compilation
« Reply #5 on: April 16, 2014, 11:56:35 AM »

Thanks for the detailed information :)
It's not the only library extension that fail with the compiler. Maybe we need to list them somewhere ?
Logged

BooBoo

  • Amiga Guru
  • A600
  • ****
  • Karma: 3
  • Offline Offline
  • Posts: 168
Re: AmosPro Turbo Plus Extension V 2.15 and Compilation
« Reply #6 on: April 16, 2014, 04:27:40 PM »

You can definitely compile with this extension - But i know Ive had this problem - I think I could only compile to Volume DH0: ?
Logged

gibs

  • A600
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 35
Re: AmosPro Turbo Plus Extension V 2.15 and Compilation
« Reply #7 on: April 16, 2014, 08:28:44 PM »

Hello Boubou, it's encouraging !

I tried to:
-Copy program.AMOS to DH0:
-Load it from DH0:
-Compile From the Editor >> Fail

Then, from the Workbench, I launched the compiler and tried to compile a program with a command from TurboPlus.

Now I have another error message :

Compilation Error Report
Program.exe
Extension Not Loaded At Line 34: >>>

Note: From the Editor, the Extension is loaded, and the program is running fine.
I'm confused :-/
Logged

Lonewolf10

  • AMOS Extensions Developer
  • AMOS Dev
  • A2000
  • *****
  • Karma: 3
  • Offline Offline
  • Gender: Male
  • Posts: 618
    • http://www.aliensrcooluk.com
Re: AmosPro Turbo Plus Extension V 2.15 and Compilation
« Reply #8 on: April 17, 2014, 04:52:41 PM »

Then, from the Workbench, I launched the compiler and tried to compile a program with a command from TurboPlus.

Now I have another error message :

Compilation Error Report
Program.exe
Extension Not Loaded At Line 34: >>>

Note: From the Editor, the Extension is loaded, and the program is running fine.
I'm confused :-/

Both the AMOS Pro Editor and the Compiler have separate configuration files that tell them which libraries (to use bruceuncles terminology) need to be loaded in. I can't recall how to set the ones that the compiler uses, if I ever did. I have always compiled my programs by loading the editor first and then loading the compiler via the drop-down menu (the configurable one, I forget it's name).
Logged

gibs

  • A600
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 35
Re: AmosPro Turbo Plus Extension V 2.15 and Compilation
« Reply #9 on: April 17, 2014, 05:09:50 PM »

Hello,
You are talking about the "AMOSPro_Interpreter_Config" file which is located is S:

I don't have any other copy of this file in my system (I read the compiler documentation) and this "AMOSPro_Interpreter_Config" file is set at the first line of my "Compiler system file", I can read:
1 - S:AMOSPro_Interpreter_Config

So when I check for error my AMOS Program using a command from the Turbo Extension Plus, I don't have any error and the program is running fine, then If I start the compiler from the Editor, I get the error message described in my 1st message on this thread.

Snoopdos, didn't help... so I don't know...any idea is welcome :)
« Last Edit: April 17, 2014, 05:11:38 PM by gibs »
Logged

Lonewolf10

  • AMOS Extensions Developer
  • AMOS Dev
  • A2000
  • *****
  • Karma: 3
  • Offline Offline
  • Gender: Male
  • Posts: 618
    • http://www.aliensrcooluk.com
Re: AmosPro Turbo Plus Extension V 2.15 and Compilation
« Reply #10 on: April 17, 2014, 05:27:37 PM »

Hello,
You are talking about the "AMOSPro_Interpreter_Config" file which is located is S:

Yes. Make sure that the above named file is the same for both the editor and the compiler. The easiest way is to carefully copy it from "AMOSPro/S/" to "Compiler/s/". If you want to be safe rename "Compiler/s/AMOSPro_Interpreter_Config" to something else (e.g. "old_Interpreter_Config"), just incase something goes wrong.

I hope this helps. It is frustrating spending ages coding something and then finding that it won't compile.
Logged

gibs

  • A600
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 35
Re: AmosPro Turbo Plus Extension V 2.15 and Compilation
« Reply #11 on: April 17, 2014, 05:35:58 PM »

No.

S:AMOSPro_Interpreter_Config is different than S:AMOSPro_Compiler_Config : there are 2 different files.

But  S:AMOSPro_Interpreter_Config is linked in S:AMOSPro_Compiler_Config
You can see that in the Compiler options, in the box "Compiler System files".
Logged

Lonewolf10

  • AMOS Extensions Developer
  • AMOS Dev
  • A2000
  • *****
  • Karma: 3
  • Offline Offline
  • Gender: Male
  • Posts: 618
    • http://www.aliensrcooluk.com
Re: AmosPro Turbo Plus Extension V 2.15 and Compilation
« Reply #12 on: April 17, 2014, 05:47:12 PM »

S:AMOSPro_Interpreter_Config is different than S:AMOSPro_Compiler_Config : there are 2 different files.

But  S:AMOSPro_Interpreter_Config is linked in S:AMOSPro_Compiler_Config
You can see that in the Compiler options, in the box "Compiler System files".

Yes, I believe they both need to be in the "S" folder. My "Compiler/S" folder contains:

AMOSPro_Compiler_Config
AMOSPro_Interpreter_Config
AP_Interpreter_Config-ori   (an old version of the AMOSPro_Interpreter_Config)
startup-sequence
Logged

gibs

  • A600
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 35
Re: AmosPro Turbo Plus Extension V 2.15 and Compilation
« Reply #13 on: April 17, 2014, 05:48:31 PM »

Can you try to insert the extension and compile ?
Logged

Lonewolf10

  • AMOS Extensions Developer
  • AMOS Dev
  • A2000
  • *****
  • Karma: 3
  • Offline Offline
  • Gender: Male
  • Posts: 618
    • http://www.aliensrcooluk.com
Re: AmosPro Turbo Plus Extension V 2.15 and Compilation
« Reply #14 on: April 17, 2014, 06:00:04 PM »


As far as I can tell the only way to "insert" extensions is to copy across the "AMOSPro_Interpreter_Config" file into the "Compiler/s/" folder as mentioned above.
I'll give it a try later today, as I don't have the time right now.
Logged
Pages: [1] 2   Go Up
 

TinyPortal 2.2.2 © 2005-2022