Debugging the program in Xcode

Hi, ALL,

I have a weird problem.

When I started working on my project I had a laptop with OSX 10.8. I installed Xcode 5 and everything was good. I was able to run the program from the Xcode and everything was working fine.

However recently I bought myself a newer Apple laptop with OSX 10.13. I installed Xcode 9.4.1, cloned my repository, opened the xcodeproject, compiled it and tried to run it.

Unfortunately the program failed to start. All I see that it stops somewhere in the assembly code, even before hitting any source code I wrote.
However when I open the Terminal and do:

Code Block
open my_program.app

I am able to execute it without any issues.

I am also able to run the program from both Xcode and the Terminal when I update the code on my old laptop.

My question would be - what I need to do in order to start working inside Xcode and not keep switching between IDE and the Terminal for testing?

Thank you.

Replies

Is it MacOS or iOS on simulator ?
I understand it is MacOS app.

Could you show your applicationDidFinishLaunching code ?

Which exact version of MacOS is it ?
Did you try create a new program (with Xcode 9.4) and see if it launches from Xcode ?
@Claude31,
  1. Yes, it is MacOS Application Bundle.

  2. The code I'm trying is exactly the same. I'm using C++ with wxWidgets to make my application.

  3. The new laptop has OSX 10.13.6 installed with Xcode 9.4.1.

The program contains of an application executable and 13 dylib projects, bundled in one Xcode workspace.
Maybe when Xcode launches the binary it can't find one of the dylibs and fails to run the Bundle?

But then why this doesn't happen on the old Mac.

Thank you.

P.S.: Is there a way to be notified about the reply posted on the thread? I didn't get any E-mails about your posting...


In addition:

The old laptop has OSX 10.8.5.

P.S.: Is there a way to be notified about the reply posted on the thread? I didn't get any E-mails about your posting...

Unfortunately not, that's one of the (many) problems of this forum


Maybe when Xcode launches the binary it can't find one of the dylibs and fails to run the Bundle?

Could well be, libs may not be compatible with newer version of OS.
Have you the source code for the libs ? If so, did you try to recompile ?

Note: with 10.13.6, you could use Xcode 10.1
@Claude31,


Unfortunately not, that's one of the (many) problems of this forum

With the old forum design that was possible. That's why I asked.
But more importantly - that's how all forums work.

Apple should fire their designers and hire someone who understand what users need. ;-)


Could well be, libs may not be compatible with newer version of OS.
Have you the source code for the libs ? If so, did you try to recompile ?

Yes, the library are part of the workspace and are developed by me as well.
And yes - I did recompile everything.

The question is - where do Xcode expects to find them? /use/local/lib? Somewhere else?
And why it still works on the old Xcode?

Thank you,