You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@arrow.apache.org by we...@apache.org on 2017/10/09 01:09:09 UTC

arrow git commit: ARROW-1535: [Python] Enable sdist tarballs to be installed

Repository: arrow
Updated Branches:
  refs/heads/master 81a0e6739 -> a0555c04d


ARROW-1535: [Python] Enable sdist tarballs to be installed

The tarballs produced by `setup.py sdist` have always been broken. This creates a tarball that can be installed assuming that the Arrow/Parquet C++ libraries are installed already on the target system.

I wanted to see if I could bundle the `cpp/cmake_modules` files without using a symlink but I couldn't figure it out; it might require subclassing the sdist cmdclass to make this work. I'm not sure having the symlink is so bad

Author: Wes McKinney <we...@twosigma.com>

Closes #1188 from wesm/ARROW-1535 and squashes the following commits:

dcc2e47d [Wes McKinney] Fix RAT excludes given changes to cmake files
310af1b7 [Wes McKinney] Move all cmake files to cpp/cmake_modules, fix up sdist tarball so it can be built/installed


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

Branch: refs/heads/master
Commit: a0555c04dd5c43230a1c50d0d0a94e06d8ad9ff0
Parents: 81a0e67
Author: Wes McKinney <we...@twosigma.com>
Authored: Sun Oct 8 21:09:03 2017 -0400
Committer: Wes McKinney <we...@twosigma.com>
Committed: Sun Oct 8 21:09:03 2017 -0400

----------------------------------------------------------------------
 cpp/cmake_modules/FindArrow.cmake            | 145 ++++++++++++++++++
 cpp/cmake_modules/FindCython.cmake           |  30 ++++
 cpp/cmake_modules/FindParquet.cmake          | 131 +++++++++++++++++
 cpp/cmake_modules/FindPlasma.cmake           |  99 +++++++++++++
 cpp/cmake_modules/UseCython.cmake            | 171 ++++++++++++++++++++++
 dev/release/rat_exclude_files.txt            |   6 +-
 python/CMakeLists.txt                        |  12 +-
 python/MANIFEST.in                           |   3 +-
 python/cmake_modules                         |   1 +
 python/cmake_modules/BuildUtils.cmake        |   1 -
 python/cmake_modules/CompilerInfo.cmake      |   1 -
 python/cmake_modules/FindArrow.cmake         | 145 ------------------
 python/cmake_modules/FindCython.cmake        |  30 ----
 python/cmake_modules/FindNumPy.cmake         |   1 -
 python/cmake_modules/FindParquet.cmake       | 131 -----------------
 python/cmake_modules/FindPlasma.cmake        |  99 -------------
 python/cmake_modules/FindPythonLibsNew.cmake |   1 -
 python/cmake_modules/SetupCxxFlags.cmake     |   1 -
 python/cmake_modules/UseCython.cmake         | 171 ----------------------
 19 files changed, 590 insertions(+), 589 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/arrow/blob/a0555c04/cpp/cmake_modules/FindArrow.cmake
----------------------------------------------------------------------
diff --git a/cpp/cmake_modules/FindArrow.cmake b/cpp/cmake_modules/FindArrow.cmake
new file mode 100644
index 0000000..12f76b6
--- /dev/null
+++ b/cpp/cmake_modules/FindArrow.cmake
@@ -0,0 +1,145 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+# - Find ARROW (arrow/api.h, libarrow.a, libarrow.so)
+# This module defines
+#  ARROW_INCLUDE_DIR, directory containing headers
+#  ARROW_LIBS, directory containing arrow libraries
+#  ARROW_STATIC_LIB, path to libarrow.a
+#  ARROW_SHARED_LIB, path to libarrow's shared library
+#  ARROW_SHARED_IMP_LIB, path to libarrow's import library (MSVC only)
+#  ARROW_FOUND, whether arrow has been found
+
+include(FindPkgConfig)
+
+if ("$ENV{ARROW_HOME}" STREQUAL "")
+  pkg_check_modules(ARROW arrow)
+  if (ARROW_FOUND)
+    pkg_get_variable(ARROW_ABI_VERSION arrow abi_version)
+    message(STATUS "Arrow ABI version: ${ARROW_ABI_VERSION}")
+    pkg_get_variable(ARROW_SO_VERSION arrow so_version)
+    message(STATUS "Arrow SO version: ${ARROW_SO_VERSION}")
+    set(ARROW_INCLUDE_DIR ${ARROW_INCLUDE_DIRS})
+    set(ARROW_LIBS ${ARROW_LIBRARY_DIRS})
+    set(ARROW_SEARCH_LIB_PATH ${ARROW_LIBRARY_DIRS})
+  endif()
+else()
+  set(ARROW_HOME "$ENV{ARROW_HOME}")
+
+  set(ARROW_SEARCH_HEADER_PATHS
+    ${ARROW_HOME}/include
+    )
+
+  set(ARROW_SEARCH_LIB_PATH
+    ${ARROW_HOME}/lib
+    )
+
+  find_path(ARROW_INCLUDE_DIR arrow/array.h PATHS
+    ${ARROW_SEARCH_HEADER_PATHS}
+    # make sure we don't accidentally pick up a different version
+    NO_DEFAULT_PATH
+    )
+endif()
+
+find_library(ARROW_LIB_PATH NAMES arrow
+  PATHS
+  ${ARROW_SEARCH_LIB_PATH}
+  NO_DEFAULT_PATH)
+get_filename_component(ARROW_LIBS ${ARROW_LIB_PATH} DIRECTORY)
+
+find_library(ARROW_PYTHON_LIB_PATH NAMES arrow_python
+  PATHS
+  ${ARROW_SEARCH_LIB_PATH}
+  NO_DEFAULT_PATH)
+get_filename_component(ARROW_PYTHON_LIBS ${ARROW_PYTHON_LIB_PATH} DIRECTORY)
+
+if (MSVC)
+  SET(CMAKE_FIND_LIBRARY_SUFFIXES ".lib" ".dll")
+
+  if (MSVC AND NOT ARROW_MSVC_STATIC_LIB_SUFFIX)
+    set(ARROW_MSVC_STATIC_LIB_SUFFIX "_static")
+  endif()
+
+  find_library(ARROW_SHARED_LIBRARIES NAMES arrow
+    PATHS ${ARROW_HOME} NO_DEFAULT_PATH
+    PATH_SUFFIXES "bin" )
+
+  find_library(ARROW_PYTHON_SHARED_LIBRARIES NAMES arrow_python
+    PATHS ${ARROW_HOME} NO_DEFAULT_PATH
+    PATH_SUFFIXES "bin" )
+  get_filename_component(ARROW_SHARED_LIBS ${ARROW_SHARED_LIBRARIES} PATH )
+  get_filename_component(ARROW_PYTHON_SHARED_LIBS ${ARROW_PYTHON_SHARED_LIBRARIES} PATH )
+endif ()
+
+if (ARROW_INCLUDE_DIR AND ARROW_LIBS)
+  set(ARROW_FOUND TRUE)
+  set(ARROW_LIB_NAME arrow)
+  set(ARROW_PYTHON_LIB_NAME arrow_python)
+  if (MSVC)
+    set(ARROW_STATIC_LIB ${ARROW_LIBS}/${ARROW_LIB_NAME}${ARROW_MSVC_STATIC_LIB_SUFFIX}${CMAKE_STATIC_LIBRARY_SUFFIX})
+    set(ARROW_PYTHON_STATIC_LIB ${ARROW_PYTHON_LIBS}/${ARROW_PYTHON_LIB_NAME}${ARROW_MSVC_STATIC_LIB_SUFFIX}${CMAKE_STATIC_LIBRARY_SUFFIX})
+    set(ARROW_SHARED_LIB ${ARROW_SHARED_LIBS}/${ARROW_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX})
+    set(ARROW_PYTHON_SHARED_LIB ${ARROW_PYTHON_SHARED_LIBS}/${ARROW_PYTHON_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX})
+    set(ARROW_SHARED_IMP_LIB ${ARROW_LIBS}/${ARROW_LIB_NAME}.lib)
+    set(ARROW_PYTHON_SHARED_IMP_LIB ${ARROW_PYTHON_LIBS}/${ARROW_PYTHON_LIB_NAME}.lib)
+  else()
+    set(ARROW_STATIC_LIB ${ARROW_PYTHON_LIB_PATH}/lib${ARROW_LIB_NAME}.a)
+    set(ARROW_PYTHON_STATIC_LIB ${ARROW_PYTHON_LIB_PATH}/lib${ARROW_PYTHON_LIB_NAME}.a)
+
+    set(ARROW_SHARED_LIB ${ARROW_LIBS}/lib${ARROW_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX})
+    set(ARROW_PYTHON_SHARED_LIB ${ARROW_LIBS}/lib${ARROW_PYTHON_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX})
+  endif()
+endif()
+
+if (ARROW_FOUND)
+  if (NOT Arrow_FIND_QUIETLY)
+    message(STATUS "Found the Arrow core library: ${ARROW_LIB_PATH}")
+    message(STATUS "Found the Arrow Python library: ${ARROW_PYTHON_LIB_PATH}")
+  endif ()
+else ()
+  if (NOT Arrow_FIND_QUIETLY)
+    set(ARROW_ERR_MSG "Could not find the Arrow library. Looked for headers")
+    set(ARROW_ERR_MSG "${ARROW_ERR_MSG} in ${ARROW_SEARCH_HEADER_PATHS}, and for libs")
+    set(ARROW_ERR_MSG "${ARROW_ERR_MSG} in ${ARROW_SEARCH_LIB_PATH}")
+    if (Arrow_FIND_REQUIRED)
+      message(FATAL_ERROR "${ARROW_ERR_MSG}")
+    else (Arrow_FIND_REQUIRED)
+      message(STATUS "${ARROW_ERR_MSG}")
+    endif (Arrow_FIND_REQUIRED)
+  endif ()
+  set(ARROW_FOUND FALSE)
+endif ()
+
+if (MSVC)
+  mark_as_advanced(
+    ARROW_INCLUDE_DIR
+    ARROW_STATIC_LIB
+    ARROW_SHARED_LIB
+    ARROW_SHARED_IMP_LIB
+    ARROW_PYTHON_STATIC_LIB
+    ARROW_PYTHON_SHARED_LIB
+    ARROW_PYTHON_SHARED_IMP_LIB
+  )
+else()
+  mark_as_advanced(
+    ARROW_INCLUDE_DIR
+    ARROW_STATIC_LIB
+    ARROW_SHARED_LIB
+    ARROW_PYTHON_STATIC_LIB
+    ARROW_PYTHON_SHARED_LIB
+  )
+endif()

http://git-wip-us.apache.org/repos/asf/arrow/blob/a0555c04/cpp/cmake_modules/FindCython.cmake
----------------------------------------------------------------------
diff --git a/cpp/cmake_modules/FindCython.cmake b/cpp/cmake_modules/FindCython.cmake
new file mode 100644
index 0000000..9df3b5d
--- /dev/null
+++ b/cpp/cmake_modules/FindCython.cmake
@@ -0,0 +1,30 @@
+# Find the Cython compiler.
+#
+# This code sets the following variables:
+#
+#  CYTHON_EXECUTABLE
+#
+# See also UseCython.cmake
+
+#=============================================================================
+# Copyright 2011 Kitware, Inc.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#=============================================================================
+
+find_program( CYTHON_EXECUTABLE NAMES cython cython.bat )
+
+include( FindPackageHandleStandardArgs )
+FIND_PACKAGE_HANDLE_STANDARD_ARGS( Cython REQUIRED_VARS CYTHON_EXECUTABLE )
+
+mark_as_advanced( CYTHON_EXECUTABLE )

