[njs] Making build and test targets separate.

Dmitry Volyntsev xeioex at nginx.com
Thu Oct 5 15:30:51 UTC 2017


details:   http://hg.nginx.org/njs/rev/65607378a01b
branches:  
changeset: 415:65607378a01b
user:      Dmitry Volyntsev <xeioex at nginx.com>
date:      Thu Oct 05 18:22:56 2017 +0300
description:
Making build and test targets separate.

Previously, if libedit was unavailable the default action was to build
libnjs and run tests. However, if it was available the default action
was just building binaries.

This patch makes the two high-level targets which are intended to be
invoked externally.  The default one for building all available binaries
and the test target for running all available tests.

diffstat:

 Makefile          |  4 +++-
 nxt/auto/editline |  2 +-
 2 files changed, 4 insertions(+), 2 deletions(-)

diffs (26 lines):

diff -r b4462c7dc1b1 -r 65607378a01b Makefile
--- a/Makefile	Thu Oct 05 15:50:36 2017 +0300
+++ b/Makefile	Thu Oct 05 18:22:56 2017 +0300
@@ -76,7 +76,9 @@ NXT_BUILDDIR =	build
 
 all:	test lib_test
 
-njs:   $(NXT_BUILDDIR)/njs
+njs:	$(NXT_BUILDDIR)/njs
+
+libnjs:	$(NXT_BUILDDIR)/libnjs.a
 
 njs_interactive_test:	njs_expect_test $(NXT_BUILDDIR)/njs_interactive_test
 	$(NXT_BUILDDIR)/njs_interactive_test
diff -r b4462c7dc1b1 -r 65607378a01b nxt/auto/editline
--- a/nxt/auto/editline	Thu Oct 05 15:50:36 2017 +0300
+++ b/nxt/auto/editline	Thu Oct 05 18:22:56 2017 +0300
@@ -43,7 +43,7 @@ else
 
     cat << END >> $NXT_MAKEFILE_CONF
 
-default:	all
+default:	libnjs
 END
 
 fi


More information about the nginx-devel mailing list