This patch renames the 'ttf-dejavu' package to 'fonts-dejavu' so Koha will install on Debian 11
here's the error on deb11... $ docker run -ti debian:bullseye bash $ echo 'deb [trusted=yes] http://debian.koha-community.org/koha stable main' > /etc/apt/sources.list.d/koha.list $ apt-get update; apt-get -y upgrade $ apt-cache policy koha-common koha-common: Installed: (none) Candidate: 20.05.00-1 Version table: 20.05.00-1 500 500 http://debian.koha-community.org/koha stable/main amd64 Packages $ apt-get -q -y -s install koha-common Reading package lists... Building dependency tree... Reading state information... Some packages could not be installed. This may mean that you have requested an impossible situation or if you are using the unstable distribution that some required packages have not yet been created or been moved out of Incoming. The following information may help to resolve the situation: The following packages have unmet dependencies: koha-common : Depends: ttf-dejavu but it is not installable E: Unable to correct problems, you have held broken packages.
Created attachment 106000 [details] [review] Bug 25792: Rename 'ttf-dejavu' package to 'fonts-dejavu' for Debian 11 to test... 1/ attempt to install koha 20.05 package on deb11, fail :'( 2/ apply patch and build new koha package 3/ attempt to install new koha package on deb11, succeed!
(In reply to Mason James from comment #2) > Created attachment 106000 [details] [review] [review] > Bug 25792: Rename 'ttf-dejavu' package to 'fonts-dejavu' for Debian 11 > > to test... > 1/ attempt to install koha 20.05 package on deb11, fail :'( > 2/ apply patch and build new koha package > 3/ attempt to install new koha package on deb11, succeed! Isn't this change going to break non bullseye OSs?
(In reply to Tomás Cohen Arazi from comment #3) > (In reply to Mason James from comment #2) > > Created attachment 106000 [details] [review] [review] [review] > > Bug 25792: Rename 'ttf-dejavu' package to 'fonts-dejavu' for Debian 11 > > > > to test... > > 1/ attempt to install koha 20.05 package on deb11, fail :'( > > 2/ apply patch and build new koha package > > 3/ attempt to install new koha package on deb11, succeed! > > Isn't this change going to break non bullseye OSs? hmm, i think no breakage will happen the 'fonts-dejavu' package has been backported to older OSs the 'ttf-dejavu' package will provide symlinks to handle current Koha installations that upgrade
Created attachment 106243 [details] [review] Bug 25792: Rename 'ttf-dejavu' package to 'fonts-dejavu' for Debian 11 to test... 1/ attempt to install koha 20.05 package on deb11, fail :'( 2/ apply patch and build new koha package 3/ attempt to install new koha package on deb11, succeed! Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
The fonts-dejavu package is available back to Jessie and the plan is to drop the transitional ttf-dejavu package in bullseye: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=872809 So this is ok.
(In reply to Tomás Cohen Arazi from comment #6) > The fonts-dejavu package is available back to Jessie and the plan is to drop > the transitional ttf-dejavu package in bullseye: > > https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=872809 > > So this is ok. Can we remove reference to ttf-dejavu ? In ubuntu fonts-dejavu is available since trusty.
(In reply to Julian Maurice from comment #7) > (In reply to Tomás Cohen Arazi from comment #6) > > The fonts-dejavu package is available back to Jessie and the plan is to drop > > the transitional ttf-dejavu package in bullseye: > > > > https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=872809 > > > > So this is ok. > > Can we remove reference to ttf-dejavu ? In ubuntu fonts-dejavu is available > since trusty. hmm, yes, i think so... but, there is a problem for current koha installs, that the font path in koha-conf.xml will be incorrect <ttf> <font type="TR" >/usr/share/fonts/truetype/ttf-dejavu/DejaVuSerif.ttf</font> ... </ttf> when the unrequired ttf-dejavu package's symlinks are removed (eg: apt autoremove) the paths will need to be manually corrected keeping the ttf-dejavu reference in debian/control would postpone this problem until the system is upgraded to deb11/bullseye (which is probably a good thing?) any thoughts?
(In reply to Mason James from comment #8) > (In reply to Julian Maurice from comment #7) > > (In reply to Tomás Cohen Arazi from comment #6) > > > The fonts-dejavu package is available back to Jessie and the plan is to drop > > > the transitional ttf-dejavu package in bullseye: > > > > > > https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=872809 > > > > > > So this is ok. > > > > Can we remove reference to ttf-dejavu ? In ubuntu fonts-dejavu is available > > since trusty. > > hmm, yes, i think so... > > but, there is a problem for current koha installs, that the font path in > koha-conf.xml will be incorrect > > > <ttf> > <font type="TR" > >/usr/share/fonts/truetype/ttf-dejavu/DejaVuSerif.ttf</font> > ... > </ttf> > > > when the unrequired ttf-dejavu package's symlinks are removed (eg: apt > autoremove) the paths will need to be manually corrected > keeping the ttf-dejavu reference in debian/control would postpone this > problem until the system is upgraded to deb11/bullseye (which is probably a > good thing?) > > > any thoughts? Ok, it is probably better this way then.
> > when the unrequired ttf-dejavu package's symlinks are removed (eg: apt > > autoremove) the paths will need to be manually corrected > > keeping the ttf-dejavu reference in debian/control would postpone this > > problem until the system is upgraded to deb11/bullseye (which is probably a > > good thing?) > > > > good news, i tested my theory and found it to be incorrect :) there does not seem to be any problem when upgrading on bullseye. bullseye will allow both packages to be installed together 'apt autoremove' does not remove the ttf-dejavu* packages
Are you still on the cases her Julian?
(In reply to Martin Renvoize from comment #11) > Are you still on the cases her Julian? I wasn't. I only asked a question and it has been answered. Case is yours if you want it ;)
I am about to push this patch and see how things are going.
Pushed to master for 20.11, thanks to everybody involved!
Looks like we have something wrong 17:03:51 koha_1 | ERROR in koha-conf.xml -- missing <font type="H">/path/to/font.ttf</font> at /kohadevbox/koha/C4/Creators/PDF.pm line 120. 17:03:51 koha_1 | ERROR in koha-conf.xml -- missing <font type="H">/path/to/font.ttf</font> at /kohadevbox/koha/C4/Creators/PDF.pm line 120. 17:03:51 koha_1 | 17:03:51 koha_1 | # Failed test 'testing StrWidth() returns correct point width' 17:03:51 koha_1 | # at t/Creators.t line 55. 17:03:51 koha_1 | # got: '19.344' 17:03:51 koha_1 | # expected: '23.044921875' 17:03:51 koha_1 | 17:03:51 koha_1 | # Failed test 'testing Text() writes to the correct x-value' 17:03:51 koha_1 | # at t/Creators.t line 59. 17:03:51 koha_1 | # got: '29.344' 17:03:51 koha_1 | # expected: '33.044921875' 17:03:51 koha_1 | ERROR in koha-conf.xml -- missing <font type="TR">/path/to/font.ttf</font> at /kohadevbox/koha/C4/Creators/PDF.pm line 120. 17:03:51 koha_1 | ERROR in koha-conf.xml -- missing <font type="TB">/path/to/font.ttf</font> at /kohadevbox/koha/C4/Creators/PDF.pm line 120. 17:03:51 koha_1 | ERROR in koha-conf.xml -- missing <font type="TI">/path/to/font.ttf</font> at /kohadevbox/koha/C4/Creators/PDF.pm line 120. 17:03:51 koha_1 | ERROR in koha-conf.xml -- missing <font type="TBI">/path/to/font.ttf</font> at /kohadevbox/koha/C4/Creators/PDF.pm line 120. 17:03:51 koha_1 | ERROR in koha-conf.xml -- missing <font type="C">/path/to/font.ttf</font> at /kohadevbox/koha/C4/Creators/PDF.pm line 120. 17:03:51 koha_1 | ERROR in koha-conf.xml -- missing <font type="CB">/path/to/font.ttf</font> at /kohadevbox/koha/C4/Creators/PDF.pm line 120. 17:03:51 koha_1 | ERROR in koha-conf.xml -- missing <font type="CO">/path/to/font.ttf</font> at /kohadevbox/koha/C4/Creators/PDF.pm line 120. 17:03:51 koha_1 | ERROR in koha-conf.xml -- missing <font type="CBO">/path/to/font.ttf</font> at /kohadevbox/koha/C4/Creators/PDF.pm line 120. 17:03:51 koha_1 | ERROR in koha-conf.xml -- missing <font type="H">/path/to/font.ttf</font> at /kohadevbox/koha/C4/Creators/PDF.pm line 120. 17:03:51 koha_1 | ERROR in koha-conf.xml -- missing <font type="HO">/path/to/font.ttf</font> at /kohadevbox/koha/C4/Creators/PDF.pm line 120. 17:03:51 koha_1 | ERROR in koha-conf.xml -- missing <font type="HB">/path/to/font.ttf</font> at /kohadevbox/koha/C4/Creators/PDF.pm line 120. 17:03:51 koha_1 | ERROR in koha-conf.xml -- missing <font type="HBO">/path/to/font.ttf</font> at /kohadevbox/koha/C4/Creators/PDF.pm line 120. 17:03:51 koha_1 | Wide character in compress at /usr/share/perl5/PDF/Reuse.pm line 823.
backported to 20.05.x for 20.05.03
(In reply to Jonathan Druart from comment #15) > Looks like we have something wrong May have been fixed by https://gitlab.com/koha-community/koha-testing-docker/-/merge_requests/143
does this need to be backported to 19.11.x?
We have a problem with D11 and koha-conf.xml, the paths are wrong: 328 <font type="TR" >/usr/share/fonts/truetype/ttf-dejavu/DejaVuSerif.ttf</font> % locate DejaVuSerif.tt /usr/share/fonts/truetype/dejavu/DejaVuSerif.ttf
(In reply to Aleisha Amohia from comment #18) > does this need to be backported to 19.11.x? let's consider this patch for 19.11.10, after its been released for 20.05
(In reply to Jonathan Druart from comment #19) > We have a problem with D11 and koha-conf.xml, the paths are wrong: > > 328 <font type="TR" > >/usr/share/fonts/truetype/ttf-dejavu/DejaVuSerif.ttf</font> > > % locate DejaVuSerif.tt > /usr/share/fonts/truetype/dejavu/DejaVuSerif.ttf can you provide link to a failed build log?
(In reply to Mason James from comment #21) > (In reply to Jonathan Druart from comment #19) > > We have a problem with D11 and koha-conf.xml, the paths are wrong: > > > > 328 <font type="TR" > > >/usr/share/fonts/truetype/ttf-dejavu/DejaVuSerif.ttf</font> > > > > % locate DejaVuSerif.tt > > /usr/share/fonts/truetype/dejavu/DejaVuSerif.ttf > > can you provide link to a failed build log? The build is not failing. I saw errors when trying to generate patron cards. The problem is obvious, the paths are wrong. I thought we confirmed at some point there was a symling? % grep TR koha-conf.xml <font type="TR" >/usr/share/fonts/truetype/ttf-dejavu/DejaVuSerif.ttf</font> % ls /usr/share/fonts/truetype/ttf-dejavu/DejaVuSerif.ttf ls: cannot access '/usr/share/fonts/truetype/ttf-dejavu/DejaVuSerif.ttf': No such file or directory % ls /usr/share/fonts/truetype/dejavu/DejaVuSerif.ttf /usr/share/fonts/truetype/dejavu/DejaVuSerif.ttf
(In reply to Jonathan Druart from comment #22) > (In reply to Mason James from comment #21) > > (In reply to Jonathan Druart from comment #19) > > > We have a problem with D11 and koha-conf.xml, the paths are wrong: > > > > > > 328 <font type="TR" > > > >/usr/share/fonts/truetype/ttf-dejavu/DejaVuSerif.ttf</font> > > > > > > % locate DejaVuSerif.tt > > > /usr/share/fonts/truetype/dejavu/DejaVuSerif.ttf > > > > can you provide link to a failed build log? > > The build is not failing. I saw errors when trying to generate patron cards. > > The problem is obvious, the paths are wrong. I thought we confirmed at some > point there was a symling? > > % grep TR koha-conf.xml > <font type="TR" > >/usr/share/fonts/truetype/ttf-dejavu/DejaVuSerif.ttf</font> > > % ls /usr/share/fonts/truetype/ttf-dejavu/DejaVuSerif.ttf > ls: cannot access '/usr/share/fonts/truetype/ttf-dejavu/DejaVuSerif.ttf': No > such file or directory > % ls /usr/share/fonts/truetype/dejavu/DejaVuSerif.ttf > /usr/share/fonts/truetype/dejavu/DejaVuSerif.ttf the path in the koha-conf.xml file is looks correct, (testing via KTD on master-bullseye) mason@xen1$ docker-compose pull mason@xen1$ ku mason@xen1$ docker exec -it koha_koha_1 bash root@kohadevbox:/kohadevbox# dpkg -l | grep koha-common ii koha-common 20.06.00-25~git+20200819211444.9708bbe2-1 all root@kohadevbox:/kohadevbox# grep TR /etc/koha/sites/kohadev/koha-conf.xml <font type="TR" >/usr/share/fonts/truetype/dejavu/DejaVuSerif.ttf</font> root@kohadevbox:/kohadevbox# ls /usr/share/fonts/truetype/dejavu/DejaVuSerif.ttf /usr/share/fonts/truetype/dejavu/DejaVuSerif.ttf fyi, there is no symlink from the old to new files, (that info was incorrect). but apt allows the two font packages to co-exist when upgrading to d11, which prevents older installs from failing on upgrade
Hum indeed, it's correct now. Maybe the ktd images were not up-to-date.
(In reply to Mason James from comment #20) > (In reply to Aleisha Amohia from comment #18) > > does this need to be backported to 19.11.x? > > let's consider this patch for 19.11.10, after its been released for 20.05 (In reply to Lucas Gass from comment #16) > backported to 20.05.x for 20.05.03 hi Aleisha, can you push this patch to 19.11.x
backported to 19.11.x for 19.11.10
Backported to 19.05.x branch for 19.05.15