installer now supports --libs-are-really-here to bypass libuuid checks too
Costa Tsaousis committed
May 14, 2016 at 02:25 UTC
35dc3b0e6644c735947d80476b150704b543a50f
1 file changed
+13
-7
netdata-installer.sh
+13
-7
@@ -27,7 +27,7 @@ ME="$0"
27
DONOTSTART=0
28
DONOTWAIT=0
29
NETDATA_PREFIX=
30
-ZLIB_IS_HERE=0
30
+LIBS_ARE_HERE=0
31
32
usage() {
33
cat <<-USAGE
@@ -52,9 +52,10 @@ usage() {
52
Start immediately building it.
53
54
--zlib-is-really-here
55
+ --libs-are-really-here
56
57
If you get errors about missing zlib,
57
- but you know it is available,
58
+ or libuuid but you know it is available,
59
you have a broken pkg-config.
60
Use this option to allow it continue
61
without checking pkg-config.
@@ -83,9 +84,9 @@ do
84
then
85
NETDATA_PREFIX="${2}/netdata"
86
shift 2
86
- elif [ "$1" = "--zlib-is-really-here" ]
87
+ elif [ "$1" = "--zlib-is-really-here" -o "$1" = "--libs-are-really-here" ]
88
then
88
- ZLIB_IS_HERE=1
89
+ LIBS_ARE_HERE=1
90
shift 1
91
elif [ "$1" = "--dont-start-it" ]
92
then
@@ -250,10 +251,13 @@ build_error() {
251
252
1. The package uuid-dev (or libuuid-devel) has to be installed.
253
254
+ If your system cannot find libuuid, although it is installed
255
+ run me with the option: --libs-are-really-here
256
+
257
2. The package zlib1g-dev (or zlib-devel) has to be installed.
258
255
- If your system cannot find ZLIB, although it is installed
256
- run me with the option: --zlib-is-really-here
259
+ If your system cannot find zlib, although it is installed
260
+ run me with the option: --libs-are-really-here
261
262
3. You need basic build tools installed, like:
263
@@ -296,12 +300,14 @@ run() {
300
return ${ret}
301
}
302
299
-if [ ${ZLIB_IS_HERE} -eq 1 ]
303
+if [ ${LIBS_ARE_HERE} -eq 1 ]
304
then
305
shift
306
echo >&2 "ok, assuming zlib is really installed."
307
export ZLIB_CFLAGS=" "
308
export ZLIB_LIBS="-lz"
309
+ export UUID_CFLAGS=" "
310
+ export UUID_LIBS="-luuid"
311
fi
312
313
trap build_error EXIT