On Fri, 2008-07-18 at 13:07 +0200, Manuel Teira wrote:
> Hello all.
> Unfortunately, I didn't have too much time to devote to this activity 
> later. Nevertheless, I was able to fix the last bug preventing the tests 
> to pass completely on my solaris build. The remaining problem was 
> submitted as QPID-1183.
> 
> So, I have a local copy with a set of uncommited changes, and I'm not 
> sure of the best way to proceed. Perhaps a categorization of the changes 
> should be a good beginning? So, I tell you what kind of changes are 
> needed (other than those already commited, or pending as JIRA patches), 
> and you could ask me to do it in a given way. As far as I remember now, 
> most changes can be categorized in this way:

I started looking for your changes today and realised that you haven't
submitted an actual patch.

I think what I'd like you to do is to submit a patch for these changes
as they are (to save you much more work) and I'll look at the patch,
change it where I think necessary and hopefully commit the port.

If you can be bothered to split the individual items below into
different jiras/patches that would help to keep each change in it's own
changeset, but if its too much work don't worry too much.

Andrew

> 
> 
> 1.- Missing include files. I think this shouldn't hurt the linux build, 
> and I think that these changes could be commited in a single patch.
> 
> 
> 2.- Some GNUishms in system calls. I think there're two cases for this:
>    2.1.- POSIX strerror_r doesn't return the buffer. Temporarily, I've 
> used a #ifndef clause, but I think that using the POSIX way everywhere 
> should be better:
> 
> #ifndef SUNOS
>      return std::string(strerror_r(err, buf, sizeof(buf)));
> #else
>     //POSIX strerror_r doesn't return the buffer
>     strerror_r(err, buf, sizeof(buf));
>     return std::string(buf);
>    
>    2.2. - pthread_yield is not POSIX compliant. Using sched_yield for 
> the Solaris version, with a #ifdef/#ifndef clause.
> 
> 3.- Solaris doesn't define the FTP and LOG_FTP syslog categories. Fixed 
> with a #ifdef/#ifndef clause.
> 
> 4.- The private inheritance bug in the solaris compiler 
> (http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6710638). Fixed with 
> a #ifdef/#ifndef to choose public inheritance when using the Sun 
> compiler as a workaround (I know, it stinks).
> 
> 5.- The Uuid.h solaris non-const members. I don't know why Solaris 
> doesn't define some arguments to these functions as constant, but they 
> produce compiler errors. The way I've fixed it was to use the dreaded 
> #ifndef constructions:
> 
> #ifdef SUNOS
>     uuid_unparse(const_cast<uint8_t*>(uuid.data()), unparsed);
> #else
>      uuid_unparse(uuid.data(), unparsed);
> #endif
> 
> 
> 6.- Some explicit namespacing. In some parts of the code, I needed to 
> specify the complete namespace for some calls. I don't know how it works 
> on linux, because in most cases, no 'using' clause should guarantee the 
> resolution of the namespace. It happened with some algorithms like 
> for_each or some boost functions. I just added the namespace when the 
> compiler complained.
> 
> 7.- Replace all the u_intN_t typenames with  uintN_t typenames. The 
> former ones are not available on solaris.
> 
> 8.- The queue issue. Some solaris header defines a struct name as 
> 'queue'. Usage of that name in constructions like:
> 
> session.queueDeclare(queue=q);
> session.messageSubscribe(queue=q, destination=dest, acquireMode=1);
> 
>   fires a compiler error, presumably because queue is a struct name. To 
> avoid that, I decided to change that usage to:
> 
> session.queueDeclare(arg::queue=q);
> session.messageSubscribe(arg::queue=q, arg::destination=dest, 
> arg::acquireMode=1);
> 
> Not the cleanest one, I know. Any idea to improve it?
> 
> 
> That's all, I think. Comments about the issues and the way the've been 
> fixed are welcomed.
> 
> 
> Proudly attaching a console output of the 'make check' command:
> 
> bash-3.00$ uname -a
> SunOS ps4000 5.10 Generic sun4u sparc SUNW,Sun-Fire-V210
> bash-3.00$ make check
> make  libshlibtest.la libdlclose_noop.la unit_test  perftest  txtest 
> latencytest client_test  topic_listener topic_publisher  publish consume
> `libshlibtest.la' is up to date.
> `libdlclose_noop.la' is up to date.
> `unit_test' is up to date.
> `perftest' is up to date.
> `txtest' is up to date.
> `latencytest' is up to date.
> `client_test' is up to date.
> `topic_listener' is up to date.
> `topic_publisher' is up to date.
> `publish' is up to date.
> `consume' is up to date.
> make  check-TESTS
> Running 155 test cases...
> 2008-jul-18 12:02:48 error Exception in client dispatch thread: 
> Connection closed by broker
> 
> *** No errors detected
> PASS: unit_test
> PASS: start_broker
> PASS: client_test
> 1779.01 1230.98 2658.65 2.59634
> PASS: quick_perftest
> PASS: quick_topictest
> sh: objdump: not found
> test_example (tests_0-10.example.ExampleTest) ... ok
> test_auto_rollback (tests_0-10.tx.TxTests) ... ok
> test_commit (tests_0-10.tx.TxTests) ... ok
> test_rollback (tests_0-10.tx.TxTests) ... ok
> test_broker_connectivity (tests_0-10.management.ManagementTest) ... ok
> test_self_session_id (tests_0-10.management.ManagementTest) ... ok
> test_standard_exchanges (tests_0-10.management.ManagementTest) ... ok
> test_system_object (tests_0-10.management.ManagementTest) ... ok
> test_bad_resume (tests_0-10.dtx.DtxTests) ... ok
> test_commit_unknown (tests_0-10.dtx.DtxTests) ... ok
> test_end (tests_0-10.dtx.DtxTests) ... ok
> test_end_suspend_and_fail (tests_0-10.dtx.DtxTests) ... ok
> test_end_unknown_xid (tests_0-10.dtx.DtxTests) ... ok
> test_forget_xid_on_completion (tests_0-10.dtx.DtxTests) ... ok
> test_get_timeout (tests_0-10.dtx.DtxTests) ... ok
> test_get_timeout_unknown (tests_0-10.dtx.DtxTests) ... ok
> test_implicit_end (tests_0-10.dtx.DtxTests) ... ok
> test_invalid_commit_not_ended (tests_0-10.dtx.DtxTests) ... ok
> test_invalid_commit_one_phase_false (tests_0-10.dtx.DtxTests) ... ok
> test_invalid_commit_one_phase_true (tests_0-10.dtx.DtxTests) ... ok
> test_invalid_prepare_not_ended (tests_0-10.dtx.DtxTests) ... ok
> test_invalid_rollback_not_ended (tests_0-10.dtx.DtxTests) ... ok
> test_prepare_unknown (tests_0-10.dtx.DtxTests) ... ok
> test_recover (tests_0-10.dtx.DtxTests) ... ok
> test_rollback_unknown (tests_0-10.dtx.DtxTests) ... ok
> test_select_required (tests_0-10.dtx.DtxTests) ... ok
> test_set_timeout (tests_0-10.dtx.DtxTests) ... ok
> test_simple_commit (tests_0-10.dtx.DtxTests) ... ok
> test_simple_prepare_commit (tests_0-10.dtx.DtxTests) ... ok
> test_simple_prepare_rollback (tests_0-10.dtx.DtxTests) ... ok
> test_simple_rollback (tests_0-10.dtx.DtxTests) ... ok
> test_start_already_known (tests_0-10.dtx.DtxTests) ... ok
> test_start_join (tests_0-10.dtx.DtxTests) ... ok
> test_start_join_and_resume (tests_0-10.dtx.DtxTests) ... ok
> test_suspend_resume (tests_0-10.dtx.DtxTests) ... ok
> test_suspend_start_end_resume (tests_0-10.dtx.DtxTests) ... ok
> test_delete_while_used_by_exchange 
> (tests_0-10.alternate_exchange.AlternateExchangeTests) ... ok
> test_delete_while_used_by_queue 
> (tests_0-10.alternate_exchange.AlternateExchangeTests) ... ok
> test_queue_delete (tests_0-10.alternate_exchange.AlternateExchangeTests) 
> ... ok
> test_unroutable (tests_0-10.alternate_exchange.AlternateExchangeTests) 
> ... ok
> test (tests_0-10.exchange.DeclareMethodPassiveFieldNotFoundRuleTests) ... ok
> testDefaultExchange (tests_0-10.exchange.DefaultExchangeRuleTests) ... ok
> testHeadersBindNoMatchArg (tests_0-10.exchange.ExchangeTests) ... ok
> testMatchAll (tests_0-10.exchange.HeadersExchangeTests) ... ok
> testMatchAny (tests_0-10.exchange.HeadersExchangeTests) ... ok
> testDifferentDeclaredType (tests_0-10.exchange.MiscellaneousErrorsTests) 
> ... ok
> testTypeNotKnown (tests_0-10.exchange.MiscellaneousErrorsTests) ... ok
> testDirect (tests_0-10.exchange.RecommendedTypesRuleTests) ... ok
> testFanout (tests_0-10.exchange.RecommendedTypesRuleTests) ... ok
> testHeaders (tests_0-10.exchange.RecommendedTypesRuleTests) ... ok
> testTopic (tests_0-10.exchange.RecommendedTypesRuleTests) ... ok
> testAmqDirect (tests_0-10.exchange.RequiredInstancesRuleTests) ... ok
> testAmqFanOut (tests_0-10.exchange.RequiredInstancesRuleTests) ... ok
> testAmqMatch (tests_0-10.exchange.RequiredInstancesRuleTests) ... ok
> testAmqTopic (tests_0-10.exchange.RequiredInstancesRuleTests) ... ok
> test_ack_and_no_ack (tests_0-10.broker.BrokerTests) ... ok
> test_simple_delivery_immediate (tests_0-10.broker.BrokerTests) ... ok
> test_simple_delivery_queued (tests_0-10.broker.BrokerTests) ... ok
> test_ack (tests_0-10.message.MessageTests) ... ok
> test_acquire (tests_0-10.message.MessageTests) ... ok
> test_acquire_with_no_accept_and_credit_flow 
> (tests_0-10.message.MessageTests) ... ok
> test_cancel (tests_0-10.message.MessageTests) ... ok
> test_consume_exclusive (tests_0-10.message.MessageTests) ... ok
> test_consume_exclusive2 (tests_0-10.message.MessageTests) ... ok
> test_consume_queue_not_found (tests_0-10.message.MessageTests) ... ok
> test_consume_queue_not_specified (tests_0-10.message.MessageTests) ... ok
> test_consume_unique_consumers (tests_0-10.message.MessageTests) ... ok
> test_credit_flow_bytes (tests_0-10.message.MessageTests) ... ok
> test_credit_flow_messages (tests_0-10.message.MessageTests) ... ok
> test_empty_body (tests_0-10.message.MessageTests) ... ok
> test_incoming_start (tests_0-10.message.MessageTests) ... ok
> test_no_local (tests_0-10.message.MessageTests) ... ok
> test_no_local_awkward (tests_0-10.message.MessageTests) ... ok
> test_no_local_exclusive_subscribe (tests_0-10.message.MessageTests) ... ok
> test_ranged_ack (tests_0-10.message.MessageTests) ... ok
> test_reject (tests_0-10.message.MessageTests) ... ok
> test_release (tests_0-10.message.MessageTests) ... ok
> test_release_ordering (tests_0-10.message.MessageTests) ... ok
> test_release_unacquired (tests_0-10.message.MessageTests) ... ok
> test_subscribe_not_acquired (tests_0-10.message.MessageTests) ... ok
> test_subscribe_not_acquired_2 (tests_0-10.message.MessageTests) ... ok
> test_subscribe_not_acquired_3 (tests_0-10.message.MessageTests) ... ok
> test_window_flow_bytes (tests_0-10.message.MessageTests) ... ok
> test_window_flow_messages (tests_0-10.message.MessageTests) ... ok
> test_ack_message_from_deleted_queue 
> (tests_0-10.persistence.PersistenceTests) ... ok
> test_delete_queue_after_publish 
> (tests_0-10.persistence.PersistenceTests) ... ok
> test_queue_deletion (tests_0-10.persistence.PersistenceTests) ... ok
> test_autodelete_shared (tests_0-10.queue.QueueTests) ... ok
> test_bind (tests_0-10.queue.QueueTests) ... ok
> test_bind_queue_existence (tests_0-10.queue.QueueTests) ... ok
> test_declare_exclusive (tests_0-10.queue.QueueTests) ... ok
> test_declare_passive (tests_0-10.queue.QueueTests) ... ok
> test_delete_ifempty (tests_0-10.queue.QueueTests) ... ok
> test_delete_ifunused (tests_0-10.queue.QueueTests) ... ok
> test_delete_queue_exists (tests_0-10.queue.QueueTests) ... ok
> test_delete_simple (tests_0-10.queue.QueueTests) ... ok
> test_purge (tests_0-10.queue.QueueTests) ... ok
> test_purge_empty_name (tests_0-10.queue.QueueTests) ... ok
> test_purge_queue_exists (tests_0-10.queue.QueueTests) ... ok
> test_unbind_direct (tests_0-10.queue.QueueTests) ... ok
> test_unbind_fanout (tests_0-10.queue.QueueTests) ... ok
> test_unbind_headers (tests_0-10.queue.QueueTests) ... ok
> test_unbind_topic (tests_0-10.queue.QueueTests) ... ok
> test_exchange_bound_direct (tests_0-10.query.QueryTests) ... ok
> test_exchange_bound_fanout (tests_0-10.query.QueryTests) ... ok
> test_exchange_bound_header (tests_0-10.query.QueryTests) ... ok
> test_exchange_bound_topic (tests_0-10.query.QueryTests) ... ok
> test_exchange_query (tests_0-10.query.QueryTests) ... ok
> test_queue_query (tests_0-10.query.QueryTests) ... ok
> test_queue_query_unknown (tests_0-10.query.QueryTests) ... ok
> 
> ----------------------------------------------------------------------
> Ran 110 tests in 86.495s
> 
> OK
> PASS: python_tests
> PASS: stop_broker
> Running federation tests using brokers on ports 46788 46789
> sh: objdump: not found
> test_bridge_create_and_close (federation.FederationTests) ... ok
> test_pull_from_exchange (federation.FederationTests) ... ok
> test_pull_from_queue (federation.FederationTests) ... ok
> test_tracing (federation.FederationTests) ... ok
> 
> ----------------------------------------------------------------------
> Ran 4 tests in 46.718s
> 
> OK
> PASS: run_federation_tests
> ==================
> All 8 tests passed
> ==================
> 
> 
> 

Reply via email to