indygreg / indygreg/python-zstandard
ARM64 ERROR: Cannot build on OpenWRT
Open
Nobody has claimed this yet.
- Dominant language
- C
- Stars
- 642
- Forks
- 116
- Avg merge
- 1d 14h
- Merged PRs (30d)
- 5
Description
error on OpenWrt 21.02-RC3 on a ARM64 board...
# python3 --version
Python 3.9.6
ERROR: Failed building wheel for zstandard
...
Failed to build zstandard
ERROR: Could not build wheels for zstandard which use PEP 517 and cannot be installed directly
...
trying to install with :
pip download --no-deps zstandard
tar -zxf zstandard-0.15.2.tar.gz
cd zstandard-0.15.2
python3 setup.py build
python3 setup.py install
get error on build :
root@ultra:~/zstandard-0.15.2# python3 setup.py build
generating build/zstandard/_cffi.c
(already up-to-date)
not modified: 'build/zstandard/_cffi.c'
running build
running build_py
running build_ext
building 'zstandard.backend_c' extension
gcc -Wno-unused-result -Wsign-compare -DNDEBUG -Os -pipe -mcpu=cortex-a53 -fno-caller-saves -fno-plt -fhonour-copts -Wno-error=unused-but-set-variable -Wno-error=unused-result -ffile-prefix-map=/builder/shared-workdir/build/sdk/build_dir/target-aarch64_cortex-a53_musl/Python-3.9.6=Python-3.9.6 -Wformat -Werror=format-security -fstack-protector -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -Os -pipe -mcpu=cortex-a53 -fno-caller-saves -fno-plt -fhonour-copts -Wno-error=unused-but-set-variable -Wno-error=unused-result -ffile-prefix-map=/builder/shared-workdir/build/sdk/build_dir/target-aarch64_cortex-a53_musl/Python-3.9.6=Python-3.9.6 -Wformat -Werror=format-security -fstack-protector -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -DNDEBUG -fno-inline -Os -pipe -mcpu=cortex-a53 -fno-caller-saves -fno-plt -fhonour-copts -Wno-error=unused-but-set-variable -Wno-error=unused-result -ffile-prefix-map=/builder/shared-workdir/build/sdk/build_dir/target-aarch64_cortex-a53_musl/Python-3.9.6=Python-3.9.6 -Wformat -Werror=format-security -fstack-protector -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -DNDEBUG -fno-inline -I/builder/shared-workdir/build/sdk/staging_dir/toolchain-aarch64_cortex-a53_gcc-8.4.0_musl/usr/include -I/builder/shared-workdir/build/sdk/staging_dir/toolchain-aarch64_cortex-a53_gcc-8.4.0_musl/include/fortify -I/builder/shared-workdir/build/sdk/staging_dir/toolchain-aarch64_cortex-a53_gcc-8.4.0_musl/include -fPIC -Ic-ext -Izstd -I/usr/include/python3.9 -c c-ext/backend_c.c -o build/temp.linux-aarch64-3.9/c-ext/backend_c.o -DZSTD_SINGLE_FILE -DZSTDLIB_VISIBILITY= -DZDICTLIB_VISIBILITY= -DZSTDERRORLIB_VISIBILITY= -fvisibility=hidden
gcc: error: unrecognized command line option '-ffile-prefix-map=/builder/shared-workdir/build/sdk/build_dir/target-aarch64_cortex-a53_musl/Python-3.9.6=Python-3.9.6'
gcc: error: unrecognized command line option '-ffile-prefix-map=/builder/shared-workdir/build/sdk/build_dir/target-aarch64_cortex-a53_musl/Python-3.9.6=Python-3.9.6'
gcc: error: unrecognized command line option '-ffile-prefix-map=/builder/shared-workdir/build/sdk/build_dir/target-aarch64_cortex-a53_musl/Python-3.9.6=Python-3.9.6'
error: command '/usr/bin/gcc' failed with exit code 1
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with setup.py and c-ext/backend_c.c, then reproduce the setup.py build on the reported OpenWrt ARM64 environment while examining the compiler invocation. Done means the zstandard extension builds and installs successfully without the reported compiler failure.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c, python
- Domain
- build-system, operating-systems
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100