-
Notifications
You must be signed in to change notification settings - Fork 35.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
"OS X at startup" code deprecation #8420
Comments
I think as long as we build with 10.11 with compatibility against 10.7 this can't be updated to the new APIs. |
Thanks. Would you happen to know the minimum version where my suggestion (or something similar) would work? I don't doubt you. I'm just, as I said, unfamiliar with the ins & outs of Apple's documentation (or lack thereof in some cases, apparently). |
I also don't know it for sure. But I guess if we access newer non-deprecated APIs, we would need to set the minimum compatible OSX version to 10.11 (which would leave out a lot of users). |
Hmmm. I'm not so sure that 10.11 would be a minimum, although I could potentially see it requiring 10.9 or even 10.10, the latter of which did break quite a bit of stuff, and quietly too. I suppose I could contact the guy who made that tutorial and get his opinion. EDIT: Heh. It helps to re-read blog posts and such once you actually know how to read them properly. :) This blog post and this helper app seem to confirm that 10.7 is a valid target. So, in theory, it should be possible to move forward. Paging @lucasderraugh. Would you mind taking a moment to confirm that my suggestions would work at all, and preferably on 10.7+? Thanks. |
Accoring to SMLoginItem.h:
This means that the API is available starting in OS 10.6. |
@lucasderraugh - Thanks! Looks like we should be great shape here. I'll play with your tutorial and see if I can pick up on any nuances. It sounds like the app just needs to be in the right subdirectory. The main app's .plist file is presumably the only thing that might need to be updated in terms of metadata and whatnot. |
Removing the option might be the way to go. There are other ways to make the app open at login in the OS. |
The code this issue references was removed in #17567. Going to close this. |
Hello. I recently compiled 0.13rc1 on my Mac. It compiled but I came across several warnings such as the following.
qt/guiutil.cpp:810:67: warning: 'kLSSharedFileListSessionLoginItems' is deprecated: first deprecated in OS X 10.11 - Use a LaunchAgent, XPCService or the ServiceManagement APIs instead. [-Wdeprecated-declarations] LSSharedFileListRef loginItems = LSSharedFileListCreate(NULL, kLSSharedFileListSessionLoginItems, NULL);
It appears that the code used to start Core when logging into OS X is now obsolete and needs to be upgraded sooner or later. I haven't tried compiling on a 10.12 beta yet but I'm guessing it still compiles on 10.12.
Anyway, after doing some research, I found this post, which implies that Apple wants everybody to move over to the ServiceManagement framework. Said framework, according to this tutorial, seems to have the following steps.
src/qt/guiutil.cpp has most of the code that needs to be updated, although it appears that src/qt/notificator.cpp also needs an update. I spent a few hours last night trying to wrap my head around how Core could be updated to handle the new method. I had some success but am not totally sure how to proceed. Here's what I have so far, which is probably incomplete.
The main problem I have is that, honestly, I'm not totally familiar with all the nuances of Apple's APIs. So, it's hard for me to figure out how certain things work. For example, the tutorial I linked used the Xcode GUI to do things, which I know would be frowned upon by Core devs. That's fine. I just don't know all the little things necessary to make OS X happy. The app signing nuances don't help either.
Would anybody like to lend a hand? I'm happy to work on this in my free time. I just need somebody who can provide some guidance and make sure I'm not going down a path that'll screw up things like app signing. I have a Core file guide here in case it helps. It covers the high level of what's going on with Core's files, including some of the Mac-specific stuff.
Thanks.
The text was updated successfully, but these errors were encountered: