Page 1 of 1

Distributing an app

PostPosted: Tue Nov 01, 2016 9:58 pm
by plantenkennis
Hello,

When my app is ready I want to distribute it to other users. And at this moment I want to test my app by some other people. However, when I copy my app and the needed databases to another directory so I can share it, the app won't run anymore. There is a sign on the app logo and when I doubleclick on the app I get the notification:
"you can't use this version of the program Plantenkennis.app with this version of OS X. U have OS X 10.11.6. The program needs OS X 10.12 or higher."
I suppose i must do something with my app so I can distribute it. What is needed?

René

Re: Distributing an app

PostPosted: Wed Nov 02, 2016 7:56 am
by Antonio Linares
René,

To support OSX versions lowers to the one that you are using, you need to use an older SDK from Apple.

Another way is to build on such lower OSX version with its corresponding Xcode and SDK (located inside Xcode)

Re: Distributing an app

PostPosted: Wed Nov 02, 2016 9:06 am
by Antonio Linares
I just found this:

https://github.com/phracker/MacOSX-SDKs

A collection of those pesky SDK folders. Compiled from various releases of XCode.

Re: Distributing an app

PostPosted: Wed Nov 02, 2016 7:18 pm
by plantenkennis
Hello Antonio,

The strange thing is that I work on one laptop with MacOS 10.11 wich is the latest version. On this laptop I build my program. When I copy my program to another folder on the same laptop I get the warning.

I also don't believe there is a version 10.12 at this moment?

Re: Distributing an app

PostPosted: Thu Nov 03, 2016 9:40 am
by Antonio Linares
René,

MacOS Sierra is 10.12

Please have your settings this way:
Image

Re: Distributing an app

PostPosted: Thu Nov 03, 2016 7:31 pm
by plantenkennis
Hello Antonio,

OK, that explains things. I have updated Xcode last week, but have not yet updated to Sierra.

A friend had some problems when he updated, due to security keys that didn't work anymore. (SSH 1024/2048). I will update this weekend and hope SourceTree will still work then.

René

Re: Distributing an app

PostPosted: Mon Nov 07, 2016 7:20 pm
by plantenkennis
Hello Antonio,

I have updated my Mac to Sierra (10.12) and now everything works fine again. Also updated SourceTree and everything is working smoothly again.

Another question I have is:
Can I place the databases and all other needed files in the app-package and if it is possible, how can I access them. Is there a path I can refer to?

René

Re: Distributing an app

PostPosted: Tue Nov 08, 2016 7:04 pm
by Antonio Linares
René,

Try to use functions AppPath() and ResPath()

Re: Distributing an app

PostPosted: Tue Nov 08, 2016 9:23 pm
by plantenkennis
Hello Antonio,

Yes, Perfect, these functions do the trick. I have put my databases, photos and bitmaps in the app package. With the given functions I can open my databases and work with them.

Thanks!

René

Tonight I will update the repositary with all new functionallity. You have to put the next folders in the app folder 'resources': Databases, foto, temp.
Folder 'resfiles' must be put in 'resources/bitmaps'