http://git-wip-us.apache.org/repos/asf/arrow/blob/a0555c04/cpp/cmake_modules/FindParquet.cmake
----------------------------------------------------------------------
diff --git a/cpp/cmake_modules/FindParquet.cmake b/cpp/cmake_modules/FindParquet.cmake
new file mode 100644
index 0000000..0339ec5
--- /dev/null
+++ b/cpp/cmake_modules/FindParquet.cmake
@@ -0,0 +1,131 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+# - Find PARQUET (parquet/parquet.h, libparquet.a, libparquet.so)
+# This module defines
+#  PARQUET_INCLUDE_DIR, directory containing headers
+#  PARQUET_LIBS, directory containing parquet libraries
+#  PARQUET_STATIC_LIB, path to libparquet.a
+#  PARQUET_SHARED_LIB, path to libparquet's shared library
+#  PARQUET_SHARED_IMP_LIB, path to libparquet's import library (MSVC only)
+#  PARQUET_FOUND, whether parquet has been found
+
+include(FindPkgConfig)
+
+if(NOT "$ENV{PARQUET_HOME}" STREQUAL "")
+    set(PARQUET_HOME "$ENV{PARQUET_HOME}")
+endif()
+
+if (MSVC)
+  SET(CMAKE_FIND_LIBRARY_SUFFIXES ".lib" ".dll")
+
+  if (MSVC AND NOT PARQUET_MSVC_STATIC_LIB_SUFFIX)
+    set(PARQUET_MSVC_STATIC_LIB_SUFFIX "_static")
+  endif()
+
+  find_library(PARQUET_SHARED_LIBRARIES NAMES parquet
+    PATHS ${PARQUET_HOME} NO_DEFAULT_PATH
+    PATH_SUFFIXES "bin" )
+
+  get_filename_component(PARQUET_SHARED_LIBS ${PARQUET_SHARED_LIBRARIES} PATH )
+endif ()
+
+if(PARQUET_HOME)
+    set(PARQUET_SEARCH_HEADER_PATHS
+        ${PARQUET_HOME}/include
+        )
+    set(PARQUET_SEARCH_LIB_PATH
+        ${PARQUET_HOME}/lib
+        )
+    find_path(PARQUET_INCLUDE_DIR parquet/api/reader.h PATHS
+        ${PARQUET_SEARCH_HEADER_PATHS}
+        # make sure we don't accidentally pick up a different version
+        NO_DEFAULT_PATH
+        )
+    find_library(PARQUET_LIBRARIES NAMES parquet
+        PATHS ${PARQUET_HOME} NO_DEFAULT_PATH
+        PATH_SUFFIXES "lib")
+    get_filename_component(PARQUET_LIBS ${PARQUET_LIBRARIES} PATH )
+    set(PARQUET_ABI_VERSION "1.0.0")
+    set(PARQUET_SO_VERSION "1")
+else()
+    pkg_check_modules(PARQUET parquet)
+    if (PARQUET_FOUND)
+        pkg_get_variable(PARQUET_ABI_VERSION parquet abi_version)
+        message(STATUS "Parquet C++ ABI version: ${PARQUET_ABI_VERSION}")
+        pkg_get_variable(PARQUET_SO_VERSION parquet so_version)
+        message(STATUS "Parquet C++ SO version: ${PARQUET_SO_VERSION}")
+        set(PARQUET_INCLUDE_DIR ${PARQUET_INCLUDE_DIRS})
+        set(PARQUET_LIBS ${PARQUET_LIBRARY_DIRS})
+        set(PARQUET_SEARCH_LIB_PATH ${PARQUET_LIBRARY_DIRS})
+        message(STATUS "Searching for parquet libs in: ${PARQUET_SEARCH_LIB_PATH}")
+        find_library(PARQUET_LIBRARIES NAMES parquet
+            PATHS ${PARQUET_SEARCH_LIB_PATH} NO_DEFAULT_PATH)
+    else()
+        find_path(PARQUET_INCLUDE_DIR NAMES parquet/api/reader.h )
+        find_library(PARQUET_LIBRARIES NAMES parquet)
+        get_filename_component(PARQUET_LIBS ${PARQUET_LIBRARIES} PATH )
+    endif()
+endif()
+
+if (PARQUET_INCLUDE_DIR AND PARQUET_LIBRARIES)
+  set(PARQUET_FOUND TRUE)
+  set(PARQUET_LIB_NAME parquet)
+  if (MSVC)
+    set(PARQUET_STATIC_LIB "${PARQUET_LIBS}/${PARQUET_LIB_NAME}${PARQUET_MSVC_STATIC_LIB_SUFFIX}${CMAKE_STATIC_LIBRARY_SUFFIX}")
+    set(PARQUET_SHARED_LIB "${PARQUET_SHARED_LIBS}/${PARQUET_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}")
+    set(PARQUET_SHARED_IMP_LIB "${PARQUET_LIBS}/${PARQUET_LIB_NAME}.lib")
+  else()
+    set(PARQUET_STATIC_LIB ${PARQUET_LIBS}/${CMAKE_STATIC_LIBRARY_PREFIX}${PARQUET_LIB_NAME}.a)
+    set(PARQUET_SHARED_LIB ${PARQUET_LIBS}/${CMAKE_SHARED_LIBRARY_PREFIX}${PARQUET_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX})
+  endif()
+else ()
+  set(PARQUET_FOUND FALSE)
+endif ()
+
+if (PARQUET_FOUND)
+  if (NOT Parquet_FIND_QUIETLY)
+    message(STATUS "Found the Parquet library: ${PARQUET_LIBRARIES}")
+  endif ()
+else ()
+  if (NOT Parquet_FIND_QUIETLY)
+    if (NOT PARQUET_FOUND)
+      set(PARQUET_ERR_MSG "${PARQUET_ERR_MSG} Could not find the parquet library.")
+    endif()
+
+    set(PARQUET_ERR_MSG "${PARQUET_ERR_MSG} Looked in ")
+    if ( _parquet_roots )
+      set(PARQUET_ERR_MSG "${PARQUET_ERR_MSG} in ${_parquet_roots}.")
+    else ()
+      set(PARQUET_ERR_MSG "${PARQUET_ERR_MSG} system search paths.")
+    endif ()
+    if (Parquet_FIND_REQUIRED)
+      message(FATAL_ERROR "${PARQUET_ERR_MSG}")
+    else (Parquet_FIND_REQUIRED)
+      message(STATUS "${PARQUET_ERR_MSG}")
+    endif (Parquet_FIND_REQUIRED)
+  endif ()
+endif ()
+
+mark_as_advanced(
+  PARQUET_FOUND
+  PARQUET_INCLUDE_DIR
+  PARQUET_LIBS
+  PARQUET_LIBRARIES
+  PARQUET_STATIC_LIB
+  PARQUET_SHARED_LIB
+)

http://git-wip-us.apache.org/repos/asf/arrow/blob/a0555c04/cpp/cmake_modules/FindPlasma.cmake
----------------------------------------------------------------------
diff --git a/cpp/cmake_modules/FindPlasma.cmake b/cpp/cmake_modules/FindPlasma.cmake
new file mode 100644
index 0000000..3acaa34
--- /dev/null
+++ b/cpp/cmake_modules/FindPlasma.cmake
@@ -0,0 +1,99 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+# - Find PLASMA (plasma/client.h, libplasma.a, libplasma.so)
+# This module defines
+#  PLASMA_INCLUDE_DIR, directory containing headers
+#  PLASMA_LIBS, directory containing plasma libraries
+#  PLASMA_STATIC_LIB, path to libplasma.a
+#  PLASMA_SHARED_LIB, path to libplasma's shared library
+#  PLASMA_SHARED_IMP_LIB, path to libplasma's import library (MSVC only)
+#  PLASMA_FOUND, whether plasma has been found
+
+include(FindPkgConfig)
+
+if ("$ENV{ARROW_HOME}" STREQUAL "")
+  pkg_check_modules(PLASMA plasma)
+  if (PLASMA_FOUND)
+    pkg_get_variable(PLASMA_EXECUTABLE plasma executable)
+    pkg_get_variable(PLASMA_ABI_VERSION plasma abi_version)
+    message(STATUS "Plasma ABI version: ${PLASMA_ABI_VERSION}")
+    pkg_get_variable(PLASMA_SO_VERSION plasma so_version)
+    message(STATUS "Plasma SO version: ${PLASMA_SO_VERSION}")
+    set(PLASMA_INCLUDE_DIR ${PLASMA_INCLUDE_DIRS})
+    set(PLASMA_LIBS ${PLASMA_LIBRARY_DIRS})
+    set(PLASMA_SEARCH_LIB_PATH ${PLASMA_LIBRARY_DIRS})
+  endif()
+else()
+  set(PLASMA_HOME "$ENV{ARROW_HOME}")
+
+  set(PLASMA_EXECUTABLE ${PLASMA_HOME}/bin/plasma_store)
+
+  set(PLASMA_SEARCH_HEADER_PATHS
+    ${PLASMA_HOME}/include
+    )
+
+  set(PLASMA_SEARCH_LIB_PATH
+    ${PLASMA_HOME}/lib
+    )
+
+  find_path(PLASMA_INCLUDE_DIR plasma/client.h PATHS
+    ${PLASMA_SEARCH_HEADER_PATHS}
+    # make sure we don't accidentally pick up a different version
+    NO_DEFAULT_PATH
+    )
+endif()
+
+find_library(PLASMA_LIB_PATH NAMES plasma
+  PATHS
+  ${PLASMA_SEARCH_LIB_PATH}
+  NO_DEFAULT_PATH)
+get_filename_component(PLASMA_LIBS ${PLASMA_LIB_PATH} DIRECTORY)
+
+if (PLASMA_INCLUDE_DIR AND PLASMA_LIBS)
+  set(PLASMA_FOUND TRUE)
+  set(PLASMA_LIB_NAME plasma)
+
+  set(PLASMA_STATIC_LIB ${PLASMA_LIBS}/lib${PLASMA_LIB_NAME}.a)
+
+  set(PLASMA_SHARED_LIB ${PLASMA_LIBS}/lib${PLASMA_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX})
+endif()
+
+if (PLASMA_FOUND)
+  if (NOT Plasma_FIND_QUIETLY)
+    message(STATUS "Found the Plasma core library: ${PLASMA_LIB_PATH}")
+    message(STATUS "Found Plasma executable: ${PLASMA_EXECUTABLE}")
+  endif ()
+else ()
+  if (NOT Plasma_FIND_QUIETLY)
+    set(PLASMA_ERR_MSG "Could not find the Plasma library. Looked for headers")
+    set(PLASMA_ERR_MSG "${PLASMA_ERR_MSG} in ${PLASMA_SEARCH_HEADER_PATHS}, and for libs")
+    set(PLASMA_ERR_MSG "${PLASMA_ERR_MSG} in ${PLASMA_SEARCH_LIB_PATH}")
+    if (Plasma_FIND_REQUIRED)
+      message(FATAL_ERROR "${PLASMA_ERR_MSG}")
+    else (Plasma_FIND_REQUIRED)
+      message(STATUS "${PLASMA_ERR_MSG}")
+    endif (Plasma_FIND_REQUIRED)
+  endif ()
+  set(PLASMA_FOUND FALSE)
+endif ()
+
+mark_as_advanced(
+  PLASMA_INCLUDE_DIR
+  PLASMA_STATIC_LIB
+  PLASMA_SHARED_LIB
+)

