Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 389293

Summary: app-office/libreoffice-l10n-3.4.3-r3: direct use of LINGUAS.
Product: Gentoo Linux Reporter: Ralph Sennhauser (RETIRED) <sera>
Component: Current packagesAssignee: Gentoo Office Team <office>
Status: RESOLVED FIXED    
Severity: normal    
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: Fixes uses of LINGUAS

Description Ralph Sennhauser (RETIRED) gentoo-dev 2011-11-02 07:40:53 UTC
Created attachment 291509 [details, diff]
Fixes uses of LINGUAS

Recent version of portage seem to sanitize the LINGUAS variable, still using LINGUAS from within an ebuild doesn't conform to PMS and the used code may fail with other package managers.

Attached patch offers an alternative.
Comment 1 Tomáš Chvátal (RETIRED) gentoo-dev 2011-11-02 08:15:22 UTC
Fixed in main tree.
Comment 2 Ralph Sennhauser (RETIRED) gentoo-dev 2011-11-02 08:48:22 UTC
Unfortunately not.

> for lang in ${LINGUAS}; do
>    # break away if not enabled; paludis support
>    use linguas_${lang} || continue

linguas_xyz might not be in IUSE and so "use linguas_xyz" must not be called. The attached patch makes use of the variable LANGUAGES defined within the ebuild instead of LINGUAS.

Thanks.
Comment 3 Tomáš Chvátal (RETIRED) gentoo-dev 2011-11-02 09:07:10 UTC
Well the code is exactly same as yours, i just added || continue instead of wrapping whole codeblock into if.

Anyway, I updated the check to verify first that the lingua thingie is in IUSE.
Comment 4 Ralph Sennhauser (RETIRED) gentoo-dev 2011-11-02 09:22:33 UTC
(In reply to comment #3)
> Well the code is exactly same as yours, i just added || continue instead of
> wrapping whole codeblock into if.
> 
> Anyway, I updated the check to verify first that the lingua thingie is in IUSE.

The quote was your commit, should have said so. Just replacing LINGUAS with LANGUAGES is enough.

The problem with LINGUAS is it's not defined in the PMS and can't be relied upon being set in the first place.
Comment 5 Tomáš Chvátal (RETIRED) gentoo-dev 2011-11-02 09:27:59 UTC
AAh I see, my bad.

I updated also the variable in the for loop now.
Comment 6 Ralph Sennhauser (RETIRED) gentoo-dev 2011-11-02 09:32:14 UTC
(In reply to comment #5)
> AAh I see, my bad.
> 
> I updated also the variable in the for loop now.

Much appreciated.