From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 10ba33,bdf664c02fab5c8,start X-Google-Attributes: gid10ba33,public X-Google-Thread: fee84,bdf664c02fab5c8,start X-Google-Attributes: gidfee84,public From: ewiles@mclean.sterling.com (Edwin Wiles) Subject: Unresolved virtual tables? (Alpha/OSF/G++ 2.7.2) Date: 1996/01/23 Message-ID: #1/1 X-Deja-AN: 136260727 organization: Sterling Software ITD, Inc. followup-to: gnu.g++.help newsgroups: comp.unix.osf.osf1,gnu.g++.help Okay, I'm lost. I _think_ I know what the problem is, but I don't know how to fix it. Hopefully, someone out there has run into this and knows what to do about it. Using gcc/g++ version 2.7.2 on an Alpha OSF/1 (3.2?) system, I have been attempting to compile a set of C++ classes. These same classes compiled just fine on other systems under 2.5.8, but would never work on the Alpha due to problems with the g++ compiler and class library prior to 2.7.2. Well, with G++ 2.7.2, we finally had a g++ and class library that compiled cleanly on the Alpha. So we tried compiling my code. After quite a few problems dealing with changes in the ANSI specs, and differences between Alpha and other unix systems, I've gotten rid of all but a few warnings (that were present in the original code, and basically harmless [I hope!]), and one set of link errors that have me quite stumped. Here's the complete set of link error messages: 1: collect2: ld returned 1 exit status 2: /usr/ucb/ld: 3: Warning: Linking some objects which contain exception information sections 4: and some which do not. This may cause fatal runtime exception handling 5: problems (last obj encountered without exceptions was /usr/local/lib/libstdc++.a). 6: Warning: clog defined as GLOBAL DATA but is defined in a shared lib as a GLOBAL FUNC 7: Unresolved: 8: GroupList virtual table 9: NameList virtual table The critical ones (to me) are lines 7, 8, and 9. I'm curious about 6, and not terribly worried about 3-5. I assume that lines 7-9 are referring to the virtual function table (vtable), and to the fact that they are apparently not being generated, so they can't be found for linkage. I don't have a clue why. I also find it suspicious that a number of 'inline' functions had to be made real (i.e. not "inline") to remove other 'unresolved function' errors. At this point, I'm suspecting the problem can only be resolved by using the "#pragma interface" and "#pragma implementation". If that's the case, I've a lot of files to modify, and would appreciate some confirmation that I'm on the right track, before I invest that much effort. Any help appreciated. Respond by EMail, and I will summarize. -- Edwin Wiles | Sterling Software, Inc. ITD | McLean, VA, USA Preferred..: ewiles@mclean.sterling.com Alternative: Edwin_Wiles@sterling.com