reading unicode file using pure C++?

161 byte By gulshan at 2007-11-25 23:52:35
Hi Guys, I need help reading a unicode/utf8 file using C/C++. Any pointers or sample code will be of great help. ThanksGulshan

Sun CC 5.2: templates: -D option quoting bug?

703 byte By sankarV at 2007-11-25 23:52:36
Hi,I am using Sun CC 5.2 (Forte 6 Update 1) on a Solaris 8.I am finding the following quoting problem in SunWS_cache.When given an option like -DINL=inline to the compiler, The SunWS_cache/CC_state file stores it as: -DINL='inline' in a =OP line. That is, it adds extraneous quotes around the ...

RTTI linkage problem

2885 byte By tzach98 at 2007-11-25 23:52:37
I added RTTI to one of my templates:cout << typeid(_Tp).name()All the libraries compile, but when I link:Undefinedfirst referenced symbolin file__RTTI__1CpnWyyy_ libxx.soI suspect the compiler expect the _RTTI_ prefix in all the libraries, but did not find it on this lib.Do I need some ...

sol 2.6, 5.3 compiler: Extern "C" gives Undefined symbol _beginthread

1229 byte By cnzzz at 2007-11-25 23:52:38
Hi,The setup we used compiled fine in 4.2 but is giving an unresolved symbol of _beginthread whentrying to link. I've tried to add wrapper to the implementation function but no effect.the problem is when it tries to link everything _beginthead is unresolvedI'm compiling in 5.3 - standard ...

Assertion error with Workshop C++ compiler 5.0 on Solaris 8

717 byte By babulalv at 2007-11-25 23:52:39
Hi,I am using C++ compiler version 5.0 with the latest patch 107311-16. The version info for the compiler gives:CC: WorkShop Compilers 5.0 01/12/04 C++ 5.0 Patch 107311-16Patch 107357-11 is also installed. But I get the following error:>> Assertion:(../links/ftemplate.cc, line 435)while ...

C++help

686 byte By binas at 2007-11-25 23:52:40
hi guys,could you please help me with my C++ programI was trying to do it but i have no clueI have to write a function that finds out how many elements in an integer array are larger than the average of all the value is the array. The function should accept and integer array and an integer that ...

__rtaccess error

1816 byte By amitraval at 2007-11-25 23:52:41
I am usingSolaris 2.8C++ compiler Forte 6 update 2Rogewave SourcePro edition 3Visibroker for C++ 3.3.2Trying to compile my application using command/usr/local/forte/SUNWspro/bin/CC -compat=4 -mt -DSOLARIS -DRWDEBUG=1 -DRW_THR_DEBUG -D_RWCONFIG=7s -features=%all,no%strictdestrorder ...

64 bit multithreaded program is dumping core(very very interesting problem)

