Go-sqlite3: #531 breaks build on Mac OSX

Created on 17 Feb 2018  路  2Comments  路  Source: mattn/go-sqlite3

Pull-request #531 breaks for OSX. The build is broken because OSX doesnt have pread, reverting to 3c6eef4 works.

~/src/github.com/mattn/go-sqlite3 master $ go build
# github.com/mattn/go-sqlite3
sqlite3-binding.c:31162:42: error: use of undeclared identifier 'pread64'
sqlite3-binding.c:31180:42: error: use of undeclared identifier 'pwrite64'
sqlite3-binding.c:31304:22: error: invalid application of 'sizeof' to an incomplete type 'struct unix_syscall []'
sqlite3-binding.c:31313:22: error: invalid application of 'sizeof' to an incomplete type 'struct unix_syscall []'
sqlite3-binding.c:31340:20: error: invalid application of 'sizeof' to an incomplete type 'struct unix_syscall []'
sqlite3-binding.c:31357:16: error: invalid application of 'sizeof' to an incomplete type 'struct unix_syscall []'
sqlite3-binding.c:13164:38: note: expanded from macro 'ArraySize'
sqlite3-binding.c:31361:14: error: invalid application of 'sizeof' to an incomplete type 'struct unix_syscall []'
sqlite3-binding.c:13164:38: note: expanded from macro 'ArraySize'
sqlite3-binding.c:33907:11: warning: type specifier missing, defaults to 'int' [-Wimplicit-int]
sqlite3-binding.c:31166:49: note: expanded from macro 'osPread64'
sqlite3-binding.c:34019:17: warning: type specifier missing, defaults to 'int' [-Wimplicit-int]
sqlite3-binding.c:31184:57: note: expanded from macro 'osPwrite64'

A quick Google-search led me to this who also had the same problem. https://github.com/tarantool/tarantool/issues/2303

Most helpful comment

I still have the same problem
GOOS=linux CGO_ENABLED=1
Also used brew install go --with-cc-all
```[[projects]]
digest = "1:3cafc6a5a1b8269605d9df4c6956d43d8011fc57f266ca6b9d04da6c09dee548"
name = "github.com/mattn/go-sqlite3"
packages = ["."]
pruneopts = "UT"
revision = "25ecb14adfc7543176f7d85291ec7dba82c6f7e4"
version = "v1.9.0"

All 2 comments

I still have the same problem
GOOS=linux CGO_ENABLED=1
Also used brew install go --with-cc-all
```[[projects]]
digest = "1:3cafc6a5a1b8269605d9df4c6956d43d8011fc57f266ca6b9d04da6c09dee548"
name = "github.com/mattn/go-sqlite3"
packages = ["."]
pruneopts = "UT"
revision = "25ecb14adfc7543176f7d85291ec7dba82c6f7e4"
version = "v1.9.0"

Was this page helpful?
0 / 5 - 0 ratings

Related issues

jeffreyantony picture jeffreyantony  路  7Comments

SaekiRaku picture SaekiRaku  路  3Comments

jackhu1990 picture jackhu1990  路  11Comments

tiaguinho picture tiaguinho  路  3Comments

mhat picture mhat  路  7Comments