[njs] Fixed building on paltforms without librt.

Igor Sysoev igor at sysoev.ru
Wed Dec 5 14:03:08 UTC 2018


details:   https://hg.nginx.org/njs/rev/23fecf3fcc60
branches:  
changeset: 685:23fecf3fcc60
user:      Igor Sysoev <igor at sysoev.ru>
date:      Wed Dec 05 15:38:33 2018 +0300
description:
Fixed building on paltforms without librt.

diffstat:

 nxt/auto/time |  14 ++++----------
 1 files changed, 4 insertions(+), 10 deletions(-)

diffs (28 lines):

diff -r 1dbef01a6d6c -r 23fecf3fcc60 nxt/auto/time
--- a/nxt/auto/time	Tue Dec 04 21:13:13 2018 +0300
+++ b/nxt/auto/time	Wed Dec 05 15:38:33 2018 +0300
@@ -27,20 +27,14 @@ if [ $nxt_found = no ]; then
     nxt_feature="clock_gettime(CLOCK_MONOTONIC) in librt"
     nxt_feature_libs="-lrt"
     . ${NXT_AUTO}feature
-fi
 
-if [ $nxt_found = yes ]; then
-    cat << END >> $NXT_MAKEFILE_CONF
+    if [ $nxt_found = yes ]; then
+        cat << END >> $NXT_MAKEFILE_CONF
 
-NXT_LIBRT = -lrt
+NXT_LIBRT =	-lrt
 END
 
-else
-    cat << END >> $NXT_MAKEFILE_CONF
-
-NXT_LIBRT =
-END
-
+    fi
 fi
 
 # Linux, FreeBSD, MacOSX.


More information about the nginx-devel mailing list