- Install homebrew from https://brew.sh/ (follow the instructions there)
- tap the https://invent.kde.org/packaging/homebrew-kde/ repo,
brew tap kde-mac/kde https://invent.kde.org/packaging/homebrew-kde.git
brew edit okular
, workaround now is to comment out or delete the linedepends_on "chmlib"
(won't compile on macos arm64 for now as of 2021-08-18), then save (if using vim you need to first pressi
to insert/type, when saving then<esc>
then:wq
then<enter>
.brew install okular
, wait for stuff to compile and/or install- It may ask for keychain credentials (to sign the binaries? because of mac arm64 security policy https://eclecticlight.co/2021/01/26/when-you-dont-have-permission-to-run-an-app-on-an-m1-mac/)
$(brew --repo kde-mac/kde)/tools/do-caveats.sh
- Now okular is in your
$HOME/Applications/KDE
folder, and will show up in Launchpad! You can view pdf, djvu, etc documents.
-
-
Save 7468696e6b/ec8fa5d6cdb4e80633b9df95869b70c0 to your computer and use it in GitHub Desktop.
For qt5 cmake error, where did you install qt5? It's better if you check the error log. For me, it's something like /opt/homebrew/lib/cmake/Qt5Gui/Qt5GuiConfig.cmake
contains get_filename_component(_qt5Gui_install_prefix ${CMAKE_CURRENT_LIST_DIR}/../../../ ABSOLUTE)
but it's invalid.
For the brew tap, you need to
brew untap kde-mac/kde --force
brew tap kde-mac/kde https://github.com/JakkuSakura/homebrew-kde
Then it should be fine
/opt/homebrew/lib/cmake//Qt6BuildInternals/StandaloneTests/Qt5CompatTestsConfig.cmake
is what is obtained by find -L /opt/homebrew/lib/cmake/ -name 'Qt5*.cmake'
. It says
% cat /opt/homebrew/lib/cmake//Qt6BuildInternals/StandaloneTests/Qt5CompatTestsConfig.cmake
# Copyright (C) 2024 The Qt Company Ltd.
# SPDX-License-Identifier: BSD-3-Clause
# TODO: Ideally this should look for each Qt module separately, with each module's specific version,
# bypassing the Qt6 Config file, aka find_package(Qt6SpecificFoo) repated x times. But it's not
# critical.
find_package(Qt6 6.8.2
COMPONENTS Core5Compat)
.
The qt5/6 is as follows:
lrwxr-xr-x 1 sakuraim admin 20 3 20 17:50 qt -> ../Cellar/qt/6.8.2_1
lrwxr-xr-x 1 sakuraim admin 24 3 21 04:47 qt5 -> ../Cellar/qt@5/5.15.16_1
lrwxr-xr-x 1 sakuraim admin 20 3 20 17:50 qt6 -> ../Cellar/qt/6.8.2_1
lrwxr-xr-x 1 sakuraim admin 24 3 21 04:41 qt@5 -> ../Cellar/qt@5/5.15.16_1
lrwxr-xr-x 1 sakuraim admin 20 3 20 17:50 qt@6 -> ../Cellar/qt/6.8.2_1
by % ls -la /opt/homebrew/opt/
. The qt5 is introduced for 2c1970eb750 qt@5: update 5.15.16_1 bottle
at /opt/homebrew/Library/Taps/homebrew/homebrew-core/Formula/q
. I guess it is /opt/homebrew/Cellar/qt@5/5.15.16_1
since it says % brew uninstall --ignore-dependencies qt@5
Uninstalling /opt/homebrew/Cellar/qt@5/5.15.16_1... (10,849 files, 341.7MB)
ls says
% ls /opt/homebrew/Cellar/qt@5/5.15.16_1
Frameworks doc
INSTALL_RECEIPT.json include
LICENSE.FDL lib
LICENSE.GPL3-EXCEPT libexec
LICENSE.GPLv2 mkspecs
LICENSE.GPLv3 phrasebooks
LICENSE.LGPLv21 plugins
LICENSE.LGPLv3 qml
LICENSE.QT-LICENSE-AGREEMENT sbom.spdx.json
README share
bin translations
Hope it works.
Some progress:
$ brew link --force qt@5
$ sudo ln -s $(brew --prefix qt@5)/mkspecs /usr/local/mkspecs
$ sudo ln -s $(brew --prefix qt@5)/plugins /usr/local/plugins
Then, by your shell script, it works after ln -s /opt/homebrew/opt/qt@5 /opt/homebrew/opt/qt5
. I could install kf5-ki18n.rb.
But, now another problem:
==> Installing kf5-kiconthemes from kde-mac/kde
==> cmake -G Ninja -B build -S . -D BUILD_QCH=ON -D BUILD_TESTING=ON -D BUILD_TE
Last 15 lines from /Users/sakuraim/Library/Logs/Homebrew/kf5-kiconthemes/01.cmake:
"KF5Archive", but CMake did not find one.
` Could not find a package configuration file provided by "KF5Archive"` ` (requested version 5.111.0) with any of the following names:`
KF5ArchiveConfig.cmake
kf5archive-config.cmake
` Add the installation prefix of "KF5Archive" to CMAKE_PREFIX_PATH or set` ` "KF5Archive_DIR" to a directory containing one of the above files. If` ` "KF5Archive" provides a separate development package or SDK, be sure it has` ` been installed.`
``
-- Configuring incomplete, errors occurred!
Some idea?
After brew install kf5-karchive.rb
in your fork repository, it delivers some errors for phonon
.
I bypassed the errors of phonon by editing the header files of enum to explicity use unsigned. It's like this: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=272029.
I think I managed to install okular, but I still cannot print PDF files in a just size. Thanks a lot!
Note that I also needed things including ln -s /opt/homebrew/lib/libKF5Archive.5.dylib /opt/homebrew/Cellar/kdoctools/5.109.0/bin/../../../../opt/karchive/lib/libKF5Archive.5.dylib
.
The qt5 cmake errors cannot be removed. I tried to ln -s but in vain. I had troubles with the "brew tap" commands as well. Is it,
brew tap jakkusakura/kde https://github.com/JakkuSakura/homebrew-kde.git --force-auto-update
or so?