@@ -40,7 +40,7 @@ This package follows the official [Golang Release Policy](https://golang.org/doc
40
40
- [ Alpine] ( #alpine )
41
41
- [ Fedora] ( #fedora )
42
42
- [ Ubuntu] ( #ubuntu )
43
- - [ Mac OSX ] ( #mac-osx )
43
+ - [ macOS ] ( #mac-osx )
44
44
- [ Windows] ( #windows )
45
45
- [ Errors] ( #errors )
46
46
- [ User Authentication] ( #user-authentication )
@@ -145,7 +145,7 @@ Click [here](https://golang.org/pkg/go/build/#hdr-Build_Constraints) for more in
145
145
If you wish to build this library with additional extensions / features, use the following command:
146
146
147
147
``` bash
148
- go build -- tags " <FEATURE>"
148
+ go build -tags " <FEATURE>"
149
149
```
150
150
151
151
For available features, see the extension list.
@@ -154,7 +154,7 @@ When using multiple build tags, all the different tags should be space delimited
154
154
Example:
155
155
156
156
``` bash
157
- go build -- tags " icu json1 fts5 secure_delete"
157
+ go build -tags " icu json1 fts5 secure_delete"
158
158
```
159
159
160
160
### Feature / Extension List
@@ -194,7 +194,7 @@ This package can be compiled for android.
194
194
Compile with:
195
195
196
196
``` bash
197
- go build -- tags " android"
197
+ go build -tags " android"
198
198
```
199
199
200
200
For more information see [ #201 ] ( https://github.com/mattn/go-sqlite3/issues/201 )
@@ -219,8 +219,8 @@ This library can be cross-compiled.
219
219
220
220
In some cases you are required to the ` CC ` environment variable with the cross compiler.
221
221
222
- ## Cross Compiling from MAC OSX
223
- The simplest way to cross compile from OSX is to use [ musl-cross ] ( https://github.com/FiloSottile/homebrew-musl-cross ) .
222
+ ## Cross Compiling from macOS
223
+ The simplest way to cross compile from macOS is to use [ xgo ] ( https://github.com/karalabe/xgo ) .
224
224
225
225
Steps:
226
226
- Install [ musl-cross] ( https://github.com/FiloSottile/homebrew-musl-cross ) (` brew install FiloSottile/musl-cross/musl-cross ` ).
@@ -241,13 +241,13 @@ To compile this package on Linux, you must install the development tools for you
241
241
To compile under linux use the build tag ` linux ` .
242
242
243
243
``` bash
244
- go build -- tags " linux"
244
+ go build -tags " linux"
245
245
```
246
246
247
247
If you wish to link directly to libsqlite3 then you can use the ` libsqlite3 ` build tag.
248
248
249
249
```
250
- go build -- tags "libsqlite3 linux"
250
+ go build -tags "libsqlite3 linux"
251
251
```
252
252
253
253
### Alpine
@@ -270,34 +270,43 @@ sudo yum groupinstall "Development Tools" "Development Libraries"
270
270
sudo apt-get install build-essential
271
271
```
272
272
273
- ## Mac OSX
273
+ ## macOS
274
274
275
- OSX should have all the tools present to compile this package. If not, install XCode to add all the developers tools.
275
+ macOS should have all the tools present to compile this package. If not, install XCode to add all the developers tools.
276
276
277
277
Required dependency:
278
278
279
279
``` bash
280
280
brew install sqlite3
281
281
```
282
282
283
- For OSX , there is an additional package to install which is required if you wish to build the ` icu ` extension.
283
+ For macOS , there is an additional package to install which is required if you wish to build the ` icu ` extension.
284
284
285
285
This additional package can be installed with ` homebrew ` :
286
286
287
287
``` bash
288
288
brew upgrade icu4c
289
289
```
290
290
291
- To compile for Mac OSX :
291
+ To compile for macOS on x86 :
292
292
293
293
``` bash
294
- go build --tags " darwin"
294
+ go build -tags " darwin amd64"
295
+ ```
296
+
297
+ To compile for macOS on ARM chips:
298
+
299
+ ``` bash
300
+ go build -tags " darwin arm64"
295
301
```
296
302
297
303
If you wish to link directly to libsqlite3, use the ` libsqlite3 ` build tag:
298
304
299
305
```
300
- go build --tags "libsqlite3 darwin"
306
+ # x86
307
+ go build -tags "libsqlite3 darwin amd64"
308
+ # ARM
309
+ go build -tags "libsqlite3 darwin arm64"
301
310
```
302
311
303
312
Additional information:
0 commit comments