summaryrefslogtreecommitdiffstats
path: root/cpukit/sapi
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>1996-05-28 21:40:52 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>1996-05-28 21:40:52 +0000
commitc627b2a3a1ca1a6aca1c20e133db0f95a65a71fb (patch)
tree8b369a80629ad635519105f923e1ca5a2a2bc87c /cpukit/sapi
parentadded maximum keys (diff)
downloadrtems-c627b2a3a1ca1a6aca1c20e133db0f95a65a71fb.tar.bz2
split the inclusion of "EXTERN" data based on whether it was sapi,
score, rtems api, or posix api related.
Diffstat (limited to 'cpukit/sapi')
-rw-r--r--cpukit/sapi/include/rtems/config.h6
-rw-r--r--cpukit/sapi/include/rtems/extension.h2
-rw-r--r--cpukit/sapi/include/rtems/io.h8
-rw-r--r--cpukit/sapi/src/exinit.c11
-rw-r--r--cpukit/sapi/src/posixapi.c26
-rw-r--r--cpukit/sapi/src/rtemsapi.c9
6 files changed, 38 insertions, 24 deletions
diff --git a/cpukit/sapi/include/rtems/config.h b/cpukit/sapi/include/rtems/config.h
index 7ff0f9f485..19a8edeb0f 100644
--- a/cpukit/sapi/include/rtems/config.h
+++ b/cpukit/sapi/include/rtems/config.h
@@ -84,7 +84,7 @@ typedef struct {
rtems_extensions_table *User_extension_table;
rtems_multiprocessing_table *User_multiprocessing_table;
rtems_api_configuration_table *RTEMS_api_configuration;
- posix_api_configuration_table *Posix_api_configuration;
+ posix_api_configuration_table *POSIX_api_configuration;
} rtems_configuration_table;
/*
@@ -92,8 +92,8 @@ typedef struct {
* the user. They are not used in RTEMS itself.
*/
-EXTERN rtems_configuration_table *_Configuration_Table;
-EXTERN rtems_multiprocessing_table *_Configuration_MP_table;
+SAPI_EXTERN rtems_configuration_table *_Configuration_Table;
+SAPI_EXTERN rtems_multiprocessing_table *_Configuration_MP_table;
#ifdef __cplusplus
}
diff --git a/cpukit/sapi/include/rtems/extension.h b/cpukit/sapi/include/rtems/extension.h
index 8f46ed80dd..ed95339348 100644
--- a/cpukit/sapi/include/rtems/extension.h
+++ b/cpukit/sapi/include/rtems/extension.h
@@ -54,7 +54,7 @@ typedef User_extensions_Table rtems_extensions_table;
* this class of objects.
*/
-EXTERN Objects_Information _Extension_Information;
+SAPI_EXTERN Objects_Information _Extension_Information;
/*
* The following records define the control block used to manage
diff --git a/cpukit/sapi/include/rtems/io.h b/cpukit/sapi/include/rtems/io.h
index a7af4df792..01042ce762 100644
--- a/cpukit/sapi/include/rtems/io.h
+++ b/cpukit/sapi/include/rtems/io.h
@@ -86,10 +86,10 @@ typedef struct {
* Address Table and Device Name Table.
*/
-EXTERN unsigned32 _IO_Number_of_drivers;
-EXTERN rtems_driver_address_table *_IO_Driver_address_table;
-EXTERN unsigned32 _IO_Number_of_devices;
-EXTERN rtems_driver_name_t *_IO_Driver_name_table;
+SAPI_EXTERN unsigned32 _IO_Number_of_drivers;
+SAPI_EXTERN rtems_driver_address_table *_IO_Driver_address_table;
+SAPI_EXTERN unsigned32 _IO_Number_of_devices;
+SAPI_EXTERN rtems_driver_name_t *_IO_Driver_name_table;
/*
* _IO_Manager_initialization
diff --git a/cpukit/sapi/src/exinit.c b/cpukit/sapi/src/exinit.c
index 9e9f0d2040..442465dda4 100644
--- a/cpukit/sapi/src/exinit.c
+++ b/cpukit/sapi/src/exinit.c
@@ -13,11 +13,12 @@
*/
/*
- * INIT is defined so all of the data will be included in this
- * file.
+ * SCORE_INIT and SAPI_INIT are defined so all of the super core and
+ * super API data will be included in this object file.
*/
-#define INIT
+#define SAPI_INIT
+#define SCORE_INIT
#include <rtems/system.h>
#include <rtems/config.h>
@@ -44,7 +45,11 @@
#include <rtems/directives.h>
#include <rtems/sptables.h>
+
#include <rtems/rtems/rtemsapi.h>
+#ifdef RTEMS_POSIX_API
+#include <rtems/posix/posixapi.h>
+#endif
/*PAGE
*
diff --git a/cpukit/sapi/src/posixapi.c b/cpukit/sapi/src/posixapi.c
index 6efba79034..4ba236e42f 100644
--- a/cpukit/sapi/src/posixapi.c
+++ b/cpukit/sapi/src/posixapi.c
@@ -14,21 +14,27 @@
* $Id$
*/
+#ifdef RTEMS_POSIX_API
+
#include <assert.h>
-#include <rtems/system.h>
+/*
+ * POSIX_API_INIT is defined so all of the POSIX API
+ * data will be included in this object file.
+ */
-#define INIT
+#define POSIX_API_INIT
+#include <rtems/system.h>
+
+#include <sys/types.h>
+#include <rtems/config.h>
#include <rtems/posix/cond.h>
-#include <rtems/posix/condmp.h>
#include <rtems/posix/config.h>
#include <rtems/posix/key.h>
#include <rtems/posix/mutex.h>
-#include <rtems/posix/mutexmp.h>
#include <rtems/posix/priority.h>
#include <rtems/posix/pthread.h>
-#include <rtems/posix/pthreadmp.h>
#include <rtems/posix/time.h>
/*PAGE
@@ -48,20 +54,17 @@ void _POSIX_API_Initialize(
assert( api_configuration );
- _RTEMS_tasks_Manager_initialization(
- api_configuration->maximum_tasks
-#if 0
-,
+ _POSIX_Threads_Manager_initialization(
+ api_configuration->maximum_threads,
api_configuration->number_of_initialization_tasks,
api_configuration->User_initialization_tasks_table
-#endif
);
_POSIX_Condition_variables_Manager_initialization(
api_configuration->maximum_condition_variables
);
- void _POSIX_Key_Manager_initialization( api_configuration->maximum_keys );
+ _POSIX_Key_Manager_initialization( api_configuration->maximum_keys );
_POSIX_Mutex_Manager_initialization(
api_configuration->maximum_mutexes
@@ -69,4 +72,5 @@ void _POSIX_API_Initialize(
}
+#endif
/* end of file */
diff --git a/cpukit/sapi/src/rtemsapi.c b/cpukit/sapi/src/rtemsapi.c
index 0d1229a277..fe27507f2a 100644
--- a/cpukit/sapi/src/rtemsapi.c
+++ b/cpukit/sapi/src/rtemsapi.c
@@ -14,12 +14,17 @@
* $Id$
*/
+/*
+ * RTEMS_API_INIT is defined so all of the RTEMS API
+ * data will be included in this object file.
+ */
+
+#define RTEMS_API_INIT
+
#include <rtems/system.h>
#include <rtems/rtems/status.h>
#include <rtems/rtems/rtemsapi.h>
-#define INIT
-
#include <rtems/rtems/intr.h>
#include <rtems/rtems/clock.h>
#include <rtems/rtems/tasks.h>