Open Beebeejohn opened 3 years ago
post-install
hook to devices/rpi-2-b/raspbian-buster-armhf/post-install
. The hook might look like (I named it run-pip3.sh
)
#/bin/sh
pip3 install adafruit-circuitpython-ads1x15 adafruit-circuitpython-bme280
sudo env INCLUDES=python3-pip ./pieman.sh
Actually where this run-pip3.sh is there? Can you tell me the path. I searched it . But I could not get it. And also this command where should I mention pip3 install adafruit-circuitpython-ads1x15 adafruit-circuitpython-bme280. Should I mention this line in pieman.sh script
devices/rpi-2-b/raspbian-buster-armhf/
post-install
and go to the directoryrun-pip3.sh
with the following contents
#/bin/sh
pip3 install adafruit-circuitpython-ads1x15 adafruit-circuitpython-bme280
sudo env INCLUDES=python3-pip ./pieman.sh
And also this command where should I mention pip3 install adafruit-circuitpython-ads1x15 adafruit-circuitpython-bme280. Should I mention this line in pieman.sh script
No, you don't have to touch pieman.sh
.
Ok. Thank you so much for the replies. If I want to install multiple python packages like adafruit-blinka, adafruit-io, In the pip3.sh file, should I mention the contents as follows: pip3 install adafruit-circuitpython-ads1x15 adafruit-circuitpython-bme280 pip3 install Adafruit-Blinka pip3 install adafruit-io Can you tell me
yeah, you can either use multiple lines like that or put it in one line as pip3 install adafruit-circuitpython-ads1x15 adafruit-circuitpython-bme280 Adafruit-Blinka adafruit-io
ya ok thank you
I tried with the above command as mentioned. But adafruit-blinka and ads1115 packages are not getting installed in python. It is showing no module found error. Can you tell me the exact command for installing supervisor, ssh and also python packages like adafruit-blinka, etc., in a single command itself . Because I need supervisor, ssh also along with python packages. I tried with this command sudo env INCLUDES=ssh,supervisor,python3-pip ./pieman.sh. But it is showing no module found error for adafruit and supervisor is installed properly without any issues Can you tell me the command please? Whether do I need to use env also or not needed?
Can anyone pls answer my above question?
Fortunately or unfortunately I'm not able to read people's mind, so 1) explain what you did step by step, 2) attach some tracebacks or anything else what could help me or anyone else to help you.
Can you tell me the exact command for installing supervisor, ssh and also python packages like adafruit-blinka, etc., in a single command itself
There is no a single command because you have to install Python packages via pip3 and hooks as I mentioned above.
Whether do I need to use env also or not needed?
It depends your task.
The steps I followed are below:
Yeah, the problem is
1) You have to create post-install
under devices/rpi-b/raspbian-buster-armhf
(actually in devices/rpi-zero-w/raspbian-buster-armhf
but it symlinks to devices/rpi-b/raspbian-buster-armhf
).
2) You're building the image for RPi 3 but not for RPi Zero W. Try sudo env DEVICE=rpi-zero-w INCLUDES=ssh,supervisor,python3-pip ./pieman.sh
Thank you. Will try like as u mentioned and check
I tried with the above commands as you mentioned. But still python packages are not getting installed
Attach the full build log, please. I need to see it to help you.
The building steps followed are
Python packages like adafruit io, adafruit blinka., etc., are not installed. Showing like no module found error while I am importing after building the image
No, as I mentioned above you have to create the post-install
directory under devices/rpi-b/raspbian-buster-armhf
(not devices/rpi-b
or anything else). Please, re-read my message carefully.
I created that post-install directory under devices/rpi-b/raspbian-buster-armhf) only. I have not mentioned that full path here. I reedited that comment. Can you check that now? I tried exactly as you mentioned. But the packages are not getting installed
Can you answer my question please
I asked you in one of my messages above to attach the full build log. To do that, redirect stderr to a file. For example,
sudo env INCLUDES=python3-pip,ssh,supervisor,DEVICE=rpi-zero-w ENABLE_WIRELESS=true ./pieman.sh 2> buildlog
Then, attach the buildlog
file. I will be able to study it and, probably, help you with your problem.
actually I did not get what is build log file. Do u mean the image which I built for built log file?
I gave an example of how to get the build log file. Please, re-read my message carefully. In that example the log file is called buildlog
.
Please find my build log file buildlog.zip
Can you answer my question?
According to the logs here's the problem: WARNING: The directory '/home/yamuna-b/.cache/pip' or its parent directory is not owned or is not writable by the current user. The cache has been disabled. Check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
It seems there is a bug in Pieman.
I will check it these weekends.
How to install python packages like Adafruit.ads1x15.ads1115,busio,time,json,logging while building raspberry pi Os using piemann