• Error when building using iconv to convert problematic encondings to UT

    From Jose G. =?ISO-8859-1?Q?L=F3pez?=@21:1/5 to All on Mon Jul 11 20:20:01 2022
    Dear mentors,

    I'm working on importing a new upstream version for scid package and I want to get rid of "national-encoding" lintian warning.
    I'm trying to use iconv to convert problematic encondings to UTF-8 but I always get an error, no matter where I put instructions (override_dh_auto_install, override_dh_install). Files exists when the command is launched ...

    I have pushed my changes to a devel branch[0]. To build from that branch I use `gbp buildpackage --git-debian-branch=devel`.

    --- Output ---
    iconv -f ISO-8859-15 -t UTF-8 -o /home/josgalo/devel/debian/packaging/scid/build-area/scid-4.7.4+dfsg1/debian/tmp/scid/usr/share/scid/tcl/lang/hungary.tcl \
    /home/josgalo/devel/debian/packaging/scid/build-area/scid-4.7.4+dfsg1/debian/tmp/scid/usr/share/scid/tcl/lang/hungary.tcl
    make[1]: *** [debian/rules:23: override_dh_auto_install] Error del bus
    make[1]: se sale del directorio '/home/josgalo/devel/debian/packaging/scid/build-area/scid-4.7.4+dfsg1'
    make: *** [debian/rules:9: binary] Error 2
    dpkg-buildpackage: fallo: fakeroot debian/rules binary subprocess returned exit status 2
    ---

    Could you point me where the error is? Or get some examples from other packages.
    Thank you very much!

    [0]https://salsa.debian.org/josgalo-guest/scid/-/tree/devel

    Regards,

    -----BEGIN PGP SIGNATURE-----

    iQIzBAEBCgAdFiEErjybAXQDiUP1e5CQB1rixSTQ0UIFAmLMaYMACgkQB1rixSTQ 0UL9RQ/9G+AHPORF80ywOll3/LeHHGr/Np2Gh27UywrOphK12s8pa9+Gk20RTvoz rMVz4xBFfJRzlrKIbxUhqmRWqMSaS31bNKobK9gg9kUe40sWukaoUhegnnf+Ez
  • From Andrey Rahmatullin@21:1/5 to All on Mon Jul 11 21:00:01 2022
    On Mon, Jul 11, 2022 at 08:18:43PM +0200, Jose G. López wrote:
    I'm working on importing a new upstream version for scid package and I want to get rid of "national-encoding" lintian warning.
    Are you sure converting that file is useful and won't break the software for the
    use cases when this file is used?

    --- Output ---
    iconv -f ISO-8859-15 -t UTF-8 -o /home/josgalo/devel/debian/packaging/scid/build-area/scid-4.7.4+dfsg1/debian/tmp/scid/usr/share/scid/tcl/lang/hungary.tcl \
    /home/josgalo/devel/debian/packaging/scid/build-area/scid-4.7.4+dfsg1/debian/tmp/scid/usr/share/scid/tcl/lang/hungary.tcl
    Your input and output file is the same. Looks like iconv crashes with
    SIGBUS in this case, instead of just silently truncating the file or
    something like that, as many other tools would do in this case. If you
    really want to convert the file, you need to output the result to a
    different file and then move it to the old location.

    make[1]: *** [debian/rules:23: override_dh_auto_install] Error del bus
    Please run your commands with LANG=C if you intend to show the output when asking for help.

    --
    WBR, wRAR

    -----BEGIN PGP SIGNATURE-----

    iQJhBAABCgBLFiEEolIP6gqGcKZh3YxVM2L3AxpJkuEFAmLMcowtFIAAAAAAFQAP cGthLWFkZHJlc3NAZ251cGcub3Jnd3JhckBkZWJpYW4ub3JnAAoJEDNi9wMaSZLh jwYQAKb17hkU6kmi+2FYs7MuFKjVWplCULQAyzUBoRdVhBolNDTDbB+TSHqmq4qN TWifkVP1oFvNZvZ+9ozFrUZiSy97Csa89Pg9Z/I/CQM/mXp/iEHd9BgQmpEjaDSn 4T81Pm+xNRYMfkj0W9allY4T3+f6l5d4PBuY7T4P3McD3J6h3aTjxFdy9lvBTlR1 9heJf84hSi6D4PqTeDO+wwoU2zEcB7iAPyAgEyeGtZjaOeq6T1B9aTyiXvmAz1Hj SxEVOg9iJ3B4xP2o8dihb3Z3ijLdaHQw24KE6i5XUg2fO2JYHHWE2jq8bj883Foa OQriFEqETrLqEx6KBmeEIEj4ydOnBH38/lgqMPsmQVAaDTvjzoAZF41voYOoYjHY mlRtTn61/2fnn2/8c0Ndc5wSxu665cRXhfSX1YqfVLFIT6sDM2XxF/35lDw+7iyy PNufxkdOGOh6VdPgWd6WWbOMJUDgl/6qBUeKEHiZ6Ram5j+AUySw16Im4UtFix0R 8yzFOeGKSPdugkJIG3Lqp2haeDKbtDjtr5RQeqV/QHrZgOMssFvJ7RF7u/9/5Gul +W5RXJROC0gZ1AwmUbVVVEsGzrVtdhI1sx2KeAQ7+/t3EDF0DSZ5YvO2ePqSKUQH kATwSfbvp/LwN2l1aDVewVmhImGQS/GbAAf+oTklrhFYlzTI
    =FJx3
    -----END PGP SIGNATURE-----

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Adam Borowski@21:1/5 to Andrey Rahmatullin on Mon Jul 11 22:10:02 2022
    On Mon, Jul 11, 2022 at 11:57:21PM +0500, Andrey Rahmatullin wrote:
    Your input and output file is the same. Looks like iconv crashes with
    SIGBUS in this case, instead of just silently truncating the file or something like that, as many other tools would do in this case. If you
    really want to convert the file, you need to output the result to a
    different file and then move it to the old location.

    Or use "sponge"; package "moreutils".


    Meow!
    --
    ⢀⣴⠾⠻⢶⣦⠀
    ⣾⠁⢠⠒⠀⣿⡁ What kind of a drug are "base" and "red pill"? I think acid is
    ⢿⡄⠘⠷⠚⠋⠀ LSD, which would make base... ? Judging from the behaviour of
    ⠈⠳⣄⠀⠀⠀⠀ those "based and redpilled", something nasty.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Jose G. =?ISO-8859-1?Q?L=F3pez?=@21:1/5 to Andrey Rahmatullin on Tue Jul 12 20:50:01 2022
    On Mon, 11 Jul 2022 23:57:21 +0500
    Andrey Rahmatullin <wrar@debian.org> wrote:

    Are you sure converting that file is useful and won't break the software for the
    use cases when this file is used?

    You're right it breaks program menus[0]. Once I handle to use iconv properly I see it ...

    On Mon, 11 Jul 2022 22:03:30 +0200
    Adam Borowski <kilobyte@angband.pl> wrote:

    On Mon, Jul 11, 2022 at 11:57:21PM +0500, Andrey Rahmatullin wrote:
    Your input and output file is the same. Looks like iconv crashes with SIGBUS in this case, instead of just silently truncating the file or something like that, as many other tools would do in this case. If you really want to convert the file, you need to output the result to a different file and then move it to the old location.

    Or use "sponge"; package "moreutils".


    I will better fill in a request/bug upstream.
    Thank you both!

    [0]https://imgur.com/a/ngd3pXb

    Regards,

    -----BEGIN PGP SIGNATURE-----

    iQIzBAEBCgAdFiEErjybAXQDiUP1e5CQB1rixSTQ0UIFAmLNwHwACgkQB1rixSTQ 0UKlfA/9H92fMefBfKVsYUQGxPi6Mg+k9r9xCD2umGyPQbAza5hPlvfJXIJqAAj2 GOgHWefwnV2wxxLyAE8033OeUcXlsJMJ9DjPMaDHZyqKUiFkqcG8/cHdgwFr5/Q4 xIxMlQek44HZTaFrl7lbxVeH1eQyXfb8nl6gecuH+OWpf1BCe7tLVmsWCFX3lZYF QuerQICvZfbRbkfCSIQy5KM0OvBtZgrk1JibXMDwN0PQb7Ate+ik2WkACu9ZjbXS xqwz3Yhkxuqm0e1Myw03UIXte0Z+57JaFB9MXB6C5jywhXfL8CY/85CLzR2HfWw0 cNmDv28+/3Z+ShnoQH5Mdg6yP3sDrhcoroxp9K9To//i6WBqHvEtmK3ngc4YM5LM uuhRzoGcd3uoYCzs+cFDQPoQfPtAnScL+N2UmQOQpOnIy8nXuYPhvuEouwAciq2P BmCsynupO3JQgdq1CgtSVz3j9fPKxjrz3JxHimcuHXVPopbUi2VEwf9Monov4V2G rj+jZvTk7fu7QmC/4+7Ut10DkSQo5pBzEyfNpNjL1TgQRH9jrj/AEgtV5ggbQZMh hwmWEKz9+/m/wGwHXrKJaMUNHvsCVUB9bp8rxDuHwQnSJnau/03LePxzQ+ApZzif LyurcjKwz4OQGq7Ti7Um9wJ1wne0rX8ylcOAFtaEuZ5LLSfrz9Y=
    =o+e8
    -----END PGP SIGNATURE-----

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)