diff options
author | Igor Sysoev <igor@sysoev.ru> | 2017-08-17 21:47:19 +0300 |
---|---|---|
committer | Igor Sysoev <igor@sysoev.ru> | 2017-08-17 21:47:19 +0300 |
commit | 949548da293fa30ef200d07c3e4ff108174404b7 (patch) | |
tree | 8f03eaad277ec558f9ce2f223db350d134532e4b /auto/make | |
parent | 5ef8e0ee8933e914b1847168255b53f07c3727b3 (diff) | |
download | unit-949548da293fa30ef200d07c3e4ff108174404b7.tar.gz unit-949548da293fa30ef200d07c3e4ff108174404b7.tar.bz2 |
The new module configuration interface.
Configuration and building example:
./configure
./configure python
./configure php
./configure go
make all
or
./configure
make nginext
./configure python
make python
./configure php
make php
./configure go
make go
Modules configuration options and building examples:
./configure python --module=python2 --config=python2.7-config
make python2
./configure php --module=php7 --config=php7.0-config
--lib-path=/usr/local/php7.0
make php7
./configure go --go=go1.6 --go-path=${HOME}/go1.6
make go1.6
Diffstat (limited to '')
-rw-r--r-- | auto/make | 49 |
1 files changed, 9 insertions, 40 deletions
@@ -20,6 +20,11 @@ NXT_EXEC_LINK = $NXT_EXEC_LINK $NXT_LD_OPT NXT_SHARED_LOCAL_LINK = $NXT_SHARED_LOCAL_LINK $NXT_LD_OPT NXT_MODULE_LINK = $NXT_MODULE_LINK $NXT_LD_OPT +.PHONY: $NXT_BIN +$NXT_BIN: $NXT_BUILD_DIR/$NXT_BIN + +all: $NXT_BIN + END @@ -169,24 +174,19 @@ $echo >> $NXT_MAKEFILE # Object files list. -nxt_modules_obj=`$echo $NXT_MODULES_SRC | sed -e "s/\.c$/\.o/"` - $echo "NXT_OBJS = \\" >> $NXT_MAKEFILE -for nxt_src in $NXT_MAKE_SRCS $NXT_MODULES_SRCS +for nxt_src in $NXT_MAKE_SRCS do nxt_obj=`$echo $nxt_src | sed -e "s/\.c$/\.o/"` $echo " $NXT_BUILD_DIR/$nxt_obj \\" >> $NXT_MAKEFILE done -$echo " $nxt_modules_obj" >> $NXT_MAKEFILE $echo >> $NXT_MAKEFILE # nginext executable. -NXT_BIN=nginext - cat << END >> $NXT_MAKEFILE $NXT_BUILD_DIR/$NXT_BIN: $NXT_BUILD_DIR/$NXT_LIB_STATIC \\ @@ -215,48 +215,17 @@ END done -# nxt_modules.c. - -cat << END >> $NXT_MAKEFILE - -$nxt_modules_obj: $NXT_MODULES_SRC \$(NXT_DEPS) - \$(CC) -c \$(CFLAGS) \$(NXT_INCS) \\ - $NXT_LIB_AUX_CFLAGS \\ - -o $nxt_modules_obj \\ - $NXT_MODULES_SRC -END - - -if [ $NXT_PYTHON_MODULE != NO ]; then - . auto/modules/python/make -fi - -if [ $NXT_PHP_MODULE != NO ]; then - . auto/modules/php/make -fi - -if [ $NXT_GO_MODULE != NO ]; then - . auto/modules/go/make -fi - - # Makefile. # *.dSYM is MacOSX Clang debug information. cat << END > Makefile -.PHONY: $NXT_BIN lib_test - -all: $NXT_BIN - include $NXT_MAKEFILE - -lib_test: $NXT_BUILD_DIR/lib_unit_test $NXT_BUILD_DIR/utf8_file_name_test +.PHONY: lib_test +lib_test: $NXT_BUILD_DIR/lib_unit_test $NXT_BUILD_DIR/utf8_file_name_test clean: - rm -rf $NXT_BUILD_DIR *.dSYM Makefile - -$NXT_BIN: $NXT_BUILD_DIR/$NXT_BIN + rm -rf $NXT_BUILD_DIR *.dSYM Makefile END |