http://git-wip-us.apache.org/repos/asf/arrow/blob/a0555c04/cpp/cmake_modules/UseCython.cmake
----------------------------------------------------------------------
diff --git a/cpp/cmake_modules/UseCython.cmake b/cpp/cmake_modules/UseCython.cmake
new file mode 100644
index 0000000..7920940
--- /dev/null
+++ b/cpp/cmake_modules/UseCython.cmake
@@ -0,0 +1,171 @@
+# Define a function to create Cython modules.
+#
+# For more information on the Cython project, see http://cython.org/.
+# "Cython is a language that makes writing C extensions for the Python language
+# as easy as Python itself."
+#
+# This file defines a CMake function to build a Cython Python module.
+# To use it, first include this file.
+#
+#   include( UseCython )
+#
+# Then call cython_add_module to create a module.
+#
+#   cython_add_module( <target_name> <pyx_target_name> <output_files> <src1> <src2> ... <srcN> )
+#
+# Where <module_name> is the desired name of the target for the resulting Python module,
+# <pyx_target_name> is the desired name of the target that runs the Cython compiler
+# to generate the needed C or C++ files, <output_files> is a variable to hold the
+# files generated by Cython, and <src1> <src2> ... are source files
+# to be compiled into the module, e.g. *.pyx, *.c, *.cxx, etc.
+# only one .pyx file may be present for each target
+# (this is an inherent limitation of Cython).
+#
+# The sample paths set with the CMake include_directories() command will be used
+# for include directories to search for *.pxd when running the Cython complire.
+#
+# Cache variables that effect the behavior include:
+#
+#  CYTHON_ANNOTATE
+#  CYTHON_NO_DOCSTRINGS
+#  CYTHON_FLAGS
+#
+# Source file properties that effect the build process are
+#
+#  CYTHON_IS_CXX
+#  CYTHON_IS_PUBLIC
+#  CYTHON_IS_API
+#
+# If this is set of a *.pyx file with CMake set_source_files_properties()
+# command, the file will be compiled as a C++ file.
+#
+# See also FindCython.cmake
+
+#=============================================================================
+# Copyright 2011 Kitware, Inc.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#=============================================================================
+
+# Configuration options.
+set( CYTHON_ANNOTATE OFF
+  CACHE BOOL "Create an annotated .html file when compiling *.pyx." )
+set( CYTHON_NO_DOCSTRINGS OFF
+  CACHE BOOL "Strip docstrings from the compiled module." )
+set( CYTHON_FLAGS "" CACHE STRING
+  "Extra flags to the cython compiler." )
+mark_as_advanced( CYTHON_ANNOTATE CYTHON_NO_DOCSTRINGS CYTHON_FLAGS)
+
+find_package( Cython REQUIRED )
+find_package( PythonLibsNew REQUIRED )
+
+set( CYTHON_CXX_EXTENSION "cxx" )
+set( CYTHON_C_EXTENSION "c" )
+
+# Create a *.c or *.cxx file from a *.pyx file.
+# Input the generated file basename.  The generate files will put into the variable
+# placed in the "generated_files" argument. Finally all the *.py and *.pyx files.
+function( compile_pyx _name pyx_target_name generated_files pyx_file)
+  # Default to assuming all files are C.
+  set( cxx_arg "" )
+  set( extension ${CYTHON_C_EXTENSION} )
+  set( pyx_lang "C" )
+  set( comment "Compiling Cython C source for ${_name}..." )
+
+  get_filename_component( pyx_file_basename "${pyx_file}" NAME_WE )
+
+  # Determine if it is a C or C++ file.
+  get_source_file_property( property_is_cxx ${pyx_file} CYTHON_IS_CXX )
+  if( ${property_is_cxx} )
+    set( cxx_arg "--cplus" )
+    set( extension ${CYTHON_CXX_EXTENSION} )
+    set( pyx_lang "CXX" )
+    set( comment "Compiling Cython CXX source for ${_name}..." )
+  endif()
+  get_source_file_property( pyx_location ${pyx_file} LOCATION )
+
+  # Set additional flags.
+  if( CYTHON_ANNOTATE )
+    set( annotate_arg "--annotate" )
+  endif()
+
+  if( CYTHON_NO_DOCSTRINGS )
+    set( no_docstrings_arg "--no-docstrings" )
+  endif()
+
+  if(NOT WIN32)
+      if( "${CMAKE_BUILD_TYPE}" STREQUAL "Debug" OR
+            "${CMAKE_BUILD_TYPE}" STREQUAL "RelWithDebInfo" )
+          set( cython_debug_arg "--gdb" )
+      endif()
+  endif()
+
+  # Determining generated file names.
+  get_source_file_property( property_is_public ${pyx_file} CYTHON_PUBLIC )
+  get_source_file_property( property_is_api ${pyx_file} CYTHON_API )
+  if( ${property_is_api} )
+      set( _generated_files "${_name}.${extension}" "${_name}.h" "${name}_api.h")
+  elseif( ${property_is_public} )
+      set( _generated_files "${_name}.${extension}" "${_name}.h")
+  else()
+      set( _generated_files "${_name}.${extension}")
+  endif()
+  set_source_files_properties( ${_generated_files} PROPERTIES GENERATED TRUE )
+
+  if (NOT WIN32)
+    # Cython creates a lot of compiler warning detritus on clang
+    set_source_files_properties(${_generated_files} PROPERTIES
+      COMPILE_FLAGS -Wno-unused-function)
+  endif()
+
+  set( ${generated_files} ${_generated_files} PARENT_SCOPE )
+
+  # Add the command to run the compiler.
+  add_custom_target(${pyx_target_name}
+    COMMAND ${CYTHON_EXECUTABLE} ${cxx_arg} ${include_directory_arg}
+    ${annotate_arg} ${no_docstrings_arg} ${cython_debug_arg}
+    ${CYTHON_FLAGS}
+    --output-file "${_name}.${extension}" ${pyx_location}
+    DEPENDS ${pyx_location}
+    # do not specify byproducts for now since they don't work with the older
+    # version of cmake available in the apt repositories.
+    #BYPRODUCTS ${_generated_files}
+    COMMENT ${comment}
+    )
+
+  # Remove their visibility to the user.
+  set( corresponding_pxd_file "" CACHE INTERNAL "" )
+  set( header_location "" CACHE INTERNAL "" )
+  set( pxd_location "" CACHE INTERNAL "" )
+endfunction()
+
+# cython_add_module( <name> src1 src2 ... srcN )
+# Build the Cython Python module.
+function( cython_add_module _name pyx_target_name generated_files)
+  set( pyx_module_source "" )
+  set( other_module_sources "" )
+  foreach( _file ${ARGN} )
+    if( ${_file} MATCHES ".*\\.py[x]?$" )
+      list( APPEND pyx_module_source ${_file} )
+    else()
+      list( APPEND other_module_sources ${_file} )
+    endif()
+  endforeach()
+  compile_pyx( ${_name} ${pyx_target_name} _generated_files ${pyx_module_source} )
+  set( ${generated_files} ${_generated_files} PARENT_SCOPE )
+  include_directories( ${PYTHON_INCLUDE_DIRS} )
+  python_add_module( ${_name} ${_generated_files} ${other_module_sources} )
+  add_dependencies( ${_name} ${pyx_target_name})
+endfunction()
+
+include( CMakeParseArguments )

