Compilation on Mac OpenAl module

BlitzMax Forums/BlitzMax Programming/Compilation on Mac OpenAl module

gameshastra(Posted 2008) [#1]
While compiling modules for Mac, I am getting the error Cstring type can be used only with extern functions in the openAl module. Also is it possible to compile individual modules separately?.

Your help is appreciated.

Regards


gameshastra(Posted 2008) [#2]
Requesting help soon


tonyg(Posted 2008) [#3]
Look in the doc under User Guide BMK for individual modul compilation.
For the OpenAL issue what level of Bmax are you using, which Mac type and OS levels, what is the exact message.
There are a number of matches using the advanced search function with 'cstring extern' which gives reaosn for the error and possible workarounds. What happens when you try these?


gameshastra(Posted 2008) [#4]
The exact error is Cstring type can be used only with extern functions


tonyg(Posted 2008) [#5]
... and it doesn't give any indication of where that problem occurs?
Did my taking time out to respond on your single module compilation query help at all? Did you do the searches for the other issues reporting the same error message?
What level of Bmax are you using and which Mac type and OS level?


gameshastra(Posted 2008) [#6]
The Blitzmax version is 118.


tonyg(Posted 2008) [#7]
Maybe you should be using the updated level?

... and it doesn't give any indication of where that problem occurs?
Did my taking time out to respond on your single module compilation query help at all? Did you do the searches for the other issues reporting the same error message?
Which Mac type and OS level?


gameshastra(Posted 2008) [#8]
The single module compilation was very helpful. Don't know about the errors.


tonyg(Posted 2008) [#9]
Don't know about the errors.

Not sure what you mean by that.
Do you mean you did the searches, read the results and don't know what to do or that you have no further information on the error?
If the former then which did you read and what did you not understand?
If the latter then re-run the job and provide the output.

Which mac type and OS level are you using?
What happens when you run with an up to date Bmax version?


Brucey(Posted 2008) [#10]
I'd be surprised if the OpenAL module compiled with 1.18.
Is there a reason you can't use at least 1.26 of BlitzMax?


gameshastra(Posted 2008) [#11]
I updated to 1.28 and all the modules compiled. However I get an error message GetActiveWindow() not found when I build the application.

I rebuilt the system module but that didn't solve the problem.

Thank you very much for the suggestions.

Regards


tonyg(Posted 2008) [#12]
GetActiveWindow() not found when I build the application.

What did you do EXACTLY to get the error message and what is the FULL error message including the file from which the error occurred?
If you're not aleardy, what happens if you run in debug mode?
Which mac type and OS level are you using?


gameshastra(Posted 2008) [#13]
I just built the application using the build command on the IDE. The error message is compile Error GetActiveWindow Not found.

Regards,


SebHoll(Posted 2008) [#14]
Are you trying to compile a previously Windows coded BMX file on Mac? It looks like you've used the GetActiveWindow() API in Pub.Win32 which will only work on Windows. If so, you will have to wrap GetActiveWindow() with compiler directive (such as ?Win32), so that it doesn't throw up error on OS X.


gameshastra(Posted 2008) [#15]
GetActiveWindow()is in system.mod and it had compiled for me earlier.
Can you tell me the exact syntax for the call is it GetActiveWindow?Win32()
or something else.

Thanks,
Regards


SebHoll(Posted 2008) [#16]
Which file in brl.mod/system.mod is the compile error reported? You shouldn't have to amend the official modules as they should already have the relevant directives.

Did you install BlitzMax by installing v1.18, and then use the *Mac* v1.28 PPC update? Did you run syncmods after installing the patch?

It sounds like you might have got some Windows files in your Mac BlitzMax folder, so you'll need to provide more more details, such as which version of BRL.System you are using (written at the top of brl.mod/system.mod/system.bmx).


gameshastra(Posted 2008) [#17]
The build module works fine. updated to 1.28 from 1.18 and the also ran syncmods from the ide. version od brl.system is 1.26

Thanking You,
Regards


SebHoll(Posted 2008) [#18]
Can you move brl.mod\system.mod\system.win32.c and brl.mod\system.mod\system.win32.bmx to a different temporary location (removing them from brl.mod\system.mod), rebuild modules, and note the file and line number of any error message which appear?


gameshastra(Posted 2008) [#19]
I moved the files brl.mod\system.mod\system.win32.c and brl.mod\system.mod\system.win32.bmx as suggested. I rebuilt the modules
without errors.

The application still gives the same error Identifier GetActiveWindow()
not found.


Regards


SebHoll(Posted 2008) [#20]
The application still gives the same error Identifier GetActiveWindow()
not found.

Does this happen with every program you compile, or just a particular one? For example, does...

Print "Hello World!"
...still throw the same error?


gameshastra(Posted 2008) [#21]
I moved the files brl.mod\system.mod\system.win32.c and brl.mod\system.mod\system.win32.bmx as suggested. I rebuilt the modules
without errors.

The application still gives the same error Identifier GetActiveWindow()
not found. I also get the following error Duplicate identifier HideMouse() in system.mod and retro.system.mod

Regards


gameshastra(Posted 2008) [#22]
Some of the sample programs that come with Blitzmax give this error also.


SebHoll(Posted 2008) [#23]
I moved the files brl.mod\system.mod\system.win32.c and brl.mod\system.mod\system.win32.bmx as suggested. I rebuilt the modules
without errors.

Yeah - I got it the first time... ;-)

Where's retro.system.mod? Never heard of that file before?


tonyg(Posted 2008) [#24]
In addition to Seb's query :
Which sample programs that come with BlitzMax give the error and what happened when you ran the 'Hello World' program as suggested without any framework or import commands?


gameshastra(Posted 2008) [#25]
retro.mod is under brl.mod and there is a system.mod under retro.mod.

The duplicate mods are system.mod under brl.mod and retro.mod.

Regards


Brucey(Posted 2008) [#26]
Woops... looks like your mod folder is looking a little sick.

There should only be two levels of folders under BlitzMax/mod

First you get the namespace folder, like brl.mod, or pub.mod, or bah.mod...

Then you get the module folder itself, like system.mod, or retro.mod, or libxml.mod.

So that it reads like :

BlitzMax/mod/brl.mod/system.mod
BlitzMax/mod/brl.mod/retro.mod

Nothing else is correct.


SebHoll(Posted 2008) [#27]
What Brucey said...

Nothing else is correct.

Some folders, however, may have a doc subfolder in too which has code examples in it...

e.g.

BlitzMax/mod/brl.mod/maxgui.mod/doc


gameshastra(Posted 2008) [#28]
mmahender


gameshastra(Posted 2008) [#29]
Installing a copy of Blitzmax 1.18 followed by 1.28 and then building the modules and finally the application on another system solved the problem.

probably the installation of 1.18 on the first machine was not proper
Thanks very much,
Regards