mirror of
https://github.com/etcd-io/etcd.git
synced 2024-09-27 06:25:44 +00:00
Makefile: Read GO_BUILD_FLAGS from env and prepend
Build flags read from env GO_BUILD_FLAGS are prepended to flags in Makefile and sent to scripts/build.sh for building executables (etcd, etcdctl & etcdutl). Signed-off-by: Bhargav Ravuri <bhargav.ravuri@infracloud.io>
This commit is contained in:
parent
61e9ec9833
commit
dadd7358f4
@ -57,6 +57,11 @@ Setup environment:
|
|||||||
- For ubuntu and debian run `sudo apt-get install build-essentials`
|
- For ubuntu and debian run `sudo apt-get install build-essentials`
|
||||||
- Verify that everything is installed by running `make build`
|
- Verify that everything is installed by running `make build`
|
||||||
|
|
||||||
|
Note: `make build` runs with `-v`. Other build flags can be added through env `GO_BUILD_FLAGS`, **if required**. Eg.,
|
||||||
|
```console
|
||||||
|
GO_BUILD_FLAGS="-buildmode=pie" make build
|
||||||
|
```
|
||||||
|
|
||||||
[file an issue]: https://github.com/etcd-io/etcd/issues/new/choose
|
[file an issue]: https://github.com/etcd-io/etcd/issues/new/choose
|
||||||
|
|
||||||
## Implement your change
|
## Implement your change
|
||||||
|
2
Makefile
2
Makefile
@ -1,6 +1,6 @@
|
|||||||
.PHONY: build
|
.PHONY: build
|
||||||
build:
|
build:
|
||||||
GO_BUILD_FLAGS="-v" ./scripts/build.sh
|
GO_BUILD_FLAGS="${GO_BUILD_FLAGS} -v" ./scripts/build.sh
|
||||||
./bin/etcd --version
|
./bin/etcd --version
|
||||||
./bin/etcdctl version
|
./bin/etcdctl version
|
||||||
./bin/etcdutl version
|
./bin/etcdutl version
|
||||||
|
Loading…
x
Reference in New Issue
Block a user