diff options
author | schmidt <douglascraigschmidt@users.noreply.github.com> | 1999-07-16 22:12:22 +0000 |
---|---|---|
committer | schmidt <douglascraigschmidt@users.noreply.github.com> | 1999-07-16 22:12:22 +0000 |
commit | 714f72a9214abbd03579f3ce6ea07dcc23159a2e (patch) | |
tree | 3bc9aa32e83a1d046af32553daacf6152ac3b61c | |
parent | 9ee6337357f40e44ebbaa61f8552277f840f7ca4 (diff) | |
download | ATCD-714f72a9214abbd03579f3ce6ea07dcc23159a2e.tar.gz |
.
-rw-r--r-- | ACE-INSTALL.html | 3 | ||||
-rw-r--r-- | ChangeLog-99b | 25 | ||||
-rw-r--r-- | TAO/ChangeLog-99c | 7 | ||||
-rw-r--r-- | TAO/orbsvcs/orbsvcs/Makefile.bor | 2 | ||||
-rw-r--r-- | TAO/orbsvcs/orbsvcs/orbsvcs.rc | 30 | ||||
-rw-r--r-- | TAO/tao/Makefile.bor | 2 | ||||
-rw-r--r-- | TAO/tao/tao.rc | 30 | ||||
-rw-r--r-- | ace/Malloc.h | 8 | ||||
-rw-r--r-- | ace/config-sunos5.5.h | 2 | ||||
-rw-r--r-- | examples/Shared_Malloc/Options.cpp | 12 | ||||
-rw-r--r-- | examples/Shared_Malloc/test_persistence.cpp | 202 | ||||
-rw-r--r-- | examples/Shared_Malloc/test_position_independent_malloc.cpp | 61 | ||||
-rw-r--r-- | include/makeinclude/build_dll.bor | 15 | ||||
-rw-r--r-- | include/makeinclude/build_exe.bor | 15 | ||||
-rw-r--r-- | include/makeinclude/compiler.bor | 3 | ||||
-rw-r--r-- | netsvcs/servers/main.cpp | 107 | ||||
-rw-r--r-- | tests/DLL_Test.cpp | 6 | ||||
-rw-r--r-- | tests/Makefile.bor | 9 | ||||
-rw-r--r-- | tests/run_tests.bat | 3 |
19 files changed, 381 insertions, 161 deletions
diff --git a/ACE-INSTALL.html b/ACE-INSTALL.html index 915e26be5bc..f1337682993 100644 --- a/ACE-INSTALL.html +++ b/ACE-INSTALL.html @@ -283,7 +283,8 @@ make: *** [libACE.so] Error 8 1999 (R5), with glibc 2.1.1.<p> If you run out of memory, it's easy to add virtual memory on - Linux. Please see the <code>mkswap</code> man page.<p> + Linux. Please see the <code>mkswap</code> man page. You'll + need around 256 to 300 MBs of swap space to compile ACE+TAO.<p> The glibc 2.0 dynamic loader isn't thread safe. If you want to use the Invocation API you'll have to set diff --git a/ChangeLog-99b b/ChangeLog-99b index 10a17a1355c..3110d13e978 100644 --- a/ChangeLog-99b +++ b/ChangeLog-99b @@ -1,12 +1,16 @@ -Fri Jul 16 16:41:22 1999 Ossama Othman <othman@cs.wustl.edu> - - * ace/Stats.cpp (print_summary): - - Fixed format specifier that was expecting an integer argument. - It needed an additional percent specifier. - Fri Jul 16 13:55:34 1999 Douglas C. Schmidt <schmidt@tango.cs.wustl.edu> + * include/makeinclude/{build_dll.bor,build_exe.bor,compiler.bor}, + ace/{Makefile.bor,ace.rc}: + Updated these files to add version information to the DLLs so + when you right click them in windows explorer you can see what + version the file is (e.g., "4.6.45"). Thanks to Christopher + Kohlhoff <chris@kohlhoff.com> for contributing this. + + * netsvcs/servers/main.cpp (main): Disable debugging messages + if the -d option isn't given to ACE_Service_Config. Thanks to + Jerry De Master <jdemaste@ipdinc.com> for reporting this. + * ace/config-win32-borland.h: Updated this file to enable some necessary macros. Thanks to Christopher Kohlhoff <chris@kohlhoff.com> for reporting this. @@ -58,6 +62,13 @@ Fri Jul 16 13:55:34 1999 Douglas C. Schmidt <schmidt@tango.cs.wustl.edu> feature was actually added a couple of beta releases ago, but somehow the ChangeLog entry got lost.] +Fri Jul 16 16:41:22 1999 Ossama Othman <othman@cs.wustl.edu> + + * ace/Stats.cpp (print_summary): + + Fixed format specifier that was expecting an integer argument. + It needed an additional percent specifier. + Fri Jul 16 09:20:42 1999 Arturo Montes <mitosys@colomsat.net.co> * ace/OS.i: Patch the dl* family to keep ACE diff --git a/TAO/ChangeLog-99c b/TAO/ChangeLog-99c index 7177dd88e19..7251d8e1484 100644 --- a/TAO/ChangeLog-99c +++ b/TAO/ChangeLog-99c @@ -64,6 +64,13 @@ Fri Jul 16 14:05:33 1999 Ossama Othman <othman@cs.wustl.edu> Fri Jul 16 13:59:10 1999 Douglas C. Schmidt <schmidt@tango.cs.wustl.edu> + * tao/{Makefile.bor,tao.rc}, + orbsvcs/orbsvcs/{Makefile.bor,orbsvcs.rc}: + Updated these files to add version information to the DLLs so + when you right click them in windows explorer you can see what + version the file is (e.g., "4.6.45"). Thanks to Christopher + Kohlhoff <chris@kohlhoff.com> for contributing this. + * examples/Borland: Updated the examples to contain several minor fixes for Borland C++ Builder. Thanks to Christopher Kohlhoff <chris@kohlhoff.com> for reporting this. diff --git a/TAO/orbsvcs/orbsvcs/Makefile.bor b/TAO/orbsvcs/orbsvcs/Makefile.bor index bb6ea8f77f9..57d0593fd65 100644 --- a/TAO/orbsvcs/orbsvcs/Makefile.bor +++ b/TAO/orbsvcs/orbsvcs/Makefile.bor @@ -144,6 +144,8 @@ OBJFILES = \ $(OBJDIR)\Trader_Utils.obj \ $(OBJDIR)\Transient_Naming_Context.obj +RESOURCE = $(OBJDIR)\orbsvcs.res + CFLAGS = $(ACE_CFLAGS) $(TAO_CFLAGS) $(ORBSVCS_BUILD_CFLAGS) $(ORBSVCS_CFLAGS) CPPDIR = .;AV;Event;concurrency;Sched;Trader;Naming;CosEvent;Time;Property;Log diff --git a/TAO/orbsvcs/orbsvcs/orbsvcs.rc b/TAO/orbsvcs/orbsvcs/orbsvcs.rc new file mode 100644 index 00000000000..9dcfda5d6d4 --- /dev/null +++ b/TAO/orbsvcs/orbsvcs/orbsvcs.rc @@ -0,0 +1,30 @@ +#include "..\..\tao\Version.h" + +1 VERSIONINFO + FILEVERSION TAO_MAJOR_VERSION,TAO_MINOR_VERSION,TAO_BETA_VERSION,0 + PRODUCTVERSION TAO_MAJOR_VERSION,TAO_MINOR_VERSION,TAO_BETA_VERSION,0 + FILEFLAGSMASK 0x3fL + FILEFLAGS 0x0L + FILEOS 0x4L + FILETYPE 0x1L + FILESUBTYPE 0x0L +BEGIN + BLOCK "StringFileInfo" + BEGIN + BLOCK "040904B0" + BEGIN + VALUE "FileDescription", "ORBSVCS\0" + VALUE "FileVersion", TAO_VERSION "\0" + VALUE "InternalName", "ORBSVCSDLL\0" + VALUE "LegalCopyright", "\0" + VALUE "LegalTrademarks", "\0" + VALUE "OriginalFilename", "ORBSVCS.DLL\0" + VALUE "ProductName", "ORBSVCS\0" + VALUE "ProductVersion", TAO_VERSION "\0" + END + END + BLOCK "VarFileInfo" + BEGIN + VALUE "Translation", 0x409, 1200 + END +END diff --git a/TAO/tao/Makefile.bor b/TAO/tao/Makefile.bor index 2cbaa9cdeb7..2e86a5da485 100644 --- a/TAO/tao/Makefile.bor +++ b/TAO/tao/Makefile.bor @@ -106,6 +106,8 @@ OBJFILES = \ $(OBJDIR)\Wait_Strategy.obj \ $(OBJDIR)\WrongTransactionC.obj +RESOURCE = $(OBJDIR)\tao.res + CFLAGS = $(ACE_CFLAGS) $(TAO_BUILD_CFLAGS) $(TAO_CFLAGS) CPPDIR = . diff --git a/TAO/tao/tao.rc b/TAO/tao/tao.rc new file mode 100644 index 00000000000..998e9157f92 --- /dev/null +++ b/TAO/tao/tao.rc @@ -0,0 +1,30 @@ +#include "Version.h" + +1 VERSIONINFO + FILEVERSION TAO_MAJOR_VERSION,TAO_MINOR_VERSION,TAO_BETA_VERSION,0 + PRODUCTVERSION TAO_MAJOR_VERSION,TAO_MINOR_VERSION,TAO_BETA_VERSION,0 + FILEFLAGSMASK 0x3fL + FILEFLAGS 0x0L + FILEOS 0x4L + FILETYPE 0x1L + FILESUBTYPE 0x0L +BEGIN + BLOCK "StringFileInfo" + BEGIN + BLOCK "040904B0" + BEGIN + VALUE "FileDescription", "TAO\0" + VALUE "FileVersion", TAO_VERSION "\0" + VALUE "InternalName", "TAODLL\0" + VALUE "LegalCopyright", "\0" + VALUE "LegalTrademarks", "\0" + VALUE "OriginalFilename", "TAO.DLL\0" + VALUE "ProductName", "TAO\0" + VALUE "ProductVersion", TAO_VERSION "\0" + END + END + BLOCK "VarFileInfo" + BEGIN + VALUE "Translation", 0x409, 1200 + END +END diff --git a/ace/Malloc.h b/ace/Malloc.h index ea744ee77e6..b7c48a0ceb8 100644 --- a/ace/Malloc.h +++ b/ace/Malloc.h @@ -140,11 +140,19 @@ public: void name (const char *); // Assign a name; +#if defined (ACE_HAS_POSITION_INDEPENDENT_MALLOC) ACE_Based_Pointer_Basic<char> name_; // Name of the Node. ACE_Based_Pointer_Basic<char> pointer_; // Pointer to the contents. +#else + char *name_; + // Name of the Node. + + char *pointer_; + // Pointer to the contents. +#endif /* ACE_HAS_POSITION_INDEPENDENT_MALLOC */ ACE_Based_Pointer<ACE_Name_Node> next_; // Pointer to the next node in the chain. diff --git a/ace/config-sunos5.5.h b/ace/config-sunos5.5.h index 07946945b44..55bd54ae98c 100644 --- a/ace/config-sunos5.5.h +++ b/ace/config-sunos5.5.h @@ -307,7 +307,7 @@ #define ACE_HAS_STL_QUEUE_CONFLICT #define ACE_HAS_IDTYPE_T -#define ACE_HAS_POSITION_INDEPENDENT_MALLOC +// #define ACE_HAS_POSITION_INDEPENDENT_MALLOC #define ACE_HAS_GPERF #define ACE_HAS_DIRENT diff --git a/examples/Shared_Malloc/Options.cpp b/examples/Shared_Malloc/Options.cpp index 133df2a2ae5..672a6871821 100644 --- a/examples/Shared_Malloc/Options.cpp +++ b/examples/Shared_Malloc/Options.cpp @@ -103,6 +103,7 @@ Options::print_usage_and_die (void) "[-p] (use processes rather than threads)\n" "[-s] (use SysV shared memory rather than mmap)\n" "[-t number of threads or processes to spawn]\n" + "[-T] (enable tracking)\n" "[-n iteration_count]\n%a", -1)); /* NOTREACHED */ } @@ -125,7 +126,7 @@ Options::Options (void) void Options::parse_args (int argc, char *argv[]) { - ACE_Get_Opt get_opt (argc, argv, "dehlL:mn:pst:"); + ACE_Get_Opt get_opt (argc, argv, "dehlL:mn:pst:T"); this->program_name_ = argv[0]; ACE_LOG_MSG->open (this->program_name_); @@ -137,9 +138,9 @@ Options::parse_args (int argc, char *argv[]) this->use_mmap_ = 1; } - int c; - - while ((c = get_opt ()) != -1) + for (int c; + (c = get_opt ()) != -1; + ) { switch (c) { @@ -175,6 +176,9 @@ Options::parse_args (int argc, char *argv[]) case 't': this->spawn_count_ = ACE_OS::atoi (get_opt.optarg); break; + case 'T': + ACE_Trace::start_tracing (); + break; default: this->print_usage_and_die (); /* NOTREACHED */ diff --git a/examples/Shared_Malloc/test_persistence.cpp b/examples/Shared_Malloc/test_persistence.cpp index 7757ae35ef0..481427019ec 100644 --- a/examples/Shared_Malloc/test_persistence.cpp +++ b/examples/Shared_Malloc/test_persistence.cpp @@ -12,7 +12,7 @@ typedef ACE_Malloc <ACE_MMAP_MEMORY_POOL, ACE_Null_Mutex> MALLOC; typedef ACE_Malloc_Iterator <ACE_MMAP_MEMORY_POOL, ACE_Null_Mutex> MALLOC_ITERATOR; // Shared memory manager. -static MALLOC *shmem_manager = 0; +static MALLOC *shmem_allocator = 0; // Backing store name. static const char *backing_store = ACE_DEFAULT_BACKING_STORE; @@ -22,23 +22,26 @@ class Employee public: Employee (void): name_ (0), id_ (0) {} - Employee (char* name, u_long id) : id_ (id) + Employee (const char *name, u_long id) : id_ (id) { - this->name_ = (char*) shmem_manager->malloc (ACE_OS::strlen (name) + 1); - ACE_OS::strcpy (this->name_, name ); + size_t len = ACE_OS::strlen (name) + 1; + this->name_ = ACE_reinterpret_cast (char *, + shmem_allocator->malloc (len)); + ACE_OS::strcpy (this->name_, name); } - ~Employee (void) { shmem_manager->free (this->name_); } + ~Employee (void) { shmem_allocator->free (this->name_); } - char *name (void) const { return this->name_; } + const char *name (void) const { return this->name_; } - void name (char* name) + void name (const char *name) { if (this->name_) - shmem_manager->free (this->name_); - - this->name_ = (char *) shmem_manager->malloc (ACE_OS::strlen (name) + 1); + shmem_allocator->free (this->name_); + size_t len = ACE_OS::strlen (name) + 1; + this->name_ = ACE_reinterpret_cast (char *, + shmem_allocator->malloc (len)); ACE_OS::strcpy (this->name_, name); } @@ -48,10 +51,10 @@ public: void *operator new (size_t) { - return shmem_manager->malloc (sizeof (Employee)); + return shmem_allocator->malloc (sizeof (Employee)); } - void operator delete (void *pointer) { shmem_manager->free (pointer); } + void operator delete (void *pointer) { shmem_allocator->free (pointer); } private: char *name_; @@ -68,7 +71,8 @@ public: ~GUI_Handler (void) { - MALLOC::MEMORY_POOL &pool = shmem_manager->memory_pool(); + MALLOC::MEMORY_POOL &pool = + shmem_allocator->memory_pool (); pool.sync (); } @@ -80,7 +84,8 @@ public: if (::scanf ("%s", option) <= 0) { - ACE_ERROR ((LM_ERROR, "try again\n")); + ACE_ERROR ((LM_ERROR, + "try again\n")); return 0; } @@ -91,7 +96,8 @@ public: case 'i' : if (::scanf ("%s %s", buf1, buf2) <= 0) break; - result = insert_employee (buf1, ACE_OS::atoi (buf2)); + result = insert_employee (buf1, + ACE_OS::atoi (buf2)); break; case 'F' : case 'f' : @@ -143,73 +149,109 @@ public: } private: - int insert_employee (char* name, u_long id) - { - if (find_employee (name) == 0) - ACE_ERROR_RETURN ((LM_ERROR, "Employee already exists\n"), -1); - - Employee* new_employee = new Employee (name, id); - shmem_manager->bind (name, new_employee); - return 0; - } - - int find_employee (char* name) - { - void *temp; - if (shmem_manager->find (name, temp) == 0) - { - Employee *employee = (Employee *) temp; - - ACE_DEBUG ((LM_DEBUG, "The following employee was found.......\n\n")); - ACE_DEBUG ((LM_DEBUG, "Employee name: %s\nEmployee id: %d\n", - employee->name (), employee->id ())); - return 0; - } - - return -1; - } - - int list_employees (void) - { - MALLOC_ITERATOR iterator (*shmem_manager); - - ACE_DEBUG ((LM_DEBUG, "The following employees were found.......\n\n")); - - for (void* temp = 0; - iterator.next (temp) != 0; - iterator.advance ()) - { - Employee *employee = (Employee *) temp; - ACE_DEBUG ((LM_DEBUG, "Employee name: %s\nEmployee id: %d\n", - employee->name (), employee->id ())); - } - return 0; - } - - int delete_employee (char* name) - { - void *temp; - - if (shmem_manager->unbind (name, temp) == 0) - { - Employee *employee = (Employee *) temp; + int insert_employee (const char *name, + u_long id); + int find_employee (const char *name); + int list_employees (void); + int delete_employee (const char *name); +}; - ACE_DEBUG ((LM_DEBUG, - "The following employee was found and deleted.......\n\n")); +int +GUI_Handler::insert_employee (const char *name, + u_long id) +{ + if (find_employee (name) == 0) + ACE_ERROR_RETURN ((LM_ERROR, + "Employee already exists\n"), + -1); + + Employee *new_employee = 0; + + ACE_NEW_RETURN (new_employee, + Employee (name, id), + -1); + + if (shmem_allocator->bind (name, + new_employee) == -1) + ACE_ERROR_RETURN ((LM_ERROR, + "bind failed\n"), + -1); + return 0; +} - ACE_DEBUG ((LM_DEBUG, "Employee name: %s\nEmployee id: %d\n", - employee->name (), employee->id ())); +int +GUI_Handler::find_employee (const char *name) +{ + void *temp; + + if (shmem_allocator->find (name, + temp) == 0) + { + Employee *employee = ACE_reinterpret_cast (Employee *, + temp); + + ACE_DEBUG ((LM_DEBUG, + "The following employee was found.......\n\n")); + ACE_DEBUG ((LM_DEBUG, + "Employee name: %s\nEmployee id: %d\n", + employee->name (), + employee->id ())); + return 0; + } + + return -1; +} - delete employee; - return 0; - } +int +GUI_Handler::list_employees (void) +{ + MALLOC_ITERATOR iterator (*shmem_allocator); + + ACE_DEBUG ((LM_DEBUG, + "The following employees were found.......\n\n")); + + for (void *temp = 0; + iterator.next (temp) != 0; + iterator.advance ()) + { + Employee *employee = ACE_reinterpret_cast (Employee *, + temp); + ACE_DEBUG ((LM_DEBUG, + "Employee name: %s\nEmployee id: %d\n", + employee->name (), + employee->id ())); + } + return 0; +} - ACE_DEBUG ((LM_DEBUG, - "There is no employee with name %s", - name)); - return -1; - } -}; +int +GUI_Handler::delete_employee (const char *name) +{ + void *temp; + + if (shmem_allocator->unbind (name, + temp) == 0) + { + Employee *employee = ACE_reinterpret_cast (Employee *, + temp); + + ACE_DEBUG ((LM_DEBUG, + "The following employee was found and deleted.......\n\n")); + + ACE_DEBUG ((LM_DEBUG, + "Employee name: %s\nEmployee id: %d\n", + employee->name (), + employee->id ())); + + delete employee; + return 0; + } + + ACE_DEBUG ((LM_DEBUG, + "There is no employee with name %s", + name)); + return -1; +} void parse_args (int argc, char *argv[]) @@ -223,7 +265,9 @@ main (int argc, char *argv[]) { parse_args (argc, argv); - shmem_manager = new MALLOC (backing_store); + ACE_NEW_RETURN (shmem_allocator, + MALLOC (backing_store), + -1); GUI_Handler handler; diff --git a/examples/Shared_Malloc/test_position_independent_malloc.cpp b/examples/Shared_Malloc/test_position_independent_malloc.cpp index 728fc158813..2586cbe0d32 100644 --- a/examples/Shared_Malloc/test_position_independent_malloc.cpp +++ b/examples/Shared_Malloc/test_position_independent_malloc.cpp @@ -5,6 +5,7 @@ #include "ace/Malloc.h" #include "ace/Based_Pointer_T.h" +#include "ace/Get_Opt.h" #include "ace/Synch.h" #include "test_position_independent_malloc.h" @@ -16,6 +17,15 @@ typedef ACE_Malloc <ACE_MMAP_MEMORY_POOL, ACE_Process_Mutex> MALLOC; static void *base_addr = ACE_DEFAULT_BASE_ADDR; #if 0 +// Some dummy data +struct Dummy_Data +{ + int i1_; + int i2_; + int i3_; + // ACE_Based_Pointer<Dummy_Data> next_; +}; + struct Long_Test { ACE_Based_Pointer<long> bpl_; @@ -26,6 +36,7 @@ struct Long_Test static void print (Dummy_Data *data) { +#if 0 ACE_DEBUG ((LM_DEBUG, "<<<<\ni1_ = %d, i2_ = %d, i3_ = %d\n", data->i1_, @@ -37,6 +48,7 @@ print (Dummy_Data *data) data->next_->i1_, data->next_->i2_, data->next_->i3_)); +#endif } static void * @@ -48,16 +60,23 @@ initialize (MALLOC *allocator) 0); Dummy_Data *data1 = new (ptr) Dummy_Data; + data1->i1_ = 111; + data1->i2_ = 222; + data1->i3_ = 333; + void *gap = 0; ACE_ALLOCATOR_RETURN (gap, allocator->malloc (sizeof (256)), 0); + allocator->free (gap); + ACE_ALLOCATOR_RETURN (ptr, allocator->malloc (sizeof (Dummy_Data)), 0); Dummy_Data *data2 = new (ptr) Dummy_Data; +#if 0 data1->next_ = data2; data1->next_->i1_ = 111; data1->next_->i2_ = 222; @@ -67,7 +86,6 @@ initialize (MALLOC *allocator) data2->next_->i2_ = -222; data2->next_->i3_ = -333; -#if 0 // Test in shared memory using long (array/pointer) ACE_ALLOCATOR_RETURN (ptr, allocator->malloc (sizeof (Long_Test)), @@ -101,17 +119,35 @@ initialize (MALLOC *allocator) long longCont_lcl4 = lt_lcl->bpl_[4]; #endif /* 0 */ - allocator->free (gap); - return data1; } +static void +parse_args (int argc, char *argv[]) +{ + ACE_Get_Opt get_opt (argc, argv, "a:T"); + + for (int c; + (c = get_opt ()) != -1; + ) + { + switch (c) + { + case 'a': + // Override the default base address. + base_addr = (void *) ACE_OS::atoi (get_opt.optarg); + break; + case 'T': + ACE_Trace::start_tracing (); + break; + } + } +} + int main (int argc, char *argv[]) { - if (argc > 1) - // Override the default base address. - base_addr = (void *) ACE_OS::atoi (argv[1]); + parse_args (argc, argv); ACE_MMAP_Memory_Pool_Options options (base_addr); @@ -129,7 +165,10 @@ main (int argc, char *argv[]) if (allocator->find ("foo", data) == -1) { - data = initialize (allocator); + // data = initialize (allocator); + + data = allocator->malloc (sizeof (long)); + *(long *) data = -36; if (allocator->bind ("foo", data) == -1) @@ -146,8 +185,10 @@ main (int argc, char *argv[]) else { // @@ Add a new print statement... - print ((Dummy_Data *) data); - + // print ((Dummy_Data *) data); + ACE_DEBUG ((LM_DEBUG, + "data = %d\n", + *(long *) data)); allocator->free (data); allocator->remove (); ACE_DEBUG ((LM_DEBUG, @@ -159,6 +200,8 @@ main (int argc, char *argv[]) #if defined (ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION) template class ACE_Based_Pointer<Dummy_Data>; +template class ACE_Based_Pointer_Basic<Dummy_Data>; #elif defined (ACE_HAS_TEMPLATE_INSTANTIATION_PRAGMA) #pragma instantiate ACE_Based_Pointer<Dummy_Data> +#pragma instantiate ACE_Based_Pointer_Basic<Dummy_Data> #endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */ diff --git a/include/makeinclude/build_dll.bor b/include/makeinclude/build_dll.bor index 93be29d69e7..29fc58487d5 100644 --- a/include/makeinclude/build_dll.bor +++ b/include/makeinclude/build_dll.bor @@ -18,24 +18,35 @@ TARGET = $(BINDIR)\$(NAME)$(LIB_DECORATOR).dll -$(TARGET): $(OBJFILES) +$(TARGET): $(OBJFILES) $(RESOURCE) @$(MAKE_BINDIR) $(LD) @&&! $(COMMON_LFLAGS) $(DLL_LFLAGS) $(LFLAGS) + $(DLL_STARTUP_OBJ) $(OBJFILES), + $(TARGET),, + - $(COMMON_LIBS) $(LIBFILES) + $(COMMON_LIBS) $(LIBFILES),, + + $(RESOURCE) ! !ifdef CPPDIR .path.cpp = $(CPPDIR) !endif +!ifdef RESDIR +.path.rc = $(RESDIR) +!else +.path.rc = . +!endif + .path.obj = $(OBJDIR) .cpp.obj: @$(MAKE_OBJDIR) $(CC) $(COMMON_CFLAGS) $(DLL_CFLAGS) $(CFLAGS) -c -n$(@D) $< +.rc.res: + @$(MAKE_OBJDIR) + $(RC) -fo$@ $< + .autodepend diff --git a/include/makeinclude/build_exe.bor b/include/makeinclude/build_exe.bor index d407aaec077..c209fbe5cf5 100644 --- a/include/makeinclude/build_exe.bor +++ b/include/makeinclude/build_exe.bor @@ -19,25 +19,36 @@ TARGET = $(BINDIR)\$(NAME).exe -$(TARGET): $(OBJFILES) +$(TARGET): $(OBJFILES) $(RESOURCE) @$(MAKE_BINDIR) $(LD) @&&! $(COMMON_LFLAGS) $(EXE_LFLAGS) $(LFLAGS) + $(EXE_STARTUP_OBJ) $(OBJFILES), + $(TARGET),, + - $(COMMON_LIBS) $(LIBFILES) + $(COMMON_LIBS) $(LIBFILES),, + + $(RESOURCE) ! !ifdef CPPDIR .path.cpp = $(CPPDIR) !endif +!ifdef RESDIR +.path.rc = $(RESDIR) +!else +.path.rc = . +!endif + .path.obj = $(OBJDIR) .cpp.obj: @$(MAKE_OBJDIR) $(CC) $(COMMON_CFLAGS) $(EXE_CFLAGS) $(CFLAGS) -c -n$(@D) $< +.rc.res: + @$(MAKE_OBJDIR) + $(RC) -fo$@ $< + .autodepend diff --git a/include/makeinclude/compiler.bor b/include/makeinclude/compiler.bor index 664cee6b4a1..24cae748a23 100644 --- a/include/makeinclude/compiler.bor +++ b/include/makeinclude/compiler.bor @@ -11,6 +11,8 @@ # ~~~~~~~~ # CC - name of compiler # LD - name of linker +# AR - name of librarian +# RC - name of resource compiler # COMMON_CFLAGS - compiler flags for all targets # COMMON_LFLAGS - linker flags for all targets # COMMON_LIBS - linker library files for all targets @@ -35,6 +37,7 @@ CC = bcc32 LD = ilink32 AR = tlib +RC = brcc32 # # Common flags diff --git a/netsvcs/servers/main.cpp b/netsvcs/servers/main.cpp index c0881b3b0aa..87acc540ca0 100644 --- a/netsvcs/servers/main.cpp +++ b/netsvcs/servers/main.cpp @@ -33,109 +33,120 @@ main (int argc, char *argv[]) if (ACE_Service_Config::open (argc, argv) == -1) { if (errno != ENOENT) - ACE_ERROR_RETURN ((LM_ERROR, + ACE_ERROR_RETURN ((LM_ERROR, "%p\n", "open"), 1); else // Use static linking. - { + { + if (ACE::debug () == 0) + ACE_Log_Msg::disable_debug_messages (); + // Calling ACE_SVC_INVOKE to create a new Service_Object. // Stash the newly created Service_Object into an // ACE_Service_Object_Ptr which is an <auto_ptr> specialized // for ACE_Service_Object. - char *l_argv[3]; + char *l_argv[3]; char name_port[] = "-p " ACE_DEFAULT_NAME_SERVER_PORT_STR; l_argv[0] = name_port; - l_argv[1] = 0; - ACE_Service_Object_Ptr sp_1 = ACE_SVC_INVOKE (ACE_Name_Acceptor); + l_argv[1] = 0; + ACE_Service_Object_Ptr sp_1 = ACE_SVC_INVOKE (ACE_Name_Acceptor); - if (sp_1->init (1, l_argv) == -1) - ACE_ERROR ((LM_ERROR, + if (sp_1->init (1, l_argv) == -1) + ACE_ERROR ((LM_ERROR, "%p\n%a", "Name Service", 1)); char time_port[] = "-p " ACE_DEFAULT_TIME_SERVER_PORT_STR; - l_argv[0] = time_port; - l_argv[1] = 0; - ACE_Service_Object_Ptr sp_2 = ACE_SVC_INVOKE (ACE_TS_Server_Acceptor); + l_argv[0] = time_port; + l_argv[1] = 0; + ACE_Service_Object_Ptr sp_2 = ACE_SVC_INVOKE (ACE_TS_Server_Acceptor); - if (sp_2->init (1, l_argv) == -1) - ACE_ERROR ((LM_ERROR, + if (sp_2->init (1, l_argv) == -1) + ACE_ERROR ((LM_ERROR, "%p\n%a", "TS Server Acceptor", 1)); char clerk_port[] = "-p 10011"; - l_argv[0] = argv[0]; - l_argv[1] = clerk_port; - l_argv[2] = 0; - ACE_Service_Object_Ptr sp_3 = ACE_SVC_INVOKE (ACE_TS_Clerk_Processor); + l_argv[0] = argv[0]; + l_argv[1] = clerk_port; + l_argv[2] = 0; + ACE_Service_Object_Ptr sp_3 = ACE_SVC_INVOKE (ACE_TS_Clerk_Processor); - if (sp_3->init (2, l_argv) == -1) - ACE_ERROR ((LM_ERROR, + if (sp_3->init (2, l_argv) == -1) + ACE_ERROR ((LM_ERROR, "%p\n%a", "TS Clerk Processor", 1)); char token_port[] = "-p " ACE_DEFAULT_TOKEN_SERVER_PORT_STR; - l_argv[0] = token_port; - l_argv[1] = 0; - ACE_Service_Object_Ptr sp_4 = ACE_SVC_INVOKE (ACE_Token_Acceptor); + l_argv[0] = token_port; + l_argv[1] = 0; + ACE_Service_Object_Ptr sp_4 = ACE_SVC_INVOKE (ACE_Token_Acceptor); - if (sp_4->init (1, l_argv) == -1) - ACE_ERROR ((LM_ERROR, + if (sp_4->init (1, l_argv) == -1) + ACE_ERROR ((LM_ERROR, "%p\n%a", "Token Service", 1)); - char thr_logging_port[] = "-p " ACE_DEFAULT_THR_LOGGING_SERVER_PORT_STR; - l_argv[0] = thr_logging_port; - l_argv[1] = 0; - ACE_Service_Object_Ptr sp_5 = ACE_SVC_INVOKE (ACE_Thr_Server_Logging_Acceptor); + char thr_logging_port[] = "-p " ACE_DEFAULT_THR_LOGGING_SERVER_PORT_S + TR; + l_argv[0] = thr_logging_port; + l_argv[1] = 0; + ACE_Service_Object_Ptr sp_5 = + ACE_SVC_INVOKE (ACE_Thr_Server_Logging_Acceptor); - if (sp_5->init (1, l_argv) == -1) - ACE_ERROR ((LM_ERROR, + if (sp_5->init (1, l_argv) == -1) + ACE_ERROR ((LM_ERROR, "%p\n%a", "Threaded Logging Server", 1)); char logging_port[] = "-p " ACE_DEFAULT_LOGGING_SERVER_PORT_STR; - l_argv[0] = logging_port; - l_argv[1] = 0; - ACE_Service_Object_Ptr sp_6 = ACE_SVC_INVOKE (ACE_Server_Logging_Acceptor); + l_argv[0] = logging_port; + l_argv[1] = 0; + ACE_Service_Object_Ptr sp_6 = + ACE_SVC_INVOKE (ACE_Server_Logging_Acceptor); - if (sp_6->init (1, l_argv) == -1) - ACE_ERROR ((LM_ERROR, + if (sp_6->init (1, l_argv) == -1) + ACE_ERROR ((LM_ERROR, "%p\n%a", "Logging Server", 1)); - l_argv[0] = logging_port; - l_argv[1] = 0; - ACE_Service_Object_Ptr sp_7 = ACE_SVC_INVOKE (ACE_Client_Logging_Acceptor); + l_argv[0] = logging_port; + l_argv[1] = 0; + ACE_Service_Object_Ptr sp_7 = + ACE_SVC_INVOKE (ACE_Client_Logging_Acceptor); - if (sp_7->init (1, l_argv) == -1) - ACE_ERROR ((LM_ERROR, + if (sp_7->init (1, l_argv) == -1) + ACE_ERROR ((LM_ERROR, "%p\n%a", "Logging Client", 1)); - // Run forever, performing the configured services until we - // are shut down by a SIGINT/SIGQUIT signal. + // Run forever, performing the configured services until we + // are shut down by a SIGINT/SIGQUIT signal. - ACE_Reactor::run_event_loop (); + ACE_Reactor::run_event_loop (); - // Destructors of ACE_Service_Object_Ptr's automagically - // call fini(). - } + // Destructors of ACE_Service_Object_Ptr's automagically + // call fini(). + } } else // Use dynamic linking. + { + if (ACE::debug () == 0) + ACE_Log_Msg::disable_debug_messages (); - // Run forever, performing the configured services until we are - // shut down by a SIGINT/SIGQUIT signal. + // Run forever, performing the configured services until we are + // shut down by a SIGINT/SIGQUIT signal. - ACE_Reactor::run_event_loop (); + ACE_Reactor::run_event_loop (); + } return 0; } diff --git a/tests/DLL_Test.cpp b/tests/DLL_Test.cpp index a35b9b19a76..c862af6d065 100644 --- a/tests/DLL_Test.cpp +++ b/tests/DLL_Test.cpp @@ -42,11 +42,7 @@ USELIB("..\ace\aced.lib"); #if defined (ACE_WIN32) # define OBJ_SUFFIX ".exe" -# if defined (__BORLANDC__) -# define OBJ_PREFIX ".\\bor\\bin\\" -# else -# define OBJ_PREFIX "" -# endif /* defined (__BORLANDC__) */ +# define OBJ_PREFIX "" #else # define OBJ_SUFFIX ACE_DLL_SUFFIX # define OBJ_PREFIX "./" ACE_DLL_PREFIX diff --git a/tests/Makefile.bor b/tests/Makefile.bor index d895c168c90..7fb5b64127f 100644 --- a/tests/Makefile.bor +++ b/tests/Makefile.bor @@ -10,6 +10,9 @@ TESTS = \ Barrier_Test \ Basic_Types_Test \ Buffer_Stream_Test \ + Cache_Map_Manager_Test \ + Cached_Conn_Test \ + Cached_Accept_Conn_Test \ CDR_Test \ Collection_Test \ Conn_Test \ @@ -19,10 +22,13 @@ TESTS = \ Enum_Interfaces_Test \ Env_Value_Test \ Future_Test \ + Future_Set_Test \ Handle_Set_Test \ High_Res_Timer_Test \ Hash_Map_Manager_Test \ + Hash_Map_Bucket_Iterator_Test \ IOStream_Test \ + Map_Manager_Test \ Map_Test \ Mem_Map_Test \ MM_Shared_Memory_Test \ @@ -66,6 +72,7 @@ TESTS = \ Task_Test \ Thread_Manager_Test \ Thread_Mutex_Test \ + Thread_Pool_Reactor_Test \ Thread_Pool_Test \ Time_Service_Test \ Time_Value_Test \ @@ -76,8 +83,6 @@ TESTS = \ Upgradable_RW_Test \ XtReactor_Test -# Map_Manager_Test \ - all_tests: $(TESTS) $(TESTS): diff --git a/tests/run_tests.bat b/tests/run_tests.bat index 17f9b782920..5314fe95db8 100644 --- a/tests/run_tests.bat +++ b/tests/run_tests.bat @@ -36,7 +36,8 @@ goto setupmsc shift :setupbor set arg=%1 -set exedir=.\bor\bin\ +set exedir=.\Dynamic\Release\ +set PATH=%PATH%;%exedir% rem Set deco to whatever decoration you have for the executables set deco= set platform=bor |