#1128017 debhelper: config files are always split

Package:
debhelper
Source:
debhelper
Submitter:
Jonas Smedegaard
Date:
2026-02-15 09:57:02 UTC
Severity:
normal
Tags:
#1128017#5
Date:
2026-02-15 08:40:08 UTC
From:
To:
The package src:icc-profiles 2.4 contains this file:

"IDEAlliance/Introducing PrintWide - Idealliance.pdf"

I then provide debian/docs with this content:

IDEAlliance

The resulting binary package contains this file:

"CONTENTS/usr/share/doc/icc-profiles/IDEAlliance/Introducing PrintWide -"

I did not expect dh_installdocs to strip " Idealliance.pdf" from the
filename.

 - Jonas

- -- System Information:
Debian Release: forky/sid
  APT prefers buildd-unstable
  APT policy: (500, 'buildd-unstable'), (500, 'unstable'), (1, 'buildd-experimental'), (1, 'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 6.17.12+deb14-amd64 (SMP w/8 CPU threads; PREEMPT)
Locale: LANG=da_DK.UTF-8, LC_CTYPE=da_DK.UTF-8 (charmap=UTF-8), LANGUAGE not set
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages debhelper depends on:
ii  autotools-dev            20240727.1
ii  dh-autoreconf            21+nmu1
ii  dh-strip-nondeterminism  1.15.0-1
ii  dpkg                     1.23.5
ii  dpkg-dev                 1.23.5
ii  dwz                      0.16-2
ii  file                     1:5.46-5+b1
ii  libdebhelper-perl        13.29
ii  libdpkg-perl             1.23.5
ii  man-db                   2.13.1-1
ii  perl                     5.40.1-7
ii  po-debconf               1.0.22

debhelper recommends no packages.

Versions of packages debhelper suggests:
pn  dh-make  <none>

- -- no debconf information
-----BEGIN PGP SIGNATURE-----

iQJABAEBCgAqFiEEn+Ppw2aRpp/1PMaELHwxRsGgASEFAmmRhmgMHGRyQGpvbmVz
LmRrAAoJECx8MUbBoAEhk8wP/jhJoYzjLuLmOpfcIq/qoJa2Gw9hKz4fnGCTJBxq
pOg1vWEcYqgwVIxAkw+blcH/oEqMSyenlNjXCheHAQUt7s1OXjP+lTZQsumJfA6H
XcKc08mL5gY2SLZOadRBpcH/TNpt/N0sg2PDLnB8DJM/J/jLa9XtFTlo86HJMREJ
d3FnDXUwH+yu+IqDrwXoz0qZzRf0JB/GJnlozNkWgyjKGxvMXitw1YN7p708k1d9
C8y5iB/ioLLNrXB0bAfI3k+XEKcFMfqU+/45We0tPuXRHONrS9AMKG0hmQS0GS7C
wajRgl877WpgoKtRQ6Ih2fMBu1Up3tgZzKajlTe7HGDNogpCjefQdgRVaOmjD78d
P8oPcuYTCw1jvB82sfdvqvkbPPG6+5druPP8pfT0/BwiUQwif9nANYnhlwVjJ+li
N32Sfp8youoBhihKlhTt9dM1/VRJUMpp9EhEfRG9VOBIs92REdGcNTUA3zPNz/2C
TsuWIDnpntkKeZH6ovzfHn0/8DSOwnKGoSf8h3+rBkZrlRJEQZP44K+IiKMnwfJq
tr100zdgpdAK81CzsFEY2EhiXJX3UFkkEec+KPcQDj6xAeUY7DHyO9l1ZxZGNlxk
DbOF5ppBdt5zMqxeB3SAILp2xhhS68hRTieu3tXlGUI77HaSRwvGkN0EawsMgEMC
Fssl
=LqLo
-----END PGP SIGNATURE-----

#1128017#10
Date:
2026-02-15 09:54:35 UTC
From:
To:
# Being honest here. See below for work arounds
# and solutions
tags 1128017 wontfix
retitle 1128017 debhelper: config files are always split
thanks

Jonas Smedegaard:
configuration files via `filearray` and `filedoublearray` that I do not
expect to be fixed.

To be honest, I am a bit surprised that any spaces survived and the code
splits on all white spaces (it uses the `split` function from Perl with
no arguments).

I can offer the following work around/solutions:

  * Using a substitution variable such as ${Space} and ${Tab}. These are
    expanded after the `split` and therefore do not count as separators.
    Assumes compat 13+. Relevant docs are in `man 7 debhelper` though, it
    should literally just `s/ /${Space}/` for the spaces you want to
    keep.

    It is one of the reasons the substitution feature was added and
    applied after the split (and before the glob). It is the "official
    solution" (read work around).

  * Using an executable `debian/pkg.docs`, since debhelper does not split
    the output (nor glob) the output of those. It is a pain, since you
    have to provide your own glob plus never emit comments, etc. On the
    "plus" side it works since compat 9. Still, I do not recommend it,
    because it will be a pain to maintain.

  * Given the simplicity of the package involved, you should be able to
    migrate it to `debputy`, which does not have this issue[1]. It is
    an entirely different packaging stack, and I do not know whether it
    is fits your style.

    - I ended up writing a patch for it, because the instructions would
      be incomplete. I have no expectations that you consider this patch.
      I wrote it because if you happened to find it interesting, I wanted
      the transition to be a smooth process and my tooling was not
      adequate at time of writing.

PS: While testing my own instructions, I noted that `debputy lint` flags
the `Comments` fields in `debian/copyright` as being a typo of
`Comment`. This is based on the official documentation
(https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/#comment-field)
uses `Comment` (without an `s`) as well with no reference to `Comments`
being an alias. In fact `Comments` are not used at all in that page.

I hope this response was useful.

Best regards,
Niels


[1]: The full part is in the attached patch. It is based on the following:

root$ apt install debputy debputy-lsp  # unstable or stable-backports
$ cd path/to/icc-profiles
$ debputy migrate-from-dh
    --acceptable-migration-issues=min-compat-level,dh-hook-targets
    --migration-target full

# Normally, fix up the manual bits. But I have attached a full patch
# because the migration code is still lacking for the `full` target.

$ git commit -a