From 1ea8fab0950144bdbfb304f11a248ceca1c56b10 Mon Sep 17 00:00:00 2001 From: George Bosilca Date: Tue, 25 Jul 2017 01:14:22 -0400 Subject: [PATCH] Make external symbols visible. All symbols that need to be accessed from a MCA component must be marked explicitly as visible using PMIX_EXPORT. This patch allows current trunk to almost work on OsX. More on the devel mailing list. Signed-off-by: George Bosilca --- .../pmix/pmix2x/pmix/src/class/pmix_hash_table.h | 2 +- opal/mca/pmix/pmix2x/pmix/src/class/pmix_list.h | 4 ++-- .../pmix2x/pmix/src/class/pmix_value_array.h | 2 +- .../pmix/src/mca/base/pmix_mca_base_framework.h | 14 +++++++------- .../pmix/pmix2x/pmix/src/mca/bfrops/base/base.h | 2 +- .../pmix2x/pmix/src/mca/bfrops/bfrops_types.h | 4 ++-- .../pmix/pmix2x/pmix/src/mca/preg/preg_types.h | 4 ++-- opal/mca/pmix/pmix2x/pmix/src/util/hash.h | 16 ++++++++-------- 8 files changed, 24 insertions(+), 24 deletions(-) diff --git a/opal/mca/pmix/pmix2x/pmix/src/class/pmix_hash_table.h b/opal/mca/pmix/pmix2x/pmix/src/class/pmix_hash_table.h index bef483e7a2..95ad39a4f8 100644 --- a/opal/mca/pmix/pmix2x/pmix/src/class/pmix_hash_table.h +++ b/opal/mca/pmix/pmix2x/pmix/src/class/pmix_hash_table.h @@ -47,7 +47,7 @@ BEGIN_C_DECLS -PMIX_CLASS_DECLARATION(pmix_hash_table_t); +PMIX_EXPORT PMIX_CLASS_DECLARATION(pmix_hash_table_t); struct pmix_hash_table_t { diff --git a/opal/mca/pmix/pmix2x/pmix/src/class/pmix_list.h b/opal/mca/pmix/pmix2x/pmix/src/class/pmix_list.h index bd5a89e1e4..df3f6a2280 100644 --- a/opal/mca/pmix/pmix2x/pmix/src/class/pmix_list.h +++ b/opal/mca/pmix/pmix2x/pmix/src/class/pmix_list.h @@ -83,13 +83,13 @@ BEGIN_C_DECLS * * The class for the list container. */ -PMIX_CLASS_DECLARATION(pmix_list_t); +PMIX_EXPORT PMIX_CLASS_DECLARATION(pmix_list_t); /** * \internal * * Base class for items that are put in list (pmix_list_t) containers. */ -PMIX_CLASS_DECLARATION(pmix_list_item_t); +PMIX_EXPORT PMIX_CLASS_DECLARATION(pmix_list_item_t); /** diff --git a/opal/mca/pmix/pmix2x/pmix/src/class/pmix_value_array.h b/opal/mca/pmix/pmix2x/pmix/src/class/pmix_value_array.h index 35910e8d25..f20579b82b 100644 --- a/opal/mca/pmix/pmix2x/pmix/src/class/pmix_value_array.h +++ b/opal/mca/pmix/pmix2x/pmix/src/class/pmix_value_array.h @@ -49,7 +49,7 @@ struct pmix_value_array_t }; typedef struct pmix_value_array_t pmix_value_array_t; -PMIX_CLASS_DECLARATION(pmix_value_array_t); +PMIX_EXPORT PMIX_CLASS_DECLARATION(pmix_value_array_t); /** * Initialize the array to hold items by value. This routine must diff --git a/opal/mca/pmix/pmix2x/pmix/src/mca/base/pmix_mca_base_framework.h b/opal/mca/pmix/pmix2x/pmix/src/mca/base/pmix_mca_base_framework.h index 79d8b0a049..3e4f3db910 100644 --- a/opal/mca/pmix/pmix2x/pmix/src/mca/base/pmix_mca_base_framework.h +++ b/opal/mca/pmix/pmix2x/pmix/src/mca/base/pmix_mca_base_framework.h @@ -169,8 +169,8 @@ typedef struct pmix_mca_base_framework_t { * * Call a framework's register function. */ -int pmix_mca_base_framework_register (pmix_mca_base_framework_t *framework, - pmix_mca_base_register_flag_t flags); +PMIX_EXPORT int pmix_mca_base_framework_register (pmix_mca_base_framework_t *framework, + pmix_mca_base_register_flag_t flags); /** * Open a framework @@ -182,8 +182,8 @@ int pmix_mca_base_framework_register (pmix_mca_base_framework_t *framework, * * Call a framework's open function. */ -int pmix_mca_base_framework_open (pmix_mca_base_framework_t *framework, - pmix_mca_base_open_flag_t flags); +PMIX_EXPORT int pmix_mca_base_framework_open (pmix_mca_base_framework_t *framework, + pmix_mca_base_open_flag_t flags); /** * Close a framework @@ -195,7 +195,7 @@ int pmix_mca_base_framework_open (pmix_mca_base_framework_t *framework, * * Call a framework's close function. */ -int pmix_mca_base_framework_close (pmix_mca_base_framework_t *framework); +PMIX_EXPORT int pmix_mca_base_framework_close (pmix_mca_base_framework_t *framework); /** @@ -206,7 +206,7 @@ int pmix_mca_base_framework_close (pmix_mca_base_framework_t *framework); * @retval true if the framework's mca variables are registered * @retval false if not */ -bool pmix_mca_base_framework_is_registered (struct pmix_mca_base_framework_t *framework); +PMIX_EXPORT bool pmix_mca_base_framework_is_registered (struct pmix_mca_base_framework_t *framework); /** @@ -217,7 +217,7 @@ bool pmix_mca_base_framework_is_registered (struct pmix_mca_base_framework_t *fr * @retval true if the framework is open * @retval false if not */ -bool pmix_mca_base_framework_is_open (struct pmix_mca_base_framework_t *framework); +PMIX_EXPORT bool pmix_mca_base_framework_is_open (struct pmix_mca_base_framework_t *framework); /** diff --git a/opal/mca/pmix/pmix2x/pmix/src/mca/bfrops/base/base.h b/opal/mca/pmix/pmix2x/pmix/src/mca/bfrops/base/base.h index 76bab62c35..8b24504b5b 100644 --- a/opal/mca/pmix/pmix2x/pmix/src/mca/bfrops/base/base.h +++ b/opal/mca/pmix/pmix2x/pmix/src/mca/bfrops/base/base.h @@ -177,7 +177,7 @@ PMIX_EXPORT extern pmix_bfrops_globals_t pmix_bfrops_globals; /** prpmix_status_t function */ pmix_bfrop_print_fn_t odti_print_fn; } pmix_bfrop_type_info_t; -PMIX_CLASS_DECLARATION(pmix_bfrop_type_info_t); +PMIX_EXPORT PMIX_CLASS_DECLARATION(pmix_bfrop_type_info_t); /* macro for registering data types - overwrite an existing * duplicate one based on type name */ diff --git a/opal/mca/pmix/pmix2x/pmix/src/mca/bfrops/bfrops_types.h b/opal/mca/pmix/pmix2x/pmix/src/mca/bfrops/bfrops_types.h index 6609bd9377..2eb7b96cc6 100644 --- a/opal/mca/pmix/pmix2x/pmix/src/mca/bfrops/bfrops_types.h +++ b/opal/mca/pmix/pmix2x/pmix/src/mca/bfrops/bfrops_types.h @@ -64,7 +64,7 @@ typedef struct { char *key; pmix_value_t *value; } pmix_kval_t; -PMIX_CLASS_DECLARATION(pmix_kval_t); +PMIX_EXPORT PMIX_CLASS_DECLARATION(pmix_kval_t); /** @@ -89,7 +89,7 @@ typedef struct { including overhead -- packed in the buffer) */ size_t bytes_used; } pmix_buffer_t; -PMIX_CLASS_DECLARATION(pmix_buffer_t); +PMIX_EXPORT PMIX_CLASS_DECLARATION(pmix_buffer_t); /* Convenience macro for loading a data blob into a pmix_buffer_t * diff --git a/opal/mca/pmix/pmix2x/pmix/src/mca/preg/preg_types.h b/opal/mca/pmix/pmix2x/pmix/src/mca/preg/preg_types.h index 95f0c5a2f2..9f1b8a8ae5 100644 --- a/opal/mca/pmix/pmix2x/pmix/src/mca/preg/preg_types.h +++ b/opal/mca/pmix/pmix2x/pmix/src/mca/preg/preg_types.h @@ -42,7 +42,7 @@ typedef struct { int start; int cnt; } pmix_regex_range_t; -PMIX_CLASS_DECLARATION(pmix_regex_range_t); +PMIX_EXPORT PMIX_CLASS_DECLARATION(pmix_regex_range_t); typedef struct { /* list object */ @@ -52,7 +52,7 @@ typedef struct { int num_digits; pmix_list_t ranges; } pmix_regex_value_t; -PMIX_CLASS_DECLARATION(pmix_regex_value_t); +PMIX_EXPORT PMIX_CLASS_DECLARATION(pmix_regex_value_t); END_C_DECLS diff --git a/opal/mca/pmix/pmix2x/pmix/src/util/hash.h b/opal/mca/pmix/pmix2x/pmix/src/util/hash.h index 057e9a803e..9685311a55 100644 --- a/opal/mca/pmix/pmix2x/pmix/src/util/hash.h +++ b/opal/mca/pmix/pmix2x/pmix/src/util/hash.h @@ -24,21 +24,21 @@ BEGIN_C_DECLS /* store a value in the given hash table for the specified * rank index.*/ -pmix_status_t pmix_hash_store(pmix_hash_table_t *table, - pmix_rank_t rank, pmix_kval_t *kv); +PMIX_EXPORT pmix_status_t pmix_hash_store(pmix_hash_table_t *table, + pmix_rank_t rank, pmix_kval_t *kv); /* Fetch the value for a specified key and rank from within * the given hash_table */ -pmix_status_t pmix_hash_fetch(pmix_hash_table_t *table, pmix_rank_t rank, - const char *key, pmix_value_t **kvs); +PMIX_EXPORT pmix_status_t pmix_hash_fetch(pmix_hash_table_t *table, pmix_rank_t rank, + const char *key, pmix_value_t **kvs); /* Fetch the value for a specified key from within * the given hash_table * It gets the next portion of data from table, where matching key. * To get the first data from table, function is called with key parameter as string. * Remaining data from table are obtained by calling function with a null pointer for the key parameter.*/ -pmix_status_t pmix_hash_fetch_by_key(pmix_hash_table_t *table, const char *key, - pmix_rank_t *rank, pmix_value_t **kvs, void **last); +PMIX_EXPORT pmix_status_t pmix_hash_fetch_by_key(pmix_hash_table_t *table, const char *key, + pmix_rank_t *rank, pmix_value_t **kvs, void **last); /* remove the specified key-value from the given hash_table. * A NULL key will result in removal of all data for the @@ -47,8 +47,8 @@ pmix_status_t pmix_hash_fetch_by_key(pmix_hash_table_t *table, const char *key, * ranks in the table. Combining key=NULL with rank=PMIX_RANK_WILDCARD * will therefore result in removal of all data from the * table */ -pmix_status_t pmix_hash_remove_data(pmix_hash_table_t *table, - pmix_rank_t rank, const char *key); +PMIX_EXPORT pmix_status_t pmix_hash_remove_data(pmix_hash_table_t *table, + pmix_rank_t rank, const char *key); END_C_DECLS