fix(build): instruct users to use GOTAGS, not GOFLAGS
GOFLAGS will _override_ all the flags. If we just want to set a tag e.g., enable OpenSSL, we should set GOTAGS=openssl. fixes https://github.com/ipfs/go-ipfs/issues/6622#issuecomment-576713181
Steven Allen committed
Jan 21, 2020 at 08:16 UTC
627b62da36fc4325558ad454ef2e470f06931fbd
3 files changed
+4
-4
CHANGELOG.md
+1
-1
@@ -425,7 +425,7 @@ receiving multiple inbound connections per second.
425
To enable openssl support, rebuild go-ipfs with:
426
427
```bash
428
-> make build GOFLAGS=-tags=openssl
428
+> make build GOTAGS=openssl
429
```
430
431
### CoreAPI
Dockerfile
+1
-1
@@ -20,7 +20,7 @@ COPY . $SRC_DIR
20
# Also: fix getting HEAD commit hash via git rev-parse.
21
RUN cd $SRC_DIR \
22
&& mkdir .git/objects \
23
- && make build GOFLAGS=-tags=openssl
23
+ && make build GOTAGS=openssl
24
25
# Get su-exec, a very minimal tool for dropping privileges,
26
# and tini, a very minimal init daemon for containers
README.md
+2
-2
@@ -66,7 +66,7 @@ IPFS can run on most Linux, macOS, and Windows systems. We recommend running it
66
67
If your system is resource constrained, we recommend:
68
69
-1. Installing OpenSSL and rebuilding go-ipfs manually with `make build GOFLAGS=-tags=openssl`. See the [download and compile](#download-and-compile-ipfs) section for more information on compiling go-ipfs.
69
+1. Installing OpenSSL and rebuilding go-ipfs manually with `make build GOTAGS=openssl`. See the [download and compile](#download-and-compile-ipfs) section for more information on compiling go-ipfs.
70
2. Initializing your daemon with `ipfs init --profile=lowpower`
71
72
### Install prebuilt packages
@@ -204,7 +204,7 @@ make build GOOS=myTargetOS GOARCH=myTargetArchitecture
204
205
##### OpenSSL
206
207
-To build go-ipfs with OpenSSL support, append `GOFLAGS=-tags=openssl` to your `make` invocation. Building with OpenSSL should significantly reduce the background CPU usage on nodes that frequently make or receive new connections.
207
+To build go-ipfs with OpenSSL support, append `GOTAGS=openssl` to your `make` invocation. Building with OpenSSL should significantly reduce the background CPU usage on nodes that frequently make or receive new connections.
208
209
Note: OpenSSL requires CGO support and, by default, CGO is disabled when cross compiling. To cross compile with OpenSSL support, you must:
210