INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Jobs

C++ Compilation problems on Solaris 5.8 (Forte C++ 6 Update 2) -- Iter

C++ Compilation problems on Solaris 5.8 (Forte C++ 6 Update 2) -- Iter

C++ Compilation problems on Solaris 5.8 (Forte C++ 6 Update 2) -- Iter

(OP)
Hi,

I am currently trying to compile a C++ binary on our Solaris 5.8 box
(Sun Sparc Ultra-250 with Forte C++ 6 Update 2 with Sun WorkShop 6
update 2 Tools.h++ 7.1) that previously compiled and ran without
errors on our other separate machine (Solaris 5.6 Sun Sparc Ultra-250
with Sun Visual Workshop C++ 5.0 with Sun WorkShop Tools.h++ 7.0).

After adapting the makefile (changing SunW C++ 5.3 directories to
Forte C++ 6), I ran it and got a lot of errors, which I don't
understand the reason.
Follows the compilation log from make:

matbildev02% make
CC -I/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source
-I/app/arbordev/arbor11/payments_4_decimals_original/WO00154_dda_mbfix_banif/bin
-I/u01/app/oracle/product/8.1.7/precomp/public
-library=rwtools7,iostream -g -xsb
-L/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source
-L/app/arbordev/arbor11/payments_4_decimals_original/WO00154_dda_mbfix_banif/bin
-L/u01/app/oracle/product/8.1.7/lib
-L/u01/app/oracle/product/8.1.7/precomp/lib -L/usr/lib
-L/opt/SUNWspro/WS6U2/lib -L/opt/SUNWspro/WS6U2/lib/rw7 -lclntsh
-lnetv2 -lnttcp -lnetwork -lncr -lnetv2 -lnttcp -lnetwork -lclient
-lcommon -lgeneric -lmm -lnlsrtl3 -lcore4 -lnlsrtl3 -lcore4 -lnlsrtl3
-lnetv2 -lnttcp -lnetwork -lncr -lnetv2 -lnttcp -lnetwork -lclient
-lcommon -lgeneric -lepc -lnlsrtl3 -lcore4 -lnlsrtl3 -lcore4 -lnlsrtl3
-lclient -lcommon -lgeneric -lnlsrtl3 -lcore4 -lnlsrtl3 -lcore4
-lnlsrtl3 -lnsl -lsocket -lgen -ldl -R
/opt/SUNWspro/lib:/u01/app/oracle/product/8.1.7/lib
-YP,/home/oracle/lib:/app/arbordev/arbor11/rosette:/lib:/u01/app/oracle/product/8.1.7/lib:/opt/lib/cobol/coblib:/opt/SUNWcluster/lib:/usr/ccs/lib:/usr/lib
-lc -laio -lm -c -o /app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/payments.o
/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/payments.cc
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXDetl.h",
line 45: Error: A qualifier is not allowed for iterator.
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXDetl.h",
line 45: Error: "," expected instead of "iterator".
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXDetl.h",
line 46: Error: Use ";" to terminate declarations.
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXDetl.h",
line 46: Error: A qualifier is not allowed for const_iterator.
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXDetl.h",
line 46: Error: "," expected instead of "const_iterator".
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXDetl.h",
line 47: Error: Use ";" to terminate declarations.
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXDetl.h",
line 47: Error: A qualifier is not allowed for size_type.
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXDetl.h",
line 47: Error: "," expected instead of "size_type".
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXDetl.h",
line 48: Error: Use ";" to terminate declarations.
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXDetl.h",
line 48: Error: A qualifier is not allowed for value_type.
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXDetl.h",
line 48: Error: "," expected instead of "value_type".
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXDetl.h",
line 49: Error: Use ";" to terminate declarations.
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXDetl.h",
line 49: Error: A qualifier is not allowed for reference.
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXDetl.h",
line 49: Error: "," expected instead of "reference".
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXDetl.h",
line 50: Error: Use ";" to terminate declarations.
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXDetl.h",
line 50: Error: A qualifier is not allowed for const_reference.
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXDetl.h",
line 50: Error: "," expected instead of "const_reference".
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXDetl.h",
line 52: Error: Use ";" to terminate declarations.
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXDetl.h",
line 163: Error: Cannot declare a reference to member type.
"/opt/SUNWspro/WS6U2/include/CC/rw7/rw/tvmset.h", line 37: Warning:
#error Cannot include header if RW_NO_STL macro is defined for your
compiler.
"/opt/SUNWspro/WS6U2/include/CC/rw7/rw/tvmset.h", line 50: Error:
multiset is not defined.
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXBatch.h",
line 33: Where: While specializing "RWTValMultiSet<LBXDetail,
std::less<LBXDetail>>".
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXBatch.h",
line 33: Where: Specialized in non-template code.
"/opt/SUNWspro/WS6U2/include/CC/rw7/rw/tvmset.h", line 50: Error:
Unexpected type name "T" encountered.
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXBatch.h",
line 33: Where: While specializing "RWTValMultiSet<LBXDetail,
std::less<LBXDetail>>".
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXBatch.h",
line 33: Where: Specialized in non-template code.
"/opt/SUNWspro/WS6U2/include/CC/rw7/rw/tvmset.h", line 50: Error: ","
expected instead of ">".
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXBatch.h",
line 33: Where: While specializing "RWTValMultiSet<LBXDetail,
std::less<LBXDetail>>".
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXBatch.h",
line 33: Where: Specialized in non-template code.
"/opt/SUNWspro/WS6U2/include/CC/rw7/rw/tvmset.h", line 50: Error:
multiset is not defined.
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXBatch.h",
line 33: Where: While specializing "RWTValMultiSet<LBXDetail,
std::less<LBXDetail>>".
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXBatch.h",
line 33: Where: Specialized in non-template code.
"/opt/SUNWspro/WS6U2/include/CC/rw7/rw/tvmset.h", line 50: Error:
Unexpected type name "T" encountered.
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXBatch.h",
line 33: Where: While specializing "RWTValMultiSet<LBXDetail,
std::less<LBXDetail>>".
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXBatch.h",
line 33: Where: Specialized in non-template code.
"/opt/SUNWspro/WS6U2/include/CC/rw7/rw/tvmset.h", line 50: Error: The
base class RW_VAssoc<<unknown>> is included more than once.
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXBatch.h",
line 33: Where: While specializing "RWTValMultiSet<LBXDetail,
std::less<LBXDetail>>".
"/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/LBXBatch.h",
line 33: Where: Specialized in non-template code.
Compilation aborted, too many Error messages.
make: *** [/app/arbordev/arbor11/release/FileInterfaces/PayConv/v1.8/source/payments.o]
Error 1
matbildev02%

