[OS X] backend ported from KDE4

Review Request #126086 - Created Nov. 16, 2015 and submitted

René J.V. Bertin
kde-mac, kdeframeworks

This revision adds a port of the OS X backend improvements I implemented for KDE4 2 years ago, plus a few additional changes (some just to spark some debate).

kauth-policy-gen still should not be built as an app bundle on OS X.
This can be achieved by using ecm_mark_nongui-executable; there appear to be no contra-indications on other platforms.

On OS X 10.9 with Qt 5.6.1 and Frameworks 5.24.0

There is an issue with one of the autotests:

build/autotests/KAuthHelperTest -vb -v1
********* Start testing of HelperTest *********
Config: Using QtTest library 5.6.1, Qt 5.6.1 (x86_64-little_endian-lp64 shared (dynamic) release build; by Clang 6.0 (clang-600.0.57) (Apple))
INFO   : HelperTest::initTestCase() entering
QDEBUG : HelperTest::initTestCase() Test backend loaded
QDEBUG : HelperTest::initTestCase() Waiting for HelperHandler to be initialized
QDEBUG : HelperTest::initTestCase() Initializing helper handler
QDEBUG : HelperTest::initTestCase() Adding proxy for thread QThread(0x7fab38e11e50)
PASS   : HelperTest::initTestCase()
INFO   : HelperTest::testBasicActionExecution() entering
QDEBUG : HelperTest::testBasicActionExecution() Capabilities changing
QDEBUG : HelperTest::testBasicActionExecution() Checking if action  "org.kde.kf5auth.autotest.standardaction" exists
QDEBUG : HelperTest::testBasicActionExecution() Caller ID: "a random caller Id"
QDEBUG : HelperTest::testBasicActionExecution() Standard action running
PASS   : HelperTest::testBasicActionExecution()
INFO   : HelperTest::testExecuteJobSignals() entering
QDEBUG : HelperTest::testExecuteJobSignals() Checking if action  "org.kde.kf5auth.autotest.longaction" exists
QDEBUG : HelperTest::testExecuteJobSignals() Caller ID: "a random caller Id"
QDEBUG : HelperTest::testExecuteJobSignals() Long action running. Don't be scared, this action takes 2 seconds to complete
PASS   : HelperTest::testExecuteJobSignals()
INFO   : HelperTest::testActionData() entering
QDEBUG : HelperTest::testActionData() Checking if action  "org.kde.kf5auth.autotest.echoaction" exists
QDEBUG : HelperTest::testActionData() Caller ID: "a random caller Id"
QDEBUG : HelperTest::testActionData() Echo action running
QWARN  : HelperTest::testActionData() QSocketNotifier: Socket notifiers cannot be enabled or disabled from another thread
^CQFATAL : HelperTest::testActionData() Received signal 2
         Function time: 3563ms Total time: 5657ms
FAIL!  : HelperTest::testActionData() Received a fatal error.
   Loc: [Unknown file(0)]
Totals: 3 passed, 1 failed, 0 skipped, 0 blacklisted
********* Finished testing of HelperTest *********

I don't know if this is a structural error or if it's just the test that should be rewritten or skipped on OS X.

Also, I've noticed that applications like ksysguard5 that rely on a helper will authorise correctly in the main app, and then post an error:

DBus Backend error: connection to helper failed: "Not connected to D-Bus server"

Does this mean those applications are not written to comply with platforms where authorisation takes place in the host, or in a helper process they activate in a different way via DBus?


  • 0
  • 1
  • 0
  • 1
Description From Last Updated
Aleix Pol Gonzalez
René J.V. Bertin
René J.V. Bertin
René J.V. Bertin
René J.V. Bertin
René J.V. Bertin
René J.V. Bertin
Review request changed

Status: Closed (submitted)

Change Summary:

Submitted with commit 5858ee8b3ee4ab6174e4893f35ae8e17d2ad3523 by R.J.V. Bertin to branch master.