Bug 106252 - [patch] can't account for partially translated man pages with just MANLANG and MAN[N]
Summary: [patch] can't account for partially translated man pages with just MANLANG an...
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Port Management Team
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-12-03 07:20 UTC by Nick Barkas
Modified: 2007-01-31 16:15 UTC (History)
0 users

See Also:


Attachments
bsd.port.mk.patch (1.24 KB, patch)
2006-12-03 07:20 UTC, Nick Barkas
no flags Details | Diff
bsd.port.mk.patch (1.87 KB, patch)
2007-01-23 00:47 UTC, Nick Barkas
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Nick Barkas 2006-12-03 07:20:20 UTC
When installing a port with only a subset of the man pages translated into other
languages, it is not currently possible to account for those translated pages
using MANLANG and the MAN[N] variables in the port's Makefile. If you set
MANLANG, it expects *all* man pages listed in MAN[N] to be installed for every
language. 

The attached patch to bsd.ports.mk allows a port maintainer to set 
MAN_PARTIAL_TRANSLATIONS to a list of two character languages codes that only 
have some of their man pages translated. Then, MAN[N]_[LANG] can be set for each
section N and each language specified in MAN_PARTIAL_TRANSLATIONS LANG to list
the man pages specific to that language which the port installs.

See also
http://lists.freebsd.org/pipermail/freebsd-ports/2006-November/036836.html

Note that this patch doesn't provide any sort of MLINKS functionality for
partially translated man pages.

How-To-Repeat: Create a port that installs english man pages foo.1 and bar.1, and the German
man page foo.1. Set MANLANG= "" de and set MAN1= foo.1 bar.1, and make will
complain that the German version of bar.1 was not installed.
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2006-12-03 10:26:44 UTC
Responsible Changed
From-To: freebsd-ports-bugs->portmgr

bsd.port.mk is port manager territory
Comment 2 Kris Kennaway 2007-01-19 19:32:28 UTC
I agree with the intent of your patch but don't like the addition of
the MAN_PARTIAL_TRANSLATIONS variable.  It seems that you don't need
it though:

* keep the meaning of MANLANG as before

* When iterating through each element of MANLANG, check for
MAN_${sect}_${lang}.  If it exists, install those manpages, otherwise
install the MAN_${sect} manpages.

Kris
Comment 3 Pav Lucistnik freebsd_committer freebsd_triage 2007-01-20 12:37:46 UTC
State Changed
From-To: open->feedback

Waiting for revised patch
Comment 4 Nick Barkas 2007-01-23 00:47:47 UTC
Here is a new patch which does what you suggest. MAN${sect} continues  
its current behavior, and extra man pages that don't get installed  
for all languages in MANLANG can be separately specified with MAN$ 
{sect}_${lang}.

Thanks!
Nick
Comment 5 Pav Lucistnik freebsd_committer freebsd_triage 2007-01-23 01:54:39 UTC
State Changed
From-To: feedback->open

New,  good patch received
Comment 6 Pav Lucistnik freebsd_committer freebsd_triage 2007-01-23 20:03:51 UTC
State Changed
From-To: open->analyzed

Accepted for a test build on the cluster.
Comment 7 Pav Lucistnik freebsd_committer freebsd_triage 2007-01-31 16:15:17 UTC
State Changed
From-To: analyzed->closed

This patch has been committed, thanks.