I'm trying to write a recipe to include files from a private repository to my rootfs. Until now I cloned the repository to a local folder and used the following recipe to copy them to the rootfs
SUMMARY = "my test data"
DESCRIPTION = "test data"
LICENSE = "CLOSED"
MY_FILES = "${THISDIR}/data/*"
MY_DESTINATION = "/home/root/testdata"
do_install(){
install -d ${D}${MY_DESTINATION}
cp -r ${MY_FILES} ${D}${MY_DESTINATION}
}
FILES_${PN} += "${MY_DESTINATION}"
Can anyone tell me what I need to change in my recipe that it will clone the repo by itself and copy the files to the rootfs? The files are mainly python scripts and some data, so no need for compilation or something.
Thanks in advance, chill
current recipe:
SUMMARY = "my test data"
DESCRIPTION = "test data"
LICENSE = "CLOSED"
#repo address
SRC_URI = "git://......;protocol=https;branch=develop;"
#SHA of desired commit
SRCREV = "....."
S = "${WORKDIR}/git"
MY_DESTINATION = "/home/root/testdata"
inherit allarch
do_install(){
install -d ${D}${MY_DESTINATION}
cp -r ${S} ${D}${MY_DESTINATION}
}
FILES_${PN} += "${MY_DESTINATION}"