Closed merrcury closed 2 years ago
When someone donates one 😝 In all seriousness when someone with an M1 wants to do the code contribution and testing is when support will be added.
I also don't know the state of Qt on M1s
Qt 6.2 will support Apple Silicon (arm64). https://bugreports.qt.io/browse/QTBUG-85279
Qt 6.2 will support Apple Silicon (arm64). https://bugreports.qt.io/browse/QTBUG-85279
That's sweet.
for those who concern, i was able to compile flameshot for M1. Looks like brew is already have an ARM formula for qt@5: https://formulae.brew.sh/formula/qt@5 so, i just used the script from README.md:
brew install qt5
brew install cmake
mkdir build
cd build
cmake ../
make
note, that i was need to use CMAKE_PREFIX_PATH
to set a correct path to qt5 that was installed by homebrew
how can I help to make this released to the release page ?
You will need to update the CI scripts
@petrukngantuk we use Github Actions to build the Flameshot for different platforms. You can find all our scripts here:
https://github.com/flameshot-org/flameshot/tree/master/.github/workflows
There is already a Mac script which you might find it very handy
well after some digging, the issue was the github actions workflows still not support macos arm64 arch, I can help with building it using self hosted runner, but it's quite tricky and not long term solution, wdyt ?
well after some digging, the issue was the github actions workflows still not support macos arm64 arch, I can help with building it using self hosted runner, but it's quite tricky and not long term solution, wdyt ?
Is it possible to cross-compile Apple Silicon(ARM64) binaries on Intel-based Macs (x86_64)?
I think maybe we could move the Mac build to TravisCI if it's still free for FOSS
About Qt official release, Qt 5.15.4 support MacOS Big Sur ARM64, but you must have a commercial license.
The article mentions "Some patches already went into Qt 5, so Qt 5.15.4 and above should build and run by passing -device-option QMAKE_APPLE_DEVICE_ARCHS=arm64 to configure. Note that this configuration is not tested in CI, and is hence unsupported at this point."
The community version will not support MacOS ARM64 and Windows ARM64 until Qt6.2. https://wiki.qt.io/New_Features_in_Qt_6.2
Most CI platforms currently do not have a MacOS ARM64 environment. Therefore, there are only two ways left:
Plus, The native compiled ARM64 version can be found here.
brew install qt@5 brew install cmake mkdir build cd build cmake ../ make
There is also a macdeployqt-universal tool that can be used.
@mmahmoudian @borgmanJeremy Qt 6.2 LTS released. https://www.qt.io/blog/qt-6.2-lts-released it's mentioned at Qt blog,
Qt 6.2 fully supports macOS on Apple Silicon. Qt now makes it easy to create universal binaries and to develop for macOS on both Intel and Apple Silicon. Of course, that version is also fully tested in our CI system. It has always been possible to run Qt applications on Apple silicon via the Rosetta layer, but Qt 6.2 now provides full support to run natively on the Apple silicon.
Any plan to upgrade to Qt 6.2 shortly?
It's not in our plan for the upcoming release. Perhaps the release after that?
I ended up getting an M1 air and the lastest master branch is working perfectly on it, it did not require an upgrade to qt6.2. The only thing to figure out is if we need to update the CI.
I ended up getting an M1 air and the lastest master branch is working perfectly on it, it did not require an upgrade to qt6.2. The only thing to figure out is if we need to update the CI.
strange for me, when i opened the app is not doing anything, no errors and not opening.
Did you try compiling from source?
Did you try compiling from source?
no, just with the dmg file from this github repo https://github.com/flameshot-org/flameshot/releases
Okay that goes back to needing to update the CI so it builds a package for aarch64 in addition to x86. I think if you build from source it will work.
I tried many approach to do cross-compile in qt5, but no luck for success, always got a problem when it linking the binary, maybe lack of knowledge from myself how to properly crosscompile qt5
you can check it out here
Maybe this helps? https://github.com/crystalidea/macdeployqt-universal
Edit: Why do you uninstall qt@5 with brew before building? I think the problem is cmake is looking there for the qt tools used in generating the MOC files.
Maybe this helps? https://github.com/crystalidea/macdeployqt-universal
Edit: Why do you uninstall qt@5 with brew before building? I think the problem is cmake is looking there for the qt tools used in generating the MOC files.
will try to look at that universal macdeployqt
I just realized that there is hardcoded brew --prefix
in the ~2/3 place in cmakelist.txt, and its make custom qt5 installation directory path not working as expected and will try to depend my understanding about cmake first
Since flameshot is working perfectly fine on Rosetta I am going to close this.
@borgmanJeremy why are you closing this when Apple Silicon M1 support is still not native to bitcoin core... :/
Because I don't intend to work on this. It is running fine on Rosetta.
If someone else can figure out how to build a universal image in our CI I'll happily merge that, but don't have time to work this when their is no real value.
Because I don't intend to work on this. It is running fine on Rosetta.
If someone else can figure out how to build a universal image in our CI I'll happily merge that, but don't have time to work this when their is no real value.
Functioning in Rosetta is one thing, but by not running natively it causes additional power draw from the system, especially when the helper is running in the background constantly. So, the "real value" is having the system perform better and not draining the battery as fast. For heavy users, that drain may be more of an issue than it is for the occasional/casual user.
especially when the helper is running in the background constantly
You can invoke Flameshot in a one-off mode (explained in the release notes of v11.0.0) which will remove the background process as soon as Flameshot is closed.
Regarding the M1, it would be nice if some of you can work on it and add M1 support to this Free and Libre OpenSource Software. Any form of contribution is most welcome 🤗
Although nice to have - in my experience running flameshot under rosetta works flawlessly and does not noticeably impact energy consumption on an M1 device. (chrome however does a lot ... 😄 )
Looks like recently Public Beta of M1 Mac runners for Github actions were made available. Would this help in getting flameshot for Mac M1s natively without having to use rosetta? @borgmanJeremy
that would be great
+1
When can we expect native support of flameshot for Apple Silicon Processors?