# build: workaround link error with LTO and mingw · gitcafe/zig

[View on GitCafe](https://git.cafe/gitcafe/zig/commit/564629f70475a1e3b397179067e22d3f61772104)

Repository: [gitcafe/zig](https://git.cafe/gitcafe/zig)

Visibility: public

Requested revision: 564629f70475a1e3b397179067e22d3f61772104

Requested commit: 564629f70475a1e3b397179067e22d3f61772104

Commit: 564629f70475a1e3b397179067e22d3f61772104

Tree: 6253e413486c257db786657a9c19fc024227155d

Author: xavier

Committer: Andrew Kelley

## Message

```
build: workaround link error with LTO and mingw

The symbol "_tls_index" gets lost when using LTO.
Disabling LTO on the object file that defines it allows the link to work.

fixes https://github.com/ziglang/zig/issues/8531

```

## Parents

- [353c19468df02db925a7b147cabb398d7e63de68](https://git.cafe/gitcafe/zig/commit/353c19468df02db925a7b147cabb398d7e63de68?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zig/tree/564629f70475a1e3b397179067e22d3f61772104?format=markdown)
