build: Make DBus code generation more portable

The $'...' quoting syntax is a Bash extension and might not be
available in other Bourne Shell compatible shells:
https://www.gnu.org/software/bash/manual/html_node/Major-Differences-From-The-Bourne-Shell.html#Major-Differences-From-The-Bourne-Shell

https://bugzilla.gnome.org/show_bug.cgi?id=734630
This commit is contained in:
Daiki Ueno 2018-03-30 16:30:48 +02:00
parent b01e54991a
commit a7f2efc450

View File

@ -89,10 +89,10 @@ temp-dbus-generated.c: $(DBUS_XML_DEFINITIONS) Makefile.am
$(AM_V_GEN) gdbus-codegen --interface-prefix org.freedesktop.Secret. \
--generate-c-code temp-dbus-generated --c-namespace SecretGen $<
secret-dbus-generated.c: temp-dbus-generated.c Makefile.am
$(AM_V_GEN) sed -e $$'1i\\\n#define GLIB_DISABLE_DEPRECATION_WARNINGS' \
-e 's/secret_gen_/_secret_gen_/g' -e 's/type-/type/g' \
$(AM_V_GEN) { echo '#define GLIB_DISABLE_DEPRECATION_WARNINGS'; \
sed -e 's/secret_gen_/_secret_gen_/g' -e 's/type-/type/g' \
-e 's/temp-dbus-generated.h/secret-dbus-generated.h/g' \
temp-dbus-generated.c > secret-dbus-generated.c
temp-dbus-generated.c; } > secret-dbus-generated.c
secret-dbus-generated.h: temp-dbus-generated.c Makefile.am
$(AM_V_GEN) sed -e 's/secret_gen_/_secret_gen_/g' -e 's/type-/type/g' \
temp-dbus-generated.h > secret-dbus-generated.h