summaryrefslogtreecommitdiffhomepage
path: root/auto/feature
diff options
context:
space:
mode:
authorMax Romanov <max.romanov@nginx.com>2017-12-01 16:28:06 +0300
committerMax Romanov <max.romanov@nginx.com>2017-12-01 16:28:06 +0300
commit630ec3f1eca0543b2d10c409822ea4acb657c87c (patch)
treea5256391de48996133269e860486c28e4745824f /auto/feature
parent1add36a7ee543b993aeba10c04a4abfc0244c3f8 (diff)
downloadunit-630ec3f1eca0543b2d10c409822ea4acb657c87c.tar.gz
unit-630ec3f1eca0543b2d10c409822ea4acb657c87c.tar.bz2
Using compiler capability to generate dependencies.
This closes #58 issue on GitHub.
Diffstat (limited to 'auto/feature')
-rw-r--r--auto/feature8
1 files changed, 6 insertions, 2 deletions
diff --git a/auto/feature b/auto/feature
index f7e7f25d..55df46bc 100644
--- a/auto/feature
+++ b/auto/feature
@@ -74,13 +74,15 @@ END
if /bin/sh -c "($NXT_AUTOTEST)" >> $NXT_AUTOCONF_ERR 2>&1; then
$echo " found"
nxt_found=yes
- cat << END >> $NXT_AUTO_CONFIG_H
+ if [ -n "$nxt_feature_name" ]; then
+ cat << END >> $NXT_AUTO_CONFIG_H
#ifndef $nxt_feature_name
#define $nxt_feature_name 1
#endif
END
+ fi
else
$echo " found but is not working"
fi
@@ -89,13 +91,15 @@ END
*)
$echo " found"
nxt_found=yes
- cat << END >> $NXT_AUTO_CONFIG_H
+ if [ -n "$nxt_feature_name" ]; then
+ cat << END >> $NXT_AUTO_CONFIG_H
#ifndef $nxt_feature_name
#define $nxt_feature_name 1
#endif
END
+ fi
;;
esac