Index: cpukit/ChangeLog
===================================================================
--- cpukit/ChangeLog	(revision 75b571311ac789d838379aad686f53754da7ab18)
+++ cpukit/ChangeLog	(revision 8d8daef461194021e0df6cdc3140a1d124d140e4)
@@ -1,2 +1,13 @@
+2007-12-13	Joel Sherrill <joel.sherrill@OARcorp.com>
+
+	* libcsupport/preinstall.am, posix/preinstall.am, posix/src/aio.c,
+	posix/src/clockgetcpuclockid.c, posix/src/clockgetenableattr.c,
+	posix/src/clockgettime.c, posix/src/clocksetenableattr.c,
+	posix/src/clocksettime.c, posix/src/devctl.c,
+	posix/src/pthreadcreate.c, posix/src/pthreadgetcpuclockid.c,
+	posix/src/types.c, rtems/preinstall.am, sapi/Makefile.am,
+	sapi/preinstall.am, score/Makefile.am, score/preinstall.am: Eliminate
+	POSIX_NOT_IMPLEMENTED(). Return ENOSYS instead.
+
 2007-12-13	Joel Sherrill <joel.sherrill@OARcorp.com>
 
Index: cpukit/libcsupport/preinstall.am
===================================================================
--- cpukit/libcsupport/preinstall.am	(revision 75b571311ac789d838379aad686f53754da7ab18)
+++ cpukit/libcsupport/preinstall.am	(revision 8d8daef461194021e0df6cdc3140a1d124d140e4)
@@ -9,8 +9,22 @@
 DISTCLEANFILES = $(PREINSTALL_DIRS)
 
+all-local: $(TMPINSTALL_FILES)
+
+TMPINSTALL_FILES =
+CLEANFILES = $(TMPINSTALL_FILES)
+
 all-am: $(PREINSTALL_FILES)
 
 PREINSTALL_FILES =
-CLEANFILES = $(PREINSTALL_FILES)
+CLEANFILES += $(PREINSTALL_FILES)
+
+$(PROJECT_LIB)/$(dirstamp):
+	@$(MKDIR_P) $(PROJECT_LIB)
+	@: > $(PROJECT_LIB)/$(dirstamp)
+PREINSTALL_DIRS += $(PROJECT_LIB)/$(dirstamp)
+
+$(PROJECT_LIB)/libcsupport.a: libcsupport.a $(PROJECT_LIB)/$(dirstamp)
+	$(INSTALL_DATA) $< $(PROJECT_LIB)/libcsupport.a
+TMPINSTALL_FILES += $(PROJECT_LIB)/libcsupport.a
 
 $(PROJECT_INCLUDE)/rtems/$(dirstamp):
Index: cpukit/posix/preinstall.am
===================================================================
--- cpukit/posix/preinstall.am	(revision 75b571311ac789d838379aad686f53754da7ab18)
+++ cpukit/posix/preinstall.am	(revision 8d8daef461194021e0df6cdc3140a1d124d140e4)
@@ -9,8 +9,18 @@
 DISTCLEANFILES = $(PREINSTALL_DIRS)
 
+all-local: $(TMPINSTALL_FILES)
+
+TMPINSTALL_FILES =
+CLEANFILES = $(TMPINSTALL_FILES)
+
 all-am: $(PREINSTALL_FILES)
 
 PREINSTALL_FILES =
-CLEANFILES = $(PREINSTALL_FILES)
+CLEANFILES += $(PREINSTALL_FILES)
+
+$(PROJECT_LIB)/$(dirstamp):
+	@$(MKDIR_P) $(PROJECT_LIB)
+	@: > $(PROJECT_LIB)/$(dirstamp)
+PREINSTALL_DIRS += $(PROJECT_LIB)/$(dirstamp)
 
 $(PROJECT_INCLUDE)/$(dirstamp):
@@ -20,4 +30,8 @@
 
 if LIBPOSIX
+$(PROJECT_LIB)/libposix.a: libposix.a $(PROJECT_LIB)/$(dirstamp)
+	$(INSTALL_DATA) $< $(PROJECT_LIB)/libposix.a
+TMPINSTALL_FILES += $(PROJECT_LIB)/libposix.a
+
 if HAS_PTHREADS
 $(PROJECT_INCLUDE)/sched.h: include/sched.h $(PROJECT_INCLUDE)/$(dirstamp)
Index: cpukit/posix/src/aio.c
===================================================================
--- cpukit/posix/src/aio.c	(revision 75b571311ac789d838379aad686f53754da7ab18)
+++ cpukit/posix/src/aio.c	(revision 8d8daef461194021e0df6cdc3140a1d124d140e4)
@@ -8,9 +8,8 @@
 
 #include <aio.h>
