# std.build: fix handling of \-Dcpu · gitcafe/zig

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

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

Visibility: public

Requested revision: 8c86043178a30a75aa9ff58b4432964237fb52dc

Requested commit: 8c86043178a30a75aa9ff58b4432964237fb52dc

Commit: 8c86043178a30a75aa9ff58b4432964237fb52dc

Tree: 353cf610a986a281fd88e02879fdfc18903e308e

Author: Isaac Freund

Committer: Andrew Kelley

## Message

```
std.build: fix handling of -Dcpu

Currently -Dcpu is completely ignored if -Dtarget isn't passed as well.
Further, -Dcpu=baseline is ignored even if -Dtarget=native is passed.

This patch fixes these 2 issues, always respecting the -Dcpu option if
present.

```

## Parents

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

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