summaryrefslogtreecommitdiffstats
path: root/hello_via_task
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>2007-10-17 20:55:06 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>2007-10-17 20:55:06 +0000
commit14f44a3474b5177a73aede9d3ab142ab003f5796 (patch)
treeeeab866e741b2a851d712497384f45ea56717863 /hello_via_task
parent2007-10-17 Joel Sherrill <joel.sherrill@oarcorp.com> (diff)
downloadada-examples-14f44a3474b5177a73aede9d3ab142ab003f5796.tar.bz2
2007-10-17 Joel Sherrill <joel.sherrill@oarcorp.com>
* Makefile, Makefile.shared, rtems_init.c, irq_test/interrupt_pkg.adb, irq_test/interrupt_pkg.ads, irq_test/irqforce.c, irq_test/irqtest.adb, rootfs/etc/hosts: Adding new tests as improvements are made to the RTEMS port of the GNAT run-time. * empty/Makefile, empty/README, empty/empty.adb, hello_via_task/.cvsignore, hello_via_task/Makefile, hello_via_task/hello.adb, irq_test/.cvsignore, irq_test/Makefile, irq_test/README, irq_test_c/.cvsignore, irq_test_c/Makefile, irq_test_c/README, irq_test_c/init.c, irq_test_c/irqforce.c: New files.
Diffstat (limited to 'hello_via_task')
-rw-r--r--hello_via_task/.cvsignore5
-rw-r--r--hello_via_task/Makefile25
-rw-r--r--hello_via_task/hello.adb27
3 files changed, 57 insertions, 0 deletions
diff --git a/hello_via_task/.cvsignore b/hello_via_task/.cvsignore
new file mode 100644
index 0000000..cf1b678
--- /dev/null
+++ b/hello_via_task/.cvsignore
@@ -0,0 +1,5 @@
+b~hello.adb
+b~hello.ads
+b~hello.ali
+hello
+hello.ali
diff --git a/hello_via_task/Makefile b/hello_via_task/Makefile
new file mode 100644
index 0000000..8602dcb
--- /dev/null
+++ b/hello_via_task/Makefile
@@ -0,0 +1,25 @@
+#
+# Makefile for Ada Dump URL example
+#
+# See README.Makefiles in the main ada-examples directory.
+#
+
+PROGRAM=hello
+
+include $(RTEMS_MAKEFILE_PATH)/Makefile.inc
+include $(RTEMS_CUSTOM)
+include $(PROJECT_ROOT)/make/leaf.cfg
+
+# stack size for the first Ada thread
+CFLAGS +=-DGNAT_MAIN_STACKSPACE=100
+
+# initialize the network stack -- assumes existence of networkconfig.h
+# CFLAGS +=-DMAIN_USE_NETWORKING=1
+
+# Should we prompt for command line arguments?
+# DEFINES +=-DMAIN_USE_REQUIRES_COMMAND_LINE
+
+# If you want to hard-code the command line, define this to a string
+# DEFINES += -DMAIN_COMMAND_LINE="ARGS"
+
+include ../Makefile.shared
diff --git a/hello_via_task/hello.adb b/hello_via_task/hello.adb
new file mode 100644
index 0000000..3d22eaf
--- /dev/null
+++ b/hello_via_task/hello.adb
@@ -0,0 +1,27 @@
+--
+-- Hello World Using a Task
+--
+
+with Text_IO; use Text_IO;
+
+procedure Hello is
+
+ task Hello_Task;
+
+ task body Hello_Task is
+ begin
+ Put_Line ("GNAT/RTEMS Hello World Test");
+ New_Line;
+ Put_Line ("Welcome to the World of Lady Ada");
+
+ New_Line;
+ Put_Line ("Initiating 2.5 second delay");
+ delay 2.5;
+ Put_Line ("Delay Complete");
+
+ Put_Line ("Test Complete");
+ end Hello_Task;
+
+begin
+ NULL;
+end Hello;