Bug 496136 - Heaptrack not able to build on MacOS anymore
Summary: Heaptrack not able to build on MacOS anymore
Status: REPORTED
Alias: None
Product: Heaptrack
Classification: Applications
Component: general (other bugs)
Version First Reported In: 1.5.0
Platform: Homebrew (macOS) macOS
: NOR normal
Target Milestone: ---
Assignee: Milian Wolff
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-11-11 16:28 UTC by diehard2
Modified: 2025-10-25 22:29 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description diehard2 2024-11-11 16:28:40 UTC
SUMMARY

I ran the steps in the github instructions for MacOS and the kde dependencies don't build as expected. There's a bug report in the heaptrack issue tracker about this from a few months ago, but its unacknowledged. I filed a separate bug for the brew issue here (https://bugs.kde.org/show_bug.cgi?id=496134). Documentation in the git repo should probably be updated to say that its not currently buildable on MacOS

STEPS TO REPRODUCE
1. 

brew install qt@5

# prepare tap
brew tap kde-mac/kde https://invent.kde.org/packaging/homebrew-kde.git
"$(brew --repo kde-mac/kde)/tools/do-caveats.sh"

# install dependencies
brew install kde-mac/kde/kf5-kcoreaddons kde-mac/kde/kf5-kitemmodels kde-mac/kde/kf5-kconfigwidgets \
             kde-mac/kde/kf5-kio kde-mac/kde/kdiagram \
             extra-cmake-modules ki18n threadweaver \
             boost zstd gettext



OBSERVED RESULT

ast 15 lines from /Users/sdanauskas/Library/Logs/Homebrew/kf5-kservice/01.cmake:
-- Could not set up the appstream test. appstreamcli is missing.
CMake Error at CMakeLists.txt:57 (find_package):
  Could not find a package configuration file provided by "KF5I18n"
  (requested version 5.111.0) with any of the following names:

    KF5I18nConfig.cmake
    kf5i18n-config.cmake

  Add the installation prefix of "KF5I18n" to CMAKE_PREFIX_PATH or set
  "KF5I18n_DIR" to a directory containing one of the above files.  If
  "KF5I18n" provides a separate development package or SDK, be sure it has
  been installed.


-- Configuring incomplete, errors occurred!




EXPECTED RESULT

success

SOFTWARE/OS VERSIONS
macOS:  14.7 (Sonoma)
Qt Version: 5

ADDITIONAL INFORMATION
Comment 1 Marius P 2024-11-11 18:16:20 UTC
Hello.
1. macOS x86_64 or arm64?
2. Can you build https://invent.kde.org/sdk/heaptrack using KDE Craft on macOS https://community.kde.org/Craft https://community.kde.org/Get_Involved/development/Mac ?
Thanks.
Comment 2 diehard2 2024-11-11 21:29:04 UTC
(In reply to Marius P from comment #1)
> Hello.
> 1. macOS x86_64 or arm64?
> 2. Can you build https://invent.kde.org/sdk/heaptrack using KDE Craft on
> macOS https://community.kde.org/Craft
> https://community.kde.org/Get_Involved/development/Mac ?
> Thanks.

Hi Marius, I'm on ARM64. I tried using craft and it started to build things, but eventually stopped on

CRAFT: [13:24:21 ~/heaptrack/build]craft heaptrack
Craft               : /Users/sdanauskas/CraftRoot
ABI                 : macos-clang-arm64
Download directory  : /Users/sdanauskas/CraftRoot/download
Cache repository    : https://files.kde.org/craft/Qt5/24.03/macos/clang/arm64
KColorScheme was added in KF6, hence it is not available for lower Qt versions
========================================================================================================================
*** Handling package: extragear/heaptrack, action: all ***
*** Action: fetch-binary for extragear/heaptrack ***
Could not find extragear/heaptrack=1.4.0 in https://files.kde.org/craft/Qt5/24.03/macos/clang/arm64/RelWithDebInfo
Could not find extragear/heaptrack=1.4.0 in https://files.kde.org/craft/Qt5/24.03/macos/clang/arm64/Release
*** extragear/heaptrack not found in cache ***
*** Action: fetch for extragear/heaptrack ***
*** Craft all succeeded: extragear/heaptrack after 0s ***
'SIG'
Traceback (most recent call last):
  File "/Users/sdanauskas/CraftRoot/craft/bin/craft.py", line 424, in <module>
    success = main(timer)
              ^^^^^^^^^^^
  File "/Users/sdanauskas/CraftRoot/craft/bin/craft.py", line 406, in main
    if not CraftCommands.run(package, action, tempArgs):
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/sdanauskas/CraftRoot/craft/bin/CraftCommands.py", line 465, in run
    if not handlePackage(info, action, directTargets=directTargets):
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/sdanauskas/CraftRoot/craft/bin/CraftCommands.py", line 111, in handlePackage
    if not doExec(package, action):
           ^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/sdanauskas/CraftRoot/craft/bin/CraftCommands.py", line 60, in doExec
    ret = package.instance.runAction(action)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/sdanauskas/CraftRoot/craft/bin/Package/PackageBase.py", line 275, in runAction
    if not getattr(self, step)():
           ^^^^^^^^^^^^^^^^^^^^^
  File "/Users/sdanauskas/CraftRoot/craft/bin/Source/MultiSource.py", line 44, in fetch
    return self._sourceClass.fetch(self)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/sdanauskas/CraftRoot/craft/bin/Source/ArchiveSource.py", line 107, in fetch
    if self.__checkFilesPresent(filenames):
       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/sdanauskas/CraftRoot/craft/bin/Source/ArchiveSource.py", line 90, in __checkFilesPresent
    if type(self.subinfo.targetDigestUrl()) == tuple:
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/sdanauskas/CraftRoot/craft/bin/info.py", line 240, in targetDigestUrl
    out = (out, CraftHash.HashAlgorithm.getAlgorithmFromFile(out[0]))
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/sdanauskas/CraftRoot/craft/bin/Utils/CraftHash.py", line 32, in getAlgorithmFromFile
    return cls.__getitem__(ext[1:].upper())
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/sdanauskas/CraftRoot/lib/Python.framework/Versions/3.11/lib/python3.11/enum.py", line 790, in __getitem__
    return cls._member_map_[name]
           ~~~~~~~~~~~~~~~~^^^^^^
KeyError: 'SIG'
Craft stopped with out completing ['extragear/heaptrack']
Comment 3 diehard2 2024-11-12 16:25:24 UTC
I asked a friend to check on their X86 mac and they're seeing the same errors with Craft
Comment 4 diehard2 2024-11-14 19:01:36 UTC
Craft also failed for both me and a friend on MacOS.  He was on an x86 Mac. The error is in this comment

https://bugs.kde.org/show_bug.cgi?id=496136#c2
Comment 5 Milian Wolff 2024-11-15 10:23:19 UTC
I guess someone should update the craft recipes to allow building against qt6/kf6?
Comment 6 Pepper Lebeck-Jobe 2025-10-25 22:29:10 UTC
I just wanted to mention that I'm also running into this problem where I can't get the heaptrack_gui to build on a Mac.

It seems like the advice in the README.md is out of date.

For example, it still says to try and use `brew`, but comments on this issue suggest using `craft` and then conclude that the "craft recipies" need to be updated to build with qt6 and kf6. But, that was last November.

I'm not familiar enough with these projects to understand what "craft recipes" means. But, I have gathered from trying to go through the process of running `craft heaptrack` that there is something similar to brew Formulae but for this custom python `craft` package manager just for kde packages?

In the meantime, shall I send a patch to the README.md advising MacOS users that they are not going to be able to build the GUI until further notice?