Changed version processing for modules.

This commit is contained in:
Alexander Borisov
2018-04-04 18:53:39 +03:00
parent 0665896a55
commit 49bd3a21e0
11 changed files with 68 additions and 20 deletions

View File

@@ -91,8 +91,23 @@ if [ $nxt_found = no ]; then
exit 1;
fi
NXT_RUBY_VERSION=`$NXT_RUBY -r rbconfig -e 'printf("%s",RbConfig::CONFIG["RUBY_PROGRAM_VERSION"])'`
$echo " + Ruby version: ${NXT_RUBY_VERSION}"
nxt_feature="Ruby version"
nxt_feature_name=""
nxt_feature_run=value
nxt_feature_incs="${NXT_RUBY_INCPATH}"
nxt_feature_libs="${NXT_RUBY_LIBS}"
nxt_feature_test="
#include <ruby.h>
#include <ruby/version.h>
int main() {
printf(\"%s\", ruby_version);
return 0;
}"
. auto/feature
if grep ^$NXT_RUBY_MODULE: $NXT_MAKEFILE 2>&1 > /dev/null; then
$echo