The line in that first file that is causing the error (LBXDetl.h),
contains:

//needed for instantiation
//STL related public types;
typedef RWTValOrderedVector<basic::type4detail> detailList;

typedef detailList::iterator iterator; //line 45

The header of this file has the following includes:

#ifndef __LBXDETAIL__
#define __LBXDETAIL__
#include "compiler.h"
#include <rw/cstring.h>
#include <rw/tvordvec.h>
#include "basic.h"
#include "tools.h"

Here is the makefile:

HOMESRC = ${HOME}/release/FileInterfaces/PayConv/v1.8/source
SHAREDSRC = ${HOME}/payments_4_decimals_original/WO00154_dda_mbfix_banif/bin
SRCDIR = ${HOMESRC}
HBINDIR = ${HOMESRC}
HOBJDIR = ${HOMESRC}
SBINDIR = ${SHAREDSRC}
SOBJDIR = ${SHAREDSRC}

CCC= CC
CCOPTIONS= -library=rwtools7,iostream -g -xsb
LIBLINK = -L${HOBJDIR} -L${SOBJDIR}
INCLDIR = -I${HOMESRC} -I${SHAREDSRC} -I${ORACLE_HOME}/precomp/public
RWINCL = .
ORACLIBS = \
-L${ORACLE_HOME}/lib \
-L${ORACLE_HOME}/precomp/lib \
-L/usr/lib \
-L/opt/SUNWspro/WS6U2/lib \
-L/opt/SUNWspro/WS6U2/lib/rw7 \
-lclntsh \
-lnetv2 -lnttcp -lnetwork -lncr -lnetv2 -lnttcp -lnetwork -lclient
-lcommon -lgeneric \
-lmm -lnlsrtl3 -lcore4 -lnlsrtl3 -lcore4 -lnlsrtl3 -lnetv2 -lnttcp \
-lnetwork -lncr -lnetv2 -lnttcp -lnetwork -lclient -lcommon -lgeneric
-lepc \
-lnlsrtl3 -lcore4 -lnlsrtl3 -lcore4 -lnlsrtl3 -lclient -lcommon
-lgeneric \
-lnlsrtl3 -lcore4 -lnlsrtl3 -lcore4 -lnlsrtl3 \
-lnsl \
-lsocket \
-lgen \
-ldl \
-R /opt/SUNWspro/lib:${ORACLE_HOME}/lib \
-YP,${LD_LIBRARY_PATH}:/opt/SUNWcluster/lib:/usr/ccs/lib:/usr/lib \
-lc -laio -lm

