Many thanks for your answer, but this didn’t work to me.
The whl file is already downloaded so I wrote a bb file similar as yours:
DESCRIPTION="WHL files"
SRC_URI = "file://torch-1.6.0-cp37-cp37m-linux_aarch64.whl"
inherit nativesdk python3-dir
LICENSE = "CLOSED"
PV = "1.6.0"
#PN = "nativesdk-python3"
do_unpack[depends] += "unzip-native:do_populate_sysroot"
PROVIDES += "nativesdk-python-whl"
DEPENDS += "nativesdk-python3"
FILES_${PN} += "\
${libdir}/${PYTHON_DIR}/site-packages/* \
"
do_install(){
install -d ${D}${libdir}/${PYTHON_DIR}/site-packages/torch-1.6.0.dist-info
install -d ${D}${libdir}/${PYTHON_DIR}/site-packages/torch
install -m 644 ${S}/torch/* ${D}${libdir}/${PYTHON_DIR}/site-packages/torch/
install -m 644 ${S}/torch-1.6.0.dist-info/* ${D}${libdir}/${PYTHON_DIR}/site-packages/torch-1.6.0.dist-info/
}
But I got some problems.
First, when I add “inherit nativesdk” I get the following error:
ERROR: Nothing PROVIDES 'virtual/x86_64-pokysdk-linux-gcc'. Close matches:
virtual/x86_64-pokysdk-linux-gcc-crosssdk
virtual/x86_64-pokysdk-linux-go-crosssdk
virtual/x86_64-pokysdk-linux-g++-crosssdk
ERROR: Required build target 'python-whl' has no buildable providers.
Missing or unbuildable dependency chain was: ['python-whl', 'virtual/x86_64-pokysdk-linux-gcc']
Then, if I delete the inherit line the whl does not unpack correctly, so I do not get the such file directory.
Please, how could I fix it?
Regards,
Sonia.