From mboxrd@z Thu Jan 1 00:00:00 1970 From: ludo@gnu.org (Ludovic =?utf-8?Q?Court=C3=A8s?=) Subject: Re: [PATCH 1/2] gnu: Add qtkeychain. Date: Tue, 10 Nov 2015 19:07:20 +0100 Message-ID: <87r3jxn2xz.fsf@gnu.org> References: <1446497399-30726-1-git-send-email-efraim@flashner.co.il> <1446497399-30726-2-git-send-email-efraim@flashner.co.il> <87d1vocf05.fsf@gnu.org> <20151107203145.75002d7c@debian-netbook> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:35816) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZwHd0-0007hi-Jf for guix-devel@gnu.org; Tue, 10 Nov 2015 17:43:03 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZwHcz-0001Wc-Li for guix-devel@gnu.org; Tue, 10 Nov 2015 17:43:02 -0500 In-Reply-To: <20151107203145.75002d7c@debian-netbook> (Efraim Flashner's message of "Sat, 7 Nov 2015 20:31:45 +0200") List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org To: Efraim Flashner Cc: guix-devel@gnu.org Efraim Flashner skribis: > On Thu, 05 Nov 2015 22:28:42 +0100 > ludo@gnu.org (Ludovic Court=C3=A8s) wrote: > >> Efraim Flashner skribis: >>=20 >> > * gnu/packages/qt.scm (qtkeychain): New variable.=20=20 >>=20 >> [...] >>=20 >> > + (modify-phases >> > + %standard-phases=20=20 >>=20 >> =E2=80=98%standard-phases=E2=80=99 goes on the previous line. >>=20 >> > + (add-before >> > + 'configure 'set-qt-trans-dir >> > + (lambda _ >> > + (substitute* "CMakeLists.txt" >> > + (("\\$\\{qt_translations_dir\\}") >> > + "${CMAKE_INSTALL_PREFIX}/share/qtkeychain/translation= s")))))))=20=20 >>=20 >> Is Qt able to find translations installed there? Is some environment >> variable needed to tell it where to look for them? > > I don't really know. Could you check by running it with a non-English locale listed that appears in the =E2=80=98translations=E2=80=99 directory? Maybe run the application in =E2=80=98strace=E2=80=99 to see whether/where = it looks for its translation files. > Without this it tries to install them to > /gnu/store/...qt5/translations, so I tried to make a directory that > would make sense. In this patch I've changed it to just /translations, > but I still didn't see it in .guix-profile/share/{de,ro}/LC_MESSAGES/, > so I don't really know what to do with it. Qt has its own mechanism for translation of UI messages. The LC_MESSAGES thing is used by the =E2=80=98gettext=E2=80=99 function, part o= f libc. Applications using =E2=80=98gettext=E2=80=99 tell libc the location of their translations using =E2=80=98bindtextdomain=E2=80=99. Qt must have a way to know where translations are; maybe it has a function similar to =E2=80=98bindtextdomain=E2=80=99, in which case things = will just work regardless of where translations are installed. TIA, Ludo=E2=80=99.