Page 1 of 1

Translations not installing building QLC+ 4.12.4 GIT

Posted: Tue Mar 23, 2021 5:25 pm
by sbenejam
Compiling QLC+ 4.12.4 GIT in Ubuntu 20.04 against Qt5.15.2 after executing sudo make install the translations are not installing in /usr/share/qlcplus/translations.
After doing some searches and testing different solutions I found this commit in QLC+ Git : https://github.com/mcallegari/qlcplus/c ... dd710b9e89
In this commit I found this explanation: "qmake will ignore the generated .qm files if they don't already exist at build system configuration time."
I got translations finally installed running ./translate.sh before running qmake. I don't know what has changed in the QLC+ source code or if this issue is a qmake problem. I've seen that in Makefile no commands are generated to install translations if ./translate.sh is not run before qmake.

Re: Translations not installing building QLC+ 4.12.4 GIT

Posted: Wed Mar 24, 2021 10:18 am
by mcallegari
I just checked and it works for me on Ubuntu 20.04 too.
Translation files are created and installed during 'make install', not during 'make' (see INSTALLS += translations)
The commit you specified is irrelevant for Ubuntu, as .spec file is used to create the RPM package for Fedora.

Re: Translations not installing building QLC+ 4.12.4 GIT

Posted: Wed Mar 24, 2021 1:42 pm
by sbenejam
In my computers sometimes it works and sometimes doesn't work. When I execute /home/user/Qt/5.15.2/gcc_64/bin/qmake in the Makefile the following lines are not created.

Code: Select all

$(QINSTALL) /home/sbenejam/qlctest/qlcplus_de_DE.qm $(INSTALL_ROOT)/usr/share/qlcplus/translations/qlcplus_de_DE.qm
        $(QINSTALL) /home/sbenejam/qlctest/qlcplus_es_ES.qm $(INSTALL_ROOT)/usr/share/qlcplus/translations/qlcplus_es_ES.qm
        $(QINSTALL) /home/sbenejam/qlctest/qlcplus_fr_FR.qm $(INSTALL_ROOT)/usr/share/qlcplus/translations/qlcplus_fr_FR.qm
        $(QINSTALL) /home/sbenejam/qlctest/qlcplus_it_IT.qm $(INSTALL_ROOT)/usr/share/qlcplus/translations/qlcplus_it_IT.qm
        $(QINSTALL) /home/sbenejam/qlctest/qlcplus_nl_NL.qm $(INSTALL_ROOT)/usr/share/qlcplus/translations/qlcplus_nl_NL.qm
        $(QINSTALL) /home/sbenejam/qlctest/qlcplus_ca_ES.qm $(INSTALL_ROOT)/usr/share/qlcplus/translations/qlcplus_ca_ES.qm
        $(QINSTALL) /home/sbenejam/qlctest/qlcplus_ja_JP.qm $(INSTALL_ROOT)/usr/share/qlcplus/translations/qlcplus_ja_JP.qm
        $(QINSTALL) /home/sbenejam/qlctest/qlcplus_cz_CZ.qm $(INSTALL_ROOT)/usr/share/qlcplus/translations/qlcplus_cz_CZ.qm
        $(QINSTALL) /home/sbenejam/qlctest/qlcplus_pt_BR.qm $(INSTALL_ROOT)/usr/share/qlcplus/translations/qlcplus_pt_BR.qm

