summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohnny Willemsen <jwillemsen@remedy.nl>2008-11-26 15:05:38 +0000
committerJohnny Willemsen <jwillemsen@remedy.nl>2008-11-26 15:05:38 +0000
commit079b1386812db53bc072cddba209141d44e4a0eb (patch)
treed15212f1731f3d4502cd4d576a37296abec678c9
parent7540dd7c4042b380a51e2da900e792e4159d6154 (diff)
downloadATCD-079b1386812db53bc072cddba209141d44e4a0eb.tar.gz
Wed Nov 26 15:04:57 UTC 2008 Johnny Willemsen <jwillemsen@remedy.nl>
-rw-r--r--flat/CIAO/CIDLC/ExecutorMappingGenerator.cpp2
-rw-r--r--flat/CIAO/ChangeLog32
-rw-r--r--flat/CIAO/DAnCE/tests/NameServiceTest/Dummy.idl7
-rw-r--r--flat/CIAO/DAnCE/tests/NameServiceTest/NameServiceTest.mpc43
-rw-r--r--flat/CIAO/DAnCE/tests/NameServiceTest/clt_main.cpp6
-rwxr-xr-xflat/CIAO/DAnCE/tests/NameServiceTest/run_test.pl73
-rw-r--r--flat/CIAO/DAnCE/tests/RedirectionServiceTest/srv_main.cpp1
-rw-r--r--flat/CIAO/ciao/ComponentServer/Configurators/NoOp/NoOp_Configurator.mpc3
-rw-r--r--flat/CIAO/ciao/Contexts/Swapping/CIAO_UpgradeableContext.idl2
-rw-r--r--flat/CIAO/examples/Swapping/Receiver/Receiver.mpc19
-rw-r--r--flat/CIAO/ofccm/NodeApplication/NodeApplication_Impl.h2
-rw-r--r--flat/CIAO/tests/CIAO_ComponentServer/Basic/client.cpp38
-rw-r--r--flat/CIAO/tests/CIAO_ComponentServer/SimpleComponent/SimpleComponent.mpc30
13 files changed, 184 insertions, 74 deletions
diff --git a/flat/CIAO/CIDLC/ExecutorMappingGenerator.cpp b/flat/CIAO/CIDLC/ExecutorMappingGenerator.cpp
index 6ffb7c23dfe..e5aa0a8b445 100644
--- a/flat/CIAO/CIDLC/ExecutorMappingGenerator.cpp
+++ b/flat/CIAO/CIDLC/ExecutorMappingGenerator.cpp
@@ -1940,7 +1940,7 @@ generate (CommandLine const& cl,
if (swapping)
{
- os << "#include <CIAO_UpgradeableContext.idl>" << endl;
+ os << "#include <ciao/Contexts/Swapping/CIAO_UpgradeableContext.idl>" << endl;
}
Traversal::TranslationUnit unit;
diff --git a/flat/CIAO/ChangeLog b/flat/CIAO/ChangeLog
index 4161ff178ec..daa935f4677 100644
--- a/flat/CIAO/ChangeLog
+++ b/flat/CIAO/ChangeLog
@@ -1,3 +1,35 @@
+Wed Nov 26 15:04:57 UTC 2008 Johnny Willemsen <jwillemsen@remedy.nl>
+
+ * ciao/ComponentServer/Configurators/NoOp/NoOp_Configurator.mpc:
+ Added dynamic flags
+
+ * ciao/Contexts/Swapping/CIAO_UpgradeableContext.idl:
+ Updated include
+
+ * CIDLC/ExecutorMappingGenerator.cpp:
+ Update the include being generated
+
+ * DAnCE/tests/NameServiceTest/clt_main.cpp:
+ * DAnCE/tests/NameServiceTest/Dummy.idl:
+ * DAnCE/tests/NameServiceTest/NameServiceTest.mpc:
+ * DAnCE/tests/NameServiceTest/run_test.pl:
+ Cleanup and wchar
+
+ * DAnCE/tests/RedirectionServiceTest/srv_main.cpp:
+ Fixed warning
+
+ * examples/Swapping/Receiver/Receiver.mpc:
+ Disabled some projects
+
+ * ofccm/NodeApplication/NodeApplication_Impl.h:
+ Updated include
+
+ * tests/CIAO_ComponentServer/Basic/client.cpp:
+ Unicode changes
+
+ * tests/CIAO_ComponentServer/SimpleComponent/SimpleComponent.mpc:
+ Updated
+
Wed Nov 26 14:22:57 UTC 2008 Johnny Willemsen <jwillemsen@remedy.nl>
* DAnCE/TargetManager/TargetManager.mpc:
diff --git a/flat/CIAO/DAnCE/tests/NameServiceTest/Dummy.idl b/flat/CIAO/DAnCE/tests/NameServiceTest/Dummy.idl
index 9f03be4188f..1f0edee59cd 100644
--- a/flat/CIAO/DAnCE/tests/NameServiceTest/Dummy.idl
+++ b/flat/CIAO/DAnCE/tests/NameServiceTest/Dummy.idl
@@ -1,12 +1,13 @@
+// $Id$
#ifndef DUMMY_IDL
#define DUMMY_IDL
module NameServiceTest
{
- interface Dummy {
- string sayHello();
- };
+ interface Dummy {
+ string sayHello();
+ };
};
#endif /* DUMMY_IDL */
diff --git a/flat/CIAO/DAnCE/tests/NameServiceTest/NameServiceTest.mpc b/flat/CIAO/DAnCE/tests/NameServiceTest/NameServiceTest.mpc
index 695fa177909..091c461d669 100644
--- a/flat/CIAO/DAnCE/tests/NameServiceTest/NameServiceTest.mpc
+++ b/flat/CIAO/DAnCE/tests/NameServiceTest/NameServiceTest.mpc
@@ -1,25 +1,30 @@
+// $Id$
-project (*NameServiceTestServer): dance, taoserver, iortable, naming_serv, dance_logger {
- exename = NameServiceTestServer
-
- IDL_Files {
- Dummy.idl
- }
+project(*idl): taoidldefaults {
+ IDL_Files {
+ Dummy.idl
+ }
+ custom_only = 1
+}
- Source_Files {
- srv_main.cpp
- DummyC.cpp
- DummyS.cpp
- DummyImpl.cpp
- }
+project (*NameServiceTestServer): dance, taoserver, iortable, naming_serv, dance_logger {
+ after += *idl
+ IDL_Files {
+ }
+ Source_Files {
+ srv_main.cpp
+ DummyC.cpp
+ DummyS.cpp
+ DummyImpl.cpp
+ }
}
project (NameServiceTestClient): dance, taoclient, naming, dance_logger {
- after = *NameServiceTestServer
- exename = NameServiceTestClient
-
- Source_Files {
- clt_main.cpp
- DummyC.cpp
- }
+ after += *idl
+ IDL_Files {
+ }
+ Source_Files {
+ clt_main.cpp
+ DummyC.cpp
+ }
}
diff --git a/flat/CIAO/DAnCE/tests/NameServiceTest/clt_main.cpp b/flat/CIAO/DAnCE/tests/NameServiceTest/clt_main.cpp
index 9ecbf355c11..f25da11c9bd 100644
--- a/flat/CIAO/DAnCE/tests/NameServiceTest/clt_main.cpp
+++ b/flat/CIAO/DAnCE/tests/NameServiceTest/clt_main.cpp
@@ -8,7 +8,7 @@
using namespace NameServiceTest;
-int main (int argc, char * argv[])
+int ACE_TMAIN (int argc, ACE_TCHAR * argv[])
{
try
{
@@ -66,11 +66,11 @@ int main (int argc, char * argv[])
}
DANCE_DEBUG((LM_DEBUG, "[%M] object -> dummy : ok.\n"));
- DANCE_DEBUG((LM_DEBUG, "[%M] Dummy object returned : %s.", dummy_obj->sayHello()));
+ DANCE_DEBUG((LM_DEBUG, "[%M] Dummy object returned : %C.", dummy_obj->sayHello()));
DANCE_DEBUG((LM_DEBUG, "[%M] The test succeeded."));
return 0;
}
- catch (CORBA::Exception & e)
+ catch (const CORBA::Exception & e)
{
DANCE_ERROR((LM_ERROR, "[%M] A CORBA exception \"%s\" (%s) was thrown. The test failed."
, e._name(), e._info().c_str()));
diff --git a/flat/CIAO/DAnCE/tests/NameServiceTest/run_test.pl b/flat/CIAO/DAnCE/tests/NameServiceTest/run_test.pl
new file mode 100755
index 00000000000..719974e5c50
--- /dev/null
+++ b/flat/CIAO/DAnCE/tests/NameServiceTest/run_test.pl
@@ -0,0 +1,73 @@
+eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}'
+ & eval 'exec perl -S $0 $argv:q'
+ if 0;
+
+# $Id$
+# -*- perl -*-
+
+use lib "$ENV{ACE_ROOT}/bin";
+use PerlACE::TestTarget;
+
+$status = 0;
+$debug_level = '0';
+
+foreach $i (@ARGV) {
+ if ($i eq '-debug') {
+ $debug_level = '10';
+ }
+}
+
+my $server = PerlACE::TestTarget::create_target (1) || die "Create target 1 failed\n";
+my $client = PerlACE::TestTarget::create_target (2) || die "Create target 2 failed\n";
+
+my $iorbase = "server.ior";
+my $server_iorfile = $server->LocalFile ($iorbase);
+my $client_iorfile = $client->LocalFile ($iorbase);
+$server->DeleteFile($iorbase);
+$client->DeleteFile($iorbase);
+
+$SV = $server->CreateProcess ("server", "-ORBdebuglevel $debug_level -o $server_iorfile");
+$CL = $client->CreateProcess ("client", "-k file://$client_iorfile");
+$server_status = $SV->Spawn ();
+
+if ($server_status != 0) {
+ print STDERR "ERROR: server returned $server_status\n";
+ exit 1;
+}
+
+if ($server->WaitForFileTimed ($iorbase,
+ $server->ProcessStartWaitInterval()) == -1) {
+ print STDERR "ERROR: cannot find file <$server_iorfile>\n";
+ $SV->Kill (); $SV->TimedWait (1);
+ exit 1;
+}
+
+if ($server->GetFile ($iorbase) == -1) {
+ print STDERR "ERROR: cannot retrieve file <$server_iorfile>\n";
+ $SV->Kill (); $SV->TimedWait (1);
+ exit 1;
+}
+if ($client->PutFile ($iorbase) == -1) {
+ print STDERR "ERROR: cannot set file <$client_iorfile>\n";
+ $SV->Kill (); $SV->TimedWait (1);
+ exit 1;
+}
+
+$client_status = $CL->SpawnWaitKill ($client->ProcessStartWaitInterval());
+
+if ($client_status != 0) {
+ print STDERR "ERROR: client returned $client_status\n";
+ $status = 1;
+}
+
+$server_status = $SV->WaitKill ($server->ProcessStopWaitInterval());
+
+if ($server_status != 0) {
+ print STDERR "ERROR: server returned $server_status\n";
+ $status = 1;
+}
+
+$server->DeleteFile($iorbase);
+$client->DeleteFile($iorbase);
+
+exit $status;
diff --git a/flat/CIAO/DAnCE/tests/RedirectionServiceTest/srv_main.cpp b/flat/CIAO/DAnCE/tests/RedirectionServiceTest/srv_main.cpp
index 06ce907b82e..c4d53236506 100644
--- a/flat/CIAO/DAnCE/tests/RedirectionServiceTest/srv_main.cpp
+++ b/flat/CIAO/DAnCE/tests/RedirectionServiceTest/srv_main.cpp
@@ -62,5 +62,6 @@ int main (int argc, char * argv[])
// {
// DANCE_ERROR((LM_ERROR, "[%M] An error has occured."));
// }
+ return 0;
}
diff --git a/flat/CIAO/ciao/ComponentServer/Configurators/NoOp/NoOp_Configurator.mpc b/flat/CIAO/ciao/ComponentServer/Configurators/NoOp/NoOp_Configurator.mpc
index 8924e3bcf14..9bd13b08b33 100644
--- a/flat/CIAO/ciao/ComponentServer/Configurators/NoOp/NoOp_Configurator.mpc
+++ b/flat/CIAO/ciao/ComponentServer/Configurators/NoOp/NoOp_Configurator.mpc
@@ -1,11 +1,10 @@
project(CIAO_NoOp_Configurator) : ccm_stub, ciao_componentserver_stub, ciao_lib {
after += CIAO_Basic_Configurator
libs += CIAO_Basic_Configurator
-
+ dynamicflags = NOOP_CONFIGURATOR_BUILD_DLL
Source_Files {
NoOp_Configurator.cpp
}
-
Header_Files {
NoOp_Configurator.h
}
diff --git a/flat/CIAO/ciao/Contexts/Swapping/CIAO_UpgradeableContext.idl b/flat/CIAO/ciao/Contexts/Swapping/CIAO_UpgradeableContext.idl
index 6d4b315ae85..98bb309d39c 100644
--- a/flat/CIAO/ciao/Contexts/Swapping/CIAO_UpgradeableContext.idl
+++ b/flat/CIAO/ciao/Contexts/Swapping/CIAO_UpgradeableContext.idl
@@ -1,6 +1,6 @@
// $Id$
-#include "ciao/CCM_Container.idl"
+#include "ccm/CCM_Container.idl"
#include "tao/PortableServer/PortableServer_include.pidl"
module CIAO
diff --git a/flat/CIAO/examples/Swapping/Receiver/Receiver.mpc b/flat/CIAO/examples/Swapping/Receiver/Receiver.mpc
index 8ca583f6ea5..3940a663112 100644
--- a/flat/CIAO/examples/Swapping/Receiver/Receiver.mpc
+++ b/flat/CIAO/examples/Swapping/Receiver/Receiver.mpc
@@ -23,11 +23,10 @@ project(Swapping_Hello_Receiver_cidl_gen) : ciaocidldefaults, taoidldefaults {
idlflags += -Wb,export_macro=RECEIVER_SVNT_Export \
-Wb,export_include=Receiver_svnt_export.h \
-SS
- requires += dummy_label
CIDL_Files {
Receiver.cidl
}
-
+
IDL_Files {
ReceiverE.idl
}
@@ -47,7 +46,7 @@ project(Swapping_Hello_Receiver_stub): ccm_stub {
Source_Files {
ReceiverC.cpp
}
-
+
Header_Files {
ReceiverC.h
Receiver_stub_export.h
@@ -68,7 +67,8 @@ project(Swapping_Hello_Receiver_svnt) : ciao_servant {
Swapping_Hello_Base_skel \
Swapping_Hello_Base_stub
dynamicflags = RECEIVER_SVNT_BUILD_DLL
-
+ requires += dummy_label
+
CIDL_Files {
}
@@ -80,14 +80,14 @@ project(Swapping_Hello_Receiver_svnt) : ciao_servant {
ReceiverS.cpp
Receiver_svnt.cpp
}
-
+
Header_Files {
ReceiverEC.h
SenderS.h
Sender_svnt.h
Sender_svnt_export.h
}
-
+
Inline_Files {
ReceiverEC.inl
ReceiverS.inl
@@ -103,7 +103,8 @@ project(Swapping_Hello_Receiver_exec) : ciao_executor {
Swapping_Receiver_svnt \
Swapping_Hello_Base_skel \
Swapping_Hello_Base_stub
-
+
+ requires += dummy_label
dynamicflags = RECEIVER_EXEC_BUILD_DLL
IDL_Files {
@@ -112,12 +113,12 @@ project(Swapping_Hello_Receiver_exec) : ciao_executor {
Source_Files {
Receiver_exec.cpp
}
-
+
Header_Files {
Receiver_exec.h
Receiver_exec_export.h
}
-
+
Inline_Files {
}
}
diff --git a/flat/CIAO/ofccm/NodeApplication/NodeApplication_Impl.h b/flat/CIAO/ofccm/NodeApplication/NodeApplication_Impl.h
index 1802e649b0f..90c908a765f 100644
--- a/flat/CIAO/ofccm/NodeApplication/NodeApplication_Impl.h
+++ b/flat/CIAO/ofccm/NodeApplication/NodeApplication_Impl.h
@@ -21,7 +21,7 @@
#include "ccm/CCM_KeylessCCMHomeC.h"
#include "ccm/ComponentsC.h"
#include "ofccm/Cdmw/CDMW_IDLC.h"
-#include "ComponentServer/ComponentServerC.h"
+#include "ccm/ComponentServer/CCM_ComponentServerC.h"
#include "Deployment/Deployment_NodeApplicationS.h"
#include "Deployment/Deployment_DeploymentPlanC.h"
#include "Deployment/DeploymentC.h"
diff --git a/flat/CIAO/tests/CIAO_ComponentServer/Basic/client.cpp b/flat/CIAO/tests/CIAO_ComponentServer/Basic/client.cpp
index 9cf2824e5d8..580751c0f9f 100644
--- a/flat/CIAO/tests/CIAO_ComponentServer/Basic/client.cpp
+++ b/flat/CIAO/tests/CIAO_ComponentServer/Basic/client.cpp
@@ -3,8 +3,8 @@
#include "ace/Get_Opt.h"
#include "ciao/ComponentServer/CIAO_ComponentServerC.h"
-const char *server_1 = "file://test1.ior";
-const char *server_2 = "file://test2.ior";
+const ACE_TCHAR *server_1 = ACE_TEXT("file://test1.ior");
+const ACE_TCHAR *server_2 = ACE_TEXT("file://test2.ior");
int
parse_args (int argc, char *argv[])
@@ -18,7 +18,7 @@ parse_args (int argc, char *argv[])
case 'k':
server_1 = get_opts.opt_arg ();
break;
-
+
case 'j':
server_2 = get_opts.opt_arg ();
break;
@@ -38,10 +38,10 @@ parse_args (int argc, char *argv[])
}
int
-ACE_TMAIN (int argc, char **argv)
+ACE_TMAIN (int argc, ACE_TCHAR **argv)
{
using namespace CIAO::Deployment;
-
+
try
{
CORBA::ORB_var orb = CORBA::ORB_init (argc, argv);
@@ -51,17 +51,17 @@ ACE_TMAIN (int argc, char **argv)
CORBA::Object_var tmp1 = orb->string_to_object(server_1);
CORBA::Object_var tmp2 = orb->string_to_object(server_2);
-
+
ComponentServer_var server1 (ComponentServer::_narrow (tmp1)),
server2 (ComponentServer::_narrow (tmp2));
-
+
if (CORBA::is_nil (server1.in ()) ||
CORBA::is_nil (server1.in ()))
{
ACE_ERROR_RETURN ((LM_ERROR,
"Nil componentserver references"), -1);
}
-
+
Components::Deployment::Container_var tmp = server1->create_container (0);
Container_var cont1a = Container::_narrow (tmp.in ());
if (CORBA::is_nil (cont1a.in ()))
@@ -71,7 +71,7 @@ ACE_TMAIN (int argc, char **argv)
return -1;
}
ACE_ERROR ((LM_DEBUG, "Got container from server 1a\n"));
-
+
Container_var cont1b = Container::_narrow (server1->create_container (0));
if (CORBA::is_nil (cont1b.in ()))
{
@@ -93,45 +93,45 @@ ACE_TMAIN (int argc, char **argv)
server2->remove_container (cont1a);
ACE_ERROR ((LM_ERROR, "Error: remove_container removed a container not belonging to the component server\n"));
}
- catch (::Components::RemoveFailure &)
+ catch (const ::Components::RemoveFailure &)
{
ACE_DEBUG ((LM_DEBUG, "Server 2 Refused to remove container it didn't own\n"));
// expected
}
-
+
::Components::Deployment::Containers_var cses = server1->get_containers ();
-
+
if (cses->length () != 2)
ACE_ERROR ((LM_ERROR, "Error: get_containers returned the wrong number of containers, %u should be 2\n",
cses->length ()));
else ACE_DEBUG ((LM_DEBUG, "Got %u containers\n", cses->length ()));
-
+
server1->remove_container (cont1a);
ACE_DEBUG ((LM_DEBUG, "Successfully removed container 1a\n"));
-
+
cses = server1->get_containers ();
if (cses->length () != 1)
ACE_ERROR ((LM_ERROR, "Error: get_containers returned %u containers after removal, should be 1\n",
cses->length ()));
-
+
server2->remove_container (cont2a);
ACE_DEBUG ((LM_DEBUG, "Successfully removed container 2a\n"));
server1->remove_container (cont1b);
ACE_DEBUG ((LM_DEBUG, "Successfully removed container 1b\n"));
-
+
server1->remove ();
server1->shutdown ();
server2->remove ();
server2->shutdown ();
-
+
orb->destroy ();
}
- catch (::Components::CreateFailure &e)
+ catch (const ::Components::CreateFailure &e)
{
ACE_ERROR ((LM_ERROR, "Error: Caught CreateFailure exception.\n"));
}
- catch (::Components::RemoveFailure &e)
+ catch (const ::Components::RemoveFailure &e)
{
ACE_ERROR ((LM_ERROR, "Error: Caught RemoveFailure exception.\n"));
}
diff --git a/flat/CIAO/tests/CIAO_ComponentServer/SimpleComponent/SimpleComponent.mpc b/flat/CIAO/tests/CIAO_ComponentServer/SimpleComponent/SimpleComponent.mpc
index 84d9135dbd9..53134fa65f4 100644
--- a/flat/CIAO/tests/CIAO_ComponentServer/SimpleComponent/SimpleComponent.mpc
+++ b/flat/CIAO/tests/CIAO_ComponentServer/SimpleComponent/SimpleComponent.mpc
@@ -22,11 +22,11 @@ project(SimpleComponent_cidl_gen) : ciaocidldefaults, taoidldefaults {
idlflags += -Wb,export_macro=SIMPLECOMPONENT_EXEC_Export \
-Wb,export_include=SimpleComponent_exec_export.h \
-SS
-
+
CIDL_Files {
SimpleComponent.cidl
}
-
+
IDL_Files {
SimpleComponentE.idl
}
@@ -34,9 +34,9 @@ project(SimpleComponent_cidl_gen) : ciaocidldefaults, taoidldefaults {
project(SimpleComponent_stub) : ccm_stub {
avoids += ace_for_tao
- after += SimpleComponent_idl_gen
- libs +=
-
+ after += SimpleComponent_idl_gen
+ libs +=
+
sharedname = SimpleComponent_stub
dynamicflags = SIMPLECOMPONENT_STUB_BUILD_DLL
@@ -61,8 +61,8 @@ project(SimpleComponent_exec) : ciao_executor, ccm_svnt {
avoids += ace_for_tao
after += SimpleComponent_cidl_gen SimpleComponent_svnt
sharedname = SimpleComponent_exec
- libs += SimpleComponent_stub SimpleComponent_svnt
-
+ libs += SimpleComponent_stub SimpleComponent_svnt
+
dynamicflags = SIMPLECOMPONENT_EXEC_BUILD_DLL
IDL_Files {
@@ -72,13 +72,13 @@ project(SimpleComponent_exec) : ciao_executor, ccm_svnt {
SimpleComponentEC.cpp
SimpleComponent_exec.cpp
}
-
+
Header_Files {
SimpleComponentEC.h
SimpleComponent_exec.h
SimpleComponent_exec_export.h
}
-
+
Inline_Files {
SimpleComponentEC.inl
}
@@ -88,28 +88,26 @@ project(SimpleComponent_exec) : ciao_executor, ccm_svnt {
project(SimpleComponent_svnt) : ciao_servant, ccm_svnt {
avoids += ace_for_tao
sharedname = SimpleComponent_svnt
- libs += SimpleComponent_stub
+ libs += SimpleComponent_stub SimpleComponent_exec
after += SimpleComponent_stub SimpleComponent_cidl_gen
dynamicflags = SIMPLECOMPONENT_SVNT_BUILD_DLL
-
+
CIDL_Files {
}
-
IDL_Files {
}
-
Source_Files {
SimpleComponentS.cpp
SimpleComponentEC.cpp
SimpleComponent_svnt.cpp
}
-
+
Header_Files {
SimpleComponentS.h
SimpleComponent_svnt.h
SimpleComponent_svnt_export.h
}
-
+
Inline_Files {
SimpleComponentS.inl
}
@@ -123,4 +121,4 @@ project (SimpleComponent_CIAOComponentServer_Test) : ciao_componentserver_stub,
Source_Files {
client.cpp
}
-} \ No newline at end of file
+}