# Creating a Slicer binary for Apple Silicon M1

**URL:** <https://discourse.slicer.org/t/creating-a-slicer-binary-for-apple-silicon-m1/24821>\
**Category:** Support\
**Created:** [August 18, 2022, 4:13pm UTC](https://discourse.slicer.org/t/creating-a-slicer-binary-for-apple-silicon-m1/24821 "2022-08-18T16:13:01Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![efu98](https://avatars.discourse-cdn.com/v4/letter/e/46a35a/32.png) [@efu98](https://discourse.slicer.org/u/efu98)\
**Post date:** [August 18, 2022, 4:13pm UTC](https://discourse.slicer.org/t/creating-a-slicer-binary-for-apple-silicon-m1/24821/1 "2022-08-18T16:13:01Z")

</div>

Hello!  
I am trying to create a binary of a custom application based on Slicer for Apple Silicon M1. I have managed built Qt5 (using this [tutorial](https://www.reddit.com/r/QtFramework/comments/ll58wg/how_to_build_qt_creator_for_macos_arm64_a_guide/)) and installed the other prerequisites. However, when I try building Slicer, I get the following errors:

 ![Screen Shot 2022-08-18 at 12.08.41 PM](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/8/3/83d66c81d231c6b1ff005b3ba2edb11dd29d287e.png)

Here is the cmake command I am using :

```auto
cmake \  
-DCMAKE_OSX_DEPLOYMENT_TARGET:STRING=12.1 \
-DSlicer_USE_SYSTEM_OpenSSL:BOOL=ON \
-DQt5_DIR:PATH=/Users/efu/qt5-5.15-macOS-release/qtbase/lib/cmake/Qt5 \
-DCMAKE_OSX_ARCHITECTURES="arm64" \
-DOPENSSL_ROOT_DIR:PATH=/opt/homebrew/opt/openssl/ \
/Users/efu/Slicer

```

Has anyone come across this problem? Is there a way to fix it?

Thank you!

---

<div class="post-metadata">

**Author:** ![pieper](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/pieper/32/8_2.png) [@pieper](https://discourse.slicer.org/u/pieper)\
**Post date:** [August 18, 2022, 4:36pm UTC](https://discourse.slicer.org/t/creating-a-slicer-binary-for-apple-silicon-m1/24821/2 "2022-08-18T16:36:08Z")

</div>

That’s a python build error so it should be fixable. You may be able to use the system python, or get a (newer?) python and edit [this file and related places](https://github.com/Slicer/Slicer/blob/main/SuperBuild/External_python.cmake).

You will no doubt hit more issues when you get to CTK and the Slicer core codebase. It would be great if you could start a draft pull request with any changes you need to make to the Slicer build system so other people can test / contribute.

---

<div class="post-metadata">

**Author:** ![efu98](https://avatars.discourse-cdn.com/v4/letter/e/46a35a/32.png) [@efu98](https://discourse.slicer.org/u/efu98)\
**Post date:** [August 18, 2022, 4:45pm UTC](https://discourse.slicer.org/t/creating-a-slicer-binary-for-apple-silicon-m1/24821/3 "2022-08-18T16:45:19Z")

</div>

Thank you! Will using the system python prevent me from creating a functional binary? I am a bit confused about what can be installed directly using homebrew and what has to be built “by hand”.

---

<div class="post-metadata">

**Author:** ![pieper](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/pieper/32/8_2.png) [@pieper](https://discourse.slicer.org/u/pieper)\
**Post date:** [August 18, 2022, 4:50pm UTC](https://discourse.slicer.org/t/creating-a-slicer-binary-for-apple-silicon-m1/24821/4 "2022-08-18T16:50:59Z")

</div>

> [@efu98](#):
>
> Will using the system python prevent me from creating a functional binary?

It might but probably it can be packaged like any python build. Best would be to find a way to build from source using a version that works on the target architecture.

As you’ve seen the Slicer build system is big and it depends on several other large projects so it make take a while to port everything.
