diff options
author | schmidt <douglascraigschmidt@users.noreply.github.com> | 1998-05-06 23:28:01 +0000 |
---|---|---|
committer | schmidt <douglascraigschmidt@users.noreply.github.com> | 1998-05-06 23:28:01 +0000 |
commit | c42126cdc454235868d33df1256384df83eb1696 (patch) | |
tree | 2a6b7f5eb3e1bfc4ee757e17cad0e1903bfefb1a | |
parent | 063f85b947aa0623de49fafa47dd6e58d22ab736 (diff) | |
download | ATCD-c42126cdc454235868d33df1256384df83eb1696.tar.gz |
*** empty log message ***
-rw-r--r-- | README | 16 | ||||
-rw-r--r-- | TAO/ChangeLog-98c | 7 | ||||
-rw-r--r-- | TAO/tests/NestedUpcall/Makefile | 34 | ||||
-rw-r--r-- | TAO/tests/NestedUpcall/NestedUpcall.dsw | 82 | ||||
-rw-r--r-- | TAO/tests/NestedUpcall/client.cpp | 340 | ||||
-rw-r--r-- | TAO/tests/NestedUpcall/client.dsp | 328 | ||||
-rw-r--r-- | TAO/tests/NestedUpcall/server.cpp | 272 | ||||
-rw-r--r-- | TAO/tests/NestedUpcall/server.dsp | 324 |
8 files changed, 792 insertions, 611 deletions
@@ -210,19 +210,26 @@ ACKNOWLEDGEMENTS ACE has been deeply influenced and improved by the following members of my research group at Washington University: +Alexander Babu Arulanthu <alex@cs.wustl.edu> Darrell Brunsch <brunsch@cs.wustl.edu> -Chris Cleeland <chris@milo.st-louis.mo.us> +Chris Cleeland <chris@cs.wustl.edu> +Sergio Flores-Gaitan <sergio@cs.wustl.edu> +Chris Gill <cdgill@cs.wustl.edu> Aniruddha Gokhale <gokhale@cs.wustl.edu> Tim Harrison <harrison@cs.wustl.edu> James Hu <jxh@cs.wustl.edu> Prashant Jain <pjain@cs.wustl.edu> +Michael Kircher <mk1@cs.wustl.edu> David Levine <levine@cs.wustl.edu> -Carlos O'Ryan <coryan@mat.puc.cl> +Carlos O'Ryan <coryan@cs.wustl.edu> Irfan Pyarali <irfan@cs.wustl.edu> -Nanbor Wang <nw1@cs.wustl.edu> +Marina Spivak <marina@cs.wustl.edu> +Nagarajan Surendran <naga@cs.wustl.edu> +Nanbor Wang <nanbor@cs.wustl.edu> +Seth Widoff <sbw1@cs.wustl.edu> I would also like to thank all the following people who have also -contributed to ACE over the years: +contributed to ACE and TAO over the years: Paul Stephenson <pstephenson@objectspace.com> Olaf Kruger <okruger@cssc-melb.tansu.com.au> @@ -537,6 +544,7 @@ James Garrison <jhg@austx.tandem.com> Brad Walton <brad.walton@transnexus.com> Paul Motuzenko <p_motuzenko@hotmail.com> Kurt Sussman <kls@best.com> +Rob Thornton <ret1@cec.wustl.edu> I would particularly like to thank Paul Stephenson, who worked with me at Ericsson and is now at ObjectSpace. Paul devised the recursive diff --git a/TAO/ChangeLog-98c b/TAO/ChangeLog-98c index a6e31d35f74..3d0c3e310ae 100644 --- a/TAO/ChangeLog-98c +++ b/TAO/ChangeLog-98c @@ -1,3 +1,10 @@ +Wed May 6 18:16:42 1998 Douglas C. Schmidt <schmidt@tango.cs.wustl.edu> + + * tests/NestedUpcall: Added the new "one-button" features for the + nested upcalls test so that it can run with a single file, just + like IDL_Cubit. Thanks to Rob Thornton <ret1@cec.wustl.edu> for + this enhancement. + Wed May 6 08:46:18 1998 Aniruddha Gokhale <gokhale@mambo.cs.wustl.edu> * rules.tao.GNU: Added dependency of the generated files on the diff --git a/TAO/tests/NestedUpcall/Makefile b/TAO/tests/NestedUpcall/Makefile index 6a3a390d9f2..b287b81386d 100644 --- a/TAO/tests/NestedUpcall/Makefile +++ b/TAO/tests/NestedUpcall/Makefile @@ -14,20 +14,18 @@ ifndef TAO_ROOT TAO_ROOT = $(ACE_ROOT)/TAO endif # ! TAO_ROOT -LDLIBS = -lTAO +LDLIBS = -lorbsvcs -lTAO -IDL_FILES = Reactor -IDL_SRC = $(IDL_FILES:%=%.idl) -IDL_GENERATED = $(foreach idlfile,$(IDL_FILES),$(addprefix $(idlfile),C.cpp S.cpp)) -PROG_SRCS = $(IDL_GENERATED) server.cpp client.cpp \ - reactor_i.cpp eh_i.cpp tmplinst.cpp +IDL_SRC = ReactorC.cpp ReactorS.cpp +PROG_SRCS = $(IDL_SRC) server.cpp client.cpp #tmplinst.cpp LSRC = $(PROG_SRCS) -SVR_OBJS = $(IDL_GENERATED:%.cpp=%.o) server.o reactor_i.o #tmplinst.o -CLT_OBJS = $(IDL_GENERATED:%.cpp=%.o) client.o eh_i.o #tmplinst.o +NESTEDUPCALLS_SVR_OBJS = ReactorS.o ReactorC.o server.o reactor_i.o +NESTEDUPCALLS_CLT_OBJS = ReactorS.o ReactorC.o client.o eh_i.o +TEST_OBJS = NestedUpCalls_Test.o -BIN = server client +BIN = server client NestedUpCalls_Test BUILD = $(BIN) VLDLIBS = $(LDLIBS:%=%$(VAR)) VBIN = $(BIN:%=%$(VAR)) @@ -48,21 +46,25 @@ include $(TAO_ROOT)/taoconfig.mk # Local targets #---------------------------------------------------------------------------- -DCFLAGS = -g +LDFLAGS += -L$(TAO_ROOT)/orbsvcs/orbsvcs -L$(TAO_ROOT)/tao -L$(TAO_ROOT)/orbsvcs/Naming_Service +CPPFLAGS += -I$(TAO_ROOT)/orbsvcs -server: $(addprefix $(VDIR),$(SVR_OBJS)) - $(LINK.cc) $(LDFLAGS) -o $@ $^ $(VLDLIBS) +DCFLAGS = -g -client: $(addprefix $(VDIR),$(CLT_OBJS)) - $(LINK.cc) $(LDFLAGS) -o $@ $^ $(VLDLIBS) +server: $(addprefix $(VDIR),$(NESTEDUPCALLS_SVR_OBJS)) + $(LINK.cc) $(LDFLAGS) -o $@ $^ $(VLDLIBS) $(POSTLINK) -.PRECIOUS: $(IDL_GENERATED) +client: $(addprefix $(VDIR),$(NESTEDUPCALLS_CLT_OBJS)) + $(LINK.cc) $(LDFLAGS) -o $@ $^ $(VLDLIBS) $(POSTLINK) +NestedUpCalls_Test: $(addprefix $(VDIR),$(TEST_OBJS)) + $(LINK.cc) $(LDFLAGS) -o $@ $^ $(VLDLIBS) $(POSTLINK) realclean: clean - -/bin/rm -rf $(IDL_GENERATED) + -/bin/rm -rf ReactorS.* ReactorC.* # DO NOT DELETE THIS LINE -- g++dep uses it. # DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY. + # IF YOU PUT ANYTHING HERE IT WILL GO AWAY diff --git a/TAO/tests/NestedUpcall/NestedUpcall.dsw b/TAO/tests/NestedUpcall/NestedUpcall.dsw index f6006d20cb7..512c7d017db 100644 --- a/TAO/tests/NestedUpcall/NestedUpcall.dsw +++ b/TAO/tests/NestedUpcall/NestedUpcall.dsw @@ -1,41 +1,41 @@ -Microsoft Developer Studio Workspace File, Format Version 5.00
-# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!
-
-###############################################################################
-
-Project: "client"=.\client.dsp - Package Owner=<4>
-
-Package=<5>
-{{{
-}}}
-
-Package=<4>
-{{{
-}}}
-
-###############################################################################
-
-Project: "server"=.\server.dsp - Package Owner=<4>
-
-Package=<5>
-{{{
-}}}
-
-Package=<4>
-{{{
-}}}
-
-###############################################################################
-
-Global:
-
-Package=<5>
-{{{
-}}}
-
-Package=<3>
-{{{
-}}}
-
-###############################################################################
-
+Microsoft Developer Studio Workspace File, Format Version 5.00
+# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!
+
+###############################################################################
+
+Project: "client"=.\client.dsp - Package Owner=<4>
+
+Package=<5>
+{{{
+}}}
+
+Package=<4>
+{{{
+}}}
+
+###############################################################################
+
+Project: "server"=.\server.dsp - Package Owner=<4>
+
+Package=<5>
+{{{
+}}}
+
+Package=<4>
+{{{
+}}}
+
+###############################################################################
+
+Global:
+
+Package=<5>
+{{{
+}}}
+
+Package=<3>
+{{{
+}}}
+
+###############################################################################
+
diff --git a/TAO/tests/NestedUpcall/client.cpp b/TAO/tests/NestedUpcall/client.cpp index b47d00f2035..c4ad09552d3 100644 --- a/TAO/tests/NestedUpcall/client.cpp +++ b/TAO/tests/NestedUpcall/client.cpp @@ -1,37 +1,69 @@ // $Id$ -// ============================================================================ -// -// = LIBRARY -// TAO/tests -// -// = FILENAME -// client.cpp -// -// = AUTHOR -// Chris Cleeland -// -// ============================================================================ - -#include "ace/Auto_Ptr.h" -#include "ace/Get_Opt.h" - -#include "tao/corba.h" - +#include "ace/Profile_Timer.h" +#include "ace/Env_Value_T.h" +#include "ace/Read_Buffer.h" +#include "client.h" #include "eh_i.h" +#include "orbsvcs/CosNamingC.h" + +#define quote(x) #x + +const int max_sequence_length = 10; +// Limit the sequence length, otherwise the time to run the test +// increases to fast.... + +// Constructor. +NestedUpCalls_Client::NestedUpCalls_Client (void) + : nested_up_calls_reactor_key_ (0), + shutdown_ (0), + call_count_ (0), + nested_up_calls_reactor_ior_file_ (0), + f_handle_ (ACE_INVALID_HANDLE), + use_naming_service_ (1) +{ +} + +// Simple function that returns the substraction of 117 from the +// parameter. + +int +NestedUpCalls_Client::func (u_int i) +{ + return i - 117; +} + +// Reads the NestedUpCalls reactor ior from a file + +int +NestedUpCalls_Client::read_ior (char *filename) +{ + // Open the file for reading. + this->f_handle_ = ACE_OS::open (filename,0); -CORBA::String_var remote_reactor_key = (char *) 0; + if (this->f_handle_ == ACE_INVALID_HANDLE) + ACE_ERROR_RETURN ((LM_ERROR, + "Unable to open %s for writing: %p\n", + filename), + -1); + ACE_Read_Buffer ior_buffer (this->f_handle_); + this->nested_up_calls_reactor_key_ = ior_buffer.read (); + + if (this->nested_up_calls_reactor_key_ == 0) + ACE_ERROR_RETURN ((LM_ERROR, + "Unable to allocate memory to read ior: %p\n"), + -1); + return 0; +} -// Completely arbitrary constant that ought to be big enough. -#define MAX_IOR_SIZE 4096 +// Parses the command line arguments and returns an error status. int -parse_args (int argc_, char* argv_[]) +NestedUpCalls_Client::parse_args (void) { - ACE_Get_Opt get_opts (argc_, argv_, "df:k:"); + ACE_Get_Opt get_opts (argc_, argv_, "dn:f:k:xs"); int c; - char temp_buf[MAX_IOR_SIZE]; - char *result = 0; + int result; while ((c = get_opts ()) != -1) switch (c) @@ -39,42 +71,35 @@ parse_args (int argc_, char* argv_[]) case 'd': // debug flag TAO_debug_level++; break; - case 'f': - { - FILE *ior_file_ = - ACE_OS::fopen (get_opts.optarg,"r"); - - if (ior_file_ == 0) - ACE_ERROR_RETURN ((LM_ERROR, - "Unable to open %s for writing: %p\n", - get_opts.optarg, "open"), -1); - - result = ACE_OS::fgets (temp_buf, MAX_IOR_SIZE, ior_file_); - if (result == 0) - ACE_ERROR_RETURN ((LM_ERROR, - "Unable to read ior from file %s: %p\n", - get_opts.optarg, - "fgets"), - -1); - - remote_reactor_key = - CORBA::string_copy (temp_buf); - ACE_OS::fclose (ior_file_); - } - break; - case 'k': - remote_reactor_key = - CORBA::string_copy (get_opts.optarg); + case 'f': // read the IOR from the file. + result = this->read_ior (get_opts.optarg); + if (result < 0) + ACE_ERROR_RETURN ((LM_ERROR, + "Unable to read ior from %s : %p\n", + get_opts.optarg), + -1); + break; + case 'k': // read the nestedupcalls IOR from the command-line. + this->nested_up_calls_reactor_key_ = + ACE_OS::strdup (get_opts.optarg); + break; + case 'x': + this->shutdown_ = 1; + break; + case 's': // Don't use the TAO Naming Service. + this->use_naming_service_ = 0; break; case '?': default: ACE_ERROR_RETURN ((LM_ERROR, "usage: %s" " [-d]" - " [-f ior-key-file]" - " [-k ior-as-string]" + " [-f nested_up_calls_reactor-obj-ref-key-file]" + " [-k nestedupcalls-obj-ref-key]" + " [-x]" + " [-s]" "\n", - argv_ [0]), + this->argv_ [0]), -1); } @@ -82,51 +107,13 @@ parse_args (int argc_, char* argv_[]) return 0; } +// Execute client example code. int -main (int argc, char *argv[]) +NestedUpCalls_Client::run (void) { + TAO_TRY { - CORBA::ORB_var orb = CORBA::ORB_init (argc, - argv, - "client", - TAO_TRY_ENV); - TAO_CHECK_ENV; - - // Initialize the object adapter. - CORBA::Object_var poa_object = - orb->resolve_initial_references ("RootPOA"); - if (CORBA::is_nil (poa_object.in ())) - ACE_ERROR_RETURN ((LM_ERROR, - " (%P|%t) Unable to initialize the POA.\n"), - 1); - - PortableServer::POA_var root_poa = - PortableServer::POA::_narrow (poa_object.in (), - TAO_TRY_ENV); - TAO_CHECK_ENV; - - parse_args (argc, argv); - - if (remote_reactor_key.in () == 0) - ACE_ERROR_RETURN ((LM_ERROR, - "%s: no remote Reactor key specified\n"), - -1); - - CORBA::Object_var reactor_object = - orb->string_to_object (ACE_const_cast(char*, remote_reactor_key.in ()), - TAO_TRY_ENV); - TAO_CHECK_ENV; - - Reactor_var remote_reactor = Reactor::_narrow (reactor_object.in (), - TAO_TRY_ENV); - TAO_CHECK_ENV; - - if (CORBA::is_nil (remote_reactor.in ())) - ACE_ERROR_RETURN ((LM_ERROR, - "%s: invalid Reactor key <%s>\n", - argv[0], remote_reactor_key.in ()), -1); - // Create an EventHandler servant to hand to the other side... auto_ptr<EventHandler_i> eh_impl (new EventHandler_i); EventHandler_var eh = eh_impl->_this (TAO_TRY_ENV); @@ -138,44 +125,175 @@ main (int argc, char *argv[]) // The bad thing is that we have to do something non-standard // such as call orb->run() with a zero timeout. It would be // nice if the spec gave us a standard way to do this. - if (orb->run (ACE_Time_Value::zero) == -1) + if (orb_->run (ACE_Time_Value::zero) == -1) ACE_ERROR_RETURN ((LM_ERROR, "%s: %p\n", - argv[0], "unable to get the ORB Core to listen"), + argv_[0], "unable to get the ORB Core to listen"), -1); // Now, after all that, we can invoke an operation on the remote // side. - CORBA::Long r = remote_reactor->register_handler (eh.in (), TAO_TRY_ENV); + CORBA::Long r = this->reactor_->register_handler (eh.in (), TAO_TRY_ENV); // We ought to have a result! ACE_DEBUG ((LM_DEBUG, "%s: received %d as return from register_handler ()\n", - argv[0], r)); + argv_[0], r)); + + this->reactor_->set_value (TAO_TRY_ENV); + TAO_CHECK_ENV; + + this->reactor_->decrement (eh.in (), 5, TAO_TRY_ENV); + TAO_CHECK_ENV; + + this->reactor_->stop (TAO_TRY_ENV); + TAO_CHECK_ENV; + + if (this->shutdown_) + { + dexc (this->env_, "server, please ACE_OS::exit"); + } + } + TAO_CATCHANY + { + TAO_TRY_ENV.print_exception ("Nestedupcalls::run ()"); + return -1; + } + TAO_ENDTRY; + return 0; +} + +NestedUpCalls_Client::~NestedUpCalls_Client (void) +{ + // Free resources + // Close the ior files + if (this->nested_up_calls_reactor_ior_file_) + ACE_OS::fclose (this->nested_up_calls_reactor_ior_file_); + if (this->f_handle_ != ACE_INVALID_HANDLE) + ACE_OS::close (this->f_handle_); - remote_reactor->set_value (TAO_TRY_ENV); + if (this->nested_up_calls_reactor_key_ != 0) + ACE_OS::free (this->nested_up_calls_reactor_key_); +} + +int +NestedUpCalls_Client::init_naming_service (void) +{ + TAO_TRY + { + CORBA::Object_var naming_obj = + this->orb_->resolve_initial_references ("NameService"); + if (CORBA::is_nil (naming_obj.in ())) + ACE_ERROR_RETURN ((LM_ERROR, + " (%P|%t) Unable to resolve the Name Service.\n"), + -1); + CosNaming::NamingContext_var naming_context = + CosNaming::NamingContext::_narrow (naming_obj.in (), + TAO_TRY_ENV); TAO_CHECK_ENV; - remote_reactor->decrement (eh.in (), 5, TAO_TRY_ENV); + CosNaming::Name nested_up_calls_reactor_name (2); + nested_up_calls_reactor_name.length (2); + nested_up_calls_reactor_name[0].id = CORBA::string_dup ("NestedUpCalls"); + nested_up_calls_reactor_name[1].id = CORBA::string_dup ("nested_up_calls_reactor"); + CORBA::Object_var reactor_obj = + naming_context->resolve (nested_up_calls_reactor_name,TAO_TRY_ENV); TAO_CHECK_ENV; - remote_reactor->stop (TAO_TRY_ENV); + this->reactor_ = + Reactor::_narrow (reactor_obj.in (),TAO_TRY_ENV); TAO_CHECK_ENV; + + if (CORBA::is_nil (this->reactor_.in ())) + ACE_ERROR_RETURN ((LM_ERROR, + " could not resolve nested up calls reactor in Naming service <%s>\n"), + -1); + } + TAO_CATCHANY + { + TAO_TRY_ENV.print_exception ("NestedUpCalls::init_naming_service"); + return -1; } + TAO_ENDTRY; + + return 0; +} + +int +NestedUpCalls_Client::init (int argc, char **argv) +{ + int naming_result; + this->argc_ = argc; + this->argv_ = argv; + + TAO_TRY + { + // Retrieve the ORB. + this->orb_ = CORBA::ORB_init (this->argc_, + this->argv_, + "internet", + TAO_TRY_ENV); + TAO_CHECK_ENV; + + // Parse command line and verify parameters. + if (this->parse_args () == -1) + return -1; + + if (this->use_naming_service_) + { + naming_result = this->init_naming_service (); + if (naming_result < 0) + return naming_result; + } + else + { + if (this->nested_up_calls_reactor_key_ == 0) + ACE_ERROR_RETURN ((LM_ERROR, + "%s: no nested up calls reactor key specified\n", + this->argv_[0]), + -1); + + + CORBA::Object_var reactor_object = + this->orb_->string_to_object (this->nested_up_calls_reactor_key_, + TAO_TRY_ENV); + TAO_CHECK_ENV; + + this->reactor_ = + Reactor::_narrow (reactor_object.in(), TAO_TRY_ENV); + TAO_CHECK_ENV; + + if (CORBA::is_nil (this->reactor_.in ())) + ACE_ERROR_RETURN ((LM_ERROR, + "invalid reactor key <%s>\n", + this->nested_up_calls_reactor_key_), + -1); + } + + ACE_DEBUG ((LM_DEBUG, "Reactor received OK\n")); + } TAO_CATCHANY { - TAO_TRY_ENV.print_exception ("main"); - return 1; + TAO_TRY_ENV.print_exception ("NestedUpCalls::init"); + return -1; } TAO_ENDTRY; return 0; } -#if defined (ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION) -template class auto_ptr<EventHandler_i>; -template class ACE_Auto_Basic_Ptr<EventHandler_i>; -#elif defined (ACE_HAS_TEMPLATE_INSTANTIATION_PRAGMA) -#pragma instantiate auto_ptr<EventHandler_i> -#pragma instantiate ACE_Auto_Basic_Ptr<EventHandler_i> -#endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */ +// This function runs the test. +int +main (int argc, char **argv) +{ + NestedUpCalls_Client nestedupcalls_client; + + ACE_DEBUG ((LM_DEBUG, + "\n \t NestedUpCalls: client \n\n")); + + if (nestedupcalls_client.init (argc, argv) == -1) + return 1; + else + return nestedupcalls_client.run (); +} + diff --git a/TAO/tests/NestedUpcall/client.dsp b/TAO/tests/NestedUpcall/client.dsp index 2c6b4cc2c8a..66315a1a9ee 100644 --- a/TAO/tests/NestedUpcall/client.dsp +++ b/TAO/tests/NestedUpcall/client.dsp @@ -1,164 +1,164 @@ -# Microsoft Developer Studio Project File - Name="client" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 5.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Console Application" 0x0103
-
-CFG=client - Win32 Debug
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "client.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "client.mak" CFG="client - Win32 Debug"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "client - Win32 Release" (based on "Win32 (x86) Console Application")
-!MESSAGE "client - Win32 Debug" (based on "Win32 (x86) Console Application")
-!MESSAGE
-
-# Begin Project
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "client - Win32 Release"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release"
-# PROP BASE Intermediate_Dir "Release"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir ""
-# PROP Intermediate_Dir "Release"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\..\.." /I "..\.." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD BASE RSC /l 0x409 /d "NDEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386
-# ADD LINK32 TAO.lib ace.lib /nologo /subsystem:console /machine:I386 /libpath:"..\..\..\ace" /libpath:"..\..\tao"
-
-!ELSEIF "$(CFG)" == "client - Win32 Debug"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug"
-# PROP BASE Intermediate_Dir "Debug"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir ""
-# PROP Intermediate_Dir "Debug"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /Zi /Od /I "..\..\.." /I "..\.." /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 TAO.lib aced.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept /libpath:"..\..\..\ace" /libpath:"..\..\tao"
-
-!ENDIF
-
-# Begin Target
-
-# Name "client - Win32 Release"
-# Name "client - Win32 Debug"
-# Begin Source File
-
-SOURCE=.\client.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\eh_i.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\Reactor.idl
-
-!IF "$(CFG)" == "client - Win32 Release"
-
-# Begin Custom Build
-InputPath=.\Reactor.idl
-InputName=Reactor
-
-BuildCmds= \
- ..\..\TAO_IDL\tao_idl $(InputName).idl
-
-"$(InputName)C.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-
-"$(InputName)C.i" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-
-"$(InputName)C.cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-
-"$(InputName)S.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-
-"$(InputName)S.i" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-
-"$(InputName)S.cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-# End Custom Build
-
-!ELSEIF "$(CFG)" == "client - Win32 Debug"
-
-# Begin Custom Build
-InputPath=.\Reactor.idl
-InputName=Reactor
-
-BuildCmds= \
- ..\..\TAO_IDL\tao_idl $(InputName).idl
-
-"$(InputName)C.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-
-"$(InputName)C.i" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-
-"$(InputName)C.cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-
-"$(InputName)S.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-
-"$(InputName)S.i" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-
-"$(InputName)S.cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-# End Custom Build
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\ReactorC.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\ReactorS.cpp
-# End Source File
-# End Target
-# End Project
+# Microsoft Developer Studio Project File - Name="client" - Package Owner=<4>
+# Microsoft Developer Studio Generated Build File, Format Version 5.00
+# ** DO NOT EDIT **
+
+# TARGTYPE "Win32 (x86) Console Application" 0x0103
+
+CFG=client - Win32 Debug
+!MESSAGE This is not a valid makefile. To build this project using NMAKE,
+!MESSAGE use the Export Makefile command and run
+!MESSAGE
+!MESSAGE NMAKE /f "client.mak".
+!MESSAGE
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "client.mak" CFG="client - Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "client - Win32 Release" (based on "Win32 (x86) Console Application")
+!MESSAGE "client - Win32 Debug" (based on "Win32 (x86) Console Application")
+!MESSAGE
+
+# Begin Project
+# PROP Scc_ProjName ""
+# PROP Scc_LocalPath ""
+CPP=cl.exe
+RSC=rc.exe
+
+!IF "$(CFG)" == "client - Win32 Release"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 0
+# PROP BASE Output_Dir "Release"
+# PROP BASE Intermediate_Dir "Release"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 0
+# PROP Output_Dir ""
+# PROP Intermediate_Dir "Release"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
+# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\..\.." /I "..\.." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
+# ADD BASE RSC /l 0x409 /d "NDEBUG"
+# ADD RSC /l 0x409 /d "NDEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+LINK32=link.exe
+# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386
+# ADD LINK32 TAO.lib ace.lib /nologo /subsystem:console /machine:I386 /libpath:"..\..\..\ace" /libpath:"..\..\tao"
+
+!ELSEIF "$(CFG)" == "client - Win32 Debug"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 1
+# PROP BASE Output_Dir "Debug"
+# PROP BASE Intermediate_Dir "Debug"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 1
+# PROP Output_Dir ""
+# PROP Intermediate_Dir "Debug"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
+# ADD CPP /nologo /MDd /W3 /Gm /GX /Zi /Od /I "..\..\.." /I "..\.." /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
+# ADD BASE RSC /l 0x409 /d "_DEBUG"
+# ADD RSC /l 0x409 /d "_DEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+LINK32=link.exe
+# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
+# ADD LINK32 TAO.lib aced.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept /libpath:"..\..\..\ace" /libpath:"..\..\tao"
+
+!ENDIF
+
+# Begin Target
+
+# Name "client - Win32 Release"
+# Name "client - Win32 Debug"
+# Begin Source File
+
+SOURCE=.\client.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\eh_i.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\Reactor.idl
+
+!IF "$(CFG)" == "client - Win32 Release"
+
+# Begin Custom Build
+InputPath=.\Reactor.idl
+InputName=Reactor
+
+BuildCmds= \
+ ..\..\TAO_IDL\tao_idl $(InputName).idl
+
+"$(InputName)C.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+
+"$(InputName)C.i" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+
+"$(InputName)C.cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+
+"$(InputName)S.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+
+"$(InputName)S.i" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+
+"$(InputName)S.cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+# End Custom Build
+
+!ELSEIF "$(CFG)" == "client - Win32 Debug"
+
+# Begin Custom Build
+InputPath=.\Reactor.idl
+InputName=Reactor
+
+BuildCmds= \
+ ..\..\TAO_IDL\tao_idl $(InputName).idl
+
+"$(InputName)C.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+
+"$(InputName)C.i" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+
+"$(InputName)C.cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+
+"$(InputName)S.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+
+"$(InputName)S.i" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+
+"$(InputName)S.cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+# End Custom Build
+
+!ENDIF
+
+# End Source File
+# Begin Source File
+
+SOURCE=.\ReactorC.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\ReactorS.cpp
+# End Source File
+# End Target
+# End Project
diff --git a/TAO/tests/NestedUpcall/server.cpp b/TAO/tests/NestedUpcall/server.cpp index 3d75ce6d0d1..30b0c2eb8fc 100644 --- a/TAO/tests/NestedUpcall/server.cpp +++ b/TAO/tests/NestedUpcall/server.cpp @@ -1,129 +1,175 @@ // $Id$ -// ============================================================================ -// -// = LIBRARY -// TAO/tests -// -// = FILENAME -// server.cpp -// -// = AUTHOR -// Chris Cleeland -// -// ============================================================================ - -#include "tao/corba.h" -#include "tao/TAO.h" -#include "reactor_i.h" +#include "server.h" + +NestedUpCalls_Server::NestedUpCalls_Server (void) + : use_naming_service_ (1), + ior_output_file_ (0) +{ +} + +int +NestedUpCalls_Server::parse_args (void) +{ + ACE_Get_Opt get_opts (argc_, argv_, "dn:o:s"); + int c; + + while ((c = get_opts ()) != -1) + switch (c) + { + case 'd': // debug flag. + TAO_debug_level++; + break; + case 'o': // output the IOR to a file. + this->ior_output_file_ = ACE_OS::fopen (get_opts.optarg, "w"); + if (this->ior_output_file_ == 0) + ACE_ERROR_RETURN ((LM_ERROR, + "Unable to open %s for writing: %p\n", + get_opts.optarg), -1); + break; + case 's': // Don't use the TAO Naming Service. + this->use_naming_service_=0; + break; + case '?': + default: + ACE_ERROR_RETURN ((LM_ERROR, + "usage: %s" + " [-d]" + " [-o] <ior_output_file>" + " [-s]" + "\n", + argv_ [0]), + 1); + } + + // Indicates successful parsing of command line. + return 0; +} int -main (int argc, char* argv[]) +NestedUpCalls_Server::init (int argc, + char** argv, + CORBA::Environment& env) { + // Call the init of TAO_ORB_Manager to create a child POA + // under the root POA. + this->orb_manager_.init_child_poa (argc, + argv, + "child_poa", + env); + + TAO_CHECK_ENV_RETURN (env,-1); + this->argc_ = argc; + this->argv_ = argv; + + this->parse_args (); + // ~~ check for the return value here + + CORBA::String_var str = + this->orb_manager_.activate_under_child_poa ("reactor", + &this->reactor_impl_, + env); ACE_DEBUG ((LM_DEBUG, - "NestedUpcall server starting\n")); + "The IOR is: <%s>\n", + str.in ())); + if (this->ior_output_file_) + { + ACE_OS::fprintf (this->ior_output_file_, + "%s", + str.in ()); + ACE_OS::fclose (this->ior_output_file_); + } + + if (this->use_naming_service_) + return this->init_naming_service (env); + + return 0; +} + +// Initialisation of Naming Service and register IDL_Cubit Context and +// cubit_factory object. + +int +NestedUpCalls_Server::init_naming_service (CORBA::Environment& env) +{ + int result; + CORBA::ORB_var orb; + PortableServer::POA_var child_poa; + + orb = this->orb_manager_.orb (); + child_poa = this->orb_manager_.child_poa (); + + result = this->my_name_server_.init (orb, + child_poa); + if (result < 0) + return result; + reactor_ = this->reactor_impl_._this (env); + TAO_CHECK_ENV_RETURN (env,-1); + + //Register the nested_up_calls_reactor name with the NestedUpCalls Naming + //Context... + CosNaming::Name nested_up_calls_context_name (1); + nested_up_calls_context_name.length (1); + nested_up_calls_context_name[0].id = CORBA::string_dup ("NestedUpCalls"); + this->naming_context_ = + this->my_name_server_->bind_new_context (nested_up_calls_context_name, + env); + TAO_CHECK_ENV_RETURN (env,-1); + + CosNaming::Name reactor_name (1); + reactor_name.length (1); + reactor_name[0].id = CORBA::string_dup ("nested_up_calls_reactor"); + this->naming_context_->bind (reactor_name, + reactor_.in (), + env); + TAO_CHECK_ENV_RETURN (env,-1); + return 0; +} + +int +NestedUpCalls_Server::run (CORBA::Environment& env) +{ + if (this->orb_manager_.run (env) == -1) + ACE_ERROR_RETURN ((LM_ERROR, + "NestedUpCalls_Server::run"), + -1); + return 0; +} + +NestedUpCalls_Server::~NestedUpCalls_Server (void) +{ +} + +int +main (int argc, char *argv[]) +{ + NestedUpCalls_Server nested_up_calls_server; + + ACE_DEBUG ((LM_DEBUG, + "\n \t NestedUpCalls:SERVER \n \n")); TAO_TRY { -#if defined(DONT_USE_ORBMGR) - // @@ Chris, can you please try to replace most of this boiler - // plate code with the TAO_Object_Manager stuff that Sumedh has - // devised? If we need to generalize his implementation to - // handle some of the things you do (e.g., create a special - // POAManager) please let me know. - CORBA::ORB_var orb = - CORBA::ORB_init (argc, argv, "server", TAO_TRY_ENV); - TAO_CHECK_ENV; - - // Initialize the object adapter. - CORBA::Object_var poa_object = - orb->resolve_initial_references("RootPOA"); - - if (CORBA::is_nil (poa_object.in ())) - ACE_ERROR_RETURN ((LM_ERROR, - " (%P|%t) Unable to initialize the POA.\n"), - 1); - - PortableServer::POA_var root_poa = - PortableServer::POA::_narrow (poa_object.in(), - TAO_TRY_ENV); - TAO_CHECK_ENV; - - PortableServer::POAManager_var poa_manager = - root_poa->the_POAManager (TAO_TRY_ENV); - TAO_CHECK_ENV; - - CORBA::PolicyList policies (2); - policies.length (2); - policies[0] = - root_poa->create_id_assignment_policy (PortableServer::USER_ID, - TAO_TRY_ENV); - policies[1] = - root_poa->create_lifespan_policy (PortableServer::PERSISTENT, - TAO_TRY_ENV); - - // We use a different POA, otherwise the user would have to - // change the object key each time it invokes the server. - PortableServer::POA_var poa = - root_poa->create_POA ("Persistent_POA", - poa_manager.in (), - policies, - TAO_TRY_ENV); - TAO_CHECK_ENV; -#else - TAO_ORB_Manager om; - - om.init_child_poa (argc, argv, "Persistent_POA", TAO_TRY_ENV); - TAO_CHECK_ENV; - - CORBA_ORB_var orb = om.orb (); -#endif - - - // Now that we've got all that done, we need to create our impl - // and register! - Reactor_i *reactor_impl = 0; - ACE_NEW_RETURN (reactor_impl, Reactor_i, -1); -#if defined(DONT_USE_ORBMGR) - PortableServer::ObjectId_var id = - PortableServer::string_to_ObjectId ("Reactor"); - - poa->activate_object_with_id (id.in (), - reactor_impl, TAO_TRY_ENV); -#else - CORBA::String s = om.activate_under_child_poa ("Reactor", reactor_impl, TAO_TRY_ENV); - CORBA::string_free (s); -#endif - TAO_CHECK_ENV; - - - // Stringify the object - Reactor_ptr reactor = reactor_impl->_this (TAO_TRY_ENV); - TAO_CHECK_ENV; - - CORBA::String_var str = - orb->object_to_string (reactor, TAO_TRY_ENV); - TAO_CHECK_ENV; - - ACE_DEBUG ((LM_DEBUG, - "(%P|%t) The reactor IOR is <%s>\n", - str.in ())); - - // Run the server now. -#if defined(DONT_USE_ORBMGR) - orb->run (); -#else - om.run (TAO_TRY_ENV); -#endif - CORBA::release (reactor); + if (nested_up_calls_server.init (argc,argv,TAO_TRY_ENV) == -1) + return 1; + else + { + nested_up_calls_server.run (TAO_TRY_ENV); + TAO_CHECK_ENV; + } } - TAO_CATCHANY + TAO_CATCH (CORBA::SystemException, sysex) { - TAO_TRY_ENV.print_exception ("orb_init"); + ACE_UNUSED_ARG (sysex); + TAO_TRY_ENV.print_exception ("System Exception"); + return -1; + } + TAO_CATCH (CORBA::UserException, userex) + { + ACE_UNUSED_ARG (userex); + TAO_TRY_ENV.print_exception ("User Exception"); return -1; } TAO_ENDTRY; - - ACE_DEBUG ((LM_DEBUG, "NestedUpcall server ending\n")); return 0; } diff --git a/TAO/tests/NestedUpcall/server.dsp b/TAO/tests/NestedUpcall/server.dsp index a3324e9ea70..1ad4dedae62 100644 --- a/TAO/tests/NestedUpcall/server.dsp +++ b/TAO/tests/NestedUpcall/server.dsp @@ -1,162 +1,162 @@ -# Microsoft Developer Studio Project File - Name="server" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 5.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Console Application" 0x0103
-
-CFG=server - Win32 Debug
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "server.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "server.mak" CFG="server - Win32 Debug"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "server - Win32 Release" (based on "Win32 (x86) Console Application")
-!MESSAGE "server - Win32 Debug" (based on "Win32 (x86) Console Application")
-!MESSAGE
-
-# Begin Project
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "server - Win32 Release"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release"
-# PROP BASE Intermediate_Dir "Release"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir ""
-# PROP Intermediate_Dir "Release"
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\..\.." /I "..\.." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD BASE RSC /l 0x409 /d "NDEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386
-# ADD LINK32 TAO.lib ace.lib /nologo /subsystem:console /machine:I386 /libpath:"..\..\..\ace" /libpath:"..\..\tao"
-
-!ELSEIF "$(CFG)" == "server - Win32 Debug"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug"
-# PROP BASE Intermediate_Dir "Debug"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir ""
-# PROP Intermediate_Dir "Debug"
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /Zi /Od /I "..\..\.." /I "..\.." /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 TAO.lib aced.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept /libpath:"..\..\..\ace" /libpath:"..\..\tao"
-
-!ENDIF
-
-# Begin Target
-
-# Name "server - Win32 Release"
-# Name "server - Win32 Debug"
-# Begin Source File
-
-SOURCE=.\Reactor.idl
-
-!IF "$(CFG)" == "server - Win32 Release"
-
-# Begin Custom Build
-InputPath=.\Reactor.idl
-InputName=Reactor
-
-BuildCmds= \
- ..\..\TAO_IDL\tao_idl $(InputName).idl
-
-"$(InputName)C.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-
-"$(InputName)C.i" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-
-"$(InputName)C.cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-
-"$(InputName)S.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-
-"$(InputName)S.i" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-
-"$(InputName)S.cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-# End Custom Build
-
-!ELSEIF "$(CFG)" == "server - Win32 Debug"
-
-# Begin Custom Build
-InputPath=.\Reactor.idl
-InputName=Reactor
-
-BuildCmds= \
- ..\..\TAO_IDL\tao_idl $(InputName).idl
-
-"$(InputName)C.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-
-"$(InputName)C.i" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-
-"$(InputName)C.cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-
-"$(InputName)S.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-
-"$(InputName)S.i" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-
-"$(InputName)S.cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- $(BuildCmds)
-# End Custom Build
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\reactor_i.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\ReactorC.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\ReactorS.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\server.cpp
-# End Source File
-# End Target
-# End Project
+# Microsoft Developer Studio Project File - Name="server" - Package Owner=<4>
+# Microsoft Developer Studio Generated Build File, Format Version 5.00
+# ** DO NOT EDIT **
+
+# TARGTYPE "Win32 (x86) Console Application" 0x0103
+
+CFG=server - Win32 Debug
+!MESSAGE This is not a valid makefile. To build this project using NMAKE,
+!MESSAGE use the Export Makefile command and run
+!MESSAGE
+!MESSAGE NMAKE /f "server.mak".
+!MESSAGE
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "server.mak" CFG="server - Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "server - Win32 Release" (based on "Win32 (x86) Console Application")
+!MESSAGE "server - Win32 Debug" (based on "Win32 (x86) Console Application")
+!MESSAGE
+
+# Begin Project
+# PROP Scc_ProjName ""
+# PROP Scc_LocalPath ""
+CPP=cl.exe
+RSC=rc.exe
+
+!IF "$(CFG)" == "server - Win32 Release"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 0
+# PROP BASE Output_Dir "Release"
+# PROP BASE Intermediate_Dir "Release"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 0
+# PROP Output_Dir ""
+# PROP Intermediate_Dir "Release"
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
+# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\..\.." /I "..\.." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
+# ADD BASE RSC /l 0x409 /d "NDEBUG"
+# ADD RSC /l 0x409 /d "NDEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+LINK32=link.exe
+# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386
+# ADD LINK32 TAO.lib ace.lib /nologo /subsystem:console /machine:I386 /libpath:"..\..\..\ace" /libpath:"..\..\tao"
+
+!ELSEIF "$(CFG)" == "server - Win32 Debug"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 1
+# PROP BASE Output_Dir "Debug"
+# PROP BASE Intermediate_Dir "Debug"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 1
+# PROP Output_Dir ""
+# PROP Intermediate_Dir "Debug"
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
+# ADD CPP /nologo /MDd /W3 /Gm /GX /Zi /Od /I "..\..\.." /I "..\.." /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
+# ADD BASE RSC /l 0x409 /d "_DEBUG"
+# ADD RSC /l 0x409 /d "_DEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+LINK32=link.exe
+# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
+# ADD LINK32 TAO.lib aced.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept /libpath:"..\..\..\ace" /libpath:"..\..\tao"
+
+!ENDIF
+
+# Begin Target
+
+# Name "server - Win32 Release"
+# Name "server - Win32 Debug"
+# Begin Source File
+
+SOURCE=.\Reactor.idl
+
+!IF "$(CFG)" == "server - Win32 Release"
+
+# Begin Custom Build
+InputPath=.\Reactor.idl
+InputName=Reactor
+
+BuildCmds= \
+ ..\..\TAO_IDL\tao_idl $(InputName).idl
+
+"$(InputName)C.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+
+"$(InputName)C.i" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+
+"$(InputName)C.cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+
+"$(InputName)S.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+
+"$(InputName)S.i" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+
+"$(InputName)S.cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+# End Custom Build
+
+!ELSEIF "$(CFG)" == "server - Win32 Debug"
+
+# Begin Custom Build
+InputPath=.\Reactor.idl
+InputName=Reactor
+
+BuildCmds= \
+ ..\..\TAO_IDL\tao_idl $(InputName).idl
+
+"$(InputName)C.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+
+"$(InputName)C.i" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+
+"$(InputName)C.cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+
+"$(InputName)S.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+
+"$(InputName)S.i" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+
+"$(InputName)S.cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ $(BuildCmds)
+# End Custom Build
+
+!ENDIF
+
+# End Source File
+# Begin Source File
+
+SOURCE=.\reactor_i.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\ReactorC.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\ReactorS.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\server.cpp
+# End Source File
+# End Target
+# End Project
|