muidev icon indicating copy to clipboard operation
muidev copied to clipboard

Compiling using MUI 3.8 SDK and GCC 6 for 68k using cross compiler

Open walkero-gr opened this issue 2 years ago • 3 comments

The last days I am trying to use GCC v6 for 68k using a cross compiler environment and I have the following issue, which I am not sure if it is a problem of GCC or of the header files not working well with this GCC version.

I am trying to compile one of my programs with the MUI 3.8 SDK, and I get the following errors. This does not happen with late MUI 5.0 SDK.

Is this logical or should I change something?

In file included from /opt/sdk/MUI_3.8/C/Include/proto/muimaster.h:6:0,
                 from src/funcs.c:40:
/opt/sdk/MUI_3.8/C/Include/inline/muimaster.h: In function 'MUI_AslRequest':
/opt/sdk/MUI_3.8/C/Include/inline/muimaster.h:55:19: warning: missing terminating " character
   __asm volatile ("
                   ^
/opt/sdk/MUI_3.8/C/Include/inline/muimaster.h:55:19: error: missing terminating " character
/opt/sdk/MUI_3.8/C/Include/inline/muimaster.h:56:3: error: expected string literal before 'jsr'
   jsr a6@(-0x36)"
   ^~~
/opt/sdk/MUI_3.8/C/Include/inline/muimaster.h:56:9: error: stray '@' in program
   jsr a6@(-0x36)"
         ^
/opt/sdk/MUI_3.8/C/Include/inline/muimaster.h:56:17: warning: missing terminating " character
   jsr a6@(-0x36)"
                 ^
/opt/sdk/MUI_3.8/C/Include/inline/muimaster.h:56:17: error: missing terminating " character
In file included from /opt/sdk/MUI_3.8/C/Include/proto/muimaster.h:6:0,
                 from src/funcs.c:40:
/opt/sdk/MUI_3.8/C/Include/inline/muimaster.h: In function 'MUI_CreateCustomClass':
/opt/sdk/MUI_3.8/C/Include/inline/muimaster.h:83:19: warning: missing terminating " character
   __asm volatile ("
                   ^
/opt/sdk/MUI_3.8/C/Include/inline/muimaster.h:83:19: error: missing terminating " character
/opt/sdk/MUI_3.8/C/Include/inline/muimaster.h:84:3: error: expected string literal before 'jsr'
   jsr a6@(-0x6c)"
   ^~~
/opt/sdk/MUI_3.8/C/Include/inline/muimaster.h:84:9: error: stray '@' in program
   jsr a6@(-0x6c)"
         ^
/opt/sdk/MUI_3.8/C/Include/inline/muimaster.h:84:17: warning: missing terminating " character
   jsr a6@(-0x6c)"
                 ^
/opt/sdk/MUI_3.8/C/Include/inline/muimaster.h:84:17: error: missing terminating " character

This is the code the inline/muimaster.h has in the complaining methods

  __asm volatile ("
  jsr a6@(-0x36)"
  : "=r" (res)
  : "r" (a6), "r" (a0), "r" (a1)
  : "d0", "d1", "a0", "a1" );

What I am doing is:

#include <libraries/mui.h>
#include <proto/muimaster.h>

Should I stick to MUI 5, instead of using MUI 3.8? Applications that are compiled with MUI 5 SDK are able to run fine on Amigas that have only MUI 3.8 installed?

Thank you for your help.

walkero-gr avatar Jun 16 '22 22:06 walkero-gr