Graphlab API compilation error on Mac OS X 10.9

User 285 | 5/4/2014, 7:42:57 AM

I have problem compiling Graphlab API on OS X 10.9.

The commands I used are: ./configure cd debug sudo make -j4 (sudo due to system complaining permission denied)

I have attached the complete configuration log and compilation log. The last couple of errors seem to suggest it has something to do with opencv and QT.

Could anybody help me to compile it successfully?


User 6 | 5/4/2014, 7:46:51 AM

Hi We do not recommend compiling with sudo - it should not be needed. We better solve the permission denied error directly. Sudo may mess up other permissions and environment variables. Furthermore, there are a lot of contributed toolkits - we recommend compiling the ones you plan to use. Do you plan to use opencv? it is part of the cloudcv image processing toolkit.


User 285 | 5/4/2014, 7:58:47 AM

I'm not sure if I need opencv, I'm still exploring the package. The first thing that I absolutely want to use is the collaborative filtering tool. So I cd to release/toolkits/collaborative_filtering, and executed make -j4. It gave me a different sets of compilation errors.

The configuration step of Hadoop encountered permission denied error (I don't need Hadoop): Performing configure step for 'hadoop' /bin/sh: /Users/wudegang/graphlab/deps/hadoop/src/hadoop/src/c++/libhdfs/configure: Permission denied make[2]: * [../deps/hadoop/src/hadoop-stamp/hadoop-configure] Error 126 make[1]: [CMakeFiles/hadoop.dir/all] Error 2 make[1]: ** Waiting for unfinished jobs.... make[2]: * [CMakeFiles/libtcmalloc-complete] Error 1 make[1]: * [CMakeFiles/libtcmalloc.dir/all] Error 2

After "[ 16%] Built target zookeeper", the compilation stopped.

User 6 | 5/4/2014, 8:00:16 AM

If you are not planning to use Hadoop HDFS please configure using ./configure --no_jvm and then recompile.

User 285 | 5/4/2014, 8:33:51 AM

Now I use ./configure --nojvm. Got a lot of errors in the linking stage, for example, the first error that showed up is: [ 93%] Built target graphlab Linking CXX executable adpredictor Linking CXX executable biassgd Linking CXX executable makesyntheticalsdata Linking CXX executable als Undefined symbols for architecture x8664: "boost::programoptions::tointernal(std::__1::basicstring<char, std::1::char_traits<char>, std::1::allocator<char> > const&)", referenced from: std::1::vector<std::1::basicstring<char, std::__1::chartraits<char>, std::1::allocator<char> >, std::1::allocator<std::1::basic_string<char, std::1::chartraits<char>, std::__1::allocator<char> > > > boost::programoptions::tointernal<std::__1::basicstring<char, std::1::char_traits<char>, std::1::allocator<char> > >(std::1::vector<std::1::basicstring<char, std::__1::chartraits<char>, std::1::allocator<char> >, std::1::allocator<std::1::basic_string<char, std::1::chartraits<char>, std::__1::allocator<char> > > > const&) in libgraphlab.a(commandline_options.cpp.o)

User 6 | 5/4/2014, 9:01:00 AM

Do you have Xcode installed? It is hard to understand the output since you compile with -j4. Please send us the following additional information The output of uname -a The hardware you are running on. The output of g++ -v and clang++ -v The contents of graphlab/config.log and graphlab/configure.deps *The full output of the compilation using "make" (and not "make -j4").

User 285 | 5/4/2014, 9:18:47 AM

I have installed both XCode and Xcode command line tools. I can compile sources from macports with no problem. I have attached the log produced by "make". Does it look like the make process cannot locate Boost library? I have Boost library installed in /opt/local/lib through Macports. I tried to pass LDFLAGS=-L/opt/local/lib to ./configure but ./configure did not recognize LDFLAGS.

User 6 | 5/4/2014, 9:23:48 AM

Take a look here: it seems to be a combination of boost, compiler and homebraw issue. I will need the requested information above (especially config.log and configure.deps).

User 285 | 5/4/2014, 9:57:39 AM

The version of boost installed is: port -v installed boost The following ports are currently installed: boost @1.54.00+nosingle+nostatic+python27 platform='darwin 13' archs='x8664' boost @1.55.00+nosingle+nostatic+python27 platform='darwin 13' archs='x8664' boost @1.55.00+nosingle+nostatic+python33-python27 platform='darwin 13' archs='x8664' boost @1.55.02+nosingle+nostatic+python33-python27 (active) platform='darwin 13' archs='x8664'

the compiler: i686-apple-darwin13-llvm-gcc-4.2 (GCC) 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2336.11) (MacPorts llvm-gcc42 2336.11_1) Copyright (C) 2007 Free Software Foundation, Inc.

User 285 | 5/4/2014, 2:35:24 PM

Now I force the system to use the clang that comes with Xcode. Now I can compile collaborative filtering with no problem. However, when I ran make in the release directory, I encountered a opencv-related error: /Users/wudegang/graphlab/deps/opencv/src/opencv/modules/ts/include/opencv2/ts/ts_gtest.h:1569:13: fatal error: 'tr1/tuple' file not found

include <tr1/tuple> // NOLINT


Interestingly, this should be a bug that was fixed one year ago ( In directory deps/opencv/src, the version of OpenCV that is fetched by Graphlab is 2.4.0, while the current version is 2.4.9. Not that I need opencv to work. Just curious.

User 6 | 5/4/2014, 2:45:55 PM

I am glad to hear the problem is fixed. I have pinged Prof. Dhruv Batra from V Tech regarding potential upgrade of opencv. We will follow on that.