hadoop-hdfs-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tibor Kiss (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HDFS-10355) Fix thread_local related build issue on Mac OS X
Date Tue, 03 May 2016 17:43:12 GMT

    [ https://issues.apache.org/jira/browse/HDFS-10355?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15269166#comment-15269166

Tibor Kiss commented on HDFS-10355:

Yes, it does have pthread support.

> Fix thread_local related build issue on Mac OS X
> ------------------------------------------------
>                 Key: HDFS-10355
>                 URL: https://issues.apache.org/jira/browse/HDFS-10355
>             Project: Hadoop HDFS
>          Issue Type: Sub-task
>          Components: hdfs-client
>         Environment: OS: Mac OS X 10.11
> clang: Apple LLVM version 7.0.2 (clang-700.1.81)
>            Reporter: Tibor Kiss
> The native hdfs library uses C++11 features heavily.
> One of such feature is thread_local storage class which is supported in GCC, Visual Studio
and the community version of clang compiler, but not by Apple's clang (which is default on
OS X boxes). 
> See further details here: http://stackoverflow.com/a/29929949
> Even though not many Hadoop cluster runs on OS X developers still use this platform for
> The problem can be solved multiple ways:
>  a) Stick to gcc/g++ or community based clang on OS X. Developers will need extra steps
to build Hadoop.
>  b) Workaround thread_local with a helper class.
>  c) Get rid of all the globals marked with thread_local. Interface change will be erquired.
>  d) Disable multi threading support in the native client on OS X and document this limitation.

> Compile error related to thread_local:
> {noformat}
>      [exec] /Users/tiborkiss/workspace/apache-hadoop/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/lib/bindings/c/hdfs.cc:66:1:
error: thread-local storage is not supported for the current target
>      [exec] thread_local std::string errstr;
>      [exec] ^
>      [exec] 1 warning and 1 error generated.
>      [exec] make[2]: *** [main/native/libhdfspp/lib/bindings/c/CMakeFiles/bindings_c_obj.dir/hdfs.cc.o]
Error 1
>      [exec] make[1]: *** [main/native/libhdfspp/lib/bindings/c/CMakeFiles/bindings_c_obj.dir/all]
Error 2
>      [exec] make: *** [all] Error 2
> {noformat}

This message was sent by Atlassian JIRA

To unsubscribe, e-mail: hdfs-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: hdfs-issues-help@hadoop.apache.org

View raw message