Ticket #15864 (closed defect: fixed)
coreutils +with_default_names creates broken man page symlinks
| Reported by: | jason.dusek@… | Owned by: | nox@… |
|---|---|---|---|
| Priority: | Normal | Milestone: | |
| Component: | ports | Version: | 1.6.0 |
| Keywords: | Cc: | ryandesign@… | |
| Port: | coreutils |
Description
The port creates manpage symlinks from gmv.1 to mv.1 but the man pages are actually gmv.1.gz and so on -- all compressed. I am trying to learn TCL to fix it, but my tentative change (to post-destroot) did not work.
variant with_default_names description {Install files without 'g' prefix} {
post-destroot {
foreach {d} {bin} {
foreach {f} [glob -tails -directory ${destroot}${prefix}/${d} g*] {
ln -sf ${prefix}/${d}/${f} ${destroot}${prefix}/${d}/[string range ${f} 1 end]
}
}
foreach {f} [glob -tails -directory ${destroot}${prefix}/share/man/man1 g*] {
ln -sf ${prefix}/${d}/${f} ${destroot}${prefix}/${d}/[string range ${f} 1 end].gz }
}
}
In the meantime, I can just make the links myself, but it is a kludge.
Change History
comment:1 Changed 5 years ago by jmr@…
- Owner changed from macports-tickets@… to nox@…
- Milestone set to Port Bugs
comment:2 follow-up: ↓ 3 Changed 5 years ago by nox@…
- Status changed from new to closed
- Resolution set to worksforme
I don't know where the problem is, the manpages are gzipped by the internal MacPorts destroot code and links are also corrected accordingly.
comment:3 in reply to: ↑ 2 Changed 4 years ago by ben@…
Replying to nox@…:
I don't know where the problem is, the manpages are gzipped by the internal MacPorts destroot code and links are also corrected accordingly.
I've found the same problem, also as described by #16354. i.e. I installed coreutils with the with_default_names variant; and now have symlinks for the default-named man pages that are supposed to point to the 'g*' named pages:
$ ls -l /opt/local/share/man/man1/{g,}ls*
-r--r--r-- 2 root admin 2964 16 Jan 16:33 /opt/local/share/man/man1/gls.1.gz
lrwxr-xr-x 1 root admin 31 16 Jan 16:34 /opt/local/share/man/man1/ls.1@ -> /opt/local/share/man/man1/gls.1
As you can see, the actual man page is compressed, but the symlink points to a non-existing uncompressed version of the man page file. Thus, "man ls" does not bring up the man page for the MacPorts 'ls', ("man gls" does, but that's a very awkward thing to have to remember).
Thanks, Ben
comment:4 Changed 4 years ago by ryandesign@…
- Cc ryandesign@… added
- Status changed from closed to reopened
- Resolution worksforme deleted
- Port set to coreutils
The underlying cause is explained in #18302. You can fix this for coreutils by having it make relative manpage symlinks instead of absolute ones.
comment:5 Changed 4 years ago by nox@…
- Status changed from reopened to closed
- Resolution set to fixed
Should be fixed in r46259.
comment:6 Changed 4 years ago by ben@…
All good here! I just did an upgrade, and after fiddling w/ gettext (per here) I have:
$ ls -l /opt/local/share/man/man1/{g,}ls*
-r--r--r-- 2 root admin 2964 2 Feb 15:19 /opt/local/share/man/man1/gls.1.gz
lrwxr-xr-x 1 root admin 8 2 Feb 15:19 /opt/local/share/man/man1/ls.1.gz@ -> gls.1.gz
Thanks very much.


Assigning to maintainer.