I have some simple python3 scripts that I packaged in such a way that upon pip install .
within the repository one can use the scripts within the bin
folder as a CLI e.g.
$ gpsinflux # execute the script as cli
gpsinflux repository.
I used devtool add gpsinflux url_of_repo
I already managed to add influxdb-python
as a recipe based on my findings in my previous SE Query regarding python application on yocto
Edit the recipe to add RDEPENDS_PN
However do I need to mention within the recipe that I want the script in the bin
folder from my repository to be installed in say, /usr/bin
folder or will the recipe do that automatically?
One does not require to perform do_install()
at all. If the setup.py
does have packages=[bin/script1]
then upon sucessfully baking the recipe and adding the recipe to you Root Filesystem will automatically provide your script1
in /usr/bin/
folder.
I looked into python-awscli
example in meta-iot-cloud and there it is no mention of do_install()
in the same repository if one needs to port python2.7 to python3 one can use sed
to change the shebang of the bin/script1
using do_install_append()