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

cmd/go: go.crypto/curve25519 fails to compile on amd64 #4180

Closed
gopherbot opened this issue Oct 1, 2012 · 8 comments
Closed

cmd/go: go.crypto/curve25519 fails to compile on amd64 #4180

gopherbot opened this issue Oct 1, 2012 · 8 comments

Comments

@gopherbot
Copy link

by julien.laffaye:

What steps will reproduce the problem?
If possible, include a link to a program on play.golang.org.
1. go install go.crypto

What is the expected output?
Successful install


What do you see instead?
./mont25519_amd64.go:45: scalarMult redeclared in this block
        previous declaration at ./curve25519.go:86


Which compiler are you using (5g, 6g, 8g, gccgo)?
6g

Which operating system are you using?
FreeBSD

Which version are you using?  (run 'go version')
go1.0.3

Please provide any additional information below.
For some reasons, the compiler tries to compile curve25519.go despite the fact that it
is flaged "+build !amd64" and running on an amd64 host compiling for an amd64
target.
@rsc
Copy link
Contributor

rsc commented Oct 1, 2012

Comment 1:

What does 'go version' say? My guess is that you have a release build of the go command
and it is not handling things right. We could try to work around this by making the //
+build comment its own block in the file.

Status changed to WaitingForReply.

@gopherbot
Copy link
Author

Comment 2 by julien.laffaye:

go1.0.3
Adding a newline after curve25519.go:6 indeed fixes it.

@gopherbot
Copy link
Author

Comment 3 by julien.laffaye:

go version go1.0.3

@rsc
Copy link
Contributor

rsc commented Oct 1, 2012

Comment 4:

CL 6587054.

@gopherbot
Copy link
Author

Comment 5 by julien.laffaye:

Sorry for the noise, but in fact it looks like that it is the package declaration line
(l5) that should be moved after the // +build block.

@rsc
Copy link
Contributor

rsc commented Oct 1, 2012

Comment 6:

Maybe you are looking at an old copy? Try go get -u go.crypto/...
The package line was in the wrong place but we fixed it a few weeks ago.

@gopherbot
Copy link
Author

Comment 7 by julien.laffaye:

You're right. It was an old copy.
Sorry for your time, you can safely close this issue.

@rsc
Copy link
Contributor

rsc commented Oct 1, 2012

Comment 8:

Status changed to Retracted.

@golang golang locked and limited conversation to collaborators Jun 24, 2016
This issue was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants