Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

fix the swab bug to compile on solaris system #6628

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 3 commits into from
Jun 24, 2016
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
fix the swab bug to compile on solaris system
on smartos will met below error when try to build:

In file included from /opt/local/include/python2.7/Python.h:44:0,

                 from src/mplutils.h:21,

                 from src/ft2font_wrapper.cpp:1:

/usr/include/unistd.h:521:75: error: declaration of C function 'void swab(const void*, void*, ssize_t)' conflicts with

In file included from /opt/local/include/python2.7/Python.h:42:0,

                 from src/mplutils.h:21,

                 from src/ft2font_wrapper.cpp:1:

/usr/include/stdlib.h:170:13: error: previous declaration 'void swab(const char*, char*, ssize_t)' here

error: command 'gcc' failed with exit status 1

Signed-off-by: Frank Yu <flyxiaoyu@gmail.com>
  • Loading branch information
FrankYu committed Jun 23, 2016
commit 761e601417ef5219d2a73d7140e4bb339c4abb8f
6 changes: 6 additions & 0 deletions 6 src/mplutils.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,12 @@ typedef unsigned __int8 uint8_t;
# undef _XOPEN_SOURCE
#endif

#if defined(__sun) || defined(sun)
#if defined(_XPG4)
#undef _XPG4
#endif
#endif

#include <Python.h>

#if PY_MAJOR_VERSION >= 3
Expand Down
7 changes: 7 additions & 0 deletions 7 src/numpy_cpp.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,13 @@
# undef _XOPEN_SOURCE
#endif


#if defined(__sun) || defined(sun)
#if defined(_XPG4)
#undef _XPG4
#endif
#endif

#include <Python.h>
#include <numpy/ndarrayobject.h>

Expand Down
Morty Proxy This is a proxified and sanitized view of the page, visit original site.