Bug 1083071

Summary: manual pages document _BSD_SOURCE and _SVID_SOURCE feature macros despite that they are deprecated
Product: [Fedora] Fedora Reporter: Petr Pisar <ppisar>
Component: man-pagesAssignee: Nikola Forró <nforro>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 22CC: mtk.manpages, pschiffe
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
URL: https://sourceware.org/glibc/wiki/Release/2.20#Packaging_Changes
Whiteboard:
Fixed In Version: man-pages-3.81-4.fc22 man-pages-3.81-5.fc22 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-04-02 04:17:15 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Petr Pisar 2014-04-01 12:40:52 UTC
glibc 2.19 introduced _DEFAULT_SOURCE feature macro which should replace _BSD_SOURCE and _SVID_SOURCE feature macros. glibc 2.20 will emit warning if the old are macros are used. See <https://sourceware.org/glibc/wiki/Release/2.20#Packaging_Changes>. This already happens in F21 as there is glibc-2.19.90, a 2.20 prerelease.

The point of man-pages is that various function synopses still promote _BSD_SOURCE and _SVID_SOURCE instead of the _DEFAULT_SOURCE. E.g.:

NAME
       mkstemp, mkostemp, mkstemps, mkostemps - create a unique temporary file

SYNOPSIS
       #include <stdlib.h>

       int mkstemp(char *template);

       int mkostemp(char *template, int flags);

       int mkstemps(char *template, int suffixlen);

       int mkostemps(char *template, int suffixlen, int flags);

   Feature Test Macro Requirements for glibc (see feature_test_macros(7)):

       mkstemp():
           _BSD_SOURCE || _SVID_SOURCE || _XOPEN_SOURCE >= 500 ||
           _XOPEN_SOURCE && _XOPEN_SOURCE_EXTENDED
           || /* Since glibc 2.12: */ _POSIX_C_SOURCE >= 200112L

It's necessary to update each manual pages referring to the _BSD_SOURCE or _SVID_SOURCE to recommend _DEFAULT_SOURCE instead.

Comment 1 Fedora Admin XMLRPC Client 2014-05-12 11:46:45 UTC
This package has changed ownership in the Fedora Package Database.  Reassigning to the new owner of this component.

Comment 2 Michael Kerrisk 2014-06-12 13:05:02 UTC
Upstream maintainer here. Yup, known problem. 190 pages to fix. I'll get to it at some point. Help welcome (in the meantime, see http://man7.org/linux/man-pages/man7/feature_test_macros.7.html).

Comment 3 Jaroslav Reznik 2015-03-03 15:39:18 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 22 development cycle.
Changing version to '22'.

More information and reason for this action is here:
https://fedoraproject.org/wiki/Fedora_Program_Management/HouseKeeping/Fedora22

Comment 4 Fedora Admin XMLRPC Client 2015-07-13 10:20:32 UTC
This package has changed ownership in the Fedora Package Database.  Reassigning to the new owner of this component.

Comment 5 Michael Kerrisk 2016-03-12 19:44:07 UTC
Note that this problem will be fixed in the upcoming upstream release, man-pages-4.05, which will be released in the next few weeks.

Comment 6 Petr Pisar 2016-03-14 08:22:15 UTC
Hooray!

Comment 7 Nikola Forró 2016-03-14 11:58:50 UTC
Thanks Michael,

I'll backport the changes to F22 and F23.

Comment 8 Michael Kerrisk 2016-03-14 17:14:05 UTC
(In reply to Nikola Forró from comment #7)
> Thanks Michael,
> 
> I'll backport the changes to F22 and F23.

Hmmm -- that may be more of a task than you expect. If you do attempt it, I'd be interested to hear how it goes.

Comment 9 Michael Kerrisk 2016-03-14 17:15:27 UTC
(In reply to Michael Kerrisk from comment #8)
> (In reply to Nikola Forró from comment #7)
> > Thanks Michael,
> > 
> > I'll backport the changes to F22 and F23.
> 
> Hmmm -- that may be more of a task than you expect. If you do attempt it,
> I'd be interested to hear how it goes.

Ohh - I realize I may have misunderstood what you meant by backport. Maybe you just mean to release man-pages-4.05 to F22 and F23. That's simple, of course.

Comment 10 Nikola Forró 2016-03-15 22:57:20 UTC
(In reply to Michael Kerrisk from comment #9)
> Ohh - I realize I may have misunderstood what you meant by backport. Maybe
> you just mean to release man-pages-4.05 to F22 and F23. That's simple, of
> course.
No, I really did mean backport. But you are right, that's not going to be easy. Maybe I'll have to reconsider it.

Comment 11 Michael Kerrisk 2016-03-16 15:40:14 UTC
(In reply to Nikola Forró from comment #10)
> (In reply to Michael Kerrisk from comment #9)
> > Ohh - I realize I may have misunderstood what you meant by backport. Maybe
> > you just mean to release man-pages-4.05 to F22 and F23. That's simple, of
> > course.
> No, I really did mean backport. But you are right, that's not going to be
> easy. Maybe I'll have to reconsider it.

In general, there's no reason to ever do such things. man-pages crefully maintains information about historical versions of the  kernel and libc. By all means, backport (any) future version of man-pages to an older Fedora release. But backporting individual patches provides no benefit, only work.

Comment 13 Fedora Update System 2016-03-23 14:26:10 UTC
man-pages-4.04-4.fc24 has been submitted as an update to Fedora 24. https://bodhi.fedoraproject.org/updates/FEDORA-2016-ae41a172c4

Comment 14 Fedora Update System 2016-03-23 14:27:03 UTC
man-pages-4.00-7.fc23 has been submitted as an update to Fedora 23. https://bodhi.fedoraproject.org/updates/FEDORA-2016-7de4dea1ac

Comment 15 Fedora Update System 2016-03-23 14:27:46 UTC
man-pages-3.81-5.fc22 has been submitted as an update to Fedora 22. https://bodhi.fedoraproject.org/updates/FEDORA-2016-2bab047f46

Comment 16 Fedora Update System 2016-03-23 19:55:25 UTC
man-pages-4.04-4.fc24 has been pushed to the Fedora 24 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2016-ae41a172c4

Comment 17 Fedora Update System 2016-03-24 01:00:40 UTC
man-pages-3.81-5.fc22 has been pushed to the Fedora 22 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2016-2bab047f46

Comment 18 Fedora Update System 2016-03-24 01:52:48 UTC
man-pages-4.00-7.fc23 has been pushed to the Fedora 23 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2016-7de4dea1ac

Comment 19 Fedora Update System 2016-03-29 19:33:53 UTC
man-pages-4.04-4.fc24 has been pushed to the Fedora 24 stable repository. If problems still persist, please make note of it in this bug report.

Comment 20 Fedora Update System 2016-04-01 00:26:31 UTC
man-pages-4.00-7.fc23 has been pushed to the Fedora 23 stable repository. If problems still persist, please make note of it in this bug report.

Comment 21 Fedora Update System 2016-04-02 04:17:10 UTC
man-pages-3.81-5.fc22 has been pushed to the Fedora 22 stable repository. If problems still persist, please make note of it in this bug report.