|
1 |
| -if echo $HTTP_MODULES | grep " ndk_http_module" > /dev/null; then |
2 |
| - echo "found ngx_devel_kit for ngx_array_var; looks good." |
| 1 | +if test -n "$ngx_module_link"; then |
| 2 | + if test -n "$NDK_SRCS"; then |
| 3 | + echo "found ngx_devel_kit for ngx_array_var; looks good." |
| 4 | + else |
| 5 | + echo "error: ngx_devel_kit is required to build ngx_array_var; please put it before ngx_array_var." 1>&2 |
| 6 | + exit 1 |
| 7 | + fi |
3 | 8 | else
|
4 |
| - echo "error: ngx_devel_kit is required to build ngx_array_var; please put it before ngx_array_var." 1>&2 |
5 |
| - exit 1 |
| 9 | + if echo $HTTP_MODULES | grep " ndk_http_module" > /dev/null; then |
| 10 | + echo "found ngx_devel_kit for ngx_array_var; looks good." |
| 11 | + else |
| 12 | + echo "error: ngx_devel_kit is required to build ngx_array_var; please put it before ngx_array_var." 1>&2 |
| 13 | + exit 1 |
| 14 | + fi |
6 | 15 | fi
|
7 | 16 |
|
8 | 17 | ngx_addon_name=ngx_http_array_var_module
|
9 |
| -HTTP_AUX_FILTER_MODULES="$HTTP_AUX_FILTER_MODULES ngx_http_array_var_module" |
10 |
| -NGX_ADDON_SRCS="$NGX_ADDON_SRCS $ngx_addon_dir/src/ngx_http_array_var_module.c $ngx_addon_dir/src/ngx_http_array_var_util.c" |
11 |
| -NGX_ADDON_DEPS="$NGX_ADDON_DEPS $ngx_addon_dir/src/ddebug.h $ngx_addon_dir/src/ngx_http_array_var_util.h" |
12 |
| -CFLAGS="$CFLAGS -DNDK_SET_VAR" |
13 | 18 |
|
| 19 | +HTTP_ARRAY_VAR_SRCS=" \ |
| 20 | + $ngx_addon_dir/src/ngx_http_array_var_module.c \ |
| 21 | + $ngx_addon_dir/src/ngx_http_array_var_util.c \ |
| 22 | + " |
| 23 | + |
| 24 | +HTTP_ARRAY_VAR_DEPS=" \ |
| 25 | + $ngx_addon_dir/src/ddebug.h \ |
| 26 | + $ngx_addon_dir/src/ngx_http_array_var_util.h \ |
| 27 | + " |
| 28 | + |
| 29 | +if test -n "$ngx_module_link"; then |
| 30 | + ngx_module_type=HTTP |
| 31 | + ngx_module_name=$ngx_addon_name |
| 32 | + ngx_module_incs= |
| 33 | + ngx_module_deps="$HTTP_ARRAY_VAR_DEPS" |
| 34 | + ngx_module_srcs="$HTTP_ARRAY_VAR_SRCS" |
| 35 | + ngx_module_libs= |
| 36 | + |
| 37 | + . auto/module |
| 38 | +else |
| 39 | + HTTP_MODULES="$HTTP_MODULES $ngx_addon_name" |
| 40 | + NGX_ADDON_SRCS="$NGX_ADDON_SRCS $HTTP_ARRAY_VAR_SRCS" |
| 41 | + NGX_ADDON_DEPS="$NGX_ADDON_DEPS $HTTP_ARRAY_VAR_DEPS" |
| 42 | +fi |
| 43 | + |
| 44 | +CFLAGS="$CFLAGS -DNDK_SET_VAR" |
0 commit comments