Author: jsdelfino
Date: Mon Oct  2 17:09:20 2006
New Revision: 452278

URL: http://svn.apache.org/viewvc?view=rev&rev=452278
Log:
Added configure options to the automake build to enable/disable C++, Ruby and 
Python samples, similar to what we've already done for the main build.

Modified:
    incubator/tuscany/cpp/sca/samples/Makefile.am
    incubator/tuscany/cpp/sca/samples/configure.ac

Modified: incubator/tuscany/cpp/sca/samples/Makefile.am
URL: 
http://svn.apache.org/viewvc/incubator/tuscany/cpp/sca/samples/Makefile.am?view=diff&rev=452278&r1=452277&r2=452278
==============================================================================
--- incubator/tuscany/cpp/sca/samples/Makefile.am (original)
+++ incubator/tuscany/cpp/sca/samples/Makefile.am Mon Oct  2 17:09:20 2006
@@ -1,3 +1,19 @@
-SUBDIRS = Calculator BigBank RubyCalculator RubyBank PythonCalculator
+if WANT_ALL_SAMPLES
+  CPP_SAMPLES = Calculator BigBank
+  PYTHON_SAMPLES = PythonCalculator
+  RUBY_SAMPLES = RubyCalculator RubyBank
+endif
+if WANT_CPP_SAMPLES
+  CPP_SAMPLES = Calculator BigBank
+endif
+if WANT_PYTHON_SAMPLES
+  PYTHON_SAMPLES = PythonCalculator
+endif
+if WANT_RUBY_SAMPLES
+  RUBY_SAMPLES = RubyCalculator RubyBank
+endif
+if WANT_PHP_SAMPLES
+endif
+SUBDIRS = ${CPP_SAMPLES} ${PYTHON_SAMPLES} ${RUBY_SAMPLES} ${PHP_SAMPLES}
 
 EXTRA_DIST = GettingStarted.html

Modified: incubator/tuscany/cpp/sca/samples/configure.ac
URL: 
http://svn.apache.org/viewvc/incubator/tuscany/cpp/sca/samples/configure.ac?view=diff&rev=452278&r1=452277&r2=452278
==============================================================================
--- incubator/tuscany/cpp/sca/samples/configure.ac (original)
+++ incubator/tuscany/cpp/sca/samples/configure.ac Mon Oct  2 17:09:20 2006
@@ -23,6 +23,108 @@
   [AC_SUBST([libsuffix],[".so"]) AC_MSG_RESULT([using .so])]
 )
 
+# Checks for libraries.
+
+# Checks for header files.
+AC_HEADER_DIRENT
+AC_HEADER_STDC
+AC_CHECK_HEADERS([inttypes.h stdlib.h string.h sys/time.h unistd.h])
+
+# Checks for typedefs, structures, and compiler characteristics.
+AC_HEADER_STDBOOL
+AC_C_CONST
+AC_C_INLINE
+
+# Checks for library functions.
+AC_FUNC_CLOSEDIR_VOID
+AC_FUNC_STAT
+AC_FUNC_VPRINTF
+AC_CHECK_FUNCS([getcwd putenv strdup])
+
+AC_MSG_CHECKING(whether to build all samples)
+AC_ARG_ENABLE(all-samples, [AS_HELP_STRING([--enable-all-samples],[build all 
samples [default=no]])],
+[ case "${enableval}" in
+  no)
+    AC_MSG_RESULT(no)
+    want_all_samples=false
+    ;;
+  *)
+    AC_MSG_RESULT(yes)
+    want_all_samples=true
+    ;;
+  esac ],
+[ AC_MSG_RESULT(no)
+  want_all_samples=false ]
+)
+AM_CONDITIONAL([WANT_ALL_SAMPLES], [test x$want_all_samples = xtrue])
+
+AC_MSG_CHECKING(whether to build C++ samples)
+AC_ARG_ENABLE(cpp, [AS_HELP_STRING([--enable-cpp],[build C++ samples 
[default=yes]])],
+[ case "${enableval}" in
+  no)
+    AC_MSG_RESULT(no)
+    want_cpp_samples=false
+    ;;
+  *)
+    AC_MSG_RESULT(yes)
+    want_cpp_samples=true
+    ;;
+  esac ],
+[ AC_MSG_RESULT(yes)
+  want_cpp_samples=true ]
+)
+AM_CONDITIONAL([WANT_CPP_SAMPLES], [test x$want_cpp_samples = xtrue])
+
+AC_MSG_CHECKING(whether to build Python samples)
+AC_ARG_ENABLE(python, [AS_HELP_STRING([--enable-python],[build Python samples 
[default=no]])],
+[ case "${enableval}" in
+  no)
+    AC_MSG_RESULT(no)
+    want_python_samples=false
+    ;;
+  *)
+    AC_MSG_RESULT(yes)
+    want_python_samples=true
+    ;;
+  esac ],
+[ AC_MSG_RESULT(no)
+  want_python_samples=false ]
+)
+AM_CONDITIONAL([WANT_PYTHON_SAMPLES], [test x$want_python_samples = xtrue])
+
+AC_MSG_CHECKING(whether to build Ruby samples)
+AC_ARG_ENABLE(ruby, [AS_HELP_STRING([--enable-ruby],[build Ruby samples 
[default=no]])],
+[ case "${enableval}" in
+  no)
+    AC_MSG_RESULT(no)
+    want_ruby_samples=false
+    ;;
+  *)
+    AC_MSG_RESULT(yes)
+    want_ruby_samples=true
+    ;;
+  esac ],
+[ AC_MSG_RESULT(no)
+  want_ruby_samples=false ]
+)
+AM_CONDITIONAL([WANT_RUBY_SAMPLES], [test x$want_ruby_samples = xtrue])
+
+AC_MSG_CHECKING(whether to build PHP samples)
+AC_ARG_ENABLE(php, [AS_HELP_STRING([--enable-php],[build PHP samples 
[default=no]])],
+[ case "${enableval}" in
+  no)
+    AC_MSG_RESULT(no)
+    want_php_samples=false
+    ;;
+  *)
+    AC_MSG_RESULT(yes)
+    want_php_samples=true
+    ;;
+  esac ],
+[ AC_MSG_RESULT(no)
+  want_php_samples=false ]
+)
+AM_CONDITIONAL([WANT_PHP_SAMPLES], [test x$want_php_samples = xtrue])
 
 AC_CONFIG_FILES([Makefile
                  Calculator/Makefile
@@ -46,4 +148,3 @@
                  RubyBank/bigbank.client/Makefile
                  ])
 AC_OUTPUT
-



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to