Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 642666 - sys-apps/darwin-miscutils: -Wsystem-headers causes large number of warnings
Summary: sys-apps/darwin-miscutils: -Wsystem-headers causes large number of warnings
Status: RESOLVED FIXED
Alias: None
Product: Gentoo/Alt
Classification: Unclassified
Component: Prefix Support (show other bugs)
Hardware: All OS X
: Normal normal (vote)
Assignee: Gentoo Prefix
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-12-29 18:43 UTC by Michael Weiser
Modified: 2018-01-01 19:05 UTC (History)
0 users

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


Attachments
Updated ebuild with silenced warnings (darwin-miscutils-12.ebuild,4.83 KB, text/plain)
2017-12-29 18:45 UTC, Michael Weiser
Details
Silence numerous warnings in md.c (md-147-warnings.patch,5.30 KB, patch)
2017-12-29 18:46 UTC, Michael Weiser
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Weiser 2017-12-29 18:43:13 UTC
Compiler option -Wsystem-headers causes a huge amount of warnings for every single file:

/usr/include/stdlib.h:342:6: warning: pointer is missing a nullability type
      specifier (_Nonnull, _Nullable, or _Null_unspecified)
      [-Wnullability-completeness]
void    *valloc(size_t) __alloc_size(1);
        ^
/usr/include/stdlib.h:342:6: note: insert '_Nullable' if the pointer may be null
/usr/include/stdlib.h:342:6: note: insert '_Nonnull' if the pointer should never
      be null
350 warnings generated.

Removing the option silences them and speeds up the build massively.

Reproducible: Always
Comment 1 Michael Weiser 2017-12-29 18:45:49 UTC
Created attachment 511986 [details]
Updated ebuild with silenced warnings

- remove -Wsystem-headers
- put LDFLAGS only on linker command lines to silence unused command line option warning
- patch md.c to silence warnings
- update misc and shell cmds to High Sierra versions
- add dependency on ncurses for ncal (should be fine for bootstrap since ncurses is merged before darwin-miscutils)
Comment 2 Michael Weiser 2017-12-29 18:46:15 UTC
Created attachment 511988 [details, diff]
Silence numerous warnings in md.c
Comment 3 Larry the Git Cow gentoo-dev 2018-01-01 19:05:04 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=56d30f30691c40e606d848ffbafac8029750bb99

commit 56d30f30691c40e606d848ffbafac8029750bb99
Author:     Fabian Groffen <grobian@gentoo.org>
AuthorDate: 2018-01-01 19:04:48 +0000
Commit:     Fabian Groffen <grobian@gentoo.org>
CommitDate: 2018-01-01 19:04:58 +0000

    sys-apps/darwin-miscutils: version bump to High Sierra version
    
    Add compilation fixes/patch by Michael Weiser from bug #642666.
    
    Closes: https://bugs.gentoo.org/642666
    Package-Manager: Portage-2.3.13, Repoman-2.3.3

 sys-apps/darwin-miscutils/Manifest                 |   3 +
 .../darwin-miscutils/darwin-miscutils-12.ebuild    | 156 +++++++++++++++++++++
 2 files changed, 159 insertions(+)