xref: /OK3568_Linux_fs/yocto/poky/meta/classes/setuptools3.bbclass (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1inherit setuptools3-base python_pep517
2
3# bdist_wheel builds in ./dist
4#B = "${WORKDIR}/build"
5
6SETUPTOOLS_BUILD_ARGS ?= ""
7
8SETUPTOOLS_SETUP_PATH ?= "${S}"
9
10setuptools3_do_configure() {
11    :
12}
13
14setuptools3_do_compile() {
15        cd ${SETUPTOOLS_SETUP_PATH}
16        NO_FETCH_BUILD=1 \
17        STAGING_INCDIR=${STAGING_INCDIR} \
18        STAGING_LIBDIR=${STAGING_LIBDIR} \
19        ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py \
20        bdist_wheel --verbose --dist-dir ${PEP517_WHEEL_PATH} ${SETUPTOOLS_BUILD_ARGS} || \
21        bbfatal_log "'${PYTHON_PN} setup.py bdist_wheel ${SETUPTOOLS_BUILD_ARGS}' execution failed."
22}
23setuptools3_do_compile[vardepsexclude] = "MACHINE"
24do_compile[cleandirs] += "${PEP517_WHEEL_PATH}"
25
26setuptools3_do_install() {
27        python_pep517_do_install
28}
29
30EXPORT_FUNCTIONS do_configure do_compile do_install
31
32export LDSHARED="${CCLD} -shared"
33DEPENDS += "python3-setuptools-native python3-wheel-native"
34