diff options
-rw-r--r-- | Makefile.am | 11 | ||||
-rw-r--r-- | README.md | 11 | ||||
-rw-r--r-- | configure.ac | 2 | ||||
-rwxr-xr-x | netdata-installer.sh | 61 |
4 files changed, 60 insertions, 25 deletions
diff --git a/Makefile.am b/Makefile.am index 9d57ca59bd..8c7e1949bb 100644 --- a/Makefile.am +++ b/Makefile.am @@ -19,7 +19,7 @@ MAINTAINERCLEANFILES= \ EXTRA_DIST = \ .gitignore \ autogen.sh \ - README \ + README.md \ LICENSE.md \ COPYING \ autogen.sh \ @@ -37,15 +37,6 @@ SUBDIRS = \ web \ $(NULL) -if GIT_TREE - -all-local: README - -README: README.md - sed -e '/^## Git/,/^$$/{d;p}' $< > $@ - -endif - dist_noinst_DATA = netdata.spec # until integrated within build @@ -109,14 +109,3 @@ It should run on any Linux system. We have tested it on: ## Documentation Check the **[netdata wiki](https://github.com/firehol/netdata/wiki)**. - - -## Git sources - -You are looking at a version of the sources extracted directly from git. -If you want a version of the source package where `configure` and any -documentation has been built for you, please get an official -[netdata package download](https://firehol.org/download/netdata/). -The `unsigned/master` folder tracks the head of the git tree and -released packages are also available. - diff --git a/configure.ac b/configure.ac index ab1550614f..1474bffdba 100644 --- a/configure.ac +++ b/configure.ac @@ -14,8 +14,6 @@ PACKAGE_RPM_RELEASE="0.0.$(echo VERSION_SUFFIX | sed 's/^_//')" AC_INIT([netdata], VERSION_NUMBER[]VERSION_SUFFIX) -AM_CONDITIONAL([GIT_TREE], [test -f README.md]) - AM_MAINTAINER_MODE([disable]) if test x"$USE_MAINTAINER_MODE" = xyes; then AC_MSG_NOTICE(***************** MAINTAINER MODE *****************) diff --git a/netdata-installer.sh b/netdata-installer.sh index c67b72d698..ab5a2bf9bd 100755 --- a/netdata-installer.sh +++ b/netdata-installer.sh @@ -127,6 +127,58 @@ if [ ! "${UID}" = 0 -o "$1" = "-h" -o "$1" = "--help" ] exit 1 fi +have_autotools= +if [ "$(type autoreconf 2> /dev/null)" ] +then + autoconf_maj_min() { + local maj min IFS=.- + + maj=$1 + min=$2 + + set -- $(autoreconf -V | sed -ne '1s/.* \([^ ]*\)$/\1/p') + eval $maj=\$1 $min=\$2 + } + autoconf_maj_min AMAJ AMIN + + if [ "$AMAJ" -gt 2 ] + then + have_autotools=Y + elif [ "$AMAJ" -eq 2 -a "$AMIN" -ge 60 ] + then + have_autotools=Y + else + echo "Found autotools $AMAJ.$AMIN" + fi +else + echo "No autotools found" +fi + +if [ ! "$have_autotools" ] +then + if [ -f configure ] + then + echo "Will skip autoreconf step" + else + cat <<-"EOF" + + Sorry, you do not seem to have autotools 2.60 or later, which is + required to build from the git sources of netdata. + + You can either install a suitable version of autotools and automake + or download a netdata package which does not have these dependencies. + + Source packages where autotools have already been run are available + here: + https://firehol.org/download/netdata/ + + The unsigned/master folder tracks the head of the git tree and released + packages are also available. + EOF + exit 1 + fi +fi + if [ ${DONOTWAIT} -eq 0 ] then if [ ! -z "${NETDATA_PREFIX}" ] @@ -155,6 +207,8 @@ You many need to check these: gcc make autoconf automake pkg-config + Autoconf version 2.60 or higher is required + 3. If your system cannot find ZLIB, although it is installed run me with the option: --zlib-is-really-here @@ -189,8 +243,11 @@ fi trap build_error EXIT -echo >&2 "Running ./autogen.sh ..." -run ./autogen.sh || exit 1 +if [ "$have_autotools" ] +then + echo >&2 "Running ./autogen.sh ..." + run ./autogen.sh || exit 1 +fi echo >&2 "Running ./configure ..." run ./configure \ |