Why won't my app open on other macs?

Joined
Feb 8, 2009
Messages
41
Reaction score
0
Points
6
Hello,
recently I spent many hours on making my own little app. The problem is it works only on my computer and it doesn't work on other Mac Computers.
It launches on a dock for a second and then automatically closes.
How do I build my own app when I'm ready?
 

vansmith

Senior Member
Joined
Oct 19, 2008
Messages
19,924
Reaction score
559
Points
113
Location
Queensland
Your Mac's Specs
Mini (2014, 2018, 2020), MBA (2020), iPad Pro (2018), iPhone 13 Pro Max, Watch (S6)
There's a lot missing here. What language are you using? How did you compile it? Are you using libraries present on other machines?
 
OP
T
Joined
Feb 8, 2009
Messages
41
Reaction score
0
Points
6
There's a lot missing here. What language are you using? How did you compile it? Are you using libraries present on other machines?

I am sorry.
I am using Objective-C (Cocoa Application). I made the app on my MacBook Pro mid 2010 running mavericks (latest Xcode) and development target is 10.7. It works perfectly and the way it should. I'm upset a little because it took me months to get the code right but I finally got everything right.

I compile the app by going to Product -> Archive ->Distribute ->Export as Application->Don't re-sign and then pressed export.
The app works perfectly on My MacBook Pro mavericks, but when I tested it on White Macbook, which runs Lion it just launches for a second and closes itself (dock icon only)

I tried it on Snow Leopard and it said it needs 10.7 or newer (makes sense) So how do I get it work on my other Macs?
 

vansmith

Senior Member
Joined
Oct 19, 2008
Messages
19,924
Reaction score
559
Points
113
Location
Queensland
Your Mac's Specs
Mini (2014, 2018, 2020), MBA (2020), iPad Pro (2018), iPhone 13 Pro Max, Watch (S6)
Odds are that the code is actually broken (welcome to the joyous and yet frustrating world of programming). I've seen it happen before - code works really well under the conditions that you're testing and as soon as you try it elsewhere, it all fails miserably.

Run the app from the command line:
Code:
open -a /path/to/app/bundle/name.app
When it fails, take a look at the error message.
 
OP
T
Joined
Feb 8, 2009
Messages
41
Reaction score
0
Points
6
Thank you very much for being so kind and replying for me.
I ran the command line and it said that the app doesn't exist, but I must tell you this that I copied the source to text edit and I did it on a Mac that runs Snow Leopard and Xcode 4.2 and it works exactly the same way and everything except the icon and minimum OS (now it's 10.4.11) is same.

I built it the same way I described you yesterday and it works on every Mac I've tried. It stays open, everything opens well.

I don't know why it didn't work when I built on other Xcode. I guess I will have to use Snow Leopard as a development OS. Maybe the problem was also that I am not an identified developer? I just started. It's a simple status bar app that views your desktop (just like in Windows Vista,7,8). I didn't find this function on a Mac and I was tired of pressing CMD+H all the time. Trackpad or built in version isn't the same as I needed.

The only coding I pretty much did was it to open my website when clicked button and web view things and to hide it when you click status bar icon. As I've explained it's a very simple app and I don't see what the problems might've been.

How do I build apps on Mavericks or Yosemite? Do I really have to be stuck on Xcode 4.2 for the rest of my life?
 

Shop Amazon


Shop for your Apple, Mac, iPhone and other computer products on Amazon.
We are a participant in the Amazon Services LLC Associates Program, an affiliate program designed to provide a means for us to earn fees by linking to Amazon and affiliated sites.
Top