error calling GPC on OS X

Previous topic - Next topic

marovada

Hi,

I'm trying to call gpc-macosx from a terminal in Mountain Lion. I get "illegal instruction: 4".  I've scoured the internet for an answer.  It could be a few things, the main ones being:

1. gpc binary is incompatible with Mountain Lion; or

2. Permissions error.

I've tried to repair permissions but get the same error. Has anyone tested gpc-macosx on Mountain Lion?

Thanks

Kitty Hello

Oh. Do GLBasic apps run? They use the same compiler options.

marovada

My app compiles fine with the cross compiler on Windows and runs perfectly on Mountain Lion. The issue I'm having is that the precompiler won't run in a terminal in Mountain Lion.

In the terminal, I type:

./gpc-macosx source.gbas

The result is:

illegal instruction: 4

marovada

I tried this on Snow Leopard and am getting a segmentation fault. When was the gpc-macosx binary last compiled?

Kitty Hello

I think I see the problem now. I compiled it on the mac. Oh dear. The mac compiler is not beef enough to compile the GPC with all the naughty code from boost::spririt.

marovada

Hi Kitty,

Are you able to cross compile it so that it works?

Thanks

Kitty Hello

Yes. Just takes some time. Sorry.

marovada

No problem. I know you've got heaps to do.  Thanks

marovada

Hi Kitty (or do you prefer Gernot??).  There was a version of GPC for Mac used in a Mac IDE that was in development a while ago: http://www.glbasic.com/forum/index.php?topic=4496.0.

Can you upload this version of GPC for Mac in the meantime (if you still have it)?

Neurox

Quote from: Kitty Hello on 2012-Dec-29
Yes. Just takes some time. Sorry.

Hi Gernot,
any news?

Paolo
Paolo Borzini | paolo@borzini.it
The WhiteFly Software | www.thewhitefly.it
Service on line for screen printers | www.4pellicole.it

Kitty Hello

Could you try the attached file? If it was working, I could link this from my PC again - which would make this GPC version always up to date with each update. Otherwise I'd have to link it from the Mac. That would be pretty silly and a lot of manual work each time.

Neurox

Quote from: Kitty Hello on 2013-Mar-24
Could you try the attached file? If it was working, I could link this from my PC again

After running in terminal, the program give me this message "illegal instruction: 4"

Paolo
Paolo Borzini | paolo@borzini.it
The WhiteFly Software | www.thewhitefly.it
Service on line for screen printers | www.4pellicole.it

MrTAToad

Sounds like an array is being accessed that is out of bounds.

marovada

Same here: illegal instruction 4

marovada

I think this is the crash log:

Quote
Process:         bash [34743]
Path:            /bin/bash
Identifier:      bash
Version:         ???
Code Type:       X86 (Native)
Parent Process:  bash [34507]
User ID:         501

Date/Time:       2013-03-30 18:56:44.302 +1100
OS Version:      Mac OS X 10.8.3 (12D78)
Report Version:  10

Crashed Thread:  Unknown

Exception Type:  EXC_BAD_ACCESS (SIGILL)
Exception Codes: KERN_INVALID_ADDRESS at 0x0000000000000000

Backtrace not available

Unknown thread crashed with X86 Thread State (32-bit):
  eax: 0x00000000  ebx: 0x00000000  ecx: 0x00000000  edx: 0x00000000
  edi: 0x00000000  esi: 0x00000000  ebp: 0x00000000  esp: 0x00000000
   ss: 0x00000023  efl: 0x00010202  eip: 0x00000000   cs: 0x0000001b
   ds: 0x00000023   es: 0x00000023   fs: 0x00000023   gs: 0x00000023
  cr2: 0x00000000
Logical CPU: 3

Binary images description not available


External Modification Summary:
  Calls made by other processes targeting this process:
    task_for_pid: 0
    thread_create: 0
    thread_set_state: 0
  Calls made by this process:
    task_for_pid: 0
    thread_create: 0
    thread_set_state: 0
  Calls made by all processes on this machine:
    task_for_pid: 11922
    thread_create: 2
    thread_set_state: 1727