forked from Imagelibrary/rtems
2004-05-10 Ralf Corsepius <ralf_corsepius@rtems.org>
* configure.ac: Add CXX-checks. New conditionals CXXTESTS, MPTESTS, NETTESTS. Add iostream/. * Makefile.am, base_mp/node1/Makefile.am, base_mp/node2/Makefile.am cdtest/Makefile.am, loopback/Makefile.am, pppd/Makefile.am: Reflect changes above. * cdtest/main.cc: Adaptation to new C++ standards.
This commit is contained in:
@@ -1,3 +1,12 @@
|
||||
2004-05-10 Ralf Corsepius <ralf_corsepius@rtems.org>
|
||||
|
||||
* configure.ac: Add CXX-checks. New conditionals CXXTESTS, MPTESTS,
|
||||
NETTESTS. Add iostream/.
|
||||
* Makefile.am, base_mp/node1/Makefile.am, base_mp/node2/Makefile.am
|
||||
cdtest/Makefile.am, loopback/Makefile.am, pppd/Makefile.am:
|
||||
Reflect changes above.
|
||||
* cdtest/main.cc: Adaptation to new C++ standards.
|
||||
|
||||
2004-05-10 Ralf Corsepius <ralf_corsepius@rtems.org>
|
||||
|
||||
* iostream/Makefile.am, iostream/init.cc, iostream/iostream.doc,
|
||||
|
||||
@@ -4,23 +4,27 @@
|
||||
|
||||
ACLOCAL_AMFLAGS = -I ../aclocal
|
||||
|
||||
CPLUSPLUS_TESTS = cdtest
|
||||
SUBDIRS = hello ticker base_sp unlimited minimum fileio
|
||||
|
||||
if MPTESTS
|
||||
## base_mp is a sample multiprocessing test
|
||||
MP_TESTS = base_mp
|
||||
SUBDIRS += base_mp
|
||||
endif
|
||||
|
||||
FP_TESTS = paranoia
|
||||
SUBDIRS += paranoia
|
||||
|
||||
if CXXTESTS
|
||||
SUBDIRS += iostream cdtest
|
||||
endif
|
||||
|
||||
if NETTESTS
|
||||
## loopback tests a network loopback interface
|
||||
NET_TESTS = loopback
|
||||
NET_TESTS += pppd
|
||||
SUBDIRS += loopback
|
||||
SUBDIRS += pppd
|
||||
endif
|
||||
|
||||
SUBDIRS = hello ticker base_sp unlimited minimum fileio $(MP_TESTS) \
|
||||
$(CPLUSPLUS_TESTS) $(FP_TESTS) $(NET_TESTS)
|
||||
|
||||
AUTOMAKE_FILES = sample.am
|
||||
|
||||
EXTRA_DIST = $(AUTOMAKE_FILES)
|
||||
DIST_SUBDIRS = hello ticker base_sp unlimited minimum fileio base_mp cdtest \
|
||||
paranoia loopback pppd
|
||||
|
||||
include $(top_srcdir)/../automake/subdirs.am
|
||||
include $(top_srcdir)/../automake/local.am
|
||||
|
||||
@@ -31,8 +31,6 @@ include $(top_srcdir)/sample.am
|
||||
|
||||
AM_CPPFLAGS += -DNODE_NUMBER=$(NODE) -I.
|
||||
|
||||
if HAS_MP
|
||||
|
||||
#
|
||||
# (OPTIONAL) Add local stuff here using +=
|
||||
#
|
||||
@@ -41,9 +39,6 @@ ${PGM}: $(OBJS) $(LINK_FILES)
|
||||
$(make-exe)
|
||||
|
||||
all-local: $(TMPINSTALL_FILES)
|
||||
else
|
||||
all-local:
|
||||
endif
|
||||
|
||||
EXTRA_DIST = $(DOCS)
|
||||
|
||||
|
||||
@@ -31,8 +31,6 @@ include $(top_srcdir)/sample.am
|
||||
|
||||
AM_CPPFLAGS += -DNODE_NUMBER=$(NODE) -I.
|
||||
|
||||
if HAS_MP
|
||||
|
||||
#
|
||||
# (OPTIONAL) Add local stuff here using +=
|
||||
#
|
||||
@@ -41,9 +39,6 @@ ${PGM}: $(OBJS) $(LINK_FILES)
|
||||
$(make-exe)
|
||||
|
||||
all-local: $(TMPINSTALL_FILES)
|
||||
else
|
||||
all-local:
|
||||
endif
|
||||
|
||||
EXTRA_DIST = $(DOCS)
|
||||
|
||||
|
||||
@@ -29,18 +29,16 @@ include $(top_srcdir)/../automake/compile.am
|
||||
include $(top_srcdir)/../automake/leaf.am
|
||||
include $(top_srcdir)/sample.am
|
||||
|
||||
# AM_CPPFLAGS += -DRTEMS_TEST_IO_STREAM
|
||||
|
||||
#
|
||||
# (OPTIONAL) Add local stuff here using +=
|
||||
#
|
||||
|
||||
if HAS_CXX
|
||||
${PGM}: $(OBJS) $(LINK_FILES)
|
||||
$(make-cxx-exe)
|
||||
|
||||
all-local: $(TMPINSTALL_FILES)
|
||||
else
|
||||
all-local:
|
||||
endif
|
||||
|
||||
EXTRA_DIST = $(C_FILES) $(CC_FILES) $(DOCS)
|
||||
|
||||
|
||||
@@ -26,10 +26,12 @@
|
||||
*/
|
||||
|
||||
#include <rtems.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
#include <cstdio>
|
||||
#include <cstdlib>
|
||||
|
||||
#ifdef RTEMS_TEST_IO_STREAM
|
||||
#include <iostream.h>
|
||||
#include <iostream>
|
||||
#endif
|
||||
|
||||
extern "C"
|
||||
@@ -144,7 +146,7 @@ cdtest(void)
|
||||
BClass bleak;
|
||||
|
||||
#ifdef RTEMS_TEST_IO_STREAM
|
||||
cout << "Testing a C++ I/O stream" << endl;
|
||||
std::cout << "Testing a C++ I/O stream" << std::endl;
|
||||
#else
|
||||
printf("IO Stream not tested\n");
|
||||
#endif
|
||||
|
||||
@@ -23,7 +23,6 @@ RTEMS_PROJECT_ROOT
|
||||
RTEMS_PROG_CC_FOR_TARGET
|
||||
|
||||
RTEMS_PROG_CXX_FOR_TARGET
|
||||
|
||||
RTEMS_CANONICALIZE_TOOLS
|
||||
|
||||
RTEMS_CHECK_CUSTOM_BSP(RTEMS_BSP)
|
||||
@@ -31,9 +30,33 @@ RTEMS_CHECK_MULTIPROCESSING(RTEMS_BSP)
|
||||
RTEMS_CHECK_CXX(RTEMS_BSP)
|
||||
RTEMS_CHECK_NETWORKING
|
||||
|
||||
AM_CONDITIONAL(HAS_NETWORKING,test "$HAS_NETWORKING" = "yes")
|
||||
AM_CONDITIONAL(HAS_CXX,test "$HAS_CPLUSPLUS" = "yes")
|
||||
AM_CONDITIONAL(HAS_MP,test "$HAS_MP" = "yes")
|
||||
|
||||
CXXTESTS=$HAS_CPLUSPLUS
|
||||
AS_IF([test $HAS_CPLUSPLUS = yes],[
|
||||
AC_LANG_PUSH([C++])
|
||||
AC_CHECK_HEADERS([cstdio cstdlib iostream],[],[CXXTESTS=no])
|
||||
AC_CACHE_CHECK(
|
||||
[if iostream supports std:: namespace],
|
||||
[rtems_cv_HAVE_IOSTREAM_STD_NAMESPACE],
|
||||
[AC_COMPILE_IFELSE(
|
||||
[AC_LANG_PROGRAM(
|
||||
[[#include <iostream>]],
|
||||
[[std::cout << "hello" << std::endl;]])
|
||||
],
|
||||
[rtems_cv_HAVE_IOSTREAM_STD_NAMESPACE=yes],
|
||||
[rtems_cv_HAVE_IOSTREAM_STD_NAMESPACE=no])
|
||||
])
|
||||
AS_IF([test $rtems_cv_HAVE_IOSTREAM_STD_NAMESPACE = no],[CXXTESTS=no])
|
||||
AS_IF([test $CXXTESTS = no],[
|
||||
AC_MSG_WARN([disabling C++ tests])
|
||||
])
|
||||
AC_LANG_POP
|
||||
])
|
||||
|
||||
AM_CONDITIONAL([CXXTESTS],[test $CXXTESTS = "yes"])
|
||||
AM_CONDITIONAL(NETTESTS,test "$HAS_NETWORKING" = "yes")
|
||||
AM_CONDITIONAL(MPTESTS,test "$HAS_MP" = "yes")
|
||||
|
||||
#FIXME: We should use a feature based check
|
||||
AM_CONDITIONAL(LIBCHIP,[test "$RTEMS_BSP_FAMILY" != "posix"])
|
||||
|
||||
@@ -50,6 +73,7 @@ unlimited/Makefile
|
||||
base_mp/Makefile
|
||||
base_mp/node1/Makefile
|
||||
base_mp/node2/Makefile
|
||||
iostream/Makefile
|
||||
cdtest/Makefile
|
||||
pppd/Makefile
|
||||
])
|
||||
|
||||
@@ -27,12 +27,10 @@ include $(top_srcdir)/sample.am
|
||||
# (OPTIONAL) Add local stuff here using +=
|
||||
#
|
||||
|
||||
if HAS_NETWORKING
|
||||
all-local: $(TMPINSTALL_FILES)
|
||||
|
||||
${PGM}: $(OBJS) $(LINK_FILES)
|
||||
$(make-exe)
|
||||
endif
|
||||
|
||||
EXTRA_DIST = $(C_FILES) $(DOCS)
|
||||
|
||||
|
||||
@@ -26,12 +26,10 @@ include $(top_srcdir)/sample.am
|
||||
# (OPTIONAL) Add local stuff here using +=
|
||||
#
|
||||
|
||||
if HAS_NETWORKING
|
||||
all-local: $(TMPINSTALL_FILES)
|
||||
|
||||
${PGM}: $(OBJS) $(LINK_FILES)
|
||||
$(make-exe)
|
||||
endif
|
||||
|
||||
EXTRA_DIST = $(C_FILES) $(H_FILES)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user