Building on Mac OSX

14 views
Skip to first unread message

Dan Mullineux

unread,
Jul 19, 2012, 6:29:55 PM7/19/12
to hyperta...@googlegroups.com
So after running a few tests with hypertable and a small ceph cluster, things are pretty stable on ubunti 12.04

But my main development is on mac (lion) so the ubuntu vm worked ok, things built fine, but Sigar does not like the VM (number of cores = 0)

So I have finally got the dependencies set up on Mac, cmake is all cool, but make runs into this this clang two-phase name lookup thing...

<pre>
/Users/Dan/projects/theirs/hypertable/src/src/cc/Common/Allocator.h:152:8: note: must qualify identifier to find this declaration in dependent base class
  void set_arena(ArenaT *arena) { m_arenap = arena; }
       ^
In file included from /Users/Dan/projects/theirs/hypertable/src/src/cc/Common/tests/container_test.cc:23:
/Users/Dan/projects/theirs/hypertable/src/src/cc/Common/PageArenaAllocator.h:46:5: error: use of undeclared identifier 'check_allocate_size'
    check_allocate_size(sz);
    ^
    this->
<pre>

I can tell doug builds the binaries from mac (its Users/doug/...  in the exceptions), so musta found a way round this. So whats the best way forward.

Cheers.

Dan Mullineux

unread,
Jul 20, 2012, 9:09:35 AM7/20/12
to hyperta...@googlegroups.com

Ach well, for the sake of any poor sap who is struggling with the mac build...

 add this to the cmake command...

-DCMAKE_CXX_COMPILER=g++ 

you dont need the following flag as I don't thing there are any pure c files (just some 'C' defs for the api's to stop name mangling)  but just in case and for the record this is the c flag -DCMAKE_CC_COMPILER=gcc 

Its because the default compiler on mac is the super strict clang (built on LLVM). 

Its been a learning experience if nothing else!
Reply all
Reply to author
Forward
0 new messages