-
Notifications
You must be signed in to change notification settings - Fork 3.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ARROW-197: Working first draft of a conda recipe for pyarrow
Includes ARROW-196. I will close that PR and merge these together as I had to make some additional changes. Requires PARQUET-617. Closes #76 Author: Wes McKinney <[email protected]> Closes #77 from wesm/ARROW-197 and squashes the following commits: 4bf3d2c [Wes McKinney] Finagle toolchain environment variables to get pyarrow conda package working c2d3684 [Wes McKinney] Add conda recipe and ensure that libarrow_parquet is installed as well
- Loading branch information
Showing
6 changed files
with
144 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
#!/bin/bash | ||
|
||
set -e | ||
set -x | ||
|
||
cd $RECIPE_DIR | ||
|
||
# Build dependencies | ||
export FLATBUFFERS_HOME=$PREFIX | ||
export PARQUET_HOME=$PREFIX | ||
|
||
cd .. | ||
|
||
rm -rf conda-build | ||
mkdir conda-build | ||
|
||
cp -r thirdparty conda-build/ | ||
|
||
cd conda-build | ||
pwd | ||
|
||
# Build googletest for running unit tests | ||
./thirdparty/download_thirdparty.sh | ||
./thirdparty/build_thirdparty.sh gtest | ||
|
||
source thirdparty/versions.sh | ||
export GTEST_HOME=`pwd`/thirdparty/$GTEST_BASEDIR | ||
|
||
if [ `uname` == Linux ]; then | ||
SHARED_LINKER_FLAGS='-static-libstdc++' | ||
elif [ `uname` == Darwin ]; then | ||
SHARED_LINKER_FLAGS='' | ||
fi | ||
|
||
cmake \ | ||
-DCMAKE_BUILD_TYPE=debug \ | ||
-DCMAKE_INSTALL_PREFIX=$PREFIX \ | ||
-DCMAKE_SHARED_LINKER_FLAGS=$SHARED_LINKER_FLAGS \ | ||
-DARROW_IPC=on \ | ||
-DARROW_PARQUET=on \ | ||
.. | ||
|
||
make | ||
ctest -L unittest | ||
make install |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
package: | ||
name: arrow-cpp | ||
version: "0.1" | ||
|
||
build: | ||
number: {{environ.get('TRAVIS_BUILD_NUMBER', 0)}} # [unix] | ||
skip: true # [win] | ||
script_env: | ||
- CC [linux] | ||
- CXX [linux] | ||
- LD_LIBRARY_PATH [linux] | ||
|
||
requirements: | ||
build: | ||
- cmake | ||
- flatbuffers | ||
- parquet-cpp | ||
- thrift-cpp | ||
|
||
run: | ||
- parquet-cpp | ||
|
||
test: | ||
commands: | ||
- test -f $PREFIX/lib/libarrow.so | ||
- test -f $PREFIX/lib/libarrow_parquet.so | ||
- test -f $PREFIX/include/arrow/api.h | ||
|
||
about: | ||
home: http://github.com/apache/arrow | ||
license: Apache 2.0 | ||
summary: 'C++ libraries for the reference Apache Arrow implementation' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
#!/bin/bash | ||
set -ex | ||
|
||
# Build dependency | ||
export ARROW_HOME=$PREFIX | ||
|
||
cd $RECIPE_DIR | ||
|
||
echo Setting the compiler... | ||
if [ `uname` == Linux ]; then | ||
EXTRA_CMAKE_ARGS=-DCMAKE_SHARED_LINKER_FLAGS=-static-libstdc++ | ||
elif [ `uname` == Darwin ]; then | ||
EXTRA_CMAKE_ARGS= | ||
fi | ||
|
||
cd .. | ||
$PYTHON setup.py build_ext --extra-cmake-args=$EXTRA_CMAKE_ARGS || exit 1 | ||
$PYTHON setup.py install || exit 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
package: | ||
name: pyarrow | ||
version: "0.1" | ||
|
||
build: | ||
number: {{environ.get('TRAVIS_BUILD_NUMBER', 0)}} # [unix] | ||
rpaths: | ||
- lib # [unix] | ||
- lib/python{{environ.get('PY_VER')}}/site-packages/pyarrow # [unix] | ||
script_env: | ||
- CC [linux] | ||
- CXX [linux] | ||
- LD_LIBRARY_PATH [linux] | ||
skip: true # [win] | ||
|
||
requirements: | ||
build: | ||
- cmake | ||
- python | ||
- setuptools | ||
- cython | ||
- numpy | ||
- pandas | ||
- arrow-cpp | ||
- pytest | ||
|
||
run: | ||
- arrow-cpp | ||
- python | ||
- numpy | ||
- pandas | ||
- six | ||
|
||
test: | ||
imports: | ||
- pyarrow | ||
|
||
about: | ||
home: http://github.com/apache/arrow | ||
license: Apache 2.0 | ||
summary: 'Python bindings for Arrow C++ and interoperability tool for pandas and NumPy' |