hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From a.@apache.org
Subject hadoop git commit: HADOOP-12727. Minor cleanups needed for CMake 3.X (Alan Burlison via aw)
Date Thu, 26 May 2016 14:37:32 GMT
Repository: hadoop
Updated Branches:
  refs/heads/trunk 77202fa10 -> fed9bf0ec


HADOOP-12727. Minor cleanups needed for CMake 3.X (Alan Burlison via aw)


Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/fed9bf0e
Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/fed9bf0e
Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/fed9bf0e

Branch: refs/heads/trunk
Commit: fed9bf0ec1946674a58745455e478fc377ee4f98
Parents: 77202fa
Author: Allen Wittenauer <aw@apache.org>
Authored: Thu May 26 07:37:22 2016 -0700
Committer: Allen Wittenauer <aw@apache.org>
Committed: Thu May 26 07:37:22 2016 -0700

----------------------------------------------------------------------
 hadoop-common-project/hadoop-common/HadoopCommon.cmake | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hadoop/blob/fed9bf0e/hadoop-common-project/hadoop-common/HadoopCommon.cmake
----------------------------------------------------------------------
diff --git a/hadoop-common-project/hadoop-common/HadoopCommon.cmake b/hadoop-common-project/hadoop-common/HadoopCommon.cmake
index 5a83f3d..c46d9e5 100644
--- a/hadoop-common-project/hadoop-common/HadoopCommon.cmake
+++ b/hadoop-common-project/hadoop-common/HadoopCommon.cmake
@@ -48,11 +48,10 @@ macro(hadoop_add_compiler_flags FLAGS)
     set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${FLAGS}")
 endmacro()
 
-# Add flags to all the CMake linker variables
+# Add flags to all the CMake linker variables.
 macro(hadoop_add_linker_flags FLAGS)
     set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${FLAGS}")
     set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} ${FLAGS}")
-    set(CMAKE_STATIC_LINKER_FLAGS "${CMAKE_STATIC_LINKER_FLAGS} ${FLAGS}")
 endmacro()
 
 # Compile a library with both shared and static variants.
@@ -188,7 +187,9 @@ if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
 #
 elseif(CMAKE_SYSTEM_NAME STREQUAL "SunOS")
     # Solaris flags. 64-bit compilation is mandatory, and is checked earlier.
-    hadoop_add_compiler_flags("-m64 -D__EXTENSIONS__ -D_POSIX_PTHREAD_SEMANTICS -D_XOPEN_SOURCE=500")
+    hadoop_add_compiler_flags("-m64 -D_POSIX_C_SOURCE=200112L -D__EXTENSIONS__ -D_POSIX_PTHREAD_SEMANTICS")
+    set(CMAKE_C_FLAGS "-std=gnu99 ${CMAKE_C_FLAGS}")
+    set(CMAKE_CXX_FLAGS "-std=gnu++98 ${CMAKE_CXX_FLAGS}")
     hadoop_add_linker_flags("-m64")
 
     # CMAKE_SYSTEM_PROCESSOR is set to the output of 'uname -p', which on Solaris is
@@ -199,7 +200,7 @@ elseif(CMAKE_SYSTEM_NAME STREQUAL "SunOS")
         set(CMAKE_SYSTEM_PROCESSOR "amd64")
         set(CMAKE_LIBRARY_ARCHITECTURE "amd64")
     elseif(CMAKE_SYSTEM_PROCESSOR STREQUAL "sparc")
-        set(CMAKE_SYSTEM_PROCESSOR STREQUAL "sparcv9")
+        set(CMAKE_SYSTEM_PROCESSOR "sparcv9")
         set(CMAKE_LIBRARY_ARCHITECTURE "sparcv9")
     else()
         message(FATAL_ERROR "Unrecognised CMAKE_SYSTEM_PROCESSOR ${CMAKE_SYSTEM_PROCESSOR}")


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


Mime
View raw message