From 7050f4a6a69523d1a9a1212840edca01382b6e37 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Fri, 20 Sep 2019 10:32:49 +0100 Subject: [PATCH] erlang: Avoid deprecation warnings. According to the Erlang website: The old legacy erl_interface library (functions with prefix erl_) is deprecated as of OTP 22, and will be removed in OTP 23. This does not apply to the ei library. Reasonably new gcc compilers will issue deprecation warnings. In order to disable these warnings, define the macro EI_NO_DEPR_WARN. That's a shame and probably means we will have to drop the Erlang bindings soon unless someone ports them to this new API (stable APIs FTW people!). In the meantime add the flag to prevent warn-errors about deprecation. --- erlang/Makefile.am | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/erlang/Makefile.am b/erlang/Makefile.am index 75b3ec9d5..19b0e973e 100644 --- a/erlang/Makefile.am +++ b/erlang/Makefile.am @@ -83,7 +83,8 @@ erl_guestfs_CPPFLAGS = \ -I$(top_srcdir)/common/utils -I$(top_builddir)/common/utils \ -I$(top_srcdir)/lib -I$(top_builddir)/lib \ -I$(srcdir)/../gnulib/lib -I../gnulib/lib \ - -I$(ERLANG_LIB_DIR_erl_interface)/include + -I$(ERLANG_LIB_DIR_erl_interface)/include \ + -DEI_NO_DEPR_WARN erl_guestfs_CFLAGS = \ $(WARN_CFLAGS) $(WERROR_CFLAGS)