With diverting packages ${PN} can sometimes not be used. In such cases
we don't to use the filename of the currently included file. This can
work with immediate assignments and a helper function like this one.
DEPENDS = "apr-util subversion"
PR = "r0"
-SRC_URI = "http://download2.berlios.de/qsvn/qsvn-${PV}-src.tar.gz \
+def vars_from_file(filename):
+ import os
+ return os.path.splitext(os.path.basename(filename))[0]
+
+FN := "${@vars_from_file(bb.data.getVar('FILE',d))}"
+
+SRC_URI = "http://download2.berlios.de/${FN}/${FN}-${PV}-src.tar.gz \
file://build.patch;patch=1"
-S = "${WORKDIR}/qsvn-${PV}"
+S = "${WORKDIR}/${FN}-${PV}"
EXTRA_QMAKEVARS_POST += "INCLUDEPATH+=${STAGING_INCDIR}/subversion-1"