+#include <errno.h>
 
 #include <rtems/system.h>
 #include <rtems/seterr.h>
-
-int POSIX_NOT_IMPLEMENTED();
 
 /*PAGE
@@ -23,5 +22,5 @@
 )
 {
-  return POSIX_NOT_IMPLEMENTED();
+  rtems_set_errno_and_return_minus_one( ENOSYS );
 }
 
@@ -35,5 +34,5 @@
 )
 {
-  return POSIX_NOT_IMPLEMENTED();
+  rtems_set_errno_and_return_minus_one( ENOSYS );
 }
 
@@ -50,5 +49,5 @@
 )
 {
-  return POSIX_NOT_IMPLEMENTED();
+  rtems_set_errno_and_return_minus_one( ENOSYS );
 }
 
@@ -62,5 +61,5 @@
 )
 {
-  return POSIX_NOT_IMPLEMENTED();
+  rtems_set_errno_and_return_minus_one( ENOSYS );
 }
 
@@ -75,5 +74,5 @@
 )
 {
-  return POSIX_NOT_IMPLEMENTED();
+  rtems_set_errno_and_return_minus_one( ENOSYS );
 }
 
@@ -88,5 +87,5 @@
 )
 {
-  return POSIX_NOT_IMPLEMENTED();
+  rtems_set_errno_and_return_minus_one( ENOSYS );
 }
 
@@ -102,5 +101,5 @@
 )
 {
-  return POSIX_NOT_IMPLEMENTED();
+  rtems_set_errno_and_return_minus_one( ENOSYS );
 }
 
@@ -115,4 +114,4 @@
 )
 {
-  return POSIX_NOT_IMPLEMENTED();
+  rtems_set_errno_and_return_minus_one( ENOSYS );
 }
Index: cpukit/posix/src/clockgetcpuclockid.c
===================================================================
--- cpukit/posix/src/clockgetcpuclockid.c	(revision 75b571311ac789d838379aad686f53754da7ab18)
+++ cpukit/posix/src/clockgetcpuclockid.c	(revision 8d8daef461194021e0df6cdc3140a1d124d140e4)
@@ -28,4 +28,4 @@
 )
 {
-  return POSIX_NOT_IMPLEMENTED();
+  rtems_set_errno_and_return_minus_one( ENOSYS );
 }
Index: cpukit/posix/src/clockgetenableattr.c
===================================================================
--- cpukit/posix/src/clockgetenableattr.c	(revision 75b571311ac789d838379aad686f53754da7ab18)
+++ cpukit/posix/src/clockgetenableattr.c	(revision 8d8daef461194021e0df6cdc3140a1d124d140e4)
@@ -28,4 +28,4 @@
 )
 {
-  return POSIX_NOT_IMPLEMENTED();
+  rtems_set_errno_and_return_minus_one( ENOSYS );
 }
Index: cpukit/posix/src/clockgettime.c
===================================================================
--- cpukit/posix/src/clockgettime.c	(revision 75b571311ac789d838379aad686f53754da7ab18)
+++ cpukit/posix/src/clockgettime.c	(revision 8d8daef461194021e0df6cdc3140a1d124d140e4)
@@ -50,5 +50,5 @@
 #ifdef _POSIX_THREAD_CPUTIME
     case CLOCK_THREAD_CPUTIME:
-      return POSIX_NOT_IMPLEMENTED();
+      rtems_set_errno_and_return_minus_one( ENOSYS );
       break;
 #endif
Index: cpukit/posix/src/clocksetenableattr.c
===================================================================
--- cpukit/posix/src/clocksetenableattr.c	(revision 75b571311ac789d838379aad686f53754da7ab18)
+++ cpukit/posix/src/clocksetenableattr.c	(revision 8d8daef461194021e0df6cdc3140a1d124d140e4)
@@ -28,4 +28,4 @@
 )
 {
-  return POSIX_NOT_IMPLEMENTED();
+  rtems_set_errno_and_return_minus_one( ENOSYS );
 }
Index: cpukit/posix/src/clocksettime.c
===================================================================
--- cpukit/posix/src/clocksettime.c	(revision 75b571311ac789d838379aad686f53754da7ab18)
+++ cpukit/posix/src/clocksettime.c	(revision 8d8daef461194021e0df6cdc3140a1d124d140e4)
@@ -43,5 +43,5 @@
 #ifdef _POSIX_CPUTIME
     case CLOCK_PROCESS_CPUTIME:
-      return POSIX_NOT_IMPLEMENTED();
+      rtems_set_errno_and_return_minus_one( ENOSYS );
       break;
 #endif
@@ -49,5 +49,5 @@
 #ifdef _POSIX_THREAD_CPUTIME
     case CLOCK_THREAD_CPUTIME:
-      return POSIX_NOT_IMPLEMENTED();
+      rtems_set_errno_and_return_minus_one( ENOSYS );
       break;
 #endif
Index: cpukit/posix/src/devctl.c
===================================================================
--- cpukit/posix/src/devctl.c	(revision 75b571311ac789d838379aad686f53754da7ab18)
+++ cpukit/posix/src/devctl.c	(revision 8d8daef461194021e0df6cdc3140a1d124d140e4)
@@ -8,6 +8,8 @@
 
 #include <devctl.h>
+#include <errno.h>
 
 #include <rtems/system.h>
+#include <rtems/seterr.h>
 
 /*PAGE
@@ -23,4 +25,4 @@
 )
 {
-  return POSIX_NOT_IMPLEMENTED();
+  rtems_set_errno_and_return_minus_one( ENOSYS );
 }
Index: cpukit/posix/src/pthreadcreate.c
===================================================================
--- cpukit/posix/src/pthreadcreate.c	(revision 75b571311ac789d838379aad686f53754da7ab18)
+++ cpukit/posix/src/pthreadcreate.c	(revision 8d8daef461194021e0df6cdc3140a1d124d140e4)
@@ -59,5 +59,5 @@
 #if 0
   int  cputime_clock_allowed;  /* see time.h */
