Commit b7529808 authored by Pavel Vainerman's avatar Pavel Vainerman

Добавил ключик enable/disable netdata plugin для configure.

По умолчанию: enabled. Для отключения --disable-netdata
parent 4fb7b140
......@@ -315,18 +315,13 @@ SharedMemoryPlus extension ('all in one') for libuniset
%build
%autoreconf
%configure %{subst_enable docs} %{subst_enable mysql} %{subst_enable sqlite} %{subst_enable pgsql} %{subst_enable python} %{subst_enable rrd} %{subst_enable io} %{subst_enable logicproc} %{subst_enable tests} %{subst_enable mqtt} %{subst_enable api}
%configure %{subst_enable docs} %{subst_enable mysql} %{subst_enable sqlite} %{subst_enable pgsql} %{subst_enable python} %{subst_enable rrd} %{subst_enable io} %{subst_enable logicproc} %{subst_enable tests} %{subst_enable mqtt} %{subst_enable api} %{subst_enable netdata}
%make_build
%install
%makeinstall_std
rm -f %buildroot%_libdir/*.la
%if_disabled netdata
rm -rf %buildroot%_libdir/netdata/python.d
rm -rf %buildroot%_sysconfdir/netdata/*
%endif
%files utils
%_bindir/%oname-admin
%_bindir/%oname-mb*
......
......@@ -239,6 +239,19 @@ if test ${buildpython} = true; then
AM_PATH_PYTHON(,,)
PKG_CHECK_MODULES(PYTHON,python-2.7,,exit)
# AC_CHECK_PROG(SWIG, swig, yes, exit)
AC_MSG_CHECKING([netdata python plugin])
netdata=true
AC_ARG_ENABLE(netdata,AC_HELP_STRING([--disable-netdata], [disable build netdata python plugin]),
[ if test $enableval = yes; then netdata=true; else netdata=false; fi],[ netdata=true; ])
if test ${netdata} = true; then
AC_MSG_RESULT([enabled])
else
AC_MSG_RESULT([disabled])
fi
AM_CONDITIONAL(HAVE_NETDATA, test ${netdata} = true)
else
AC_MSG_RESULT([disabled])
fi
......
if DISABLE_PYTHON
else
if HAVE_NETDATA
netdataconfdir = $(sysconfdir)/netdata/python.d
netdataconf_DATA = *.conf
......@@ -10,3 +10,4 @@ plug_DATA = *.py
include $(top_builddir)/include.mk
endif
endif
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment