Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 713514 - net-mail/fdm-2.0-r1 : fdm.h: fatal error: sys/cdefs.h: No such file or directory
Summary: net-mail/fdm-2.0-r1 : fdm.h: fatal error: sys/cdefs.h: No such file or directory
Status: CONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Gentoo musl team
URL:
Whiteboard: cdefs.h
Keywords:
Depends on:
Blocks:
 
Reported: 2020-03-19 18:20 UTC by Toralf Förster
Modified: 2022-08-10 21:32 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge-info.txt (emerge-info.txt,16.42 KB, text/plain)
2020-03-19 18:20 UTC, Toralf Förster
Details
emerge-history.txt (emerge-history.txt,159.30 KB, text/plain)
2020-03-19 18:20 UTC, Toralf Förster
Details
environment (environment,36.87 KB, text/plain)
2020-03-19 18:20 UTC, Toralf Förster
Details
etc.portage.tbz2 (etc.portage.tbz2,17.41 KB, application/x-bzip)
2020-03-19 18:20 UTC, Toralf Förster
Details
logs.tbz2 (logs.tbz2,6.64 KB, application/x-bzip)
2020-03-19 18:20 UTC, Toralf Förster
Details
net-mail:fdm-2.0:20200319-180445.log (net-mail:fdm-2.0:20200319-180445.log,5.50 KB, text/plain)
2020-03-19 18:20 UTC, Toralf Förster
Details
temp.tbz2 (temp.tbz2,11.01 KB, application/x-bzip)
2020-03-19 18:20 UTC, Toralf Förster
Details
Fix base64 declarations, from makepost at firemail dot cc. (fdm-2.0-base64.patch,841 bytes, patch)
2022-08-10 21:24 UTC, CFuga
Details | Diff
Do not add base64.c twice, from Rosen Penev. (fdm-2.0-base64-twice.patch,541 bytes, patch)
2022-08-10 21:25 UTC, CFuga
Details | Diff
fixes for musl libc (0001-net-mail-fdm-fixes-for-musl-libc.patch,3.65 KB, patch)
2022-08-10 21:32 UTC, CFuga
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Toralf Förster gentoo-dev 2020-03-19 18:20:23 UTC
x86_64-gentoo-linux-musl-gcc -DPACKAGE_NAME=\fdm\ -DPACKAGE_TARNAME=\fdm\ -DPACKAGE_VERSION=\2.0\ -DPACKAGE_STRING=\fdm\ 2.0\ -DPACKAGE_BUGREPORT=\\ -DPACKAGE_URL=\\ -DPACKAGE=\fdm\ -DVERSION=\2.0\ -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_SYS_QUEUE_H=1 -DHAVE_MREMAP=1 -DHAVE_SETRESUID=1 -DHAVE_SETRESGID=1 -DHAVE_STRLCPY=1 -DHAVE_STRLCAT=1 -I.   -I/usr/local/include -DPCRE -DSYSCONFFILE=\/etc/fdm.conf\ -DSYSLOCKFILE=\/var/lib/run/fdm.lock\   -O2 -pipe -march=native -fno-common -falign-functions=32:25:16 -D_GNU_SOURCE -std=gnu99 -O2  -c -o attach.o attach.c
In file included from attach.c:24:
fdm.h:23:10: fatal error: sys/cdefs.h: No such file or directory
   23 | #include <sys/cdefs.h>
      |          ^~~~~~~~~~~~~
compilation terminated.

  -------------------------------------------------------------------

  This is an unstable amd64 chroot image at a tinderbox (==build bot)
  name: 17.0_musl-20200316-165821

  -------------------------------------------------------------------

gcc-config -l:
 [1] x86_64-gentoo-linux-musl-9.3.0 *
clang version 10.0.0 
Target: x86_64-gentoo-linux-musl
Thread model: posix
InstalledDir: /usr/lib/llvm/10/bin
/usr/lib/llvm/10
10.0.0
Available Python interpreters, in order of preference:
  [1]   python3.8
  [2]   python3.7
  [3]   python3.6
  [4]   python2.7 (fallback)
Available Ruby profiles:
  [1]   ruby24 (with Rubygems)
  [2]   ruby25 (with Rubygems) *
Available Rust versions:
  [1]   rust-1.41.1 *

repository:
==> /var/db/repos/gentoo/metadata/timestamp.chk <==
Wed, 18 Mar 2020 13:38:27 +0000
emerge -qpvO net-mail/fdm
[ebuild  N    ] net-mail/fdm-2.0  USE="pcre -examples -libressl"
Comment 1 Toralf Förster gentoo-dev 2020-03-19 18:20:26 UTC
Created attachment 622824 [details]
emerge-info.txt
Comment 2 Toralf Förster gentoo-dev 2020-03-19 18:20:29 UTC
Created attachment 622826 [details]
emerge-history.txt
Comment 3 Toralf Förster gentoo-dev 2020-03-19 18:20:31 UTC
Created attachment 622828 [details]
environment
Comment 4 Toralf Förster gentoo-dev 2020-03-19 18:20:34 UTC
Created attachment 622830 [details]
etc.portage.tbz2
Comment 5 Toralf Förster gentoo-dev 2020-03-19 18:20:37 UTC
Created attachment 622832 [details]
logs.tbz2
Comment 6 Toralf Förster gentoo-dev 2020-03-19 18:20:40 UTC
Created attachment 622834 [details]
net-mail:fdm-2.0:20200319-180445.log
Comment 7 Toralf Förster gentoo-dev 2020-03-19 18:20:43 UTC
Created attachment 622836 [details]
temp.tbz2
Comment 8 Michael 'veremitz' Everitt 2020-03-19 19:15:02 UTC
musl upstream has a FAQ entry specifically for this error:
https://wiki.musl-libc.org/faq.html#Q:-When-compiling-something-against-musl,-I-get-error-messages-about-%3Ccode%3Esys/cdefs.h%3C/code%3E

We will need to check/report upstream and patch affected code temporarily.
Comment 9 Agostino Sarubbo gentoo-dev 2022-02-01 17:36:59 UTC
tinderbox_musl has reproduced this issue with version 2.0-r1 - Updating summary.
Comment 10 CFuga 2022-08-10 21:24:15 UTC
Created attachment 799181 [details, diff]
Fix base64 declarations, from makepost at firemail dot cc.

Patch from upstream, removes <sys/cdefs.h> include

https://github.com/nicm/fdm/commit/519e41833c1f7d353c09d8d51bfd6d13d0cfc16c
Comment 11 CFuga 2022-08-10 21:25:46 UTC
Created attachment 799183 [details, diff]
Do not add base64.c twice, from Rosen Penev.

Patch from upstream

https://github.com/nicm/fdm/commit/519e41833c1f7d353c09d8d51bfd6d13d0cfc16c
Comment 12 CFuga 2022-08-10 21:32:45 UTC
Created attachment 799185 [details, diff]
fixes for musl libc

This patch includes:

* upstream patch to remove <sys/cdefs.h> include
* upstream patch to fix base64.c added twice (+ required autoreconf)
* adds sys-libs/queue-standalone as a dependency when compiled for musl