shanemhansen / gossl Goto Github PK
View Code? Open in Web Editor NEWGo bindings to the openssl library
License: MIT License
Go bindings to the openssl library
License: MIT License
Something strange is happening here, it I try to use your example (examples/testhttpserver/httpserver.go) after succesfully go geting the package I get mixed results. I tried windows/linux 386/amd64 permutations and it only works if GOOS=linux and GOARCH=amd64. The error message is really strange:
dmagyar@dmtest:~/go/ossl$ GOOS=windows GOARCH=386 go get github.com/shanemhansen/gossl
dmagyar@dmtest:~/go/ossl$ GOOS=windows GOARCH=386 go run gossltest.go
go build github.com/shanemhansen/gossl/sslerr: build constraints exclude all Go files in /home/dmagyar/go/src/github.com/shanemhansen/gossl/sslerr
dmagyar@dmtest:~/go/ossl$ GOOS=windows GOARCH=amd64 go get github.com/shanemhansen/gossl
dmagyar@dmtest:~/go/ossl$ GOOS=windows GOARCH=amd64 go run gossltest.go
go build github.com/shanemhansen/gossl/sslerr: build constraints exclude all Go files in /home/dmagyar/go/src/github.com/shanemhansen/gossl/sslerr
dmagyar@dmtest:~/go/ossl$ GOOS=linux GOARCH=386 go get github.com/shanemhansen/gossl
dmagyar@dmtest:~/go/ossl$ GOOS=linux GOARCH=386 go run gossltest.go
go build github.com/shanemhansen/gossl/sslerr: build constraints exclude all Go files in /home/dmagyar/go/src/github.com/shanemhansen/gossl/sslerr
dmagyar@dmtest:~/go/ossl$ GOOS=linux GOARCH=amd64 go get github.com/shanemhansen/gossl
dmagyar@dmtest:~/go/ossl$ GOOS=linux GOARCH=amd64 go run gossltest.go
-cert string
The path to a PEM certificate
-key string
The path to a PEM key
dmagyar@dmtest:~/go/ossl$
Any clues what could be wrong? I am trying to use this on windows/386 eventually.
Currently tests with Go 1.3.3 are green while with Go 1.4.3 and 1.5.1 they shows these errors (even on Travis):
# testmain
/var/tmp/go-link-3O2XVs/000003.o: In function `_cgo_1bc98585464e_Cfunc_free':
/home/travis/gopath/src/github.com/shanemhansen/gossl/rand/rand.go:74: multiple definition of `_cgo_1bc98585464e_Cfunc_free'
/var/tmp/go-link-3O2XVs/000000.o:/home/travis/gopath/src/github.com/shanemhansen/gossl/rand/rand.go:74: first defined here
/var/tmp/go-link-3O2XVs/000003.o: In function `_cgo_1bc98585464e_Cfunc_RAND_bytes':
/home/travis/gopath/src/github.com/shanemhansen/gossl/rand/rand.go:40: multiple definition of `_cgo_1bc98585464e_Cfunc_RAND_bytes'
/var/tmp/go-link-3O2XVs/000000.o:/home/travis/gopath/src/github.com/shanemhansen/gossl/rand/rand.go:40: first defined here
/var/tmp/go-link-3O2XVs/000003.o: In function `_cgo_1bc98585464e_Cfunc_RAND_file_name':
/home/travis/gopath/src/github.com/shanemhansen/gossl/rand/rand.go:56: multiple definition of `_cgo_1bc98585464e_Cfunc_RAND_file_name'
/var/tmp/go-link-3O2XVs/000000.o:/home/travis/gopath/src/github.com/shanemhansen/gossl/rand/rand.go:56: first defined here
collect2: ld returned 1 exit status
/home/travis/.gimme/versions/go1.4.3.linux.amd64/pkg/tool/linux_amd64/6l: running gcc failed: unsuccessful exit status 0x100
FAIL github.com/shanemhansen/gossl/rand [build failed]
seems like something wrong with the included files in cgo, this should be fixed
--- FAIL: TestGenerateKey (0.00s)
panic: runtime error: cgo argument has Go pointer to Go pointer [recovered]
panic: runtime error: cgo argument has Go pointer to Go pointer
Make the gossl pass go lint. Currently it does not:
$ golint ./... | wc -l
3322
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.