pEp macOS Desktop adapter
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

107 lines
2.8 KiB

2 years ago
2 years ago
2 years ago
2 years ago
12 months ago
12 months ago
12 months ago
12 months ago
12 months ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
  1. # p≡p macOS Desktop adapter
  2. This adapter sports three main features:
  3. - p≡p API via Apple XPC
  4. - p≡p Update Client
  5. Missing Features
  6. - p≡p API via p≡p JSON adapter (still provided by miniadapter)
  7. ## Deployment
  8. PER_MACHINE_DIRECTORY="/Library/Application Support/pEp"
  9. PER_USER_DIRECTORY=$HOME/.pEp
  10. This software is supporting macOS 10.10 and later.
  11. ## Required Tools
  12. For building the engine, you need a working python3 environment and all dependencies:
  13. ```
  14. sudo port install git
  15. sudo port install gmake
  16. sudo port install autoconf
  17. sudo port install libtool
  18. sudo port install automake
  19. sudo port install wget
  20. sudo port install gsed
  21. pushd ~
  22. git clone https://gitea.pep.foundation/fdik/yml2
  23. popd
  24. curl https://sh.rustup.rs -sSf | sh
  25. ```
  26. add this to ~/.profile (create if it doesn't exist):
  27. ```
  28. source $HOME/.cargo/env
  29. export PATH="$HOME/.cargo/bin:$PATH"
  30. ```
  31. restart your Console (!)
  32. ```
  33. sudo port install pkgconfig
  34. rustup update
  35. ```
  36. Install Xcode (if not installed already)
  37. ## Apple IDs & Certificates
  38. ### Apple ID
  39. You need to have an Apple ID (connected to pEp team account) configured in Xcode . Ask `#service`, if you want to be added to the team account.
  40. ## Build Dependencies
  41. ```
  42. mkdir src_pEpMacOSAdapter
  43. cd src_pEpMacOSAdapter
  44. git clone https://gitea.pep.foundation/buff/common-dependency-build-helpers-4-apple-hardware.git
  45. git clone http://pep-security.lu/gitlab/iOS/pep-toolbox.git
  46. git clone https://pep-security.lu/gitlab/iOS/CocoaLumberjack
  47. git clone https://pep-security.lu/gitlab/misc/libetpan.git
  48. git clone https://pep-security.lu/gitlab/misc/sqlite.git
  49. git clone https://gitea.pep.foundation/pEp.foundation/pEpEngine
  50. git clone https://gitea.pep.foundation/pep.foundation/pEpObjCAdapter.git
  51. git clone https://gitea.pep.foundation/fdik/pEpMacOSAdapter.git
  52. ```
  53. ## Build
  54. ### Using Xcode UI
  55. `open pEpMacOSAdapter/pEpMacOSAdapter.xcworkspace/`
  56. Build scheme "All" of pEpMacOSAdapter.xcworkspace
  57. ### Using terminal
  58. `xcodebuild -workspace "pEpMacOSAdapter.xcworkspace" -scheme "All" -configuration RELEASE`
  59. (or DEBUG)
  60. ### Build Dir & Build Artefacts
  61. You can find the build artefacts in the `build` folder odf the project or the used submodules:
  62. src_pEpMacOSAdapter/pEpMacOSAdapter/build/foundation.pEp.adapter.macOS.xpc
  63. src_pEpMacOSAdapter/pEpMacOSAdapter/Submodules/pEpNotifications/build/p≡p updates.app
  64. ## Implementation
  65. The implementation is split in to parts:
  66. 1. the working code is in pEpMacOSAdapter; the implementation is in Objective C
  67. 1. the User Interface is in pEpNotifications; the implementation is in Swift
  68. ### PEPMacOSAdapterProtocol, implemented with XPC
  69. see pEpMacOSAdapter/PEPMacOSAdapterProtocol.h
  70. This protocol is provided to the User Interface to get informed when a download was happening.
  71. When a subscription is active updateNow() can be used to search for immediate updates.