Index: c/src/ada-tests/ChangeLog
===================================================================
--- c/src/ada-tests/ChangeLog	(revision c94a4546288b0a5de614aa53fc46508a9fe7c1fd)
+++ c/src/ada-tests/ChangeLog	(revision a846105767b6f8368babbffd056891c400dae100)
@@ -1,12 +1,15 @@
+2002-08-27	Ralf Corsepius <corsepiu@faw.uni-ulm.de>
+
+	* sptests/sp09/sptest.adb: Add Result to SCREEN_13.
+	Remove Status from TASK_1.
+	* sptests/sp21/sptest.adb: Add Result to TASK_1.
+	* tmtests/tm20/tmtest.adb: Remove various RETURN_VALUEs.
+	* ada.am: Remove ADACOMPILE, ADAC. Add AM_LDFLAGS, LDFLAGS.
+	* configure.ac: Check for m4. Abort if HAS_GNAT = no.
+
 2002-08-26	Joel Sherrill <joel@OARcorp.com>
 
 	* tm27 and tm27 are irrelevant as Ada binding tests.
 	* tmtests/tm26/config.h, tmtests/tm26/config.h: Removed.
-
-2002-08-26	Joel Sherrill <joel@OARcorp.com>
-
-	* sptests/sp19/sptest.adb: Modified to follow pattern of SP01
-	even though this test is not supported.
-	* sptests/sp19/sp19.adb: New file.
 
 2002-08-26	Joel Sherrill <joel@OARcorp.com>
Index: c/src/ada-tests/ada.am
===================================================================
--- c/src/ada-tests/ada.am	(revision c94a4546288b0a5de614aa53fc46508a9fe7c1fd)
+++ c/src/ada-tests/ada.am	(revision a846105767b6f8368babbffd056891c400dae100)
@@ -1,7 +1,4 @@
 SUFFIXES = .adb .ali .ads
 
-ADACOMPILE = $(ADAC) $(AM_ADAFLAGS) $(ADAFLAGS) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-
-ADAC = @ADAC@ $(GCCSPECS)
 GNATMAKE = @GNATMAKE@ -cargs $(GCCSPECS) -largs $(GCCSPECS)
 
@@ -13,5 +10,6 @@
 -margs $(AM_ADAFLAGS) $(ADAFLAGS) \
 -cargs $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) \
--largs $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+-largs $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) \
+$(AM_LDFLAGS) $(LDFLAGS)
 
 CLEANFILES = *.ali *.o b~*.adb b~*.ads
Index: c/src/ada-tests/configure.ac
===================================================================
--- c/src/ada-tests/configure.ac	(revision c94a4546288b0a5de614aa53fc46508a9fe7c1fd)
+++ c/src/ada-tests/configure.ac	(revision a846105767b6f8368babbffd056891c400dae100)
@@ -15,4 +15,5 @@
 AM_MAINTAINER_MODE
 
+AC_CHECK_PROGS([M4],[gm4 m4]) 
 RTEMS_PROG_GNAT
 RTEMS_CANONICALIZE_TOOLS
@@ -25,5 +26,9 @@
 RTEMS_CHECK_BSP_CACHE(RTEMS_BSP)
 
-AM_CONDITIONAL([ADA],[test x"$HAVE_GNAT" = x"yes"])
+AS_IF([test x"$HAVE_GNAT" = x"no"],[
+  AC_MSG_ERROR([No acceptable GNATMAKE found.])
+])
+
+RTEMS_CHECK_TOOL([GNATPREP],[gnatprep],[])
 
 # FIXME: Enable building the examples which are known to be broken
Index: c/src/ada-tests/sptests/sp09/sptest.adb
===================================================================
--- c/src/ada-tests/sptests/sp09/sptest.adb	(revision c94a4546288b0a5de614aa53fc46508a9fe7c1fd)
+++ c/src/ada-tests/sptests/sp09/sptest.adb	(revision a846105767b6f8368babbffd056891c400dae100)
@@ -2652,4 +2652,5 @@
    procedure SCREEN_13
    is
+      RESULT : RTEMS.Unsigned32;
       TIME   : RTEMS.TIME_OF_DAY;
       STATUS : RTEMS.STATUS_CODES;
@@ -2688,4 +2689,5 @@
          0,
          RTEMS.NULL_ADDRESS,
+         RESULT,
          STATUS
       );
@@ -3025,5 +3027,4 @@
       ARGUMENT : in     RTEMS.TASK_ARGUMENT
    ) is
-      STATUS : RTEMS.STATUS_CODES;
    begin
 
Index: c/src/ada-tests/sptests/sp21/sptest.adb
===================================================================
--- c/src/ada-tests/sptests/sp21/sptest.adb	(revision c94a4546288b0a5de614aa53fc46508a9fe7c1fd)
+++ c/src/ada-tests/sptests/sp21/sptest.adb	(revision a846105767b6f8368babbffd056891c400dae100)
@@ -77,4 +77,5 @@
       ARGUMENT : in     RTEMS.TASK_ARGUMENT
    ) is
+      RESULT       : RTEMS.Unsigned32;
       STATUS       : RTEMS.STATUS_CODES;
    begin
@@ -86,4 +87,5 @@
          0,
          RTEMS.NULL_ADDRESS,
+         RESULT,
          STATUS 
       );
@@ -154,4 +156,5 @@
          0,
          RTEMS.NULL_ADDRESS,
+         RESULT,
          STATUS 
       );
@@ -222,4 +225,5 @@
          0,
          RTEMS.NULL_ADDRESS,
+         RESULT,
          STATUS 
       );
Index: c/src/ada-tests/tmtests/tm20/tmtest.adb
===================================================================
--- c/src/ada-tests/tmtests/tm20/tmtest.adb	(revision c94a4546288b0a5de614aa53fc46508a9fe7c1fd)
+++ c/src/ada-tests/tmtests/tm20/tmtest.adb	(revision a846105767b6f8368babbffd056891c400dae100)
@@ -433,5 +433,4 @@
                0,
                RTEMS.NULL_ADDRESS,
-               RETURN_VALUE,
                STATUS
             );
@@ -454,5 +453,4 @@
                0,
                RTEMS.NULL_ADDRESS,
-               RETURN_VALUE,
                STATUS
             );
@@ -475,5 +473,4 @@
                0,
                RTEMS.NULL_ADDRESS,
-               RETURN_VALUE,
                STATUS
             );
@@ -496,5 +493,4 @@
                0,
                RTEMS.NULL_ADDRESS,
-               RETURN_VALUE,
                STATUS
             );
@@ -517,5 +513,4 @@
                0,
                RTEMS.NULL_ADDRESS,
-               RETURN_VALUE,
                STATUS
             );
