package/pkg-rebar.mk: fix remove-rebar-config-dependencies

Handle the case where there is only one dependency described in
rebar.config, so when the line starts by '{deps' and ends by '}.'.
Before it was deleting this line but also all next lines until finding
a line that ends by '}.'.

Signed-off-by: Johan Oudinet <johan.oudinet@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
This commit is contained in:
Johan Oudinet 2018-12-05 17:06:16 +01:00 committed by Thomas Petazzoni
parent bb7c13273f
commit ab60ea2939

View File

@ -96,7 +96,8 @@ endef
# Remove the "deps" statement from a rebar.config file
define remove-rebar-config-dependencies
$(SED) '/^{deps/,/}\.$$/d' $($(PKG)_DIR)/rebar.config
$(SED) '/^{deps.*}\.$$/d' -e '/^{deps/,/}\.$$/d' \
$($(PKG)_DIR)/rebar.config
endef