developer | 2bf53a9 | 2022-06-06 12:08:58 +0800 | [diff] [blame] | 1 | FILESEXTRAPATHS_prepend := "${THISDIR}/files:" |
| 2 | |
| 3 | SRC_URI += "\ |
| 4 | file://enabling_dhcp_lease_resync.patch;apply=no \ |
| 5 | file://meshagent-enable-ovs-default.patch;apply=no \ |
| 6 | " |
| 7 | |
developer | 2bf53a9 | 2022-06-06 12:08:58 +0800 | [diff] [blame] | 8 | # we need to patch to code for mesh-agent |
| 9 | do_turris_meshagent_patches() { |
| 10 | cd ${S} |
| 11 | if [ ! -e patch_applied ]; then |
| 12 | bbnote "Patching enabling_dhcp_lease_resync.patch" |
| 13 | patch -p1 < ${WORKDIR}/enabling_dhcp_lease_resync.patch ${S}/source/MeshAgentSsp/cosa_mesh_apis.c |
| 14 | |
| 15 | bbnote "Patching meshagent-enable-ovs-default.patch" |
| 16 | patch -p1 < ${WORKDIR}/meshagent-enable-ovs-default.patch ${S}/source/MeshAgentSsp/cosa_mesh_apis.c |
| 17 | |
| 18 | touch patch_applied |
| 19 | fi |
| 20 | } |
| 21 | addtask turris_meshagent_patches after do_unpack before do_configure |
| 22 | |
| 23 | do_install_append () { |
| 24 | install -D -m 0644 ${S}/systemd_units/meshAgent.service ${D}${systemd_unitdir}/system/meshAgent.service |
| 25 | } |
| 26 | |
| 27 | FILES_${PN}_append = "${systemd_unitdir}/system/meshAgent.service" |
| 28 | |
| 29 | CFLAGS_append = " -D_PLATFORM_TURRIS_" |