| 1 |
RESUME |
| 2 |
------ |
| 3 |
Scripts to build binary digiKam package for MacOS |
| 4 |
|
| 5 |
These scripts build a binary digiKam package for MacOS using Macports |
| 6 |
environment and Packages application. |
| 7 |
|
| 8 |
These scripts follow instructions from Qt bundle deployment for MacOS as shared libraries |
| 9 |
available at this url: https://doc.qt.io/qt-5/osx-deployment.html |
| 10 |
|
| 11 |
|
| 12 |
AUTHORS |
| 13 |
------- |
| 14 |
|
| 15 |
(c) 2015 by Shanti <listaccount at revenant dot org> |
| 16 |
(c) 2015-2026 by Gilles Caulier <caulier dot gilles at gmail dot com> |
| 17 |
|
| 18 |
|
| 19 |
DESCRIPTION |
| 20 |
----------- |
| 21 |
These files and scripts are used to make a binary package of the digiKam |
| 22 |
Software Collection for MacOS. In addition to this README, there are |
| 23 |
comments in the scripts that provide some additional explanations for |
| 24 |
how they work. |
| 25 |
|
| 26 |
|
| 27 |
BUNDLE CONTENTS |
| 28 |
--------------- |
| 29 |
|
| 30 |
Note: the bundle is relocatable. |
| 31 |
|
| 32 |
Bundle is composed of two main application containers (digikam and showfoto), to start from the macOS lauchpad. |
| 33 |
The digikam sub-container include all resources shared with showfoto. |
| 34 |
The showfoto sub-container directories are linked to the digikam sub-container to reduce used-space. |
| 35 |
The host directory is called "digiKam.org" and not "digiKam" to allow Showfoto icon to be show on macOS lauchpad, |
| 36 |
else only digiKam is visible. |
| 37 |
|
| 38 |
digiKam.org |
| 39 |
├── digikam.app digiKam sub-container |
| 40 |
│ └── Contents |
| 41 |
│ ├── bin Extra binaries |
| 42 |
│ ├── etc Extra configuration |
| 43 |
│ ├── lib Libraries and extra dependencies |
| 44 |
│ ├── libexec Run time dependencies |
| 45 |
│ │ └── qt5 |
| 46 |
│ │ ├── lib |
| 47 |
│ │ └── plugins Plugins |
| 48 |
│ │ ├── bearer |
| 49 |
│ │ ├── designer |
| 50 |
│ │ ├── digikam digiKam and Showfoto DPlugins |
| 51 |
│ │ │ ├── bqm |
| 52 |
│ │ │ ├── dimg |
| 53 |
│ │ │ ├── editor |
| 54 |
│ │ │ ├── generic |
| 55 |
│ │ │ └── rawimport |
| 56 |
│ │ ├── generic |
| 57 |
│ │ ├── iconengines |
| 58 |
│ │ ├── imageformats |
| 59 |
│ │ ├── kauth |
| 60 |
│ │ ├── kf5 |
| 61 |
│ │ ├── platforms |
| 62 |
│ │ ├── platformthemes |
| 63 |
│ │ ├── printsupport |
| 64 |
│ │ ├── sqldrivers |
| 65 |
│ │ └── styles |
| 66 |
│ ├── MacOS digiKam binary |
| 67 |
│ ├── Resources Data and resource files |
| 68 |
│ │ ├── applications |
| 69 |
│ │ ├── data |
| 70 |
│ │ ├── digikam |
| 71 |
│ │ ├── kf5 |
| 72 |
│ │ ├── knotifications5 |
| 73 |
│ │ ├── kservices5 |
| 74 |
│ │ ├── kservicetypes5 |
| 75 |
│ │ ├── kxmlgui5 |
| 76 |
│ │ ├── lensfun Lens auto correction profiles |
| 77 |
│ │ ├── locale |
| 78 |
│ │ ├── mime |
| 79 |
│ │ ├── opencv4 |
| 80 |
│ │ ├── plugins |
| 81 |
│ │ ├── showfoto |
| 82 |
│ │ └── solid |
| 83 |
│ └── share Shared files |
| 84 |
└── showfoto.app Showfoto sub-container |
| 85 |
└── Contents |
| 86 |
├── bin -> ../../digikam.app/Contents/bin |
| 87 |
├── etc -> ../../digikam.app/Contents/etc |
| 88 |
├── lib -> ../../digikam.app/Contents/lib |
| 89 |
├── libexec -> ../../digikam.app/Contents/libexec |
| 90 |
├── MacOS Showfoto binary |
| 91 |
├── Resources -> ../../digikam.app/Contents/Resources |
| 92 |
└── share -> ../../digikam.app/Contents/share |
| 93 |
|
| 94 |
REQUIREMENTS |
| 95 |
------------ |
| 96 |
|
| 97 |
To build bundle you need a macOS install in a real Apple computer. |
| 98 |
|
| 99 |
The scripts build digiKam with MacPorts, so you will need Xcode and the other |
| 100 |
prerequisites for Macports. |
| 101 |
|
| 102 |
See this url for details: https://guide.macports.org/#installing.xcode. |
| 103 |
|
| 104 |
For all other Macports requirements, see https://www.macports.org/install.php. |
| 105 |
|
| 106 |
You will also need to install Packages software which does the actual packaging of the files needed to install digiKam: |
| 107 |
|
| 108 |
https://s.sudre.free.fr/Software/Packages/about.html |
| 109 |
|
| 110 |
IMPORTANT: |
| 111 |
- You must set the minimal MacOS target with relevant SDK installed for backward compatibility. |
| 112 |
- You must set the digiKam git tags to checkout right source code to package. |
| 113 |
- You must set the option to host debug symbols or not in package. |
| 114 |
|
| 115 |
NOTE: Look in config.sh file for settings details. |
| 116 |
|
| 117 |
|
| 118 |
HERE THERE BE DRAGONS |
| 119 |
--------------------- |
| 120 |
Use these scripts at your own risk. For example, both scripts contain |
| 121 |
"rm -rf" (to clear previous builds) -- a mistake could wipe your drive. |
| 122 |
|
| 123 |
|
| 124 |
COMPONENTS |
| 125 |
---------- |
| 126 |
There are 4 main scripts to be run by the user. 2 first ones installs |
| 127 |
MacPorts and all dependencies, next one digiKam, and last one makes a |
| 128 |
PKG binary installer for MacOS using Packages. |
| 129 |
|
| 130 |
|
| 131 |
SCRIPT DESCRIPTIONS |
| 132 |
------------------- |
| 133 |
All scripts should be run from within the digikam-package directory. |
| 134 |
|
| 135 |
* 01-build-macports.sh: |
| 136 |
|
| 137 |
This script downloads and configures a custom non-root install |
| 138 |
of MacPorts to /opt/digikam.org._arch_. |
| 139 |
|
| 140 |
* 02-build-extralibs.sh: |
| 141 |
|
| 142 |
This script configures, and compile a custom non-root install to /opt/digikam.org._arch_ |
| 143 |
of extra libraries, including KF5 frameworks, and most important photo management |
| 144 |
libs used by digiKam as Exiv2 and LensFun. |
| 145 |
|
| 146 |
* 03-build-digikam.sh: |
| 147 |
|
| 148 |
This script configures, and compile a custom non-root install of digiKam to |
| 149 |
/opt/digikam.org._arch_. |
| 150 |
|
| 151 |
* 04-build-installer.sh: |
| 152 |
|
| 153 |
Once you've successfully built digiKam, /opt/digikam.org._arch_ may contain over 10GB of files. |
| 154 |
This script grabs the ~250MB needed to run digiKam and Showfoto, |
| 155 |
and places them in ./installer/opt. These include applications documentations |
| 156 |
and translations. |
| 157 |
|
| 158 |
This script creates Applescript launch applications for the programs that will |
| 159 |
be run by the user (digiKam, Showfoto, etc), and preinstall/postinstall |
| 160 |
scripts in ./installer. |
| 161 |
|
| 162 |
The launcher applications: |
| 163 |
1) Update desktop.org files cache system with kbuildsyscoca5. |
| 164 |
2) set "DYLD_IMAGE_SUFFIX=_debug" if the digikam port was built with the |
| 165 |
+debug variant. |
| 166 |
|
| 167 |
This script also create the pre-install and post-install scripts that are run |
| 168 |
when the package is installed. They delete any pre-existing /opt/digikam.org._arch_, |
| 169 |
delete and recreate /Applications/digiKam.org. |
| 170 |
|
| 171 |
Finally, this script sets the version number, and runs Packages to |
| 172 |
put everything together in the bundle. |
| 173 |
|
| 174 |
Depending of configuration done in config.sh, this script is able to upload automatically |
| 175 |
the bundle file on files.kde.org digiKam area through ssh. A valid ssh key configured |
| 176 |
with remote KDE server need to be set previously with the account. You can load ssh key |
| 177 |
at startup following instruction give at this url: |
| 178 |
|
| 179 |
https://unix.stackexchange.com/questions/90853/how-can-i-run-ssh-add-automatically-without-password-prompt |
| 180 |
|
| 181 |
Note: the bundle can be signed with GPG. You must setup your private and public keys before |
| 182 |
and put your passphare to a text file (~/.gnupg/dkorg-gpg-pwd.txt) |
| 183 |
|
| 184 |
* rll.py |
| 185 |
|
| 186 |
Run by 04-build-installer.sh. It is a Python script that takes a list of binaries |
| 187 |
and libraries supplied by 04-build-installer.sh and recursively lists the dylibs on |
| 188 |
which they depend, and their dependencies, etc.. Adapted with minimal |
| 189 |
modification (mostly deleting stuff) from |
| 190 |
https://github.com/mixxxdj/mixxx/blob/master/build/osx/otool.py. |
| 191 |
|
| 192 |
* makeall.sh |
| 193 |
|
| 194 |
This script permit to build whole package from scratch (all stages). |
| 195 |
|
| 196 |
* update.sh |
| 197 |
|
| 198 |
This script re-build only digiKam and package (2 last stages). |
| 199 |
|
| 200 |
|
| 201 |
LICENSES |
| 202 |
-------- |
| 203 |
rll.py, like the otool.py source from which it has been adapted, is licensed |
| 204 |
under GNU General Public License version 2. |
| 205 |
|
| 206 |
The scripts and other contents that we have created are licensed |
| 207 |
under the GNU General Public License version 2, or any later version. |