-  POSIX_NOT_IMPLEMENTED();
+  rtems_set_errno_and_return_minus_one( ENOSYS );
 #endif
 
Index: cpukit/posix/src/pthreadgetcpuclockid.c
===================================================================
--- cpukit/posix/src/pthreadgetcpuclockid.c	(revision 75b571311ac789d838379aad686f53754da7ab18)
+++ cpukit/posix/src/pthreadgetcpuclockid.c	(revision 8d8daef461194021e0df6cdc3140a1d124d140e4)
@@ -20,4 +20,5 @@
 
 #include <rtems/system.h>
+#include <rtems/seterr.h>
 
 int pthread_getcpuclockid(
@@ -26,4 +27,4 @@
 )
 {
-  return POSIX_NOT_IMPLEMENTED();
+  rtems_set_errno_and_return_minus_one( ENOSYS );
 }
Index: cpukit/posix/src/types.c
===================================================================
--- cpukit/posix/src/types.c	(revision 75b571311ac789d838379aad686f53754da7ab18)
+++ cpukit/posix/src/types.c	(revision 8d8daef461194021e0df6cdc3140a1d124d140e4)
@@ -18,17 +18,2 @@
 #include <rtems/seterr.h>
 
-/*
- * TEMPORARY
- */
-
-#include <assert.h>
-
-int POSIX_NOT_IMPLEMENTED()
-{
-  assert( 0 );
-  return 0;
-}
-
-/*
- * END OF TEMPORARY
- */
Index: cpukit/rtems/preinstall.am
===================================================================
--- cpukit/rtems/preinstall.am	(revision 75b571311ac789d838379aad686f53754da7ab18)
+++ cpukit/rtems/preinstall.am	(revision 8d8daef461194021e0df6cdc3140a1d124d140e4)
@@ -9,8 +9,18 @@
 DISTCLEANFILES = $(PREINSTALL_DIRS)
 
+all-local: $(TMPINSTALL_FILES)
+
+TMPINSTALL_FILES =
+CLEANFILES = $(TMPINSTALL_FILES)
+
 all-am: $(PREINSTALL_FILES)
 
 PREINSTALL_FILES =
-CLEANFILES = $(PREINSTALL_FILES)
+CLEANFILES += $(PREINSTALL_FILES)
+
+$(PROJECT_LIB)/$(dirstamp):
+	@$(MKDIR_P) $(PROJECT_LIB)
+	@: > $(PROJECT_LIB)/$(dirstamp)
+PREINSTALL_DIRS += $(PROJECT_LIB)/$(dirstamp)
 
 $(PROJECT_INCLUDE)/$(dirstamp):
@@ -18,4 +28,8 @@
 	@: > $(PROJECT_INCLUDE)/$(dirstamp)
 PREINSTALL_DIRS += $(PROJECT_INCLUDE)/$(dirstamp)
