You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-dev@axis.apache.org by "Ed Slattery (JIRA)" <ji...@apache.org> on 2006/03/23 13:44:19 UTC
[jira] Created: (AXIS2C-106) some problems building sample code
some problems building sample code
----------------------------------
Key: AXIS2C-106
URL: http://issues.apache.org/jira/browse/AXIS2C-106
Project: Axis2-C
Type: Bug
Versions: M0.5
Environment: windows
Reporter: Ed Slattery
Ive been using the samples as a base for testing use of OM. Ive had a number of problems which I guess others will meet.
1) The sample code cannot be built against the shipped binaries. I would have expected that it did.
The main reason is that the shipped header files drag in headers which are not shipped. To date I have needed
axis_string.h, axis_hash.h ,axis_log_default.h and axis_error_default.h
2) AXIS_DECLARE_DATA comes out as AXIS_IMPORT since I dont have any particular requirement to link statically.
This gives many warnings like:
__declspec(dllimport ) ' : ignored on left of 'struct axis2_thread_pool_ops' when no variable is declared.
Setting AXIS_DECLARE_DATA to be empty at line 141 of axis2_defines.h fixes this, but I dont know if thats the right thing to do.
3) I used a few lines from the OM tutorial (which is great), however, the code introduces an "env" parameter without explaining where to get it, so at first I had a lot of problems because its really an env**, not an env*. A few lines inserted in the tutorial from the echo sample would fix that.
My sample (which now runs):
extern "C" {
int main (int argc, char** argv)
{
/* general axis setup stuff */
axis2_status_t status = AXIS2_FAILURE;
axis2_env_t *env = NULL;
axis2_error_t *error = NULL;
axis2_log_t *log = NULL;
axis2_allocator_t *allocator = NULL;
allocator = axis2_allocator_init (NULL);
error = axis2_error_create(allocator);
log = axis2_log_create(allocator, NULL, "main.log");
env = axis2_env_create_with_error_log(allocator, error, log);
env->log->level = AXIS2_LOG_LEVEL_TRACE;
axis2_error_init();
axis2_om_node_t *my_node = NULL;
axis2_om_element_t *my_ele = NULL;
my_ele = axis2_om_element_create(&env, NULL, "MY_ELEMENT", NULL, &my_node);
printf("OM test done\n");
return 0;
}
}
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
[jira] Commented: (AXIS2C-106) some problems building sample code
Posted by "nandika jayawardana (JIRA)" <ji...@apache.org>.
[ http://issues.apache.org/jira/browse/AXIS2C-106?page=comments#action_12371718 ]
nandika jayawardana commented on AXIS2C-106:
--------------------------------------------
1. The Makefile shipped with M0.5 does not copy the header files as you have mentioned to includes. Thanks for pointing this out. This problem will be fixed in the next release.
2. You don't need to use calling conventions when creating standalone applications. So, you don't need to use the preprocessor directive . For creating the shipped dll's we used "AXIS2_DECLARE_EXPORT" preprocessor directive.
3. We will be improving the om tutorial in the next release. For the time being you can use the samples available in svn.
> some problems building sample code
> ----------------------------------
>
> Key: AXIS2C-106
> URL: http://issues.apache.org/jira/browse/AXIS2C-106
> Project: Axis2-C
> Type: Bug
> Versions: M0.5
> Environment: windows
> Reporter: Ed Slattery
>
> Ive been using the samples as a base for testing use of OM. Ive had a number of problems which I guess others will meet.
> 1) The sample code cannot be built against the shipped binaries. I would have expected that it did.
> The main reason is that the shipped header files drag in headers which are not shipped. To date I have needed
> axis_string.h, axis_hash.h ,axis_log_default.h and axis_error_default.h
> 2) AXIS_DECLARE_DATA comes out as AXIS_IMPORT since I dont have any particular requirement to link statically.
> This gives many warnings like:
> __declspec(dllimport ) ' : ignored on left of 'struct axis2_thread_pool_ops' when no variable is declared.
> Setting AXIS_DECLARE_DATA to be empty at line 141 of axis2_defines.h fixes this, but I dont know if thats the right thing to do.
> 3) I used a few lines from the OM tutorial (which is great), however, the code introduces an "env" parameter without explaining where to get it, so at first I had a lot of problems because its really an env**, not an env*. A few lines inserted in the tutorial from the echo sample would fix that.
> My sample (which now runs):
> extern "C" {
> int main (int argc, char** argv)
> {
> /* general axis setup stuff */
> axis2_status_t status = AXIS2_FAILURE;
> axis2_env_t *env = NULL;
> axis2_error_t *error = NULL;
> axis2_log_t *log = NULL;
> axis2_allocator_t *allocator = NULL;
>
> allocator = axis2_allocator_init (NULL);
> error = axis2_error_create(allocator);
> log = axis2_log_create(allocator, NULL, "main.log");
> env = axis2_env_create_with_error_log(allocator, error, log);
> env->log->level = AXIS2_LOG_LEVEL_TRACE;
> axis2_error_init();
> axis2_om_node_t *my_node = NULL;
> axis2_om_element_t *my_ele = NULL;
> my_ele = axis2_om_element_create(&env, NULL, "MY_ELEMENT", NULL, &my_node);
> printf("OM test done\n");
> return 0;
> }
> }
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
[jira] Commented: (AXIS2C-106) some problems building sample code
Posted by "Ed Slattery (JIRA)" <ji...@apache.org>.
[ http://issues.apache.org/jira/browse/AXIS2C-106?page=comments#action_12371563 ]
Ed Slattery commented on AXIS2C-106:
------------------------------------
Picky I know, but the OM tutorial sample code listing 2:
axis2_om_namespace_t *ns1 = NULL;
axis2_om_namespace_t *ns2 = NULL;
axis2_om_element_t* root_ele = NULL;
axis2_om_node_t* root_ele_node = NULL;
axis2_om_element_t *ele1 = NULL;
axis2_om_node_t *ele1_node = NULL;
ns1 = axis2_om_namespace_create(env, "bar", "x");
ns2 = axis2_om_namespace_create(env, "bar1", "y");
root_ele = axis2_om_element_create(env, NULL, "root", ns1, &root_ele_node);
ele1_node = axis2_om_element_create(env, root_node, "foo1", ns2, &ele1_node);
Would compile better if the last line was:
ele1 = axis2_om_element_create(&env, root_ele_node, "foo1", ns2, &ele1_node);
> some problems building sample code
> ----------------------------------
>
> Key: AXIS2C-106
> URL: http://issues.apache.org/jira/browse/AXIS2C-106
> Project: Axis2-C
> Type: Bug
> Versions: M0.5
> Environment: windows
> Reporter: Ed Slattery
>
> Ive been using the samples as a base for testing use of OM. Ive had a number of problems which I guess others will meet.
> 1) The sample code cannot be built against the shipped binaries. I would have expected that it did.
> The main reason is that the shipped header files drag in headers which are not shipped. To date I have needed
> axis_string.h, axis_hash.h ,axis_log_default.h and axis_error_default.h
> 2) AXIS_DECLARE_DATA comes out as AXIS_IMPORT since I dont have any particular requirement to link statically.
> This gives many warnings like:
> __declspec(dllimport ) ' : ignored on left of 'struct axis2_thread_pool_ops' when no variable is declared.
> Setting AXIS_DECLARE_DATA to be empty at line 141 of axis2_defines.h fixes this, but I dont know if thats the right thing to do.
> 3) I used a few lines from the OM tutorial (which is great), however, the code introduces an "env" parameter without explaining where to get it, so at first I had a lot of problems because its really an env**, not an env*. A few lines inserted in the tutorial from the echo sample would fix that.
> My sample (which now runs):
> extern "C" {
> int main (int argc, char** argv)
> {
> /* general axis setup stuff */
> axis2_status_t status = AXIS2_FAILURE;
> axis2_env_t *env = NULL;
> axis2_error_t *error = NULL;
> axis2_log_t *log = NULL;
> axis2_allocator_t *allocator = NULL;
>
> allocator = axis2_allocator_init (NULL);
> error = axis2_error_create(allocator);
> log = axis2_log_create(allocator, NULL, "main.log");
> env = axis2_env_create_with_error_log(allocator, error, log);
> env->log->level = AXIS2_LOG_LEVEL_TRACE;
> axis2_error_init();
> axis2_om_node_t *my_node = NULL;
> axis2_om_element_t *my_ele = NULL;
> my_ele = axis2_om_element_create(&env, NULL, "MY_ELEMENT", NULL, &my_node);
> printf("OM test done\n");
> return 0;
> }
> }
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
[jira] Closed: (AXIS2C-106) some problems building sample code
Posted by "Samisa Abeysinghe (JIRA)" <ji...@apache.org>.
[ http://issues.apache.org/jira/browse/AXIS2C-106?page=all ]
Samisa Abeysinghe closed AXIS2C-106:
------------------------------------
> some problems building sample code
> ----------------------------------
>
> Key: AXIS2C-106
> URL: http://issues.apache.org/jira/browse/AXIS2C-106
> Project: Axis2-C
> Type: Bug
> Versions: M0.5
> Environment: windows
> Reporter: Ed Slattery
> Fix For: 0.90
>
> Ive been using the samples as a base for testing use of OM. Ive had a number of problems which I guess others will meet.
> 1) The sample code cannot be built against the shipped binaries. I would have expected that it did.
> The main reason is that the shipped header files drag in headers which are not shipped. To date I have needed
> axis_string.h, axis_hash.h ,axis_log_default.h and axis_error_default.h
> 2) AXIS_DECLARE_DATA comes out as AXIS_IMPORT since I dont have any particular requirement to link statically.
> This gives many warnings like:
> __declspec(dllimport ) ' : ignored on left of 'struct axis2_thread_pool_ops' when no variable is declared.
> Setting AXIS_DECLARE_DATA to be empty at line 141 of axis2_defines.h fixes this, but I dont know if thats the right thing to do.
> 3) I used a few lines from the OM tutorial (which is great), however, the code introduces an "env" parameter without explaining where to get it, so at first I had a lot of problems because its really an env**, not an env*. A few lines inserted in the tutorial from the echo sample would fix that.
> My sample (which now runs):
> extern "C" {
> int main (int argc, char** argv)
> {
> /* general axis setup stuff */
> axis2_status_t status = AXIS2_FAILURE;
> axis2_env_t *env = NULL;
> axis2_error_t *error = NULL;
> axis2_log_t *log = NULL;
> axis2_allocator_t *allocator = NULL;
>
> allocator = axis2_allocator_init (NULL);
> error = axis2_error_create(allocator);
> log = axis2_log_create(allocator, NULL, "main.log");
> env = axis2_env_create_with_error_log(allocator, error, log);
> env->log->level = AXIS2_LOG_LEVEL_TRACE;
> axis2_error_init();
> axis2_om_node_t *my_node = NULL;
> axis2_om_element_t *my_ele = NULL;
> my_ele = axis2_om_element_create(&env, NULL, "MY_ELEMENT", NULL, &my_node);
> printf("OM test done\n");
> return 0;
> }
> }
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
[jira] Resolved: (AXIS2C-106) some problems building sample code
Posted by "Samisa Abeysinghe (JIRA)" <ji...@apache.org>.
[ http://issues.apache.org/jira/browse/AXIS2C-106?page=all ]
Samisa Abeysinghe resolved AXIS2C-106:
--------------------------------------
Fix Version: 0.9
Resolution: Fixed
This is fixed in the latest 0.90 release.
Thank you for testing with M0.5, please try with 0.90
> some problems building sample code
> ----------------------------------
>
> Key: AXIS2C-106
> URL: http://issues.apache.org/jira/browse/AXIS2C-106
> Project: Axis2-C
> Type: Bug
> Versions: M0.5
> Environment: windows
> Reporter: Ed Slattery
> Fix For: 0.9
>
> Ive been using the samples as a base for testing use of OM. Ive had a number of problems which I guess others will meet.
> 1) The sample code cannot be built against the shipped binaries. I would have expected that it did.
> The main reason is that the shipped header files drag in headers which are not shipped. To date I have needed
> axis_string.h, axis_hash.h ,axis_log_default.h and axis_error_default.h
> 2) AXIS_DECLARE_DATA comes out as AXIS_IMPORT since I dont have any particular requirement to link statically.
> This gives many warnings like:
> __declspec(dllimport ) ' : ignored on left of 'struct axis2_thread_pool_ops' when no variable is declared.
> Setting AXIS_DECLARE_DATA to be empty at line 141 of axis2_defines.h fixes this, but I dont know if thats the right thing to do.
> 3) I used a few lines from the OM tutorial (which is great), however, the code introduces an "env" parameter without explaining where to get it, so at first I had a lot of problems because its really an env**, not an env*. A few lines inserted in the tutorial from the echo sample would fix that.
> My sample (which now runs):
> extern "C" {
> int main (int argc, char** argv)
> {
> /* general axis setup stuff */
> axis2_status_t status = AXIS2_FAILURE;
> axis2_env_t *env = NULL;
> axis2_error_t *error = NULL;
> axis2_log_t *log = NULL;
> axis2_allocator_t *allocator = NULL;
>
> allocator = axis2_allocator_init (NULL);
> error = axis2_error_create(allocator);
> log = axis2_log_create(allocator, NULL, "main.log");
> env = axis2_env_create_with_error_log(allocator, error, log);
> env->log->level = AXIS2_LOG_LEVEL_TRACE;
> axis2_error_init();
> axis2_om_node_t *my_node = NULL;
> axis2_om_element_t *my_ele = NULL;
> my_ele = axis2_om_element_create(&env, NULL, "MY_ELEMENT", NULL, &my_node);
> printf("OM test done\n");
> return 0;
> }
> }
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira