Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 712628 - mail-filter/libmilter-1.0.2_p1 : ../.../cdefs.h: fatal error: sys/cdefs.h: No such file or directory
Summary: mail-filter/libmilter-1.0.2_p1 : ../.../cdefs.h: fatal error: sys/cdefs.h: No...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo musl team
URL:
Whiteboard: cdefs.h
Keywords: PullRequest
: 713132 (view as bug list)
Depends on:
Blocks:
 
Reported: 2020-03-15 09:27 UTC by Toralf Förster
Modified: 2020-06-28 10:41 UTC (History)
1 user (show)

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


Attachments
emerge-info.txt (emerge-info.txt,15.42 KB, text/plain)
2020-03-15 09:27 UTC, Toralf Förster
Details
emerge-history.txt (emerge-history.txt,99.45 KB, text/plain)
2020-03-15 09:27 UTC, Toralf Förster
Details
environment (environment,50.96 KB, text/plain)
2020-03-15 09:27 UTC, Toralf Förster
Details
etc.portage.tbz2 (etc.portage.tbz2,11.98 KB, application/x-bzip)
2020-03-15 09:27 UTC, Toralf Förster
Details
mail-filter:libmilter-1.0.2_p1:20200315-010252.log (mail-filter:libmilter-1.0.2_p1:20200315-010252.log,7.07 KB, text/plain)
2020-03-15 09:27 UTC, Toralf Förster
Details

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-15 09:27:21 UTC
In file included from ../../include/sm/gen.h:21,
                 from main.c:11:
../../include/sm/cdefs.h:29:12: fatal error: sys/cdefs.h: No such file or directory
   29 | #  include <sys/cdefs.h>
      |            ^~~~~~~~~~~~~
compilation terminated.

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

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

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

gcc-config -l:
 [1] x86_64-gentoo-linux-musl-9.2.0 *
 [2] 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-bin-1.41.1
  [2]   rust-1.41.1 *
The following VMs are available for generation-2:

repository:
==> /var/db/repos/gentoo/metadata/timestamp.chk <==
Sat, 14 Mar 2020 23:50:12 +0000
emerge -qpvO mail-filter/libmilter
[ebuild  N    ] mail-filter/libmilter-1.0.2_p1  USE="ipv6 -poll"
Comment 1 Toralf Förster gentoo-dev 2020-03-15 09:27:24 UTC
Created attachment 619386 [details]
emerge-info.txt
Comment 2 Toralf Förster gentoo-dev 2020-03-15 09:27:26 UTC
Created attachment 619388 [details]
emerge-history.txt
Comment 3 Toralf Förster gentoo-dev 2020-03-15 09:27:29 UTC
Created attachment 619390 [details]
environment
Comment 4 Toralf Förster gentoo-dev 2020-03-15 09:27:32 UTC
Created attachment 619392 [details]
etc.portage.tbz2
Comment 5 Toralf Förster gentoo-dev 2020-03-15 09:27:35 UTC
Created attachment 619394 [details]
mail-filter:libmilter-1.0.2_p1:20200315-010252.log
Comment 6 Michael 'veremitz' Everitt 2020-03-16 14:10:05 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 7 Toralf Förster gentoo-dev 2020-03-16 16:12:41 UTC
The first attempt to tinderbox a musl image failed at all.

I'll mass close therefore all filed bug reports of the last days related to this tinderbox image.

Please feel free to re-open if you think that the bug is real in musl and not fixed by the musl overlay.
Comment 8 Michael 'veremitz' Everitt 2020-03-18 21:31:15 UTC
*** Bug 713132 has been marked as a duplicate of this bug. ***
Comment 9 Larry the Git Cow gentoo-dev 2020-06-28 10:41:11 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=874649cd8388e2959d55ab0eb51cc4654ce86837

commit 874649cd8388e2959d55ab0eb51cc4654ce86837
Author:     Wynn Wolf Arbor <wolf@oriole.systems>
AuthorDate: 2020-06-09 14:12:24 +0000
Commit:     Joonas Niilola <juippis@gentoo.org>
CommitDate: 2020-06-28 10:40:58 +0000

    mail-filter/libmilter: Fix build on musl
    
    The build on musl currently fails in two different places.
    
    Firstly, the sys/cdefs.h header is not available on musl. sendmail
    already includes all necessary compatibility definitions for cdefs.h in
    its 'libsm' library, but these are turned off through a platform
    specific header file when building on Linux. Since gcc processes
    -include options after all -D or -U options, we can't simply pass
    '-DSM_CONF_SYS_CDEFS_H=0' in the ebuild. Instead, for now, patch the
    Linux platform header file directly.
    
    Secondly, musl does not include the getipnodeby* function family. Pass
    '-DNEEDSGETIPNODE' to fix this.
    
    Closes: https://bugs.gentoo.org/712628
    Signed-off-by: Wynn Wolf Arbor <wolf@oriole.systems>
    Package-Manager: Portage-2.3.99, Repoman-2.3.22
    Signed-off-by: Joonas Niilola <juippis@gentoo.org>

 .../libmilter/files/libmilter-musl-disable-cdefs.patch        | 11 +++++++++++
 mail-filter/libmilter/libmilter-1.0.2_p1.ebuild               |  6 ++++++
 2 files changed, 17 insertions(+)