You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mxnet.apache.org by GitBox <gi...@apache.org> on 2018/01/31 14:53:25 UTC
[GitHub] lebeg opened a new issue #9646: Android build broken
lebeg opened a new issue #9646: Android build broken
URL: https://github.com/apache/incubator-mxnet/issues/9646
## Description
The shared memory implementation uses POSIX function calls that are not available on Android.
## Environment info (Required)
```
----------Python Info----------
('Version :', '2.7.9')
('Compiler :', 'GCC 4.9.2')
('Build :', ('default', 'Jun 29 2016 13:08:31'))
('Arch :', ('64bit', 'ELF'))
------------Pip Info-----------
('Version :', '9.0.1')
('Directory :', '/usr/local/lib/python2.7/dist-packages/pip')
----------MXNet Info-----------
No MXNet installed.
----------System Info----------
('Platform :', 'Linux-4.9.60-linuxkit-aufs-x86_64-with-debian-8.10')
('system :', 'Linux')
('node :', '440208ec43e4')
('release :', '4.9.60-linuxkit-aufs')
('version :', '#1 SMP Mon Nov 6 16:00:12 UTC 2017')
----------Hardware Info----------
('machine :', 'x86_64')
('processor :', '')
Architecture: x86_64
CPU op-mode(s): 32-bit, 64-bit
Byte Order: Little Endian
CPU(s): 2
On-line CPU(s) list: 0,1
Thread(s) per core: 1
Core(s) per socket: 1
Socket(s): 2
Vendor ID: GenuineIntel
CPU family: 6
Model: 61
Model name: Intel(R) Core(TM) i7-5557U CPU @ 3.10GHz
Stepping: 4
CPU MHz: 3097.758
BogoMIPS: 6302.63
L1d cache: 32K
L1i cache: 32K
L2 cache: 256K
L3 cache: 4096K
----------Network Test----------
Setting timeout: 10
Timing for MXNet: https://github.com/apache/incubator-mxnet, DNS: 0.0475 sec, LOAD: 1.0690 sec.
Timing for PYPI: https://pypi.python.org/pypi/pip, DNS: 0.0490 sec, LOAD: 0.2531 sec.
Timing for FashionMNIST: https://apache-mxnet.s3-accelerate.dualstack.amazonaws.com/gluon/dataset/fashion-mnist/train-labels-idx1-ubyte.gz, DNS: 0.0487 sec, LOAD: 0.8761 sec.
Timing for Conda: https://repo.continuum.io/pkgs/free/, DNS: 0.0409 sec, LOAD: 0.1492 sec.
Timing for Gluon Tutorial(en): http://gluon.mxnet.io, DNS: 0.0607 sec, LOAD: 0.1259 sec.
Timing for Gluon Tutorial(cn): https://zh.gluon.ai, DNS: 0.0431 sec, LOAD: 0.8136 sec.
```
## Build info (Required if built from source)
aarch64-linux-android-clang++
MXNet commit hash:
5e0a0b0bd54cdeb92321f958bf964ddc8aca94e9
Build config:
Building with docker containers:
```
cd docker_multiarch
python tool.py
```
With using the ```Dockerfile.build.android.arm64``` docker file:
```
# Build OpenBLAS
# https://github.com/xianyi/OpenBLAS/wiki/How-to-build-OpenBLAS-for-Android
RUN git clone https://github.com/xianyi/OpenBLAS.git && \
cd OpenBLAS && \
make -j$(nproc) TARGET=ARMV8 ARM_SOFTFP_ABI=1 HOSTCC=gcc NOFORTRAN=1 libs
ENV OPENBLAS_ROOT /work/OpenBLAS
ENV LIBRARY_PATH /work/OpenBLAS/lib/:/work/OpenBLAS/:$LIBRARY_PATH
ENV CPLUS_INCLUDE_PATH /work/OpenBLAS/include/:/work/OpenBLAS/:$CPLUS_INCLUDE_PATH
WORKDIR /work
ENV CC=${CROSS_ROOT}/bin/${CROSS_TRIPLE}-clang
ENV CXX=${CROSS_ROOT}/bin/${CROSS_TRIPLE}-clang++
ENV BUILD_OPTS "USE_BLAS=openblas USE_SSE=0 DMLC_LOG_STACK_TRACE=0 USE_OPENCV=0 USE_LAPACK=0"
# Build MXNet
ADD mxnet mxnet
ADD arm.crosscompile.android.mk /work/mxnet/make/config.mk
RUN cd mxnet && \
make -j$(nproc) $BUILD_OPTS
```
## Error Message:
```
/usr/aarch64-linux-android/bin/aarch64-linux-android-clang++ -std=c++11 -c -DMSHADOW_FORCE_STREAM -Wall -Wsign-compare -O3 -DNDEBUG=1 -I/work/mxnet/mshadow/ -I/work/mxnet/dmlc-core/include -fPIC -I/work/mxnet/nnvm/include -I/work/mxnet/dlpack/include -Iinclude -funroll-loops -Wno-unused-variable -Wno-unused-parameter -Wno-unknown-pragmas -Wno-unused-local-typedefs -DMSHADOW_USE_SSE=0 -DMSHADOW_USE_CUDA=0 -DMSHADOW_USE_CBLAS=1 -DMSHADOW_USE_MKL=0 -DMSHADOW_RABIT_PS=0 -DMSHADOW_DIST_PS=0 -DMSHADOW_USE_PASCAL=0 -DMXNET_USE_OPENCV=0 -fopenmp -DMXNET_USE_NCCL=0 -DMXNET_USE_LIBJPEG_TURBO=0 -MMD -c src/storage/storage.cc -o build/src/storage/storage.o
In file included from src/storage/storage.cc:30:
src/storage/./cpu_shared_storage_manager.h:167:13: error: use of undeclared identifier 'shm_open'
fid = shm_open(filename.c_str(), O_EXCL|O_CREAT|O_RDWR, 0666);
^
src/storage/./cpu_shared_storage_manager.h:172:11: error: use of undeclared identifier 'shm_open'
fid = shm_open(filename.c_str(), O_RDWR, 0666);
^
src/storage/./cpu_shared_storage_manager.h:208:14: error: use of undeclared identifier 'shm_unlink'
CHECK_EQ(shm_unlink(filename.c_str()), 0)
^
3 errors generated.
Makefile:393: recipe for target 'build/src/storage/storage.o' failed
```
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services