Skip to content

undef _XOPEN_SOURCE breaks the build in AIX #12548

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Oct 24, 2018

Conversation

ayappanec
Copy link
Contributor

@ayappanec ayappanec commented Oct 17, 2018

PR Summary

This PR addresses the issue #12535
Some of the function declarations in AIX header files are based on the _XOPEN_SOURCE value. So undefining it breaks the build.

PR Checklist

  • Has Pytest style unit tests
  • Code is Flake 8 compliant
  • New features are documented, with examples if plot related
  • Documentation is sphinx and numpydoc compliant
  • Added an entry to doc/users/next_whats_new/ if major new feature (follow instructions in README.rst there)
  • Documented in doc/api/api_changes.rst if API changed in a backward-incompatible way

@tacaswell tacaswell added this to the v2.2.4 milestone Oct 17, 2018
@tacaswell
Copy link
Member

attn @mdboom @QuLogic

I am curious why we unset this to begin with.

@dopplershift
Copy link
Contributor

Well, today I learned what _XOPEN_SOURCE is. Seems kinda sketchy to me to be undef-ing it unconditionally.

@ayappanec
Copy link
Contributor Author

ayappanec commented Oct 18, 2018

Yes. This _XOPEN_SOURCE specifies the X/OPEN & POSIX standards.
Undefining it basically doesn't include the APIs/functions brought under this standard in some of the UNIX based Operating systems (with AIX being one of them).

@QuLogic
Copy link
Member

QuLogic commented Oct 19, 2018

Well, I don't understand why we undefine these in the first place. The commit message is a nebulous "Fixes for clang", but I don't know what clang has to do with it.

@QuLogic QuLogic requested a review from mdboom October 19, 2018 03:24
@ayappanec
Copy link
Contributor Author

@mdboom Any update on this ?

@tacaswell
Copy link
Member

As we are going to do a 3.0.1 (likely today) due to other issues I am in favor of merging this and investigating why we are unsetting _XOPEN_SOURCE to begin with to a later issue.

@ayappanec
Copy link
Contributor Author

Thanks @tacaswell !

Copy link
Contributor

@dopplershift dopplershift left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems like the least-risky option (compared with just removing the #undefs).

@dopplershift dopplershift merged commit 52b7d4e into matplotlib:master Oct 24, 2018
meeseeksmachine pushed a commit to meeseeksmachine/matplotlib that referenced this pull request Oct 24, 2018
meeseeksmachine pushed a commit to meeseeksmachine/matplotlib that referenced this pull request Oct 24, 2018
jklymak added a commit that referenced this pull request Oct 24, 2018
…548-on-v3.0.x

Backport PR #12548 on branch v3.0.x (undef _XOPEN_SOURCE breaks the build in AIX)
jklymak added a commit that referenced this pull request Oct 24, 2018
…548-on-v2.2.x

Backport PR #12548 on branch v2.2.x (undef _XOPEN_SOURCE breaks the build in AIX)
@ayappanec
Copy link
Contributor Author

Thank You Guys for the support.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants