[Pkg-gmagick-im-team] Bug#551017: imagemagick: FTBFS on hurd-i386: wrong PATH_MAX and /proc usage

Pino Toscano pino at kde.org
Wed Oct 14 22:59:36 UTC 2009

Package: imagemagick
Version: 7:
Severity: important
Tags: patch
User: debian-hurd at lists.debian.org
Usertags: hurd


as shown in [1], currently imagemagick does not build on GNU/Hurd.
The reason is in magick/utility.c, in the implementation of GetExecutionPath():
Hurd has both getpid() and readlink(), so the
code block is used. Although, this block has two problems for Hurd:
- inconditional usage of PATH_MAX (which is not a problem, as it could be fixed)
- use of /proc/$PID/{exe,file}; Hurd's proc have none of those two, so the code
  there would be unuseful anyway

The solution I chose was to exclude that block for Hurd, and add a new
Hurd-specific block which makes use of the GNU-specific program_invocation_name
extern variable (see /usr/include/errno.h) - and cwd if program_invocation_name
is relative - to get the absolute path of the execution application.

[1] http://buildd.debian-ports.org/fetch.php?&pkg=imagemagick&ver=7:

-------------- next part --------------
A non-text attachment was scrubbed...
Name: 01_hurd_fixes.diff
Type: text/x-c
Size: 1391 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/pkg-gmagick-im-team/attachments/20091015/c261b020/attachment.bin>

More information about the Pkg-gmagick-im-team mailing list