[Pkg-gmagick-im-team] Bug#959749: imagemagick-6.q16: behavior is different whether one runs "display" or "/usr/bin/display"
Vincent Lefevre
vincent at vinc17.net
Mon May 4 21:43:23 BST 2020
Package: imagemagick-6.q16
Version: 8:6.9.10.23+dfsg-2.1+b2
Severity: normal
First, note that I have as configured by default:
lrwxrwxrwx 1 root root 25 2016-10-14 03:28:16 /usr/bin/display -> /etc/alternatives/display
lrwxrwxrwx 1 root root 24 2016-10-14 03:28:16 /etc/alternatives/display -> /usr/bin/display-im6.q16
This seems to matter in the following.
The problem: the behavior is different whether one runs "display" or
"/usr/bin/display", even though /usr/bin/display is first in the path:
zira:~> which display
/usr/bin/display
The difference can first be seen with strace:
zira:~> strace display |& grep -E '/.?display'
execve("/usr/bin/display", ["display"], 0x7ffd0c7957a0 /* 132 vars */) = 0
readlink("/proc/2897115/exe", "/usr/bin/display-im6.q16", 4096) = 24
stat("/usr/bin/display-im6.q16", {st_mode=S_IFREG|0755, st_size=14488, ...}) = 0
access("/usr/bin/display-im6.q16", F_OK) = 0
openat(AT_FDCWD, "/home/vinc17/.display-im6.q16rc", O_RDONLY) = -1 ENOENT (No such file or directory)
zira:~> strace /usr/bin/display |& grep -E '/.?display'
execve("/usr/bin/display", ["/usr/bin/display"], 0x7fff78329600 /* 132 vars */) = 0
stat("/usr/bin/display", {st_mode=S_IFREG|0755, st_size=14488, ...}) = 0
access("/usr/bin/display", F_OK) = 0
openat(AT_FDCWD, "/home/vinc17/.displayrc", O_RDONLY) = -1 ENOENT (No such file or directory)
It seems that if one does not run the command as its full path, "display"
tries to guess what the real program name is via /proc, so that it gets
the result after symlink resolution, hence the difference.
The configuration file (here, non-existing with both invocations) is
not the only difference. The X resource is the program name determined
in the above way ("display-im6.q16" and "display" respectively), thus
is affected too, and ditto for the class, but with a capital "D". The
consequence is that I get a different font in the menus, unless I use
the -font option.
This seems to be a regression, as I had added
Display*font: -adobe-helvetica-bold-r-normal--0-0-0-0-p-0-*
in my .Xresources in 2015, and IIRC, it was working with "display"
since this is how I normally run it. Now, it is taken into account
only with "/usr/bin/display".
BTW, "Display-im6.q16" seems to be an invalid class name:
zira:~> appres Display-im6.q16
usage: appres [class [instance]] [-1] [-V] [toolkitoptions]
-1 list resources only at the specified level
-V print command version and exit
The number of class and instance elements must be equal.
-- Package-specific info:
ImageMagick program version
---------------------------
animate: ImageMagick 6.9.10-23 Q16 x86_64 20190101 https://imagemagick.org
compare: ImageMagick 6.9.10-23 Q16 x86_64 20190101 https://imagemagick.org
convert: ImageMagick 6.9.10-23 Q16 x86_64 20190101 https://imagemagick.org
composite: ImageMagick 6.9.10-23 Q16 x86_64 20190101 https://imagemagick.org
conjure: ImageMagick 6.9.10-23 Q16 x86_64 20190101 https://imagemagick.org
display: ImageMagick 6.9.10-23 Q16 x86_64 20190101 https://imagemagick.org
identify: ImageMagick 6.9.10-23 Q16 x86_64 20190101 https://imagemagick.org
import: ImageMagick 6.9.10-23 Q16 x86_64 20190101 https://imagemagick.org
mogrify: ImageMagick 6.9.10-23 Q16 x86_64 20190101 https://imagemagick.org
montage: ImageMagick 6.9.10-23 Q16 x86_64 20190101 https://imagemagick.org
stream: ImageMagick 6.9.10-23 Q16 x86_64 20190101 https://imagemagick.org
-- System Information:
Debian Release: bullseye/sid
APT prefers unstable-debug
APT policy: (500, 'unstable-debug'), (500, 'stable-updates'), (500, 'unstable'), (500, 'testing'), (500, 'stable'), (1, 'experimental')
Architecture: amd64 (x86_64)
Kernel: Linux 5.6.0-1-amd64 (SMP w/8 CPU cores)
Locale: LANG=POSIX, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), LANGUAGE=POSIX (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled
Versions of packages imagemagick-6.q16 depends on:
ii hicolor-icon-theme 0.17-2
ii libc6 2.30-4
ii libmagickcore-6.q16-6 8:6.9.10.23+dfsg-2.1+b2
ii libmagickwand-6.q16-6 8:6.9.10.23+dfsg-2.1+b2
Versions of packages imagemagick-6.q16 recommends:
ii ghostscript 9.52~dfsg-1
ii libmagickcore-6.q16-6-extra 8:6.9.10.23+dfsg-2.1+b2
ii netpbm 2:10.0-15.3+b2
Versions of packages imagemagick-6.q16 suggests:
pn autotrace <none>
ii cups-bsd [lpr] 2.3.3-1
ii curl 7.68.0-1
pn enscript <none>
ii ffmpeg 7:4.2.2-1+b1
ii fig2dev [transfig] 1:3.2.7b-3
ii gimp 2.10.18-1
ii gnuplot-qt [gnuplot] 5.2.8+dfsg1-2
pn grads <none>
pn graphviz <none>
ii groff-base 1.22.4-4
pn hp2xx <none>
pn html2ps <none>
ii imagemagick-6-doc [imagemagick-doc] 8:6.9.10.23+dfsg-2.1
ii libwmf-bin 0.2.8.4-17
ii mplayer 2:1.3.0-8+b6
pn povray <none>
pn radiance <none>
ii sane-utils 1.0.27-3.2+b1
ii texlive-binaries [texlive-base-bin] 2020.20200327.54578-4
pn ufraw-batch <none>
ii xdg-utils 1.1.3-2
-- no debconf information
--
Vincent Lefèvre <vincent at vinc17.net> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)
More information about the Pkg-gmagick-im-team
mailing list