Skip to content
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

Build fails in pip install of librabbitmq #536

Open
dougbyrne opened this issue Oct 30, 2018 · 1 comment
Open

Build fails in pip install of librabbitmq #536

dougbyrne opened this issue Oct 30, 2018 · 1 comment

Comments

@dougbyrne
Copy link

Hi, I'm posting on behalf of a couple issues opened on the python library side, where the package fails to install on OSX. It appears to be a problem in the configure here.

The related issues on the python library:
celery/librabbitmq#121
celery/librabbitmq#123
celery/librabbitmq#126

I'm running:

  • OSX 10.13.6 High Sierra
  • pip 18.1
  • Python 2.7.10
  • autoconf (GNU Autoconf) 2.69
  • cc --version: Apple LLVM version 9.1.0 (clang-902.0.39.2)

The python library attempts to install this version of the c library: https://github.com/alanxz/rabbitmq-c/tree/caad0ef1533783729c7644a226c989c79b4c497b

The following errors are generated:

In file included from /private/var/folders/fk/wyj_nk8x49x2w646k2qxq8l00000gn/T/pip-install-lO7dVP/librabbitmq/rabbitmq-c/librabbitmq/amqp_api.c:48:
  /private/var/folders/fk/wyj_nk8x49x2w646k2qxq8l00000gn/T/pip-install-lO7dVP/librabbitmq/rabbitmq-c/librabbitmq/amqp_private.h:332:1: error: expected ')'
  DECLARE_XTOXLL(hton)
  ^
  /private/var/folders/fk/wyj_nk8x49x2w646k2qxq8l00000gn/T/pip-install-lO7dVP/librabbitmq/rabbitmq-c/librabbitmq/amqp_private.h:298:26: note: expanded from macro 'DECLARE_XTOXLL'
    static inline uint64_t func##ll(uint64_t val)     \
                           ^
  <scratch space>:425:1: note: expanded from here
  htonll
  ^
  /usr/include/sys/_endian.h:141:25: note: expanded from macro 'htonll'
  #define htonll(x)       __DARWIN_OSSwapInt64(x)
                          ^
  /usr/include/libkern/_OSByteOrder.h:78:30: note: expanded from macro '__DARWIN_OSSwapInt64'
      (__builtin_constant_p(x) ? __DARWIN_OSSwapConstInt64(x) : _OSSwapInt64(x))
                               ^
  /private/var/folders/fk/wyj_nk8x49x2w646k2qxq8l00000gn/T/pip-install-lO7dVP/librabbitmq/rabbitmq-c/librabbitmq/amqp_private.h:332:1: note: to match this '('
  /private/var/folders/fk/wyj_nk8x49x2w646k2qxq8l00000gn/T/pip-install-lO7dVP/librabbitmq/rabbitmq-c/librabbitmq/amqp_private.h:298:26: note: expanded from macro 'DECLARE_XTOXLL'
    static inline uint64_t func##ll(uint64_t val)     \
                           ^
  <scratch space>:425:1: note: expanded from here
  htonll
  ^
  /usr/include/sys/_endian.h:141:25: note: expanded from macro 'htonll'
  #define htonll(x)       __DARWIN_OSSwapInt64(x)
                          ^
  /usr/include/libkern/_OSByteOrder.h:78:5: note: expanded from macro '__DARWIN_OSSwapInt64'
      (__builtin_constant_p(x) ? __DARWIN_OSSwapConstInt64(x) : _OSSwapInt64(x))
      ^
  In file included from /private/var/folders/fk/wyj_nk8x49x2w646k2qxq8l00000gn/T/pip-install-lO7dVP/librabbitmq/rabbitmq-c/librabbitmq/amqp_api.c:48:
  /private/var/folders/fk/wyj_nk8x49x2w646k2qxq8l00000gn/T/pip-install-lO7dVP/librabbitmq/rabbitmq-c/librabbitmq/amqp_private.h:332:1: error: definition of builtin function '__builtin_constant_p'
  DECLARE_XTOXLL(hton)
  ^
  /private/var/folders/fk/wyj_nk8x49x2w646k2qxq8l00000gn/T/pip-install-lO7dVP/librabbitmq/rabbitmq-c/librabbitmq/amqp_private.h:298:26: note: expanded from macro 'DECLARE_XTOXLL'
    static inline uint64_t func##ll(uint64_t val)     \
                           ^
  <scratch space>:425:1: note: expanded from here
  htonll
  ^
  /usr/include/sys/_endian.h:141:25: note: expanded from macro 'htonll'
  #define htonll(x)       __DARWIN_OSSwapInt64(x)
                          ^
  /usr/include/libkern/_OSByteOrder.h:78:6: note: expanded from macro '__DARWIN_OSSwapInt64'
      (__builtin_constant_p(x) ? __DARWIN_OSSwapConstInt64(x) : _OSSwapInt64(x))
       ^
  In file included from /private/var/folders/fk/wyj_nk8x49x2w646k2qxq8l00000gn/T/pip-install-lO7dVP/librabbitmq/rabbitmq-c/librabbitmq/amqp_api.c:48:
  /private/var/folders/fk/wyj_nk8x49x2w646k2qxq8l00000gn/T/pip-install-lO7dVP/librabbitmq/rabbitmq-c/librabbitmq/amqp_private.h:333:1: error: expected ')'
  DECLARE_XTOXLL(ntoh)
  ^
  /private/var/folders/fk/wyj_nk8x49x2w646k2qxq8l00000gn/T/pip-install-lO7dVP/librabbitmq/rabbitmq-c/librabbitmq/amqp_private.h:298:26: note: expanded from macro 'DECLARE_XTOXLL'
    static inline uint64_t func##ll(uint64_t val)     \
                           ^
  <scratch space>:428:1: note: expanded from here
  ntohll
  ^
  /usr/include/sys/_endian.h:140:25: note: expanded from macro 'ntohll'
  #define ntohll(x)       __DARWIN_OSSwapInt64(x)
                          ^
  /usr/include/libkern/_OSByteOrder.h:78:30: note: expanded from macro '__DARWIN_OSSwapInt64'
      (__builtin_constant_p(x) ? __DARWIN_OSSwapConstInt64(x) : _OSSwapInt64(x))
                               ^
  /private/var/folders/fk/wyj_nk8x49x2w646k2qxq8l00000gn/T/pip-install-lO7dVP/librabbitmq/rabbitmq-c/librabbitmq/amqp_private.h:333:1: note: to match this '('
  /private/var/folders/fk/wyj_nk8x49x2w646k2qxq8l00000gn/T/pip-install-lO7dVP/librabbitmq/rabbitmq-c/librabbitmq/amqp_private.h:298:26: note: expanded from macro 'DECLARE_XTOXLL'
    static inline uint64_t func##ll(uint64_t val)     \
                           ^
  <scratch space>:428:1: note: expanded from here
  ntohll
  ^
  /usr/include/sys/_endian.h:140:25: note: expanded from macro 'ntohll'
  #define ntohll(x)       __DARWIN_OSSwapInt64(x)
                          ^
  /usr/include/libkern/_OSByteOrder.h:78:5: note: expanded from macro '__DARWIN_OSSwapInt64'
      (__builtin_constant_p(x) ? __DARWIN_OSSwapConstInt64(x) : _OSSwapInt64(x))
      ^
  In file included from /private/var/folders/fk/wyj_nk8x49x2w646k2qxq8l00000gn/T/pip-install-lO7dVP/librabbitmq/rabbitmq-c/librabbitmq/amqp_api.c:48:
  /private/var/folders/fk/wyj_nk8x49x2w646k2qxq8l00000gn/T/pip-install-lO7dVP/librabbitmq/rabbitmq-c/librabbitmq/amqp_private.h:333:1: error: definition of builtin function '__builtin_constant_p'
  DECLARE_XTOXLL(ntoh)
  ^
  /private/var/folders/fk/wyj_nk8x49x2w646k2qxq8l00000gn/T/pip-install-lO7dVP/librabbitmq/rabbitmq-c/librabbitmq/amqp_private.h:298:26: note: expanded from macro 'DECLARE_XTOXLL'
    static inline uint64_t func##ll(uint64_t val)     \
                           ^
  <scratch space>:428:1: note: expanded from here
  ntohll
  ^
  /usr/include/sys/_endian.h:140:25: note: expanded from macro 'ntohll'
  #define ntohll(x)       __DARWIN_OSSwapInt64(x)
                          ^
  /usr/include/libkern/_OSByteOrder.h:78:6: note: expanded from macro '__DARWIN_OSSwapInt64'
      (__builtin_constant_p(x) ? __DARWIN_OSSwapConstInt64(x) : _OSSwapInt64(x))
       ^
  4 errors generated.
  error: command 'cc' failed with exit status 1

It looks like HAVE_HTONLL is not getting defined by the config.

The interesting lines to me from the pip install are:

  configure: line 13135: syntax error near unexpected token `0.17'
  configure: line 13135: `PKG_PROG_PKG_CONFIG(0.17)'

These come before the check that would define HAVE_HTONLL.

The full pip output:
https://gist.github.com/dougbyrne/4b5893ffbac388aa94608048e1e5fb2c

I'm out of my expertise at this point. I'm guessing the issue might be in configure.ac, but I'm not sure how to fix that.

@dougbyrne
Copy link
Author

Hi, just confirming that I still see the issue on OSX 10.14.1 and cc Apple LLVM version 10.0.0 (clang-1000.10.44.4)

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

No branches or pull requests

1 participant