Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed to build with Go 1.9.2 #136

Open
ying911008 opened this issue Apr 22, 2018 · 7 comments
Open

Failed to build with Go 1.9.2 #136

ying911008 opened this issue Apr 22, 2018 · 7 comments

Comments

@ying911008
Copy link

I use go1.9.2 windows/amd64 and TDM-GCC-64 in win10,but it can‘t work:

github.com/sciter-sdk/go-sciter

src\github.com\sciter-sdk\go-sciter\sciter.go:675[C:\Users\ZYQ\AppData\Local\Temp\go-build684847486\github.com\sciter-sdk\go-sciter_obj\sciter.cgo1.go:511:22]: cannot use bs (type _Ctype_LPCSTR) as type *_Ctype_char in argument to _Cfunc_GoString
src\github.com\sciter-sdk\go-sciter\sciter.go:806[C:\Users\ZYQ\AppData\Local\Temp\go-build684847486\github.com\sciter-sdk\go-sciter_obj\sciter.cgo1.go:652:5]: cannot use cname (type *_Ctype_char) as type *_Ctype_CHAR in argument to func literal
src\github.com\sciter-sdk\go-sciter\sciter.go:823[C:\Users\ZYQ\AppData\Local\Temp\go-build684847486\github.com\sciter-sdk\go-sciter_obj\sciter.cgo1.go:675:5]: cannot use cname (type *_Ctype_char) as type *_Ctype_CHAR in argument to func literal
src\github.com\sciter-sdk\go-sciter\sciter.go:885[C:\Users\ZYQ\AppData\Local\Temp\go-build684847486\github.com\sciter-sdk\go-sciter_obj\sciter.cgo1.go:748:5]: cannot use cname (type *_Ctype_char) as type *_Ctype_CHAR in argument to func literal
src\github.com\sciter-sdk\go-sciter\sciter.go:897[C:\Users\ZYQ\AppData\Local\Temp\go-build684847486\github.com\sciter-sdk\go-sciter_obj\sciter.cgo1.go:771:5]: cannot use cname (type *_Ctype_char) as type *_Ctype_CHAR in argument to func literal
src\github.com\sciter-sdk\go-sciter\types.go:596[C:\Users\ZYQ\AppData\Local\Temp\go-build684847486\github.com\sciter-sdk\go-sciter_obj\types.cgo1.go:527:26]: cannot use s.name (type _Ctype_LPCSTR) as type *_Ctype_char in argument to _Cfunc_GoString
src\github.com\sciter-sdk\go-sciter\types.go:979[C:\Users\ZYQ\AppData\Local\Temp\go-build684847486\github.com\sciter-sdk\go-sciter_obj\types.cgo1.go:725:26]: cannot use s.behaviorName (type _Ctype_LPCSTR) as type *_Ctype_char in argument to _Cfunc_GoString

@pravic
Copy link
Member

pravic commented Apr 22, 2018

1.9 is unsupported, unfortunately. The latest revision was 9646a0a, I'll make a tag for that may be.

@pravic pravic changed the title go get -x github.com/sciter-sdk/go-sciter faild Failed to build with Go 1.9.2 Apr 23, 2018
@pravic
Copy link
Member

pravic commented Apr 23, 2018

Could you use this version instead? https://github.com/sciter-sdk/go-sciter/releases/tag/go-1.9

@ying911008
Copy link
Author

yes, It can work well for me

@ying911008
Copy link
Author

this version can work in Go 1.9.5, but can't use in Go1.10.1

@pravic
Copy link
Member

pravic commented Apr 23, 2018

Exactly. They are incompatible.

If you can fix it - you're welcome :)

@ying911008
Copy link
Author

@pravic I‘m sorry, I just learned golang a few days. I have no power to do it.

@waleson
Copy link

waleson commented Apr 26, 2018

C:\Users\waleson>gcc --version
gcc (MinGW.org GCC-6.3.0-1) 6.3.0
Copyright (C) 2016 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

C:\Users\waleson>go version
go version go1.10.1 windows/386

C:\Users\waleon>go get github.com\sciter-sdk\go-sciter

github.com/sciter-sdk/go-sciter

Warning: resolving _SciterHostCallback_cgo by linking to _SciterHostCallback_cgo@8
Use --enable-stdcall-fixup to disable these warnings
Use --disable-stdcall-fixup to disable these fixups
Warning: resolving _SciterElementCallback_cgo by linking to _SciterElementCallback_cgo@8
Warning: resolving _LPCWSTR_RECEIVER_cgo by linking to _LPCWSTR_RECEIVER_cgo@12
Warning: resolving _LPCSTR_RECEIVER_cgo by linking to _LPCSTR_RECEIVER_cgo@12
Warning: resolving _LPCBYTE_RECEIVER_cgo by linking to _LPCBYTE_RECEIVER_cgo@12
Warning: resolving _KeyValueCallback_cgo by linking to _KeyValueCallback_cgo@12
Warning: resolving _ElementEventProc_cgo by linking to _ElementEventProc_cgo@16
Warning: resolving _ELEMENT_COMPARATOR_cgo by linking to _ELEMENT_COMPARATOR_cgo@12

https://codeload.github.com/sciter-sdk/go-sciter/zip/go-1.9
only this version worked (with warning) for me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

3 participants