# How to embed Info.plist in a simple Mac binary file

**URL:** https://discourse.cmake.org/t/how-to-embed-info-plist-in-a-simple-mac-binary-file/512
**Category:** Usage
**Tags:** os:macos
**Created:** [January 15, 2020, 11:36pm UTC](https://discourse.cmake.org/t/how-to-embed-info-plist-in-a-simple-mac-binary-file/512 "2020-01-15T23:36:18Z")
**Posts on this page:** 1
**Showing post:** 2

<div class="post-metadata">

### Author: ![smokris](https://discourse.cmake.org/user_avatar/discourse.cmake.org/smokris/32/108_2.png) [@smokris](https://discourse.cmake.org/u/smokris)
#### Post date: [January 16, 2020, 2:14am UTC](https://discourse.cmake.org/t/how-to-embed-info-plist-in-a-simple-mac-binary-file/512/2 "2020-01-16T02:14:16Z")

</div>

We’re successfully using CMake to embed an Info.plist into a CLI using the following syntax:

```
target_link_options(${target} PRIVATE LINKER:-sectcreate, __TEXT,__ info_plist,${CMAKE_CURRENT_SOURCE_DIR}/Info.plist)

```

(If I understand correctly, it’s preferred to use `target_link_options` to specify linker options per-target rather than globally with `add_link_options`. And the [`LINKER:` keyword](https://cmake.org/cmake/help/latest/command/add_link_options.html) is a compiler-independent way to pass options to the linker.)

> but it then seems to go on to do other linker stages which blow away the section

If the above doesn’t work, could you either push a branch to [GitHub - Deep-Symmetry/carabiner: A loose connector for interacting with Ableton Link](https://github.com/Deep-Symmetry/carabiner) that demonstrates the problem, or share the verbose build output? (I’m not clear on what “other linker stages” you’re referring to.)

---

_[View the full topic](https://discourse.cmake.org/t/how-to-embed-info-plist-in-a-simple-mac-binary-file/512)._
