Title: resolve sinpi() name clash with libm
Type: compile error Stage: resolved
Components: Extension Modules Versions: Python 3.8, Python 3.7, Python 2.7
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: cheryl.sabella, dimpase, eamanu, koobs, mark.dickinson, miss-islington, ned.deily, serhiy.storchaka
Priority: normal Keywords: patch

Created on 2019-02-25 13:47 by dimpase, last changed 2019-04-12 20:33 by cheryl.sabella. This issue is now closed.

Pull Requests
URL Status Linked Edit
PR 12027 merged dimpase, 2019-02-25 13:47
PR 12046 merged miss-islington, 2019-02-26 06:36
PR 12050 merged dimpase, 2019-02-26 09:57
Messages (11)
msg336519 - (view) Author: Dmitrii Pasechnik (dimpase) * Date: 2019-02-25 13:47
The standard math library (libm) may follow IEEE-754 recommendation to
include an implementation of sinPi(), i.e. sinPi(x):=sin(pi*x).
And this triggers a name clash, found by FreeBSD developer
Steve Kargl, who worken on putting sinpi into libm used on FreeBSD
(it has to be named "sinpi", not "sinPi", cf. e.g.
msg336525 - (view) Author: Emmanuel Arias (eamanu) * Date: 2019-02-25 14:53

It seem a good improve to resolve a potential problem. But I am not convinced if that problem could appear because sinpi() is definded locally.
msg336528 - (view) Author: Dmitrii Pasechnik (dimpase) * Date: 2019-02-25 15:00
This has a potential header conflict. For the same reason functions like
lgamma, etc. are prefixed with `m_` in Modules/mathmodule.c
msg336529 - (view) Author: Dmitrii Pasechnik (dimpase) * Date: 2019-02-25 15:05
e.g. if I rename `m_lgamma` to `lgamma` I get
mathmodule.c:389:1: error: static declaration of ‘lgamma’ follows non-static declaration
 lgamma(double x)
msg336618 - (view) Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) Date: 2019-02-26 06:36
New changeset f57cd8288dbe6aba99c057f37ad6d58f8db75350 by Serhiy Storchaka (Dima Pasechnik) in branch 'master':
bpo-36106: Resolve sinpi name clash with libm (IEEE-754 violation). (GH-12027)
msg336622 - (view) Author: miss-islington (miss-islington) Date: 2019-02-26 07:10
New changeset 4e6646fef5d2cc53422e4eca0b18201ed5a5c4b6 by Miss Islington (bot) in branch '3.7':
bpo-36106: Resolve sinpi name clash with libm (IEEE-754 violation). (GH-12027)
msg336633 - (view) Author: Kubilay Kocak (koobs) (Python triager) Date: 2019-02-26 08:59
Downstream issue:
msg336641 - (view) Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) Date: 2019-02-26 10:41
New changeset b545ba0a508a5980ab147ed2641a42be3b31a2db by Serhiy Storchaka (Dima Pasechnik) in branch '2.7':
[2.7] bpo-36106: resolve sinpi name clash with libm (IEEE-754 violation). (GH-12027) (GH-12050)
msg336692 - (view) Author: Mark Dickinson (mark.dickinson) * (Python committer) Date: 2019-02-26 16:34
This one was my fault. Thanks for the fix!
msg340099 - (view) Author: Dmitrii Pasechnik (dimpase) * Date: 2019-04-12 19:15
Can this also be backported to 3.5. and 3.6, as requested by FreeBSD maintainers?
msg340110 - (view) Author: Cheryl Sabella (cheryl.sabella) * (Python committer) Date: 2019-04-12 20:33
I'll nosy Ned as the release manager about the request to 3.6.
Date User Action Args
2019-04-12 20:33:52cheryl.sabellasetnosy: + cheryl.sabella, ned.deily
messages: + msg340110
2019-04-12 19:15:40dimpasesetmessages: + msg340099
2019-02-26 16:34:18mark.dickinsonsetmessages: + msg336692
2019-02-26 10:42:10serhiy.storchakasetstatus: open -> closed
resolution: fixed
stage: patch review -> resolved
2019-02-26 10:41:18serhiy.storchakasetmessages: + msg336641
2019-02-26 09:57:40dimpasesetpull_requests: + pull_request12076
2019-02-26 08:59:25koobssetnosy: + koobs

messages: + msg336633
versions: + Python 2.7, Python 3.8
2019-02-26 07:10:58miss-islingtonsetnosy: + miss-islington
messages: + msg336622
2019-02-26 06:36:25miss-islingtonsetkeywords: + patch
pull_requests: + pull_request12071
2019-02-26 06:36:17serhiy.storchakasetnosy: + serhiy.storchaka
messages: + msg336618
2019-02-25 15:05:12dimpasesetmessages: + msg336529
2019-02-25 15:00:24dimpasesetmessages: + msg336528
2019-02-25 14:53:31eamanusetmessages: + msg336525
2019-02-25 14:48:47eamanusetnosy: + eamanu
2019-02-25 13:53:56SilentGhostsetnosy: + mark.dickinson

stage: patch review
2019-02-25 13:47:03dimpasecreate