Package: golang-go
Version: 2:1.0.2-1
Severity: normal
godoc tries to read documentation from /doc (ignoring GOROOT prefix)
instead of /usr/lib/go/doc and shows following error message
#godoc -goroot=/usr/lib/go -http=:6060
2012/06/30 15:52:29 updateMetadata: open /doc: no such file or directory
As I see, the cause of that problem is a patch from #669354
(godoc-symlinks.diff): it just disrespects godoc's root binding.
So if you don't mind, here is replacement for it
--- a/src/cmd/godoc/filesystem.go
+++ b/src/cmd/godoc/filesystem.go
@@ -121,7 +121,22 @@
}
func (root osFS) ReadDir(path string) ([]os.FileInfo, error) {
- return ioutil.ReadDir(root.resolve(path)) // is sorted
+ dirName := root.resolve(path)
+ fis, err := ioutil.ReadDir(dirName) // is sorted
+ if err != nil {
+ return nil, err
+ }
+ // Replace symlinks with what they are pointing to
+ for i, fi := range fis {
+ if fi.Mode()&os.ModeSymlink != 0 {
+ fi, err = os.Stat(filepath.Join(dirName, fi.Name()))
+ if err != nil {
+ return nil, err
+ }
+ }
+ fis[i] = fi
+ }
+ return fis, nil
}
// hasPathPrefix returns true if x == y or x == y + "/" + more
-- System Information:
Debian Release: wheezy/sid
APT prefers unstable
APT policy: (500, 'unstable'), (1, 'experimental')
Architecture: amd64 (x86_64)
Kernel: Linux 3.2.0-3-amd64 (SMP w/2 CPU cores)
Locale: LANG=ru_UA.UTF-8, LC_CTYPE=ru_UA.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Versions of packages golang-go depends on:
ii debconf [debconf-2.0] 1.5.44
ii golang-src 2:1.0.2-1
ii libc6 2.13-34
ii perl 5.14.2-12
golang-go recommends no packages.
golang-go suggests no packages.
-- debconf information excluded
--
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]