diff --git a/Makefile b/Makefile index 5e10d9e5..e19eed61 100644 --- a/Makefile +++ b/Makefile @@ -142,14 +142,16 @@ ICG_EXE := ${TRICK_HOME}/bin/trick-ICG ################################################################################ # DEFAULT TARGET # 1 Build Trick-core and Trick Data-products. -all: no_dp webserver dp +all: no_dp dp @ echo ; echo "Trick compilation complete:" ; date ifeq ($(USE_JAVA), 1) all: java endif - +ifeq ($(TRICK_MONGOOSE), 1) +all: webserver +endif #------------------------------------------------------------------------------- # 1.1 Build Trick-core no_dp: $(TRICK_LIB) $(TRICK_SWIG_LIB) diff --git a/autoconf/configure.ac b/autoconf/configure.ac index 0db59d49..8f108929 100644 --- a/autoconf/configure.ac +++ b/autoconf/configure.ac @@ -298,6 +298,33 @@ AC_ARG_ENABLE([offline], ) AC_SUBST([TRICK_OFFLINE]) +# If offline is specified, set some compilation flags +AC_ARG_ENABLE([mongoose], + AS_HELP_STRING([--enable-mongoose], [Compile Trick with webserver capabilites.]), + AS_IF([test "x$enable_mongoose" = xyes], + [ + TRICK_MONGOOSE="1" + AC_MSG_WARN($(tput setaf 1) --enable-mongoose Mongoose is released under GPLv2 and Trick is \ +released under NASA Open Source Agreement 1.3. Distribution must comply with \ +these agreements$(tput sgr0)) + ], + [TRICK_MONGOOSE="0"] + ), + [TRICK_MONGOOSE="0"] +) +AC_SUBST([TRICK_OFFLINE]) + +# If offline is specified, set some compilation flags +AC_ARG_ENABLE([offline], + AS_HELP_STRING([--enable-offline], [Compile Trick in offline mode. Un-tar the trick-offline directory in TRICK_HOME to use this feature]), + AS_IF([test "x$enable_offline" = xyes], + [TRICK_OFFLINE="1"], + [TRICK_OFFLINE="0"] + ), + [TRICK_OFFLINE="0"] +) +AC_SUBST([TRICK_OFFLINE]) + dnl look for programs we need to compile and run AC_PROG_AWK AC_PROG_CC diff --git a/configure b/configure index 0722e342..e063d43e 100755 --- a/configure +++ b/configure @@ -745,6 +745,7 @@ enable_option_checking with_x enable_32bit enable_offline +enable_mongoose with_swig enable_java with_llvm @@ -1407,6 +1408,7 @@ Optional Features: --enable-offline Compile Trick in offline mode. Un-tar the trick-offline directory in TRICK_HOME to use this feature + --enable-mongoose Compile Trick with webserver capabilites. --enable-java use java (default is yes) --enable-er7utils use er7_utils (default is yes) @@ -3856,6 +3858,46 @@ fi +# If offline is specified, set some compilation flags +# Check whether --enable-mongoose was given. +if test "${enable_mongoose+set}" = set; then : + enableval=$enable_mongoose; if test "x$enable_mongoose" = xyes; then : + + TRICK_MONGOOSE="1" + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $(tput setaf 1) --enable-mongoose Mongoose is released under GPLv2 and Trick is \ +released under NASA Open Source Agreement 1.3. Distribution must comply with \ +these agreements$(tput sgr0)" >&5 +$as_echo "$as_me: WARNING: $(tput setaf 1) --enable-mongoose Mongoose is released under GPLv2 and Trick is \ +released under NASA Open Source Agreement 1.3. Distribution must comply with \ +these agreements$(tput sgr0)" >&2;} + +else + TRICK_MONGOOSE="0" + +fi +else + TRICK_MONGOOSE="0" + +fi + + + +# If offline is specified, set some compilation flags +# Check whether --enable-offline was given. +if test "${enable_offline+set}" = set; then : + enableval=$enable_offline; if test "x$enable_offline" = xyes; then : + TRICK_OFFLINE="1" +else + TRICK_OFFLINE="0" + +fi +else + TRICK_OFFLINE="0" + +fi + + + for ac_prog in gawk mawk nawk awk do # Extract the first word of "$ac_prog", so it can be a program name with args. @@ -5933,9 +5975,6 @@ else fi - - - if test "$USE_JAVA" = "1"; then : for ac_prog in gawk mawk nawk awk diff --git a/share/trick/makefiles/config_user.mk.in b/share/trick/makefiles/config_user.mk.in index 54b4e957..69e92343 100644 --- a/share/trick/makefiles/config_user.mk.in +++ b/share/trick/makefiles/config_user.mk.in @@ -17,6 +17,7 @@ USE_JAVA = @USE_JAVA@ JAVAC = @JAVA_CC@ TRICK_OFFLINE = @TRICK_OFFLINE@ +TRICK_MONGOOSE = @TRICK_MONGOOSE@ USE_X_WINDOWS = @USE_X_WINDOWS@