Discussion:
[omniORB] Fw: (by abcluo@163.com)use sequ ence<struct> problem ?
roger
2006-10-17 08:09:28 UTC
Permalink
Thanks to Clarke Brunt!

I has this problem:

I downloaded the Win32 binary distribution of omniORB,File is omniORB-4.0.7-win32-vc7.zip , file size is 17.6MB,But omniORB407_ms7.exe is 36.3MB size.
What's the difference between them( .exe file and .zip file package)?

In omniORB-4.0.7-win32-vc7.zip ,It's .DLL and .lib is used by the compiler
which one? Is MSVC++7.1 or MSVC++7.1 compiler?

My application code in debug mode ,add The following Libraries to "Additional Dependencies":
omniORB407_rtd.lib
omnithread32_rtd.lib
omniDynamic407_rtd.lib
ws2_32.lib
mswsock.lib
odbc32.lib
odbccp32.lib
msvcstubd.lib

release mode add The following Libraries to "Additional Dependencies":
omniORB407_rt.lib
omnithread32_rt.lib
omniDynamic407_rt.lib
ws2_32.lib
mswsock.lib
odbc32.lib
odbccp32.lib
msvcstub.lib

Is this correct?





-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.omniorb-support.com/pipermail/omniorb-list/attachments/20061017/6d2acd35/attachment.htm
OKeeffe, Michael K
2006-10-17 20:37:11 UTC
Permalink
The omniORB407_ms7.exe file is a self-extracting zip file, which will install omniORB for you for that version of VC++.

Details here:
http://www.omniorb-support.com/pipermail/omniorb-list/2006-July/027864.html

You don't need both msvcstub.lib and omniDynamic407_rt.lib. The msvcstub.lib is useful if you aren't using dynamic interfaces, so you can link to a smaller library. See the make files in the examples directory for more details.

-Mike

-----Original Message-----
From: omniorb-list-***@omniorb-support.com [mailto:omniorb-list-***@omniorb-support.com] On Behalf Of roger
Sent: Monday, October 16, 2006 9:09 PM
To: omniorb-***@omniorb-support.com
Subject: [omniORB] Fw: (by ***@163.com)use sequ ence<struct> problem ?


Thanks to Clarke Brunt!

I has this problem:

I downloaded the Win32 binary distribution of omniORB,File is omniORB-4.0.7-win32-vc7.zip , file size is 17.6MB,But omniORB407_ms7.exe is 36.3MB size.
What's the difference between them( .exe file and .zip file package)?

In omniORB-4.0.7-win32-vc7.zip ,It's .DLL and .lib is used by the compiler
which one? Is MSVC++7.1 or MSVC++7.1 compiler?

My application code in debug mode ,add The following Libraries to "Additional Dependencies":
omniORB407_rtd.lib
omnithread32_rtd.lib
omniDynamic407_rtd.lib
ws2_32.lib
mswsock.lib
odbc32.lib
odbccp32.lib
msvcstubd.lib

release mode add The following Libraries to "Additional Dependencies":
omniORB407_rt.lib
omnithread32_rt.lib
omniDynamic407_rt.lib
ws2_32.lib
mswsock.lib
odbc32.lib
odbccp32.lib
msvcstub.lib

Is this correct?












ÃÀ Å® ¿Ö ²À °Ü ŒÒ Ðã ( ×é ÍŒ )
¶À ŒÒ Åû ¶ ! С ×Ê Å® ÈË 8 žö Ÿø ¶¥ Òþ ÃØ µÄ È€ Ê ( ×é ÍŒ ) <http://adtaobao.allyes.com/main/adfclick?db=adtaobao&bid=600,597,58&cid=29985,198,1&sid=32501&show=ignore&url=http://www.taobao.com/vertical/lady/pro.php>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.omniorb-support.com/pipermail/omniorb-list/attachments/20061017/5dcb303c/attachment.htm
Clarke Brunt
2006-10-17 22:33:37 UTC
Permalink
I still mainly use VC6 myself, so can't be sure option options in 7.

In VC6, under Project Settings, C/C++, Code Generation, Use run-time
library, you need to choose Multithreaded DLL (or Debug Multithreaded
DLL for debug build), and not either of the single threaded options, or
the ones which don't mention DLL (statically linked). I would guess that
VC7 has similar options?
--
Clarke Brunt, Principal Software Engineer, Trafficmaster