+
+$(PROJECT_LIB)/librtems.a: librtems.a $(PROJECT_LIB)/$(dirstamp)
+	$(INSTALL_DATA) $< $(PROJECT_LIB)/librtems.a
+TMPINSTALL_FILES += $(PROJECT_LIB)/librtems.a
 
 $(PROJECT_INCLUDE)/rtems.h: include/rtems.h $(PROJECT_INCLUDE)/$(dirstamp)
Index: cpukit/sapi/Makefile.am
===================================================================
--- cpukit/sapi/Makefile.am	(revision 75b571311ac789d838379aad686f53754da7ab18)
+++ cpukit/sapi/Makefile.am	(revision 8d8daef461194021e0df6cdc3140a1d124d140e4)
@@ -20,4 +20,5 @@
 AM_CPPFLAGS += -D__RTEMS_INSIDE__
 
+project_lib_LIBRARIES = libsapi.a
 noinst_LIBRARIES = libsapi.a
 libsapi_a_SOURCES = src/debug.c src/extension.c src/extensioncreate.c \
Index: cpukit/sapi/preinstall.am
===================================================================
--- cpukit/sapi/preinstall.am	(revision 75b571311ac789d838379aad686f53754da7ab18)
+++ cpukit/sapi/preinstall.am	(revision 8d8daef461194021e0df6cdc3140a1d124d140e4)
@@ -9,8 +9,18 @@
 DISTCLEANFILES = $(PREINSTALL_DIRS)
 
+all-local: $(TMPINSTALL_FILES)
+
+TMPINSTALL_FILES =
+CLEANFILES = $(TMPINSTALL_FILES)
+
 all-am: $(PREINSTALL_FILES)
 
 PREINSTALL_FILES =
-CLEANFILES = $(PREINSTALL_FILES)
+CLEANFILES += $(PREINSTALL_FILES)
+
+$(PROJECT_LIB)/$(dirstamp):
+	@$(MKDIR_P) $(PROJECT_LIB)
+	@: > $(PROJECT_LIB)/$(dirstamp)
+PREINSTALL_DIRS += $(PROJECT_LIB)/$(dirstamp)
 
 $(PROJECT_INCLUDE)/rtems/$(dirstamp):
@@ -55,2 +65,6 @@
 PREINSTALL_FILES += $(PROJECT_INCLUDE)/rtems/extension.inl
 
+$(PROJECT_LIB)/libsapi.a: libsapi.a $(PROJECT_LIB)/$(dirstamp)
+	$(INSTALL_DATA) $< $(PROJECT_LIB)/libsapi.a
+TMPINSTALL_FILES += $(PROJECT_LIB)/libsapi.a
+
Index: cpukit/score/Makefile.am
===================================================================
--- cpukit/score/Makefile.am	(revision 75b571311ac789d838379aad686f53754da7ab18)
+++ cpukit/score/Makefile.am	(revision 8d8daef461194021e0df6cdc3140a1d124d140e4)
@@ -65,4 +65,5 @@
 AM_CPPFLAGS += -D__RTEMS_INSIDE__
 
+project_lib_LIBRARIES = libscore.a
 noinst_LIBRARIES = libscore.a
 libscore_a_SOURCES =
Index: cpukit/score/preinstall.am
===================================================================
--- cpukit/score/preinstall.am	(revision 75b571311ac789d838379aad686f53754da7ab18)
+++ cpukit/score/preinstall.am	(revision 8d8daef461194021e0df6cdc3140a1d124d140e4)
@@ -9,8 +9,18 @@
 DISTCLEANFILES += $(PREINSTALL_DIRS)
 
+all-local: $(TMPINSTALL_FILES)
+
+TMPINSTALL_FILES =
+CLEANFILES = $(TMPINSTALL_FILES)
+
 all-am: $(PREINSTALL_FILES)
 
 PREINSTALL_FILES =
-CLEANFILES = $(PREINSTALL_FILES)
+CLEANFILES += $(PREINSTALL_FILES)
+
+$(PROJECT_LIB)/$(dirstamp):
+	@$(MKDIR_P) $(PROJECT_LIB)
+	@: > $(PROJECT_LIB)/$(dirstamp)
+PREINSTALL_DIRS += $(PROJECT_LIB)/$(dirstamp)
 
 $(PROJECT_INCLUDE)/rtems/$(dirstamp):
@@ -274,2 +284,6 @@
 PREINSTALL_FILES += $(PROJECT_INCLUDE)/rtems/score/threadmp.inl
 endif
+$(PROJECT_LIB)/libscore.a: libscore.a $(PROJECT_LIB)/$(dirstamp)
+	$(INSTALL_DATA) $< $(PROJECT_LIB)/libscore.a
+TMPINSTALL_FILES += $(PROJECT_LIB)/libscore.a
+