CPPFLAGS = ${INCLDIR} $(STLINCL) $(CCOPTIONS) $(LIBLINK) $(ORACLIBS)

OBJECTS = \
${HOBJDIR}/payments.o \
${HOBJDIR}/CTTFile.o \
${HOBJDIR}/CTTHeader.o \
${HOBJDIR}/CTTDetail.o \
${HOBJDIR}/CTTTrailer.o \
${HOBJDIR}/EFTFile.o \
${HOBJDIR}/EFTHeader.o \
${HOBJDIR}/EFTDetail.o \
${HOBJDIR}/EFTTrailer.o \
${HOBJDIR}/ESFile.o \
${HOBJDIR}/ESHeader.o \
${HOBJDIR}/ESDetail.o \
${HOBJDIR}/ESTrailer.o \
${HOBJDIR}/MBFile.o \
${HOBJDIR}/MBHeader.o \
${HOBJDIR}/MBDetail.o \
${HOBJDIR}/MBTrailer.o \
${HOBJDIR}/PS2File.o \
${HOBJDIR}/PS2Header.o \
${HOBJDIR}/PS2Detail.o \
${HOBJDIR}/PS2Trailer.o \
${HOBJDIR}/tools.o \
${HOBJDIR}/LBXDetl.o \
${HOBJDIR}/LBXBatch.o \
${HOBJDIR}/LockBox.o \
${HOBJDIR}/basic.o \
${HOBJDIR}/LBXFile.o \
${HOBJDIR}/conversion.o \
${HOBJDIR}/conversionES.o \
${HOBJDIR}/inifile.o \
${HOBJDIR}/conversionMB.o \
${HOBJDIR}/MBContainer.o \
${HOBJDIR}/conversionCTT.o \
${HOBJDIR}/ErrorMgr.o \
${HOBJDIR}/conversionPS2.o \
${HOBJDIR}/conversionEFT.o \
${HOBJDIR}/EFTRejectFile.o \
${HOBJDIR}/EFTRejectHeader.o \
${HOBJDIR}/EFTRejectDetail.o \
${HOBJDIR}/EFTRejectTrailer.o

.SUFFIXES: .pcc

all: ${HBINDIR}/payments

.pcc.cc:
proc INAME=$*.pcc CODE=cpp CPP_SUFFIX=cc PARSE=NONE

${HBINDIR}/payments: ${OBJECTS}
$(CCC) $(CPPFLAGS) -o $@ ${OBJECTS}

clean:
rm ${HOBJDIR}/*.* ${HBINDIR}/payments

##################################################
# general case for compilation
${HOBJDIR}/%.o: ${HOMESRC}/%.cc
$(CCC) $(CCFLAGS) $(CPPFLAGS) -c -o $@ $<


${HOBJDIR}/%.o: ${SHAREDSRC}/%.cc
$(CCC) $(CCFLAGS) $(CPPFLAGS) -c -o $@ $<

I have tried using the -compat=5 flag, adding using std::vector; but
it did not help.

Anyone have any idea what things must be taken into consideration when
porting from SunW C++ 5 to Forte 6 U2.
Any ideas on why the errors are appearing, such as some include or
makefile parameter that should not be there???

If you need anymore information, let me know.
Thanks a lot in advance,
Tiago A.

RE: C++ Compilation problems on Solaris 5.8 (Forte C++ 6 Update 2) -- Iter

At a guess, it doesn't like the typedef iterator.  Try typedef'ing to something else.  I've never actually seen this syntax before.  Isn't it somethinglike

typedef RWTValOrderedVectorIterator<basic::type4detail> detailIter;

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members!

Resources

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close