http://git-wip-us.apache.org/repos/asf/arrow/blob/a0555c04/dev/release/rat_exclude_files.txt
----------------------------------------------------------------------
diff --git a/dev/release/rat_exclude_files.txt b/dev/release/rat_exclude_files.txt
index 83c9f19..fa7113c 100644
--- a/dev/release/rat_exclude_files.txt
+++ b/dev/release/rat_exclude_files.txt
@@ -34,11 +34,7 @@ cpp/src/plasma/thirdparty/xxhash.h
 dev/release/rat_exclude_files.txt
 js/.npmignore
 js/closure-compiler-scripts/*
-python/cmake_modules/BuildUtils.cmake
-python/cmake_modules/FindPythonLibsNew.cmake
-python/cmake_modules/FindNumPy.cmake
-python/cmake_modules/SetupCxxFlags.cmake
-python/cmake_modules/CompilerInfo.cmake
+python/cmake_modules
 python/doc/requirements.txt
 python/MANIFEST.in
 python/pyarrow/includes/__init__.pxd

http://git-wip-us.apache.org/repos/asf/arrow/blob/a0555c04/python/CMakeLists.txt
----------------------------------------------------------------------
diff --git a/python/CMakeLists.txt b/python/CMakeLists.txt
index d148d11..169e7ad 100644
--- a/python/CMakeLists.txt
+++ b/python/CMakeLists.txt
@@ -21,7 +21,17 @@
 cmake_minimum_required(VERSION 2.7)
 project(pyarrow)
 
-set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/cmake_modules")
+# Running from a Python sdist tarball
+set(LOCAL_CMAKE_MODULES "${CMAKE_SOURCE_DIR}/cmake_modules")
+if (EXISTS "${LOCAL_CMAKE_MODULES}")
+  set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${LOCAL_CMAKE_MODULES})
+endif()
+
+# Running from a git source tree
+set(CPP_CMAKE_MODULES "${CMAKE_SOURCE_DIR}/../cpp/cmake_modules")
+if (EXISTS "${CPP_CMAKE_MODULES}")
+  set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${CPP_CMAKE_MODULES})
+endif()
 
 include(CMakeParseArguments)
 

http://git-wip-us.apache.org/repos/asf/arrow/blob/a0555c04/python/MANIFEST.in
----------------------------------------------------------------------
diff --git a/python/MANIFEST.in b/python/MANIFEST.in
index 756879a..c6c9cd4 100644
--- a/python/MANIFEST.in
+++ b/python/MANIFEST.in
@@ -2,9 +2,8 @@ include README.md
 include LICENSE.txt
 
 global-include CMakeLists.txt
+graft pyarrow
 graft cmake_modules
-recursive-include src/pyarrow *.cc *.h
-recursive-include pyarrow *.pxd
 
 global-exclude *.so
 global-exclude *.pyc

http://git-wip-us.apache.org/repos/asf/arrow/blob/a0555c04/python/cmake_modules
----------------------------------------------------------------------
diff --git a/python/cmake_modules b/python/cmake_modules
new file mode 120000
index 0000000..76e2a8d
--- /dev/null
+++ b/python/cmake_modules
@@ -0,0 +1 @@
+../cpp/cmake_modules
\ No newline at end of file
diff --git a/python/cmake_modules/BuildUtils.cmake b/python/cmake_modules/BuildUtils.cmake
deleted file mode 120000
index e3c98c8..0000000
--- a/python/cmake_modules/BuildUtils.cmake
+++ /dev/null
@@ -1 +0,0 @@
-../../cpp/cmake_modules/BuildUtils.cmake
\ No newline at end of file
diff --git a/python/cmake_modules/CompilerInfo.cmake b/python/cmake_modules/CompilerInfo.cmake
deleted file mode 120000
index 559ac32..0000000
--- a/python/cmake_modules/CompilerInfo.cmake
+++ /dev/null
@@ -1 +0,0 @@
-../../cpp/cmake_modules/CompilerInfo.cmake
\ No newline at end of file
diff --git a/python/cmake_modules/FindArrow.cmake b/python/cmake_modules/FindArrow.cmake
deleted file mode 100644
index 12f76b6..0000000
--- a/python/cmake_modules/FindArrow.cmake
+++ /dev/null
@@ -1,145 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-#
-#   http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied.  See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-# - Find ARROW (arrow/api.h, libarrow.a, libarrow.so)
-# This module defines
-#  ARROW_INCLUDE_DIR, directory containing headers
-#  ARROW_LIBS, directory containing arrow libraries
-#  ARROW_STATIC_LIB, path to libarrow.a
-#  ARROW_SHARED_LIB, path to libarrow's shared library
-#  ARROW_SHARED_IMP_LIB, path to libarrow's import library (MSVC only)
-#  ARROW_FOUND, whether arrow has been found
-
-include(FindPkgConfig)
-
-if ("$ENV{ARROW_HOME}" STREQUAL "")
-  pkg_check_modules(ARROW arrow)
-  if (ARROW_FOUND)
-    pkg_get_variable(ARROW_ABI_VERSION arrow abi_version)
-    message(STATUS "Arrow ABI version: ${ARROW_ABI_VERSION}")
-    pkg_get_variable(ARROW_SO_VERSION arrow so_version)
-    message(STATUS "Arrow SO version: ${ARROW_SO_VERSION}")
-    set(ARROW_INCLUDE_DIR ${ARROW_INCLUDE_DIRS})
-    set(ARROW_LIBS ${ARROW_LIBRARY_DIRS})
-    set(ARROW_SEARCH_LIB_PATH ${ARROW_LIBRARY_DIRS})
-  endif()
-else()
-  set(ARROW_HOME "$ENV{ARROW_HOME}")
-
-  set(ARROW_SEARCH_HEADER_PATHS
-    ${ARROW_HOME}/include
-    )
-
-  set(ARROW_SEARCH_LIB_PATH
-    ${ARROW_HOME}/lib
-    )
-
-  find_path(ARROW_INCLUDE_DIR arrow/array.h PATHS
-    ${ARROW_SEARCH_HEADER_PATHS}
-    # make sure we don't accidentally pick up a different version
-    NO_DEFAULT_PATH
-    )
-endif()
-
-find_library(ARROW_LIB_PATH NAMES arrow
-  PATHS
-  ${ARROW_SEARCH_LIB_PATH}
-  NO_DEFAULT_PATH)
-get_filename_component(ARROW_LIBS ${ARROW_LIB_PATH} DIRECTORY)
-
-find_library(ARROW_PYTHON_LIB_PATH NAMES arrow_python
-  PATHS
-  ${ARROW_SEARCH_LIB_PATH}
-  NO_DEFAULT_PATH)
-get_filename_component(ARROW_PYTHON_LIBS ${ARROW_PYTHON_LIB_PATH} DIRECTORY)
-
-if (MSVC)
-  SET(CMAKE_FIND_LIBRARY_SUFFIXES ".lib" ".dll")
-
-  if (MSVC AND NOT ARROW_MSVC_STATIC_LIB_SUFFIX)
-    set(ARROW_MSVC_STATIC_LIB_SUFFIX "_static")
-  endif()
-
-  find_library(ARROW_SHARED_LIBRARIES NAMES arrow
-    PATHS ${ARROW_HOME} NO_DEFAULT_PATH
-    PATH_SUFFIXES "bin" )
-
-  find_library(ARROW_PYTHON_SHARED_LIBRARIES NAMES arrow_python
-    PATHS ${ARROW_HOME} NO_DEFAULT_PATH
-    PATH_SUFFIXES "bin" )
-  get_filename_component(ARROW_SHARED_LIBS ${ARROW_SHARED_LIBRARIES} PATH )
-  get_filename_component(ARROW_PYTHON_SHARED_LIBS ${ARROW_PYTHON_SHARED_LIBRARIES} PATH )
-endif ()
-
-if (ARROW_INCLUDE_DIR AND ARROW_LIBS)
-  set(ARROW_FOUND TRUE)
-  set(ARROW_LIB_NAME arrow)
-  set(ARROW_PYTHON_LIB_NAME arrow_python)
-  if (MSVC)
-    set(ARROW_STATIC_LIB ${ARROW_LIBS}/${ARROW_LIB_NAME}${ARROW_MSVC_STATIC_LIB_SUFFIX}${CMAKE_STATIC_LIBRARY_SUFFIX})
-    set(ARROW_PYTHON_STATIC_LIB ${ARROW_PYTHON_LIBS}/${ARROW_PYTHON_LIB_NAME}${ARROW_MSVC_STATIC_LIB_SUFFIX}${CMAKE_STATIC_LIBRARY_SUFFIX})
-    set(ARROW_SHARED_LIB ${ARROW_SHARED_LIBS}/${ARROW_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX})
-    set(ARROW_PYTHON_SHARED_LIB ${ARROW_PYTHON_SHARED_LIBS}/${ARROW_PYTHON_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX})
-    set(ARROW_SHARED_IMP_LIB ${ARROW_LIBS}/${ARROW_LIB_NAME}.lib)
-    set(ARROW_PYTHON_SHARED_IMP_LIB ${ARROW_PYTHON_LIBS}/${ARROW_PYTHON_LIB_NAME}.lib)
-  else()
-    set(ARROW_STATIC_LIB ${ARROW_PYTHON_LIB_PATH}/lib${ARROW_LIB_NAME}.a)
-    set(ARROW_PYTHON_STATIC_LIB ${ARROW_PYTHON_LIB_PATH}/lib${ARROW_PYTHON_LIB_NAME}.a)
-
-    set(ARROW_SHARED_LIB ${ARROW_LIBS}/lib${ARROW_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX})
-    set(ARROW_PYTHON_SHARED_LIB ${ARROW_LIBS}/lib${ARROW_PYTHON_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX})
-  endif()
-endif()
-
-if (ARROW_FOUND)
-  if (NOT Arrow_FIND_QUIETLY)
-    message(STATUS "Found the Arrow core library: ${ARROW_LIB_PATH}")
-    message(STATUS "Found the Arrow Python library: ${ARROW_PYTHON_LIB_PATH}")
-  endif ()
-else ()
-  if (NOT Arrow_FIND_QUIETLY)
-    set(ARROW_ERR_MSG "Could not find the Arrow library. Looked for headers")
-    set(ARROW_ERR_MSG "${ARROW_ERR_MSG} in ${ARROW_SEARCH_HEADER_PATHS}, and for libs")
-    set(ARROW_ERR_MSG "${ARROW_ERR_MSG} in ${ARROW_SEARCH_LIB_PATH}")
-    if (Arrow_FIND_REQUIRED)
-      message(FATAL_ERROR "${ARROW_ERR_MSG}")
-    else (Arrow_FIND_REQUIRED)
-      message(STATUS "${ARROW_ERR_MSG}")
-    endif (Arrow_FIND_REQUIRED)
-  endif ()
-  set(ARROW_FOUND FALSE)
-endif ()
-
-if (MSVC)
-  mark_as_advanced(
-    ARROW_INCLUDE_DIR
-    ARROW_STATIC_LIB
-    ARROW_SHARED_LIB
-    ARROW_SHARED_IMP_LIB
-    ARROW_PYTHON_STATIC_LIB
-    ARROW_PYTHON_SHARED_LIB
-    ARROW_PYTHON_SHARED_IMP_LIB
-  )
-else()
-  mark_as_advanced(
-    ARROW_INCLUDE_DIR
-    ARROW_STATIC_LIB
-    ARROW_SHARED_LIB
-    ARROW_PYTHON_STATIC_LIB
-    ARROW_PYTHON_SHARED_LIB
-  )
-endif()
diff --git a/python/cmake_modules/FindCython.cmake b/python/cmake_modules/FindCython.cmake
deleted file mode 100644
index 9df3b5d..0000000
--- a/python/cmake_modules/FindCython.cmake
+++ /dev/null
@@ -1,30 +0,0 @@
-# Find the Cython compiler.
-#
-# This code sets the following variables:
-#
-#  CYTHON_EXECUTABLE
-#
-# See also UseCython.cmake
-
-#=============================================================================
-# Copyright 2011 Kitware, Inc.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#=============================================================================
-
-find_program( CYTHON_EXECUTABLE NAMES cython cython.bat )
-
-include( FindPackageHandleStandardArgs )
-FIND_PACKAGE_HANDLE_STANDARD_ARGS( Cython REQUIRED_VARS CYTHON_EXECUTABLE )
-
-mark_as_advanced( CYTHON_EXECUTABLE )
diff --git a/python/cmake_modules/FindNumPy.cmake b/python/cmake_modules/FindNumPy.cmake
deleted file mode 120000
index 767b320..0000000
--- a/python/cmake_modules/FindNumPy.cmake
+++ /dev/null
@@ -1 +0,0 @@
-../../cpp/cmake_modules/FindNumPy.cmake
\ No newline at end of file
diff --git a/python/cmake_modules/FindParquet.cmake b/python/cmake_modules/FindParquet.cmake
deleted file mode 100644
index 0339ec5..0000000
--- a/python/cmake_modules/FindParquet.cmake
+++ /dev/null
@@ -1,131 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-#
-#   http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied.  See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-# - Find PARQUET (parquet/parquet.h, libparquet.a, libparquet.so)
-# This module defines
-#  PARQUET_INCLUDE_DIR, directory containing headers
-#  PARQUET_LIBS, directory containing parquet libraries
-#  PARQUET_STATIC_LIB, path to libparquet.a
-#  PARQUET_SHARED_LIB, path to libparquet's shared library
-#  PARQUET_SHARED_IMP_LIB, path to libparquet's import library (MSVC only)
-#  PARQUET_FOUND, whether parquet has been found
-
-include(FindPkgConfig)
-
-if(NOT "$ENV{PARQUET_HOME}" STREQUAL "")
-    set(PARQUET_HOME "$ENV{PARQUET_HOME}")
-endif()
-
-if (MSVC)
-  SET(CMAKE_FIND_LIBRARY_SUFFIXES ".lib" ".dll")
-
-  if (MSVC AND NOT PARQUET_MSVC_STATIC_LIB_SUFFIX)
-    set(PARQUET_MSVC_STATIC_LIB_SUFFIX "_static")
-  endif()
-
-  find_library(PARQUET_SHARED_LIBRARIES NAMES parquet
-    PATHS ${PARQUET_HOME} NO_DEFAULT_PATH
-    PATH_SUFFIXES "bin" )
-
-  get_filename_component(PARQUET_SHARED_LIBS ${PARQUET_SHARED_LIBRARIES} PATH )
-endif ()
-
-if(PARQUET_HOME)
-    set(PARQUET_SEARCH_HEADER_PATHS
-        ${PARQUET_HOME}/include
-        )
-    set(PARQUET_SEARCH_LIB_PATH
-        ${PARQUET_HOME}/lib
-        )
-    find_path(PARQUET_INCLUDE_DIR parquet/api/reader.h PATHS
-        ${PARQUET_SEARCH_HEADER_PATHS}
-        # make sure we don't accidentally pick up a different version
-        NO_DEFAULT_PATH
-        )
-    find_library(PARQUET_LIBRARIES NAMES parquet
-        PATHS ${PARQUET_HOME} NO_DEFAULT_PATH
-        PATH_SUFFIXES "lib")
-    get_filename_component(PARQUET_LIBS ${PARQUET_LIBRARIES} PATH )
-    set(PARQUET_ABI_VERSION "1.0.0")
-    set(PARQUET_SO_VERSION "1")
-else()
-    pkg_check_modules(PARQUET parquet)
-    if (PARQUET_FOUND)
-        pkg_get_variable(PARQUET_ABI_VERSION parquet abi_version)
-        message(STATUS "Parquet C++ ABI version: ${PARQUET_ABI_VERSION}")
-        pkg_get_variable(PARQUET_SO_VERSION parquet so_version)
-        message(STATUS "Parquet C++ SO version: ${PARQUET_SO_VERSION}")
-        set(PARQUET_INCLUDE_DIR ${PARQUET_INCLUDE_DIRS})
-        set(PARQUET_LIBS ${PARQUET_LIBRARY_DIRS})
-        set(PARQUET_SEARCH_LIB_PATH ${PARQUET_LIBRARY_DIRS})
-        message(STATUS "Searching for parquet libs in: ${PARQUET_SEARCH_LIB_PATH}")
-        find_library(PARQUET_LIBRARIES NAMES parquet
-            PATHS ${PARQUET_SEARCH_LIB_PATH} NO_DEFAULT_PATH)
-    else()
-        find_path(PARQUET_INCLUDE_DIR NAMES parquet/api/reader.h )
-        find_library(PARQUET_LIBRARIES NAMES parquet)
-        get_filename_component(PARQUET_LIBS ${PARQUET_LIBRARIES} PATH )
-    endif()
-endif()
-
-if (PARQUET_INCLUDE_DIR AND PARQUET_LIBRARIES)
-  set(PARQUET_FOUND TRUE)
-  set(PARQUET_LIB_NAME parquet)
-  if (MSVC)
-    set(PARQUET_STATIC_LIB "${PARQUET_LIBS}/${PARQUET_LIB_NAME}${PARQUET_MSVC_STATIC_LIB_SUFFIX}${CMAKE_STATIC_LIBRARY_SUFFIX}")
-    set(PARQUET_SHARED_LIB "${PARQUET_SHARED_LIBS}/${PARQUET_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}")
-    set(PARQUET_SHARED_IMP_LIB "${PARQUET_LIBS}/${PARQUET_LIB_NAME}.lib")
-  else()
-    set(PARQUET_STATIC_LIB ${PARQUET_LIBS}/${CMAKE_STATIC_LIBRARY_PREFIX}${PARQUET_LIB_NAME}.a)
-    set(PARQUET_SHARED_LIB ${PARQUET_LIBS}/${CMAKE_SHARED_LIBRARY_PREFIX}${PARQUET_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX})
-  endif()
-else ()
-  set(PARQUET_FOUND FALSE)
-endif ()
-
-if (PARQUET_FOUND)
-  if (NOT Parquet_FIND_QUIETLY)
-    message(STATUS "Found the Parquet library: ${PARQUET_LIBRARIES}")
-  endif ()
-else ()
-  if (NOT Parquet_FIND_QUIETLY)
-    if (NOT PARQUET_FOUND)
-      set(PARQUET_ERR_MSG "${PARQUET_ERR_MSG} Could not find the parquet library.")
-    endif()
-
-    set(PARQUET_ERR_MSG "${PARQUET_ERR_MSG} Looked in ")
-    if ( _parquet_roots )
-      set(PARQUET_ERR_MSG "${PARQUET_ERR_MSG} in ${_parquet_roots}.")
-    else ()
-      set(PARQUET_ERR_MSG "${PARQUET_ERR_MSG} system search paths.")
-    endif ()
-    if (Parquet_FIND_REQUIRED)
-      message(FATAL_ERROR "${PARQUET_ERR_MSG}")
-    else (Parquet_FIND_REQUIRED)
-      message(STATUS "${PARQUET_ERR_MSG}")
-    endif (Parquet_FIND_REQUIRED)
-  endif ()
-endif ()
-
-mark_as_advanced(
-  PARQUET_FOUND
-  PARQUET_INCLUDE_DIR
-  PARQUET_LIBS
-  PARQUET_LIBRARIES
-  PARQUET_STATIC_LIB
-  PARQUET_SHARED_LIB
-)
diff --git a/python/cmake_modules/FindPlasma.cmake b/python/cmake_modules/FindPlasma.cmake
deleted file mode 100644
index 3acaa34..0000000
--- a/python/cmake_modules/FindPlasma.cmake
+++ /dev/null
@@ -1,99 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-#
-#   http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied.  See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-# - Find PLASMA (plasma/client.h, libplasma.a, libplasma.so)
-# This module defines
-#  PLASMA_INCLUDE_DIR, directory containing headers
-#  PLASMA_LIBS, directory containing plasma libraries
-#  PLASMA_STATIC_LIB, path to libplasma.a
-#  PLASMA_SHARED_LIB, path to libplasma's shared library
-#  PLASMA_SHARED_IMP_LIB, path to libplasma's import library (MSVC only)
-#  PLASMA_FOUND, whether plasma has been found
-
-include(FindPkgConfig)
-
-if ("$ENV{ARROW_HOME}" STREQUAL "")
-  pkg_check_modules(PLASMA plasma)
-  if (PLASMA_FOUND)
-    pkg_get_variable(PLASMA_EXECUTABLE plasma executable)
-    pkg_get_variable(PLASMA_ABI_VERSION plasma abi_version)
-    message(STATUS "Plasma ABI version: ${PLASMA_ABI_VERSION}")
-    pkg_get_variable(PLASMA_SO_VERSION plasma so_version)
-    message(STATUS "Plasma SO version: ${PLASMA_SO_VERSION}")
-    set(PLASMA_INCLUDE_DIR ${PLASMA_INCLUDE_DIRS})
-    set(PLASMA_LIBS ${PLASMA_LIBRARY_DIRS})
-    set(PLASMA_SEARCH_LIB_PATH ${PLASMA_LIBRARY_DIRS})
-  endif()
-else()
-  set(PLASMA_HOME "$ENV{ARROW_HOME}")
-
-  set(PLASMA_EXECUTABLE ${PLASMA_HOME}/bin/plasma_store)
-
-  set(PLASMA_SEARCH_HEADER_PATHS
-    ${PLASMA_HOME}/include
-    )
-
-  set(PLASMA_SEARCH_LIB_PATH
-    ${PLASMA_HOME}/lib
-    )
-
-  find_path(PLASMA_INCLUDE_DIR plasma/client.h PATHS
-    ${PLASMA_SEARCH_HEADER_PATHS}
-    # make sure we don't accidentally pick up a different version
-    NO_DEFAULT_PATH
-    )
-endif()
-
-find_library(PLASMA_LIB_PATH NAMES plasma
-  PATHS
-  ${PLASMA_SEARCH_LIB_PATH}
-  NO_DEFAULT_PATH)
-get_filename_component(PLASMA_LIBS ${PLASMA_LIB_PATH} DIRECTORY)
-
-if (PLASMA_INCLUDE_DIR AND PLASMA_LIBS)
-  set(PLASMA_FOUND TRUE)
-  set(PLASMA_LIB_NAME plasma)
-
-  set(PLASMA_STATIC_LIB ${PLASMA_LIBS}/lib${PLASMA_LIB_NAME}.a)
-
-  set(PLASMA_SHARED_LIB ${PLASMA_LIBS}/lib${PLASMA_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX})
-endif()
-
-if (PLASMA_FOUND)
-  if (NOT Plasma_FIND_QUIETLY)
-    message(STATUS "Found the Plasma core library: ${PLASMA_LIB_PATH}")
-    message(STATUS "Found Plasma executable: ${PLASMA_EXECUTABLE}")
-  endif ()
-else ()
-  if (NOT Plasma_FIND_QUIETLY)
-    set(PLASMA_ERR_MSG "Could not find the Plasma library. Looked for headers")
-    set(PLASMA_ERR_MSG "${PLASMA_ERR_MSG} in ${PLASMA_SEARCH_HEADER_PATHS}, and for libs")
-    set(PLASMA_ERR_MSG "${PLASMA_ERR_MSG} in ${PLASMA_SEARCH_LIB_PATH}")
-    if (Plasma_FIND_REQUIRED)
-      message(FATAL_ERROR "${PLASMA_ERR_MSG}")
-    else (Plasma_FIND_REQUIRED)
-      message(STATUS "${PLASMA_ERR_MSG}")
-    endif (Plasma_FIND_REQUIRED)
-  endif ()
-  set(PLASMA_FOUND FALSE)
-endif ()
-
-mark_as_advanced(
-  PLASMA_INCLUDE_DIR
-  PLASMA_STATIC_LIB
-  PLASMA_SHARED_LIB
-)
diff --git a/python/cmake_modules/FindPythonLibsNew.cmake b/python/cmake_modules/FindPythonLibsNew.cmake
deleted file mode 120000
index 7087123..0000000
--- a/python/cmake_modules/FindPythonLibsNew.cmake
+++ /dev/null
@@ -1 +0,0 @@
-../../cpp/cmake_modules/FindPythonLibsNew.cmake
\ No newline at end of file
diff --git a/python/cmake_modules/SetupCxxFlags.cmake b/python/cmake_modules/SetupCxxFlags.cmake
deleted file mode 120000
index 3121a89..0000000
--- a/python/cmake_modules/SetupCxxFlags.cmake
+++ /dev/null
@@ -1 +0,0 @@
-../../cpp/cmake_modules/SetupCxxFlags.cmake
\ No newline at end of file
diff --git a/python/cmake_modules/UseCython.cmake b/python/cmake_modules/UseCython.cmake
deleted file mode 100644
index 7920940..0000000
--- a/python/cmake_modules/UseCython.cmake
+++ /dev/null
@@ -1,171 +0,0 @@
-# Define a function to create Cython modules.
-#
-# For more information on the Cython project, see http://cython.org/.
-# "Cython is a language that makes writing C extensions for the Python language
-# as easy as Python itself."
-#
-# This file defines a CMake function to build a Cython Python module.
-# To use it, first include this file.
-#
-#   include( UseCython )
-#
-# Then call cython_add_module to create a module.
-#
-#   cython_add_module( <target_name> <pyx_target_name> <output_files> <src1> <src2> ... <srcN> )
-#
-# Where <module_name> is the desired name of the target for the resulting Python module,
-# <pyx_target_name> is the desired name of the target that runs the Cython compiler
-# to generate the needed C or C++ files, <output_files> is a variable to hold the
-# files generated by Cython, and <src1> <src2> ... are source files
-# to be compiled into the module, e.g. *.pyx, *.c, *.cxx, etc.
-# only one .pyx file may be present for each target
-# (this is an inherent limitation of Cython).
-#
-# The sample paths set with the CMake include_directories() command will be used
-# for include directories to search for *.pxd when running the Cython complire.
-#
-# Cache variables that effect the behavior include:
-#
-#  CYTHON_ANNOTATE
-#  CYTHON_NO_DOCSTRINGS
-#  CYTHON_FLAGS
-#
-# Source file properties that effect the build process are
-#
-#  CYTHON_IS_CXX
-#  CYTHON_IS_PUBLIC
-#  CYTHON_IS_API
-#
-# If this is set of a *.pyx file with CMake set_source_files_properties()
-# command, the file will be compiled as a C++ file.
-#
-# See also FindCython.cmake
-
-#=============================================================================
-# Copyright 2011 Kitware, Inc.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#=============================================================================
-
-# Configuration options.
-set( CYTHON_ANNOTATE OFF
-  CACHE BOOL "Create an annotated .html file when compiling *.pyx." )
-set( CYTHON_NO_DOCSTRINGS OFF
-  CACHE BOOL "Strip docstrings from the compiled module." )
-set( CYTHON_FLAGS "" CACHE STRING
-  "Extra flags to the cython compiler." )
-mark_as_advanced( CYTHON_ANNOTATE CYTHON_NO_DOCSTRINGS CYTHON_FLAGS)
-
-find_package( Cython REQUIRED )
-find_package( PythonLibsNew REQUIRED )
-
-set( CYTHON_CXX_EXTENSION "cxx" )
-set( CYTHON_C_EXTENSION "c" )
-
-# Create a *.c or *.cxx file from a *.pyx file.
-# Input the generated file basename.  The generate files will put into the variable
-# placed in the "generated_files" argument. Finally all the *.py and *.pyx files.
-function( compile_pyx _name pyx_target_name generated_files pyx_file)
-  # Default to assuming all files are C.
-  set( cxx_arg "" )
-  set( extension ${CYTHON_C_EXTENSION} )
-  set( pyx_lang "C" )
-  set( comment "Compiling Cython C source for ${_name}..." )
-
-  get_filename_component( pyx_file_basename "${pyx_file}" NAME_WE )
-
-  # Determine if it is a C or C++ file.
-  get_source_file_property( property_is_cxx ${pyx_file} CYTHON_IS_CXX )
-  if( ${property_is_cxx} )
-    set( cxx_arg "--cplus" )
-    set( extension ${CYTHON_CXX_EXTENSION} )
-    set( pyx_lang "CXX" )
-    set( comment "Compiling Cython CXX source for ${_name}..." )
-  endif()
-  get_source_file_property( pyx_location ${pyx_file} LOCATION )
-
-  # Set additional flags.
-  if( CYTHON_ANNOTATE )
-    set( annotate_arg "--annotate" )
-  endif()
-
-  if( CYTHON_NO_DOCSTRINGS )
-    set( no_docstrings_arg "--no-docstrings" )
-  endif()
-
-  if(NOT WIN32)
-      if( "${CMAKE_BUILD_TYPE}" STREQUAL "Debug" OR
-            "${CMAKE_BUILD_TYPE}" STREQUAL "RelWithDebInfo" )
-          set( cython_debug_arg "--gdb" )
-      endif()
-  endif()
-
-  # Determining generated file names.
-  get_source_file_property( property_is_public ${pyx_file} CYTHON_PUBLIC )
-  get_source_file_property( property_is_api ${pyx_file} CYTHON_API )
-  if( ${property_is_api} )
-      set( _generated_files "${_name}.${extension}" "${_name}.h" "${name}_api.h")
-  elseif( ${property_is_public} )
-      set( _generated_files "${_name}.${extension}" "${_name}.h")
-  else()
-      set( _generated_files "${_name}.${extension}")
-  endif()
-  set_source_files_properties( ${_generated_files} PROPERTIES GENERATED TRUE )
-
-  if (NOT WIN32)
-    # Cython creates a lot of compiler warning detritus on clang
-    set_source_files_properties(${_generated_files} PROPERTIES
-      COMPILE_FLAGS -Wno-unused-function)
-  endif()
-
-  set( ${generated_files} ${_generated_files} PARENT_SCOPE )
-
-  # Add the command to run the compiler.
-  add_custom_target(${pyx_target_name}
-    COMMAND ${CYTHON_EXECUTABLE} ${cxx_arg} ${include_directory_arg}
-    ${annotate_arg} ${no_docstrings_arg} ${cython_debug_arg}
-    ${CYTHON_FLAGS}
-    --output-file "${_name}.${extension}" ${pyx_location}
-    DEPENDS ${pyx_location}
-    # do not specify byproducts for now since they don't work with the older
-    # version of cmake available in the apt repositories.
-    #BYPRODUCTS ${_generated_files}
-    COMMENT ${comment}
-    )
-
-  # Remove their visibility to the user.
-  set( corresponding_pxd_file "" CACHE INTERNAL "" )
-  set( header_location "" CACHE INTERNAL "" )
-  set( pxd_location "" CACHE INTERNAL "" )
-endfunction()
-
-# cython_add_module( <name> src1 src2 ... srcN )
-# Build the Cython Python module.
-function( cython_add_module _name pyx_target_name generated_files)
-  set( pyx_module_source "" )
-  set( other_module_sources "" )
-  foreach( _file ${ARGN} )
-    if( ${_file} MATCHES ".*\\.py[x]?$" )
-      list( APPEND pyx_module_source ${_file} )
-    else()
-      list( APPEND other_module_sources ${_file} )
-    endif()
-  endforeach()
-  compile_pyx( ${_name} ${pyx_target_name} _generated_files ${pyx_module_source} )
-  set( ${generated_files} ${_generated_files} PARENT_SCOPE )
-  include_directories( ${PYTHON_INCLUDE_DIRS} )
-  python_add_module( ${_name} ${_generated_files} ${other_module_sources} )
-  add_dependencies( ${_name} ${pyx_target_name})
-endfunction()
-
-include( CMakeParseArguments )

http://git-wip-us.apache.org/repos/asf/arrow/blob/a0555c04/python/cmake_modules/BuildUtils.cmake
----------------------------------------------------------------------
diff --git a/python/cmake_modules/BuildUtils.cmake b/python/cmake_modules/BuildUtils.cmake
deleted file mode 120000
index e3c98c8..0000000
--- a/python/cmake_modules/BuildUtils.cmake
+++ /dev/null
@@ -1 +0,0 @@
-../../cpp/cmake_modules/BuildUtils.cmake
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/arrow/blob/a0555c04/python/cmake_modules/CompilerInfo.cmake
----------------------------------------------------------------------
diff --git a/python/cmake_modules/CompilerInfo.cmake b/python/cmake_modules/CompilerInfo.cmake
deleted file mode 120000
index 559ac32..0000000
--- a/python/cmake_modules/CompilerInfo.cmake
+++ /dev/null
@@ -1 +0,0 @@
-../../cpp/cmake_modules/CompilerInfo.cmake
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/arrow/blob/a0555c04/python/cmake_modules/FindArrow.cmake
----------------------------------------------------------------------
diff --git a/python/cmake_modules/FindArrow.cmake b/python/cmake_modules/FindArrow.cmake
deleted file mode 100644
index 12f76b6..0000000
--- a/python/cmake_modules/FindArrow.cmake
+++ /dev/null
@@ -1,145 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-#
-#   http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied.  See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-# - Find ARROW (arrow/api.h, libarrow.a, libarrow.so)
-# This module defines
-#  ARROW_INCLUDE_DIR, directory containing headers
-#  ARROW_LIBS, directory containing arrow libraries
-#  ARROW_STATIC_LIB, path to libarrow.a
-#  ARROW_SHARED_LIB, path to libarrow's shared library
-#  ARROW_SHARED_IMP_LIB, path to libarrow's import library (MSVC only)
-#  ARROW_FOUND, whether arrow has been found
-
-include(FindPkgConfig)
-
-if ("$ENV{ARROW_HOME}" STREQUAL "")
-  pkg_check_modules(ARROW arrow)
-  if (ARROW_FOUND)
-    pkg_get_variable(ARROW_ABI_VERSION arrow abi_version)
-    message(STATUS "Arrow ABI version: ${ARROW_ABI_VERSION}")
-    pkg_get_variable(ARROW_SO_VERSION arrow so_version)
-    message(STATUS "Arrow SO version: ${ARROW_SO_VERSION}")
-    set(ARROW_INCLUDE_DIR ${ARROW_INCLUDE_DIRS})
-    set(ARROW_LIBS ${ARROW_LIBRARY_DIRS})
-    set(ARROW_SEARCH_LIB_PATH ${ARROW_LIBRARY_DIRS})
-  endif()
-else()
-  set(ARROW_HOME "$ENV{ARROW_HOME}")
-
-  set(ARROW_SEARCH_HEADER_PATHS
-    ${ARROW_HOME}/include
-    )
-
-  set(ARROW_SEARCH_LIB_PATH
-    ${ARROW_HOME}/lib
-    )
-
-  find_path(ARROW_INCLUDE_DIR arrow/array.h PATHS
-    ${ARROW_SEARCH_HEADER_PATHS}
-    # make sure we don't accidentally pick up a different version
-    NO_DEFAULT_PATH
-    )
-endif()
-
-find_library(ARROW_LIB_PATH NAMES arrow
-  PATHS
-  ${ARROW_SEARCH_LIB_PATH}
-  NO_DEFAULT_PATH)
-get_filename_component(ARROW_LIBS ${ARROW_LIB_PATH} DIRECTORY)
-
-find_library(ARROW_PYTHON_LIB_PATH NAMES arrow_python
-  PATHS
-  ${ARROW_SEARCH_LIB_PATH}
-  NO_DEFAULT_PATH)
-get_filename_component(ARROW_PYTHON_LIBS ${ARROW_PYTHON_LIB_PATH} DIRECTORY)
-
-if (MSVC)
-  SET(CMAKE_FIND_LIBRARY_SUFFIXES ".lib" ".dll")
-
-  if (MSVC AND NOT ARROW_MSVC_STATIC_LIB_SUFFIX)
-    set(ARROW_MSVC_STATIC_LIB_SUFFIX "_static")
-  endif()
-
-  find_library(ARROW_SHARED_LIBRARIES NAMES arrow
-    PATHS ${ARROW_HOME} NO_DEFAULT_PATH
-    PATH_SUFFIXES "bin" )
-
-  find_library(ARROW_PYTHON_SHARED_LIBRARIES NAMES arrow_python
-    PATHS ${ARROW_HOME} NO_DEFAULT_PATH
-    PATH_SUFFIXES "bin" )
-  get_filename_component(ARROW_SHARED_LIBS ${ARROW_SHARED_LIBRARIES} PATH )
-  get_filename_component(ARROW_PYTHON_SHARED_LIBS ${ARROW_PYTHON_SHARED_LIBRARIES} PATH )
-endif ()
-
-if (ARROW_INCLUDE_DIR AND ARROW_LIBS)
-  set(ARROW_FOUND TRUE)
-  set(ARROW_LIB_NAME arrow)
-  set(ARROW_PYTHON_LIB_NAME arrow_python)
-  if (MSVC)
-    set(ARROW_STATIC_LIB ${ARROW_LIBS}/${ARROW_LIB_NAME}${ARROW_MSVC_STATIC_LIB_SUFFIX}${CMAKE_STATIC_LIBRARY_SUFFIX})
-    set(ARROW_PYTHON_STATIC_LIB ${ARROW_PYTHON_LIBS}/${ARROW_PYTHON_LIB_NAME}${ARROW_MSVC_STATIC_LIB_SUFFIX}${CMAKE_STATIC_LIBRARY_SUFFIX})
-    set(ARROW_SHARED_LIB ${ARROW_SHARED_LIBS}/${ARROW_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX})
-    set(ARROW_PYTHON_SHARED_LIB ${ARROW_PYTHON_SHARED_LIBS}/${ARROW_PYTHON_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX})
-    set(ARROW_SHARED_IMP_LIB ${ARROW_LIBS}/${ARROW_LIB_NAME}.lib)
-    set(ARROW_PYTHON_SHARED_IMP_LIB ${ARROW_PYTHON_LIBS}/${ARROW_PYTHON_LIB_NAME}.lib)
-  else()
-    set(ARROW_STATIC_LIB ${ARROW_PYTHON_LIB_PATH}/lib${ARROW_LIB_NAME}.a)
-    set(ARROW_PYTHON_STATIC_LIB ${ARROW_PYTHON_LIB_PATH}/lib${ARROW_PYTHON_LIB_NAME}.a)
-
-    set(ARROW_SHARED_LIB ${ARROW_LIBS}/lib${ARROW_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX})
-    set(ARROW_PYTHON_SHARED_LIB ${ARROW_LIBS}/lib${ARROW_PYTHON_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX})
-  endif()
-endif()
-
-if (ARROW_FOUND)
-  if (NOT Arrow_FIND_QUIETLY)
-    message(STATUS "Found the Arrow core library: ${ARROW_LIB_PATH}")
-    message(STATUS "Found the Arrow Python library: ${ARROW_PYTHON_LIB_PATH}")
-  endif ()
-else ()
-  if (NOT Arrow_FIND_QUIETLY)
-    set(ARROW_ERR_MSG "Could not find the Arrow library. Looked for headers")
-    set(ARROW_ERR_MSG "${ARROW_ERR_MSG} in ${ARROW_SEARCH_HEADER_PATHS}, and for libs")
-    set(ARROW_ERR_MSG "${ARROW_ERR_MSG} in ${ARROW_SEARCH_LIB_PATH}")
-    if (Arrow_FIND_REQUIRED)
-      message(FATAL_ERROR "${ARROW_ERR_MSG}")
-    else (Arrow_FIND_REQUIRED)
-      message(STATUS "${ARROW_ERR_MSG}")
-    endif (Arrow_FIND_REQUIRED)
-  endif ()
-  set(ARROW_FOUND FALSE)
-endif ()
-
-if (MSVC)
-  mark_as_advanced(
-    ARROW_INCLUDE_DIR
-    ARROW_STATIC_LIB
-    ARROW_SHARED_LIB
-    ARROW_SHARED_IMP_LIB
-    ARROW_PYTHON_STATIC_LIB
-    ARROW_PYTHON_SHARED_LIB
-    ARROW_PYTHON_SHARED_IMP_LIB
-  )
-else()
-  mark_as_advanced(
-    ARROW_INCLUDE_DIR
-    ARROW_STATIC_LIB
-    ARROW_SHARED_LIB
-    ARROW_PYTHON_STATIC_LIB
-    ARROW_PYTHON_SHARED_LIB
-  )
-endif()

http://git-wip-us.apache.org/repos/asf/arrow/blob/a0555c04/python/cmake_modules/FindCython.cmake
----------------------------------------------------------------------
diff --git a/python/cmake_modules/FindCython.cmake b/python/cmake_modules/FindCython.cmake
deleted file mode 100644
index 9df3b5d..0000000
--- a/python/cmake_modules/FindCython.cmake
+++ /dev/null
@@ -1,30 +0,0 @@
-# Find the Cython compiler.
-#
-# This code sets the following variables:
-#
-#  CYTHON_EXECUTABLE
-#
-# See also UseCython.cmake
-
-#=============================================================================
-# Copyright 2011 Kitware, Inc.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#=============================================================================
-
-find_program( CYTHON_EXECUTABLE NAMES cython cython.bat )
-
-include( FindPackageHandleStandardArgs )
-FIND_PACKAGE_HANDLE_STANDARD_ARGS( Cython REQUIRED_VARS CYTHON_EXECUTABLE )
-
-mark_as_advanced( CYTHON_EXECUTABLE )

http://git-wip-us.apache.org/repos/asf/arrow/blob/a0555c04/python/cmake_modules/FindNumPy.cmake
----------------------------------------------------------------------
diff --git a/python/cmake_modules/FindNumPy.cmake b/python/cmake_modules/FindNumPy.cmake
deleted file mode 120000
index 767b320..0000000
--- a/python/cmake_modules/FindNumPy.cmake
+++ /dev/null
@@ -1 +0,0 @@
-../../cpp/cmake_modules/FindNumPy.cmake
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/arrow/blob/a0555c04/python/cmake_modules/FindParquet.cmake
----------------------------------------------------------------------
diff --git a/python/cmake_modules/FindParquet.cmake b/python/cmake_modules/FindParquet.cmake
deleted file mode 100644
index 0339ec5..0000000
--- a/python/cmake_modules/FindParquet.cmake
+++ /dev/null
@@ -1,131 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-#
-#   http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied.  See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-# - Find PARQUET (parquet/parquet.h, libparquet.a, libparquet.so)
-# This module defines
-#  PARQUET_INCLUDE_DIR, directory containing headers
-#  PARQUET_LIBS, directory containing parquet libraries
-#  PARQUET_STATIC_LIB, path to libparquet.a
-#  PARQUET_SHARED_LIB, path to libparquet's shared library
-#  PARQUET_SHARED_IMP_LIB, path to libparquet's import library (MSVC only)
-#  PARQUET_FOUND, whether parquet has been found
-
-include(FindPkgConfig)
-
-if(NOT "$ENV{PARQUET_HOME}" STREQUAL "")
-    set(PARQUET_HOME "$ENV{PARQUET_HOME}")
-endif()
-
-if (MSVC)
-  SET(CMAKE_FIND_LIBRARY_SUFFIXES ".lib" ".dll")
-
-  if (MSVC AND NOT PARQUET_MSVC_STATIC_LIB_SUFFIX)
-    set(PARQUET_MSVC_STATIC_LIB_SUFFIX "_static")
-  endif()
-
-  find_library(PARQUET_SHARED_LIBRARIES NAMES parquet
-    PATHS ${PARQUET_HOME} NO_DEFAULT_PATH
-    PATH_SUFFIXES "bin" )
-
-  get_filename_component(PARQUET_SHARED_LIBS ${PARQUET_SHARED_LIBRARIES} PATH )
-endif ()
-
-if(PARQUET_HOME)
-    set(PARQUET_SEARCH_HEADER_PATHS
-        ${PARQUET_HOME}/include
-        )
-    set(PARQUET_SEARCH_LIB_PATH
-        ${PARQUET_HOME}/lib
-        )
-    find_path(PARQUET_INCLUDE_DIR parquet/api/reader.h PATHS
-        ${PARQUET_SEARCH_HEADER_PATHS}
-        # make sure we don't accidentally pick up a different version
-        NO_DEFAULT_PATH
-        )
-    find_library(PARQUET_LIBRARIES NAMES parquet
-        PATHS ${PARQUET_HOME} NO_DEFAULT_PATH
-        PATH_SUFFIXES "lib")
-    get_filename_component(PARQUET_LIBS ${PARQUET_LIBRARIES} PATH )
-    set(PARQUET_ABI_VERSION "1.0.0")
-    set(PARQUET_SO_VERSION "1")
-else()
-    pkg_check_modules(PARQUET parquet)
-    if (PARQUET_FOUND)
-        pkg_get_variable(PARQUET_ABI_VERSION parquet abi_version)
-        message(STATUS "Parquet C++ ABI version: ${PARQUET_ABI_VERSION}")
-        pkg_get_variable(PARQUET_SO_VERSION parquet so_version)
-        message(STATUS "Parquet C++ SO version: ${PARQUET_SO_VERSION}")
-        set(PARQUET_INCLUDE_DIR ${PARQUET_INCLUDE_DIRS})
-        set(PARQUET_LIBS ${PARQUET_LIBRARY_DIRS})
-        set(PARQUET_SEARCH_LIB_PATH ${PARQUET_LIBRARY_DIRS})
-        message(STATUS "Searching for parquet libs in: ${PARQUET_SEARCH_LIB_PATH}")
-        find_library(PARQUET_LIBRARIES NAMES parquet
-            PATHS ${PARQUET_SEARCH_LIB_PATH} NO_DEFAULT_PATH)
-    else()
-        find_path(PARQUET_INCLUDE_DIR NAMES parquet/api/reader.h )
-        find_library(PARQUET_LIBRARIES NAMES parquet)
-        get_filename_component(PARQUET_LIBS ${PARQUET_LIBRARIES} PATH )
-    endif()
-endif()
-
-if (PARQUET_INCLUDE_DIR AND PARQUET_LIBRARIES)
-  set(PARQUET_FOUND TRUE)
-  set(PARQUET_LIB_NAME parquet)
-  if (MSVC)
-    set(PARQUET_STATIC_LIB "${PARQUET_LIBS}/${PARQUET_LIB_NAME}${PARQUET_MSVC_STATIC_LIB_SUFFIX}${CMAKE_STATIC_LIBRARY_SUFFIX}")
-    set(PARQUET_SHARED_LIB "${PARQUET_SHARED_LIBS}/${PARQUET_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}")
-    set(PARQUET_SHARED_IMP_LIB "${PARQUET_LIBS}/${PARQUET_LIB_NAME}.lib")
-  else()
-    set(PARQUET_STATIC_LIB ${PARQUET_LIBS}/${CMAKE_STATIC_LIBRARY_PREFIX}${PARQUET_LIB_NAME}.a)
-    set(PARQUET_SHARED_LIB ${PARQUET_LIBS}/${CMAKE_SHARED_LIBRARY_PREFIX}${PARQUET_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX})
-  endif()
-else ()
-  set(PARQUET_FOUND FALSE)
-endif ()
-
-if (PARQUET_FOUND)
-  if (NOT Parquet_FIND_QUIETLY)
-    message(STATUS "Found the Parquet library: ${PARQUET_LIBRARIES}")
-  endif ()
-else ()
-  if (NOT Parquet_FIND_QUIETLY)
-    if (NOT PARQUET_FOUND)
-      set(PARQUET_ERR_MSG "${PARQUET_ERR_MSG} Could not find the parquet library.")
-    endif()
-
-    set(PARQUET_ERR_MSG "${PARQUET_ERR_MSG} Looked in ")
-    if ( _parquet_roots )
-      set(PARQUET_ERR_MSG "${PARQUET_ERR_MSG} in ${_parquet_roots}.")
-    else ()
-      set(PARQUET_ERR_MSG "${PARQUET_ERR_MSG} system search paths.")
-    endif ()
-    if (Parquet_FIND_REQUIRED)
-      message(FATAL_ERROR "${PARQUET_ERR_MSG}")
-    else (Parquet_FIND_REQUIRED)
-      message(STATUS "${PARQUET_ERR_MSG}")
-    endif (Parquet_FIND_REQUIRED)
-  endif ()
-endif ()
-
-mark_as_advanced(
-  PARQUET_FOUND
-  PARQUET_INCLUDE_DIR
-  PARQUET_LIBS
-  PARQUET_LIBRARIES
-  PARQUET_STATIC_LIB
-  PARQUET_SHARED_LIB
-)

http://git-wip-us.apache.org/repos/asf/arrow/blob/a0555c04/python/cmake_modules/FindPlasma.cmake
----------------------------------------------------------------------
diff --git a/python/cmake_modules/FindPlasma.cmake b/python/cmake_modules/FindPlasma.cmake
deleted file mode 100644
index 3acaa34..0000000
--- a/python/cmake_modules/FindPlasma.cmake
+++ /dev/null
@@ -1,99 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-#
-#   http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied.  See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-# - Find PLASMA (plasma/client.h, libplasma.a, libplasma.so)
-# This module defines
-#  PLASMA_INCLUDE_DIR, directory containing headers
-#  PLASMA_LIBS, directory containing plasma libraries
-#  PLASMA_STATIC_LIB, path to libplasma.a
-#  PLASMA_SHARED_LIB, path to libplasma's shared library
-#  PLASMA_SHARED_IMP_LIB, path to libplasma's import library (MSVC only)
-#  PLASMA_FOUND, whether plasma has been found
-
-include(FindPkgConfig)
-
-if ("$ENV{ARROW_HOME}" STREQUAL "")
-  pkg_check_modules(PLASMA plasma)
-  if (PLASMA_FOUND)
-    pkg_get_variable(PLASMA_EXECUTABLE plasma executable)
-    pkg_get_variable(PLASMA_ABI_VERSION plasma abi_version)
-    message(STATUS "Plasma ABI version: ${PLASMA_ABI_VERSION}")
-    pkg_get_variable(PLASMA_SO_VERSION plasma so_version)
-    message(STATUS "Plasma SO version: ${PLASMA_SO_VERSION}")
-    set(PLASMA_INCLUDE_DIR ${PLASMA_INCLUDE_DIRS})
-    set(PLASMA_LIBS ${PLASMA_LIBRARY_DIRS})
-    set(PLASMA_SEARCH_LIB_PATH ${PLASMA_LIBRARY_DIRS})
-  endif()
-else()
-  set(PLASMA_HOME "$ENV{ARROW_HOME}")
-
-  set(PLASMA_EXECUTABLE ${PLASMA_HOME}/bin/plasma_store)
-
-  set(PLASMA_SEARCH_HEADER_PATHS
-    ${PLASMA_HOME}/include
-    )
-
-  set(PLASMA_SEARCH_LIB_PATH
-    ${PLASMA_HOME}/lib
-    )
-
-  find_path(PLASMA_INCLUDE_DIR plasma/client.h PATHS
-    ${PLASMA_SEARCH_HEADER_PATHS}
-    # make sure we don't accidentally pick up a different version
-    NO_DEFAULT_PATH
-    )
-endif()
-
-find_library(PLASMA_LIB_PATH NAMES plasma
-  PATHS
-  ${PLASMA_SEARCH_LIB_PATH}
-  NO_DEFAULT_PATH)
-get_filename_component(PLASMA_LIBS ${PLASMA_LIB_PATH} DIRECTORY)
-
-if (PLASMA_INCLUDE_DIR AND PLASMA_LIBS)
-  set(PLASMA_FOUND TRUE)
-  set(PLASMA_LIB_NAME plasma)
-
-  set(PLASMA_STATIC_LIB ${PLASMA_LIBS}/lib${PLASMA_LIB_NAME}.a)
-
-  set(PLASMA_SHARED_LIB ${PLASMA_LIBS}/lib${PLASMA_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX})
-endif()
-
-if (PLASMA_FOUND)
-  if (NOT Plasma_FIND_QUIETLY)
-    message(STATUS "Found the Plasma core library: ${PLASMA_LIB_PATH}")
-    message(STATUS "Found Plasma executable: ${PLASMA_EXECUTABLE}")
-  endif ()
-else ()
-  if (NOT Plasma_FIND_QUIETLY)
-    set(PLASMA_ERR_MSG "Could not find the Plasma library. Looked for headers")
-    set(PLASMA_ERR_MSG "${PLASMA_ERR_MSG} in ${PLASMA_SEARCH_HEADER_PATHS}, and for libs")
-    set(PLASMA_ERR_MSG "${PLASMA_ERR_MSG} in ${PLASMA_SEARCH_LIB_PATH}")
-    if (Plasma_FIND_REQUIRED)
-      message(FATAL_ERROR "${PLASMA_ERR_MSG}")
-    else (Plasma_FIND_REQUIRED)
-      message(STATUS "${PLASMA_ERR_MSG}")
-    endif (Plasma_FIND_REQUIRED)
-  endif ()
-  set(PLASMA_FOUND FALSE)
-endif ()
-
-mark_as_advanced(
-  PLASMA_INCLUDE_DIR
-  PLASMA_STATIC_LIB
-  PLASMA_SHARED_LIB
-)

http://git-wip-us.apache.org/repos/asf/arrow/blob/a0555c04/python/cmake_modules/FindPythonLibsNew.cmake
----------------------------------------------------------------------
diff --git a/python/cmake_modules/FindPythonLibsNew.cmake b/python/cmake_modules/FindPythonLibsNew.cmake
deleted file mode 120000
index 7087123..0000000
--- a/python/cmake_modules/FindPythonLibsNew.cmake
+++ /dev/null
@@ -1 +0,0 @@
-../../cpp/cmake_modules/FindPythonLibsNew.cmake
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/arrow/blob/a0555c04/python/cmake_modules/SetupCxxFlags.cmake
----------------------------------------------------------------------
diff --git a/python/cmake_modules/SetupCxxFlags.cmake b/python/cmake_modules/SetupCxxFlags.cmake
deleted file mode 120000
index 3121a89..0000000
--- a/python/cmake_modules/SetupCxxFlags.cmake
+++ /dev/null
@@ -1 +0,0 @@
-../../cpp/cmake_modules/SetupCxxFlags.cmake
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/arrow/blob/a0555c04/python/cmake_modules/UseCython.cmake
----------------------------------------------------------------------
diff --git a/python/cmake_modules/UseCython.cmake b/python/cmake_modules/UseCython.cmake
deleted file mode 100644
index 7920940..0000000
--- a/python/cmake_modules/UseCython.cmake
+++ /dev/null
@@ -1,171 +0,0 @@
-# Define a function to create Cython modules.
-#
-# For more information on the Cython project, see http://cython.org/.
-# "Cython is a language that makes writing C extensions for the Python language
-# as easy as Python itself."
-#
-# This file defines a CMake function to build a Cython Python module.
-# To use it, first include this file.
-#
-#   include( UseCython )
-#
-# Then call cython_add_module to create a module.
-#
-#   cython_add_module( <target_name> <pyx_target_name> <output_files> <src1> <src2> ... <srcN> )
-#
-# Where <module_name> is the desired name of the target for the resulting Python module,
-# <pyx_target_name> is the desired name of the target that runs the Cython compiler
-# to generate the needed C or C++ files, <output_files> is a variable to hold the
-# files generated by Cython, and <src1> <src2> ... are source files
-# to be compiled into the module, e.g. *.pyx, *.c, *.cxx, etc.
-# only one .pyx file may be present for each target
-# (this is an inherent limitation of Cython).
-#
-# The sample paths set with the CMake include_directories() command will be used
-# for include directories to search for *.pxd when running the Cython complire.
-#
-# Cache variables that effect the behavior include:
-#
-#  CYTHON_ANNOTATE
-#  CYTHON_NO_DOCSTRINGS
-#  CYTHON_FLAGS
-#
-# Source file properties that effect the build process are
-#
-#  CYTHON_IS_CXX
-#  CYTHON_IS_PUBLIC
-#  CYTHON_IS_API
-#
-# If this is set of a *.pyx file with CMake set_source_files_properties()
-# command, the file will be compiled as a C++ file.
-#
-# See also FindCython.cmake
-
-#=============================================================================
-# Copyright 2011 Kitware, Inc.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#=============================================================================
-
-# Configuration options.
-set( CYTHON_ANNOTATE OFF
-  CACHE BOOL "Create an annotated .html file when compiling *.pyx." )
-set( CYTHON_NO_DOCSTRINGS OFF
-  CACHE BOOL "Strip docstrings from the compiled module." )
-set( CYTHON_FLAGS "" CACHE STRING
-  "Extra flags to the cython compiler." )
-mark_as_advanced( CYTHON_ANNOTATE CYTHON_NO_DOCSTRINGS CYTHON_FLAGS)
-
-find_package( Cython REQUIRED )
-find_package( PythonLibsNew REQUIRED )
-
-set( CYTHON_CXX_EXTENSION "cxx" )
-set( CYTHON_C_EXTENSION "c" )
-
-# Create a *.c or *.cxx file from a *.pyx file.
-# Input the generated file basename.  The generate files will put into the variable
-# placed in the "generated_files" argument. Finally all the *.py and *.pyx files.
-function( compile_pyx _name pyx_target_name generated_files pyx_file)
-  # Default to assuming all files are C.
-  set( cxx_arg "" )
-  set( extension ${CYTHON_C_EXTENSION} )
-  set( pyx_lang "C" )
-  set( comment "Compiling Cython C source for ${_name}..." )
-
-  get_filename_component( pyx_file_basename "${pyx_file}" NAME_WE )
-
-  # Determine if it is a C or C++ file.
-  get_source_file_property( property_is_cxx ${pyx_file} CYTHON_IS_CXX )
-  if( ${property_is_cxx} )
-    set( cxx_arg "--cplus" )
-    set( extension ${CYTHON_CXX_EXTENSION} )
-    set( pyx_lang "CXX" )
-    set( comment "Compiling Cython CXX source for ${_name}..." )
-  endif()
-  get_source_file_property( pyx_location ${pyx_file} LOCATION )
-
-  # Set additional flags.
-  if( CYTHON_ANNOTATE )
-    set( annotate_arg "--annotate" )
-  endif()
-
-  if( CYTHON_NO_DOCSTRINGS )
-    set( no_docstrings_arg "--no-docstrings" )
-  endif()
-
-  if(NOT WIN32)
-      if( "${CMAKE_BUILD_TYPE}" STREQUAL "Debug" OR
-            "${CMAKE_BUILD_TYPE}" STREQUAL "RelWithDebInfo" )
-          set( cython_debug_arg "--gdb" )
-      endif()
-  endif()
-
-  # Determining generated file names.
-  get_source_file_property( property_is_public ${pyx_file} CYTHON_PUBLIC )
-  get_source_file_property( property_is_api ${pyx_file} CYTHON_API )
-  if( ${property_is_api} )
-      set( _generated_files "${_name}.${extension}" "${_name}.h" "${name}_api.h")
-  elseif( ${property_is_public} )
-      set( _generated_files "${_name}.${extension}" "${_name}.h")
-  else()
-      set( _generated_files "${_name}.${extension}")
-  endif()
-  set_source_files_properties( ${_generated_files} PROPERTIES GENERATED TRUE )
-
-  if (NOT WIN32)
-    # Cython creates a lot of compiler warning detritus on clang
-    set_source_files_properties(${_generated_files} PROPERTIES
-      COMPILE_FLAGS -Wno-unused-function)
-  endif()
-
-  set( ${generated_files} ${_generated_files} PARENT_SCOPE )
-
-  # Add the command to run the compiler.
-  add_custom_target(${pyx_target_name}
-    COMMAND ${CYTHON_EXECUTABLE} ${cxx_arg} ${include_directory_arg}
-    ${annotate_arg} ${no_docstrings_arg} ${cython_debug_arg}
-    ${CYTHON_FLAGS}
-    --output-file "${_name}.${extension}" ${pyx_location}
-    DEPENDS ${pyx_location}
-    # do not specify byproducts for now since they don't work with the older
-    # version of cmake available in the apt repositories.
-    #BYPRODUCTS ${_generated_files}
-    COMMENT ${comment}
-    )
-
-  # Remove their visibility to the user.
-  set( corresponding_pxd_file "" CACHE INTERNAL "" )
-  set( header_location "" CACHE INTERNAL "" )
-  set( pxd_location "" CACHE INTERNAL "" )
-endfunction()
-
-# cython_add_module( <name> src1 src2 ... srcN )
-# Build the Cython Python module.
-function( cython_add_module _name pyx_target_name generated_files)
-  set( pyx_module_source "" )
-  set( other_module_sources "" )
-  foreach( _file ${ARGN} )
-    if( ${_file} MATCHES ".*\\.py[x]?$" )
-      list( APPEND pyx_module_source ${_file} )
-    else()
-      list( APPEND other_module_sources ${_file} )
-    endif()
-  endforeach()
-  compile_pyx( ${_name} ${pyx_target_name} _generated_files ${pyx_module_source} )
-  set( ${generated_files} ${_generated_files} PARENT_SCOPE )
-  include_directories( ${PYTHON_INCLUDE_DIRS} )
-  python_add_module( ${_name} ${_generated_files} ${other_module_sources} )
-  add_dependencies( ${_name} ${pyx_target_name})
-endfunction()
-
-include( CMakeParseArguments )