This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify the system manager. This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. If you are not the intended recipient you are notified that disclosing, copying, distributing or taking any action in reliance on the contents of this information is strictly prohibited.
roger
2006-10-23 11:39:16 UTC
Permalink
Hi,
My problem was Solved!
Thanks to everyone!
Special thanks Clarke Brunt!


I am use omniORB4.0.7 on win2000+vc7.1,
The problem isn't Cause by use sequence<struct> ,and it is caused by project setting lib file and runtime library mode!
The project setting choose "Multithreaded DLL(release build)" or "Debug Multithreaded DLL (debug build)". This is OK.
My application is work fine now!

Application code :
=====================================

//----------IDL---------
struct NetDataItem
{
long id;
string name;
};
typedef sequence<NetDataItem> DataArray;
typedef sequence<long> DataLongArray;

interface QDataSeq
{
DataArray QueryDatas();
DataLongArray QueryLongData();
};

//---------server code--------------

// return struct data Sequence
DataArray* QDataSeq_i::QueryDatas(){
int cnt =100;
DataArray_var datas = new DataArray((CORBA::Long)cnt);
datas->length(cnt);
for (int i =0;i< cnt; ++i)
{
datas[i].id = (CORBA::Long)(i+1);
datas[i].name = CORBA::string_dup("aaaa"); //
}
std::cout << "OK" << endl;

return datas._retn();
}

// return long Sequence
DataArray* QDataSeq_i::QueryLongData(){
int cnt =100;
DataLongArray_var datas = new DataLongArray((CORBA::Long)cnt);
datas->length(cnt);
for (int i =0;i< cnt; ++i)
{
datas[i] = (CORBA::Long)(i+1);
}
std::cout << "OK" << endl;

return datas._retn();

}


//-----------client code-----------------------

//query struct data Sequence , use _var
void queryStructSeqData(QDataSeq_ptr e)
{
DataArray_var dest = e->QuearyDatas();
int len = pdest->length();
std::cerr << "query sequence size &pound;&ordm;" << len << endl;

//do something...

}


//query long Sequence. It is work fine and not have memory leak.
void queryLongSeqData(QDataSeq_ptr e)
{
DataArray_var dest = e->QueryLongData();
int len = dest->length();
std::cerr << "query sequence size is:" << len << endl;

//do something...

}

//-----------project setting--------------
debug mode add The following Libraries to "Additional Dependencies":
omniORB407_rtd.lib
omnithread32_rtd.lib
omniDynamic407_rtd.lib
ws2_32.lib
mswsock.lib
odbc32.lib
odbccp32.lib

Run-time library:Debug Multithreaded DLL

----------------
release mode add The following Libraries to "Additional Dependencies":
omniORB407_rt.lib
omnithread32_rt.lib
omniDynamic407_rt.lib
ws2_32.lib
mswsock.lib
odbc32.lib
odbccp32.lib

Run-time library:Multithreaded DLL

====================================

Thanks again to everyone!









-----Ô­ÊŒÓÊŒþ-----
·¢ŒþÈË:"Clarke Brunt"
·¢ËÍʱŒä:2006-10-18 00:33:38
ÊÕŒþÈË:""
³­ËÍ:(ÎÞ)
Ö÷Ìâ:Re: [omniORB] Fw: (by ***@163.com)use sequ ence problem ?


I still mainly use VC6 myself, so can't be sure option options in 7.



In VC6, under Project Settings, C/C++, Code Generation, Use run-time

library, you need to choose Multithreaded DLL (or Debug Multithreaded

DLL for debug build), and not either of the single threaded options, or

the ones which don't mention DLL (statically linked). I would guess that

VC7 has similar options?
--
Clarke Brunt, Principal Software Engineer, Trafficmaster





This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify the system manager. This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. If you are not the intended recipient you are notified that disclosing, copying, distributing or taking any action in reliance on the contents of this information is strictly prohibited.



_______________________________________________

omniORB-list mailing list

omniORB-***@omniorb-support.com

http://www.omniorb-support.com/mailman/listinfo/omniorb-list

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.omniorb-support.com/pipermail/omniorb-list/attachments/20061023/74bcfadb/attachment.htm
Loading...