Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f4ccb4f7 authored by Steve Muckle's avatar Steve Muckle
Browse files

fix builds on macOS when kernel modules are used

The mac implementation of sed has different requirements for the -i
option. Instead of using that, just redirect the output to the final
location of modules.dep, since it's being copied in the very next
line anyway.

Bug: 38268091
Test: run build with kernel modules on macOS
Merged-In: I49e4a1a69f01139ef47711ab1223d3a8e5cda568
Change-Id: I49e4a1a69f01139ef47711ab1223d3a8e5cda568
parent e90119fd
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -1154,8 +1154,7 @@ define build-image-kernel-modules
    $(hide) mkdir -p $(4)/lib/modules/0.0/$(3)lib/modules
    $(hide) cp $(1) $(4)/lib/modules/0.0/$(3)lib/modules
    $(hide) $(DEPMOD) -b $(4) 0.0
    $(hide) sed -e 's/\(.*modules.*\):/\/\1:/g' -e 's/ \([^ ]*modules[^ ]*\)/ \/\1/g' -i $(4)/lib/modules/0.0/modules.dep
    $(hide) cp $(4)/lib/modules/0.0/modules.dep $(2)/lib/modules
    $(hide) sed -e 's/\(.*modules.*\):/\/\1:/g' -e 's/ \([^ ]*modules[^ ]*\)/ \/\1/g' $(4)/lib/modules/0.0/modules.dep > $(2)/lib/modules/modules.dep
endef

# $(1): output file