martomi / chiadog

A watch dog providing a peace in mind that your Chia farm is running smoothly 24/7.
MIT License
457 stars 120 forks source link

./install.sh fails on arm64 #151

Closed sbates130272 closed 3 years ago

sbates130272 commented 3 years ago

The /install.sh script fails which building the wheel for pynacl on arm64 machines.

  aarch64-linux-gnu-gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -g -fwrapv -O2 -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -g -fwrapv -O2 -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -I/home/batesste/chiadog/venv/include -I/usr/include/python3.8 -Ibuild/temp.linux-aarch64-3.8/include -c build/temp.linux-aarch64-3.8/_sodium.c -o build/temp.linux-aarch64-3.8/build/temp.linux-aarch64-3.8/_sodium.o
  build/temp.linux-aarch64-3.8/_sodium.c:50:14: fatal error: pyconfig.h: No such file or directory
     50 | #    include <pyconfig.h>
        |              ^~~~~~~~~~~~
  compilation terminated.
  error: command 'aarch64-linux-gnu-gcc' failed with exit status 1
  ----------------------------------------
  ERROR: Failed building wheel for pynacl
Failed to build pynacl
ERROR: Could not build wheels for pynacl which use PEP 517 and cannot be installed directly

A clear and concise description of what the bug is and how it can be reproduced.

git clone on an arm64 machine (I was working on an AWS Graviton-2 based VM). . ./install

Environment:

sbates130272 commented 3 years ago

This was due to a missing package dependency. Perhaps this needs to be added to the install script?

sudo apt install python3-dev
djdookie commented 3 years ago

I recently had a similar problem with additional package dependency problems, and I solved it. See here: https://github.com/martomi/chiadog/issues/148

pieterhelsen commented 3 years ago

Thanks, I have a branch ready for this that adds the following line to the install.sh file

# Install dev tools
sudo apt-get update
sudo apt-get install libpython3-dev build-essential -y