uninstall_translations: FORCE
        -$(DEL_FILE) -r $(INSTALL_ROOT)/usr/share/qlcplus/translations/qlcplus_pt_BR.qm
        -$(DEL_FILE) -r $(INSTALL_ROOT)/usr/share/qlcplus/translations/qlcplus_cz_CZ.qm
        -$(DEL_FILE) -r $(INSTALL_ROOT)/usr/share/qlcplus/translations/qlcplus_ja_JP.qm
        -$(DEL_FILE) -r $(INSTALL_ROOT)/usr/share/qlcplus/translations/qlcplus_ca_ES.qm
        -$(DEL_FILE) -r $(INSTALL_ROOT)/usr/share/qlcplus/translations/qlcplus_nl_NL.qm
        -$(DEL_FILE) -r $(INSTALL_ROOT)/usr/share/qlcplus/translations/qlcplus_it_IT.qm
        -$(DEL_FILE) -r $(INSTALL_ROOT)/usr/share/qlcplus/translations/qlcplus_fr_FR.qm
        -$(DEL_FILE) -r $(INSTALL_ROOT)/usr/share/qlcplus/translations/qlcplus_es_ES.qm
        -$(DEL_FILE) -r $(INSTALL_ROOT)/usr/share/qlcplus/translations/qlcplus_de_DE.qm
        -$(DEL_DIR) $(INSTALL_ROOT)/usr/share/qlcplus/translations/ 
If I execute ./translate.sh before /home/user/Qt/5.15.2/gcc_64/bin/qmake this lines are present in the Makefile. If this lines are not present in Makefile the translations are not installing. It's very strange.
To compile QLC+ I usually run make distclean, qmake, make -j8, sudo make install. I'm missing something?.

Re: Translations not installing building QLC+ 4.12.4 GIT

Posted: Wed Mar 24, 2021 4:20 pm
by mcallegari
To compile QLC+ I usually run make distclean, qmake, make -j8, sudo make install. I'm missing something?
It's the correct sequence of commands.
Perhaps make sure after distclean that no qm files are present in the folder. (even though the distclean target now includes qm removal)

Re: Translations not installing building QLC+ 4.12.4 GIT

Posted: Wed Mar 24, 2021 5:18 pm
by sbenejam
Hi Massimo,
Attached you can find the Makefile generated after executing /home/user/Qt/5.15.2/gcc_64/bin/qmake on a freshly downloaded QLC+ source from github. Compiling with make and installing with sudo make install the translations are not installing in /usr/share/qlcplus/translations.
I repeated executing ./translate.sh before /home/user/Qt/5.15.2/gcc_64/bin/qmake, see the attached Makefile-translate.txt this file now includes some lines referencing to translation qm files. After make and sudo make install translation file are newly generated and copied to /usr/share/qlcplus/translations as expected.
One more thing make distclean deletes the qm files early generated.
On my Ubuntu gcc version is 9.3.0.

Re: Translations not installing building QLC+ 4.12.4 GIT

Posted: Fri Mar 26, 2021 5:38 pm
by mcallegari
Can you please try with Qt version 5.14.2?
Thanks

Re: Translations not installing building QLC+ 4.12.4 GIT

Posted: Fri Mar 26, 2021 5:55 pm
by sbenejam
mcallegari wrote: Fri Mar 26, 2021 5:38 pm Can you please try with Qt version 5.14.2?
Thanks
I'm installing Qt version 5.14.2. I'll try later and report the results.

Re: Translations not installing building QLC+ 4.12.4 GIT

Posted: Fri Mar 26, 2021 9:16 pm
by sbenejam
I built QLC+ with Qt version 5.14.2 and the translations are not installed, although if they are created at the end of sudo make install. I tried with a freshly cloned sources from Github.
What more tests can I do?.

Re: Translations not installing building QLC+ 4.12.4 GIT

Posted: Sat Mar 27, 2021 11:41 am
by sbenejam
I tested too with the default Qt on Ubuntu that is Qt version 5.12.8, same results, translations are not installing. For me is not a problem to run ./translate.sh before executing qmake to get translations installed. But I think that some users can run into problems compiling QLC+ from sources.

Re: Translations not installing building QLC+ 4.12.4 GIT

Posted: Sat Sep 18, 2021 9:13 am
by sbenejam
It seems that this issue is solved by this commit https://github.com/mcallegari/qlcplus/c ... affdc36be8