developer | 9037957 | 2024-05-29 17:23:20 +0800 | [diff] [blame^] | 1 | LICENSE="CLOSED" |
| 2 | |
| 3 | DEPENDS += " rdk-wifi-hal hal-wifi-generic" |
| 4 | SRC_URI = " \ |
| 5 | ${CMF_GITHUB_ROOT}/rdkb-wifi-hal;protocol=https;branch=feature/TDK-6732;name=wifihal \ |
| 6 | ${CMF_GITHUB_ROOT}/rdkb-wifi-haltest;protocol=https;branch=feature/TDK-7346;name=ut;destsuffix=git/ut \ |
| 7 | ${CMF_GITHUB_ROOT}/ut-core;protocol=https;branch=develop;name=ut-core;destsuffix=git/ut/ut-core \ |
| 8 | https://sourceforge.net/projects/cunit/files/CUnit/2.1-3/CUnit-2.1-3.tar.bz2;name=cunit;destsuffix=git/ut/ut-core/framework \ |
| 9 | git://github.com/jwerle/asprintf.c;branch=master;protocol=https;name=asprintf;destsuffix=git/ut/ut-core/framework/asprintf/asprintf.c-master \ |
| 10 | git://github.com/pantoniou/libfyaml;branch=master;protocol=https;name=libfyaml;destsuffix=git/ut/ut-core/framework/libfyaml-master \ |
| 11 | file://fix_build_and_startup_issue.patch;apply=no \ |
| 12 | file://radio_config \ |
| 13 | file://vap_config \ |
| 14 | " |
| 15 | SRCREV_wifihal = "${AUTOREV}" |
| 16 | SRCREV_ut = "${AUTOREV}" |
| 17 | SRCREV_ut-core = "${AUTOREV}" |
| 18 | SRCREV_asprintf = "${AUTOREV}" |
| 19 | SRCREV_libfyaml = "${AUTOREV}" |
| 20 | SRC_URI[cunit.sha256sum] = "f5b29137f845bb08b77ec60584fdb728b4e58f1023e6f249a464efa49a40f214" |
| 21 | |
| 22 | SRCREV_FORMAT = "wifihal_ut_ut-core" |
| 23 | |
| 24 | S = "${WORKDIR}/git/ut" |
| 25 | |
| 26 | do_configure(){ |
| 27 | cp ${WORKDIR}/CUnit-2.1-3/CUnit/Headers/CUnit.h.in ${WORKDIR}/CUnit-2.1-3/CUnit/Headers/CUnit.h |
| 28 | cp -rf ${WORKDIR}/CUnit-2.1-3 ${S}/ut-core/framework |
| 29 | rm ${S}/ut-core/framework/asprintf/asprintf.c-master/test.c |
| 30 | cp -f ${S}/ut-core/src/libyaml/patches/CorrectWarningsAndBuildIssuesInLibYaml.patch ${S}/ut-core/framework/ |
| 31 | cp -f ${S}/ut-core/src/cunit/cunit_lgpl/patches/CorrectBuildWarningsInCunit.patch ${S}/ut-core/framework/ |
| 32 | cd ${S}/ut-core/framework/ |
| 33 | patch -p0 < CorrectWarningsAndBuildIssuesInLibYaml.patch |
| 34 | patch -u CUnit-2.1-3/CUnit/Sources/Framework/TestRun.c -i CorrectBuildWarningsInCunit.patch |
| 35 | } |
| 36 | |
| 37 | do_filogic_patches() { |
| 38 | cd ${S} |
| 39 | if [ ! -e patch_applied ]; then |
| 40 | patch -p1 < ${WORKDIR}/fix_build_and_startup_issue.patch |
| 41 | touch patch_applied |
| 42 | fi |
| 43 | } |
| 44 | addtask filogic_patches after do_patch before do_compile |
| 45 | |
| 46 | do_compile (){ |
| 47 | cd ${S} |
| 48 | oe_runmake TARGET=arm |
| 49 | } |
| 50 | |
| 51 | do_install(){ |
| 52 | install -d ${D}/usr/sbin ${D}${sysconfdir} |
| 53 | install -m 0755 ${S}/bin/hal_test ${D}/usr/sbin |
| 54 | install -m 0644 ${WORKDIR}/radio_config ${D}${sysconfdir}/ |
| 55 | install -m 0644 ${WORKDIR}/vap_config ${D}${sysconfdir}/ |
| 56 | } |