4521 byte By sudhirshp at 2007-11-25 23:52:42
Hi,I have a C++ program which is quite huge !When run this runs fine for some 3 hrs (The program is some batch process)and after that it produces a SIGSEGV.The SEGV is coming in the STLs.The function stack is given below [1] _lsearch(0xffffffff7e1bede8, 0x18, 0xffffffff7e1bee00, 0x40, ...

CCrti.o

253 byte By cmcwi00 at 2007-11-25 23:52:43
what is CCrti.o? I received the following error when doing a simple compile: CC: Cannot fin /opt/SUNWspro/WS6U2/lib/CCrti.o Is this part of the initial compiler installation or is it built after?-new to Forte CC

Using static function in c++

312 byte By clerma at 2007-11-25 23:52:44
Hi,I'm using an static function on C++ program, as :static int lRead(char *ptr, Socket *pSock);but when I compiled recived the following error: Error: "static" is not allowed here.any idea about how do i need to set static functions and variables?regards, ...

Solaris 2.6/2.8

133 byte By carsonw200 at 2007-11-25 23:52:46
Does anyone know, if I build an executable under Solaris 2.6, will it work under Solaris 2.8?ThanksCarson

How could I capture IP addresses changed at run-time

26 byte By paulshen at 2007-11-25 23:52:47
as the title

problems with (STL)string new

1617 byte By its_user at 2007-11-25 23:52:48
I am working on C++ solaris8.0 using STL strings within my application. The code regularly crashes when built in 64 bit mode at the point when I create a new string. But when the same code is compiled in 32 bit, it works without any problem. The code has been checked with purify and there are ...

memory issues when running C++ code linked with ld

539 byte By rbankar at 2007-11-25 23:52:50
I have an application which was compiled with CC, but linked using ld.When I run my executable, I always have memory issues. The program slows down tremendously until it uses close to 2GB of memory and then errors with:Run-time exception error; current exception: xallocNo handler for ...

How could my program be notified when IP addresses are changed?

26 byte By paulshen at 2007-11-25 23:52:51
As the title

Where to find undefined symbol delay and drv_usectohz

284 byte By fschroedter at 2007-11-25 23:52:53
Hello,i use WS6U1 on Solaris 5.8 and i try to use the kernel function delay (example see "man delay").I get 2 undefined symbols "delay" and "drv_usectohz", but i don't know which lib-file to include.Can anybody help ?kind regardsFrank

symbol referencing error

314 byte By songangxp at 2007-11-25 23:52:55
hi ,would you help me ?my application is using oracle's PRO*C connect oracle DB.precompiling finished successfully,but compiling and linking failedi use command :make -f demo_proc.mk OBJS=test.o EXE=test build.but system tell me :symbol referencing errorwhy ?thank you ! ...

WorkShop C++ 5.0 compiler issue

1247 byte By susanac at 2007-11-25 23:52:57
Hi,I'm trying to re-compile some sample code from a trusted source(these codes were compiled by sender, in a package with their respective executables and object files). They have no problem compiling their code.The only requirement is that the compiler be WorkShop version 4.X or greaterWhen I ...

Problem with RWTValSortedVector<RWCString, RWCString>

444 byte By himanshu_prakash at 2007-11-25 23:52:59
Hi,I'm facing this problem when I try to define following:RWTValSortedVector<RWCString, RWCString> list;Now if I say list.insert(RWCString("xyz"));It reports compile error saying:"/sollocal/SUNWspro/WS6U2/include/CC/rw7/rw/ev_srtsq.h", line 98: Error: Could not find a match for ...

Compilation Error while using string (Please help)

999 byte By mshetty1 at 2007-11-25 23:53:00
Hi,I am using "Sun WorkShop Compiler C++ SPARC Version 5.000". Compiling code which contains a "string variable" throws the following error:"/opt/WS5/SC5.0/include/CC/./new", line 32: Error: The prior declaration for operator new(unsigned) has no exception ...

specialization of class template functions

843 byte By szombath at 2007-11-25 23:53:01
Hello all,what's wrong with this code? It works just fine with g++.class Foo {public:Foo() { }template <typename T> void method();};template <> void Foo::method<int>() { }int main(int argc, char *argv[]){Foo foo;foo.method<int>(); //OKFoo& foo_ref = ...

TimeZones - Lists and Conversions

815 byte By jonjsilver at 2007-11-25 23:53:03
I am needing to provide a TOD function that will accept an orig_time, orig_timezone and dest_timezone and will outpout dest_time. It will take into account DST as well. Any idea where I can get a list of all of the possible timezones? and how I would go aboutthis conversion. I really do not see ...

C++ Compiler 3.0.1 needed

733 byte By ezzhang at 2007-11-25 23:53:04
Hi, My UNIX was recently upgraded from Solaries 7 to Solaries 8. My collegues has reinstalledC++ 3.0.1 which was working on Solaries 7 before. But when I tried to compile a simple code #include <stdio.h>main () { printf("Hello World!");}using%CC test.C",We got following error message,ld: ...

testcase: enums + operator overloads

2006 byte By szombath at 2007-11-25 23:53:06
Hallo all,we have detected that Forte C++ 5.3 shows up a different behavior with respect to operator overloading of enums. The example below works with Forte C++ 5.2 and g++, but not with Forte C++ 5.3.I would also like to know, which one comforming the ISO C++ standard. Thanks in advance.> ...

iostreams run too slow in CC 5.3

2067 byte By psandison at 2007-11-25 23:53:08
Hi,I'm having a lot of trouble with the performance of the standard iostreams implementation on CC 5.3. We recently ported a lot of code from CC 4.2 (using the STLport implementation) to CC 5.3 (using RogueWave 2.1.1 according to the readme). I have read the note in the c++_faq readme which ...

Would like to look at owner / lock status of mutex, possibly adding to dbx?

603 byte By belliott2 at 2007-11-25 23:53:09
Given the functions in libthread_db.so I can do all sorts of neat stuff like look at the lock status of a mutex or look at the thread pointer of the thread that locked the mutex... Instead of writing a new tool to do this, could I add a plugin to dbx?Could I add a command, say "printsyncobj ...

HP-UX to Solaris Porting Guide

204 byte By mshetty1 at 2007-11-25 23:53:10
Hi,Is there an HP-UX to Solaris Porting Guide available ? Any thing that talks of the things supported by HP-UX and not supported by Solaris.Thanks and Regards,Mranalini

compiling error using STL vector

2251 byte By paulshen at 2007-11-25 23:53:11
When I using the following code#include <vector>in my program. compiling error will be:"/usr/include/sys/machlock.h", line 36: Error: lock_t is not defined."/usr/include/sys/synch.h", line 54: Error: Type name expected instead of "upad64_t"."/usr/include/sys/synch.h", line 56: Error: Type ...

using __SUNPRO_CC in makefile -error

668 byte By cnzzz at 2007-11-25 23:53:12
Hi,Using solaris 2.6, make (i think is) sun0s 5.6 and compiler version is 5.3In the make file I'm trying to do a couple of things: ifneq(__SUNPRO_CC,0x530)include $(OBJDIR)/.dependendifIt should be equal and therefore not do makedepend (for some reason we get a coredump when doing a makedepend ...

dbx() sees bogus[?] thrown exception

4958 byte By mdfeather at 2007-11-25 23:53:13
While debugging a multithreaded C++ application, dbx() issued the warning(s) shown below, which I interpret to mean that although an exception was thrown, dbx() cannot provide more detailed information. Most often the "exception" occurs in a call to ofstream::open(), but not always. I placed a ...

SUNWspro/WS6U2/include compilation error

2046 byte By kaylorb at 2007-11-25 23:53:14
I am using Solaris 2.7 with compiler version: Sun WorkShop 6 update 2 C++5.3 Patch 111685-06 2002/03/09I am using -library=rwtools7,iostream and during compilation, I get thefollowing errors:"/usr/Forte/SUNWspro/WS6U2/include/CC/./exception", line 22: Error:"virtual" is not allowed ...

Forte C++ 6 UP1 const static member initialization

435 byte By sureshpc at 2007-11-25 23:53:15
Class A{public: static const X = 123; static const char* const A = ?ABC?;};I am getting compilation error on char* initialization , but it works for the static int initialization !Is that a compiler bug ? or a problem with my program ?$ CC test.cpp"test.cpp", line 7: Error: A member cannot be ...

Solaris 2.6 sunpro 5.3 compiler roguewave 7.1.1 -ws is not a member of _STL

726 byte By cnzzz at 2007-11-25 23:53:16
I have an error when trying to compile using Rogue wave 7.1.1.Here are the specs:RW = roguewave 7.1.1RW flags: -DRWSTD_MULTI_THREAD -DRW_MULTI_THREADRW includes: -I/rogue_wave/7.1.1/workspaces/SOLARIS26/SUNPRO50/12d(-12d -release)RW libs: /isv ...

dbx crashes

247 byte By janowsky at 2007-11-25 23:53:17
we're using Forte 6 u2 with recent patches, and dbx complains about a typedef:dbx: warning: unknown symbol type ...and then when a variable containing said typedef is printed, dbx crashes with a segmentation violation.

Solaris C/++ programming q: what is "_reaper" ?

1323 byte By deangelc at 2007-11-25 23:53:18
Hi,If I run my multithreaded C++ program under dbx, I see a thread running that started off its call stack in "_reaper" (as far as dbx can tell without complete debug symbols for all system libs...). Does anyone know what this thread does? I am noticing now that someone introduced a pointer bug ...

DBX __SLIP.DELETER__J

133 byte By ivandn at 2007-11-25 23:53:19
Does any one know what the following indicates from within a dbx stack dump?Thanks, Ivan__SLIP.DELETER__J

dbx error when tracing

799 byte By BerenHalfHanded at 2007-11-25 23:53:20
Attempting a trace like:trace access w 0xFE1407F8, 4gives me the error:dbx: internal error: using wrong type of accessor for slot '' of type Addresswhen it is apparently hit. Any clues?We're trying to diagnose a problem of wild writes into _smalloc and friends' heap list. For whatever ...

enum operator overloads not called

1410 byte By szombath at 2007-11-25 23:53:21
Hi,we are faced with a serious problem of the current Forte C++ compiler version (WS6U2 with actual patches). The following test program shows that the compiler does not accept operator overloads for enums. Instead of this all enums are implicitly converted to int.The sample compiles and runs ...

ISO C++ String functions missing.

524 byte By dthompsn at 2007-11-25 23:53:22
Looking at the man page for strchr, I believe that there is a problem. ISO has declared this function to be:char * strchr( char *s, int c); const char * strchr( const char *s, int c); Thus it is overloaded. Within the Forte development environment Sun Workshop 6, this is missing (only the const ...

Runtime error

763 byte By chr1st1awan at 2007-11-25 23:53:23
Hi all,I have problem with Forte C++. I have compile my library successfully, but the error appear when I try to run my application. The error is like this:/export/home/oracle/dp5/libNativeSmsApi.so: ld.so.1: /usr/java/bin/../bin/sparc/native_threads/java: fatal: relocation error: file ...

Developing on Trusted Solaris

187 byte By dshanes at 2007-11-25 23:53:24
Does anyone have any feedback on using this, or any other, development tool to write programs to run on Trusted Solaris?Thanks,Daviddshanes@maximsys.com

GUI development direction

1017 byte By sb2188 at 2007-11-25 23:53:25
I am trying to get a feel for where Sun is heading with GUI development tools. The visu tool (XDesigner) included with Forte C++ installs with "support" for integrating a numer of widget sets into the base program. However, I have never been able to create a fully functional widget set-specific ...

core_lo_pathmap?

2945 byte By wes0472 at 2007-11-25 23:53:26
We've recently upgraded our development machines to WS6U2. Ever since then, we've been having consistent problems debugging core dumps from the field. They appear to be trash, here's some example error messages from today:core file header read successfullyReading ld.so.1dbx: core file read ...

ofstream detect file remove/move

1389 byte By raesha at 2007-11-25 23:53:27
I am trying to detect, while writing to a file, if another application or user manually deletes or moved that file. For performance reasons, I do not want to open and close the file for every output message.I wrote the following program:#include <iostream.h>#include <fstream.h>int ...

Cannot find ../WS6U2/lib/values-xa.o file while linking.

459 byte By cdarchibald at 2007-11-25 23:53:28
I recently installed the Forte 6.2 C++ package on a Solaris 2.6 system and am receiving the following error when trying to compile a simple test program:Cannot find the file /usr/local/forte6.2/WS6U2/lib/values-xa.oThis error occurs during the linking portion of the compile. The Forte software ...

DBX results in Segmentation Fault

194 byte By vivekkarwal at 2007-11-25 23:53:31
Hi,The following is what I get running dbx debugger:./dbx Segmentation FaultAny help or pointer is highly appreciated.Regards,Vivek Karwal

no warning created for undefined return value

599 byte By cmqa at 2007-11-25 23:53:32
As a novice in C/C++ programming I expect so see compiler warnings if the return value of a function is not specified (in this case if function argument != 1). I use the +w or +w2 switches. A comparable piece of code in Java will not compile without warnings/errors. Is there any way to get a ...

Compilation error for templates

605 byte By mshetty1 at 2007-11-25 23:53:33
Hi,I am using Workshop 5.0 with the "compat=4" option. On compiling a program containing vectors I get the following error:Line 44: Error: Template parameter Allocator requires a type argument.where Line 44 istypedef vector<MyClass>MyClass_vector;There doesn't seem to be anything wrong ...

Read 2.6 core file on 2.8

302 byte By geemonkb at 2007-11-25 23:53:35
Hi ,I have a core file generated on Solaris 2.6 by running a c++ application. The application was compiled on Sun Compiler 6.1 and OS version 2.6 .Can I get all the relevant information from the core file on Solaris 2.8 using the same dbx version.Thanks,Geemon ...

roguewave library

346 byte By sadhanak at 2007-11-25 23:53:36
hi, I am not sure whether this is a revelant forum or not.I am trying to port a tool from solaris 2.6 and sunworkshop 4.0 to solaris 8 and sun work 6.2. my previous code uses roguewave library. Can anybody tell where can I get free download of roguewave 7(tools.h++ 7)(atleast an evaluation ...