Wednesday, October 13, 2021

Re: NEW: devel/dtools

On Wed, 13 Oct 2021 14:01:56 +0000
Brian Callahan <bcallah@posteo.net> wrote:

> Attached is a new port, devel/dtools. These are the ancillary tools for
> the D programming language compiler.

Build fails on powerpc and powerpc64, because logbl(3) is missing in
/usr/lib/libm.a. This shouldn't block the import, but I won't ok
before I either build dtools on amd64, or fix libm; I might need to
add LDBL_MAYBE_UNUSED_CLONE(logb) in /usr/src/lib/libm/src/s_logb.c

The error on powerpc64 is,

/usr/local/bin/gdmd -O -release -inline -w -de -ofdget dget.d
ld: error: undefined symbol: logbl
>>> referenced by math.d:3721 (/usr/ports/pobj/gcc-11.2.0/gcc-11.2.0/libphobos/src/std/math.d:3721)
>>> math.o:(_D3std4math4logbFNbNiNeeZe) in archive /usr/local/lib/gcc/powerpc64-unknown-openbsd7.0/11.2.0/../../../libgphobos.a
>>> did you mean: ilogbl
>>> defined in: /usr/lib/libm.so.10.1
collect2: error: ld returned 1 exit status
gmake: *** [posix.mak:47: dget] Error 1

On powerpc, this port (and probably every port that runs gdc) needs
USE_LLD = No (like lang/gcc/11),

.if ${MACHINE_ARCH} == "powerpc"
# ld: error: relocation refers to a discarded section
USE_LLD = No
.endif

This allows powerpc to reach "undefined reference to `logbl'"

> Lastly, the catdoc program in this package was renamed catdocd to avoid
> a conflict with textproc/catdoc.

I checked if other distros rename catdoc, and found these:

Alpine Linux (builds dtools without catdoc)
Arch Linux dtools-catdoc
NixOS catdoc
Void Linux dtools-catdoc

But I don't like dtools- prefix, so name "catdocd" is good enough.
--George

No comments:

Post a Comment