Linking Errors for STL

Hi,
I am working on a porting project. I am porting code compiled earlier under gcc2.95 to Sun Workshop 6. We are using stl libraries in our code. I had made chages in code like
using std::sort;
using std::istream;
using std::ostream;
using std::vector;
using std::list;
but it gives link time errors like
ild: (undefined symbol) void std::__final_insertion_sort<int*>(__type_0,__type_0) -- referenced in the text segment of ../../studio_SOLARIS64/lib/leq.a(bdd_FAExpression.o)
ild: (undefined symbol) __type_1 std::copy<int*,int*>(__type_0,__type_0,__type_1) -- referenced in the text segment of ../../studio_SOLARIS64/lib/leq.a(bdd_FAExpression.o)
ild: (undefined symbol) void std::vector<FAExpression*,std::allocator<FAExpression*> >::__insert_aux(FAExpression**,FAExpression*const&) -- referenced in the text segment of ../../studio_SOLARIS64/lib/leq.a(bdd_FAExpression.o)
ild: (undefined symbol) void std::vector<FAExpression*,std::allocator<FAExpression*> >::__insert_aux(FAExpression**,FAExpression*const&) -- referenced in the text segment of ../../studio_SOLARIS64/lib/leq.a(leq_convert.o)
ild: (undefined symbol) void std::vector<FAMacroGroup*,std::allocator<FAMacroGroup*> >::__insert_aux(FAMacroGroup**,FAMacroGroup*const&) -- referenced in the text segment of ../../studio_SOLARIS64/lib/leq.a(bdd_FAExpression.o)
ild: (undefined symbol) void std::vector<FAMacro*,std::allocator<FAMacro*> >::__insert_aux(FAMacro**,FAMacro*const&) -- referenced in the text segment of ../../studio_SOLARIS64/lib/leq.a(bdd_FAExpression.o)
Can anyone help me to sort out thse problems. I would like to say thanks in advance.
Amandeep

Hi Amandeep!
I'm sorry that nobody answered you for 6 years. Maybe this answer will be useful for someone nowadays.
I had the same problem some time ago and I got to fix it after hard work and thinking.
This problem is specific for Sun WorkShop 6 update 2 C++ 5.3 2001/05/15.
First of all, the best solution is updating to the last version of Sun Studio if possible, because
the version mentioned above is an end-of-life one. If not possible, try the following.
Typically, you declare a vector and later add elements to it:
//Template is declared empty:
std::vector<ClassObject> ObjectVector;
// Later, when appendig an object is required, methods insert or push_back are used:
ObjectVector.push_back (Object);
// or
ObjectVector.insert (Position, Object);
But push_back and insert methods, among others, use __insert_aux method, that is not available.
However, there's an other way to handle a vector that avoid the use of those buggy methods
(buggy in this compiler version only):
int n = theNeededSize;
std::vector<ClassObject> ObjectVector (n);
int TemplateSize = n;
// Now objects in the template can be set properly.
for (size_type Index = 0; Index < TemplateSize; Index++)
     ObjectVector[Index].SetDataMethod1 (...);
     ObjectVector[Index].SetDataMethodN (...);
     // or ...
     ClassObject objectOfClassObject;
     ObjectVector[Index] = objectOfClassObject;
Using the constructor:
EXPLICIT vector (sizetype n)
: __start(0), __finish(0), __end_of_storage(0,Allocator())
T value = T();
__initn(n,value);
solves the problem.
In this thread there is more detailed information:
http://forum.java.sun.com/thread.jspa?threadID=5071034
Hope this is useful.
Bye.

Similar Messages

  • Trying to resolve a "_OBJC_METACLASS_$_CDVCommandQueue" with MainViewControllers.a, MainViewControllers.o, 7 in total.  Apple Mach-O Linker error for all 7.  Thanks to any assistance.

    Trying to resolve a "_OBJC_METACLASS_$_CDVCommandQueue" with MainViewControllers.a, MainViewControllers.o, 7 in total.  Apple Mach-O Linker error for all 7.  Thanks to any assistance.

    No I didn't even read through your post, to long.
    You said that "No matter what program I try to install, as soon as the installer opens it crashes". Were you talking about the install for this/these 3D programs or ANY program? As it is worded it sounded like ANY program. That tells me there is a problem with your Mac, software or hardware.
    Now you say others install programs, which is it. Programs other then the 3D ones install or no programs install?
    Could simply be your Mac is to old to run these programs and the installer knows that. You never said what model or year Mac it is.

  • Link error for distribution

    Hi, I received an email with the link to download the new version of flash player for distribution, but does not work
    Dear Miguel Ángel Abarca,
    Thank you for submitting a request to distribute Adobe® Software. Your request has been approved, and you may now distribute the Adobe® Software listed below, subject to the terms and conditions set forth in the Adobe Reader and Runtime Software Distribution License Agreement.
    Approved Software:
    Adobe® Flash® Player
    Adobe® Reader® Software
    Attached is an Adobe Portable Document Format (PDF) file of the distribution license agreement. Please keep this file for your records. The agreement is valid for one year, after that one year you can renew the distribution license agreement by following the same process.
    Below you will find the necessary details and download links for the product(s) that you have been approved.
    Adobe® Flash® Player
    To download the Flash Player version that you would like to distribute, please visit the following URL:
    http://www.adobe.com/products/flashplayer/distribution4.html?auth=<number>

    Hello, here paste part of message:
    To download the Flash Player version that you would like to distribute,
    please visit the following URL:
    http://www.adobe.com/products/flashplayer/distribution4.html?auth=4358bc39-5e77-4893-99cf- 9f7c7a8d5456
    *You may not share the above link, share information with others, or
    publish the above link on websites, blogs, or by any other means that
    can be publicly accessed. The information contained on this site is
    meant for your use only in accordance with Adobe Flash Player
    Distribution License Agreement you accepted. You may direct others to
    http://www.adobe.com/products/players/fpsh_distribution1.html to request
    distribution rights.
    El 13/01/2015 a las 17:53, m_vargas escribió:
    >
          Link error for distribution
    created by m_vargas <https://forums.adobe.com/people/m_vargas> in
    /Installing Flash Player/ - View the full discussion
    <https://forums.adobe.com/message/7091835#7091835>

  • Link error for simpapp

    after installing tuxedo, and compiled the simpapp application, started the service toupper as described. i faild with the simpcl.exe. it the ordinal number 14 is missing in the LIBFML.dll. could anyone please tell mit the propper link settings.
    i am using msvc 6.0
    thanks.
    chris.

    Hello, here paste part of message:
    To download the Flash Player version that you would like to distribute,
    please visit the following URL:
    http://www.adobe.com/products/flashplayer/distribution4.html?auth=4358bc39-5e77-4893-99cf- 9f7c7a8d5456
    *You may not share the above link, share information with others, or
    publish the above link on websites, blogs, or by any other means that
    can be publicly accessed. The information contained on this site is
    meant for your use only in accordance with Adobe Flash Player
    Distribution License Agreement you accepted. You may direct others to
    http://www.adobe.com/products/players/fpsh_distribution1.html to request
    distribution rights.
    El 13/01/2015 a las 17:53, m_vargas escribió:
    >
          Link error for distribution
    created by m_vargas <https://forums.adobe.com/people/m_vargas> in
    /Installing Flash Player/ - View the full discussion
    <https://forums.adobe.com/message/7091835#7091835>

  • Link errors for NI-MAQdx examples

    I’m getting link errors while debug compiling for all of the NIMAQdx examples.  There are three of them and they start with Undefined symbol, then ‘_UPLIBBreadpointWithElab@16’ referenced in the .lib file.  Using version CVI2013 and NI-MAQdx 4.2  Any suggestions?  Thanks.
    snelson

    Hi Andy,
    It's occurring on all of the examples IMAQdx examples.  I have a 32-bit PC, but tried it also on a 64-bit with the same linking errors.  I'm compiling in debug, but same errors during release version.  I think I'm including all of the appropriate files.  Attached is a screen shot.
    Thanks,
    snelson
    snelson
    Attachments:
    screen shot.jpg ‏191 KB

  • Link errors for Labwindows CVI.

    I am currently trying to implement the exer1.cws example from the Cvi sample and tutorials section.
    But i get 9 Link errors while trying to generate the DLL.
    I have attached the Link errors as a txt file.
    Please tell me whats wrong with the program??
    I have incorporated the RTmain as entry point function of the program.
    I have initialised variables used in the main program globally.
    Other user interface functions have also been defined outside the body of the Rtmain program.
    Hope this info is sufficient.
    Regards
    raghu
    Solved!
    Go to Solution.
    Attachments:
    ERRORS.txt ‏1 KB

    Hey , Thanks for the reply.
    The tutorial asks us to select the Option as 'Real Time Only'.
    I reverted to 'Full Run-time engine' as you asked.
    But there is no change.
    Although i did debug most of the erros.
    I just included the Functions in the headerfile.
    But even though, i am stuck with two errors.
    I am attaching the complete set as txt file.
    Please see if you notice anything unorderly.
    Attachments:
    ERRORS.txt ‏1 KB
    exer1.c ‏3 KB
    exer1.h ‏2 KB

  • Link error with STL

    Hi there,
    I am trying to build a C++ on Solaris, met the following error:
    CC xerces-c2_3_0/lib/SunOS/libxerces-c.so.23 -o output/SunOS/bin2xml output/SunOS/bin2xml.o output/SunOS/libxmlcompiler.a
    Undefined first referenced
    symbol in file
    void std::__insertion_sort<Dictionary::Word*,Dictionary::WordUsageCompare>(__type_0,__type_0,__type_1) output/SunOS/libxmlcompiler.a(Dictionary.o)
    void std::vector<XREFINFO*,std::allocator<XREFINFO*> >::__insert_aux(XREFINFO**,XREFINFO*const&) output/SunOS/libxmlcompiler.a(xdecompiler.o)
    ld: fatal: Symbol referencing errors. No output written to output/SunOS/bin2xml
    make: *** [output/SunOS/bin2xml] Error 1
    It seems to be that the STL library has not been linked. Is there anyone give me some hint how to solve the problem.
    Thanks
    Sliu

    The C++ standard library (including STL) is automatically linked, so that isn't your problem.
    But the missing template instance cannot be in the library, because it depends on a user-defined type. The instance has to be generated by compiling the program.
    Some code in the .o or in one of the libraries needs an instance of std::__insertion_sort that is not present in any of the provided binaries. You aren't giving the compiler any source code, so it cannot generate the instance itself.
    Run "nm -C" on each binary, and look for a line containing "UNDEF" and "std::__insertion_sort", matching the undefined symbol the linker complains about. You probably need to recompile that binary.
    But that binary might have been compiled with generation of that template instance turned off, so some source code modification might be needed.

  • Unsatisfied link error for oracle database connection

    Hi all,
    I am tryin to establing connection to the oracle database through weblogic 6.1.
    the connection starts normally and then it gives me an error stating that weblogicoci37
    is not found in the java library path. I tried to find it out in the weblogic
    directory but managed to find out some files with ...oci36. Am doing something
    weird!!
    I am sure i downloaded the correct driver. My OS is NT and webserver 6.1 and the
    jdriver is ocirel510sp11 package for oracle. Would be great to have some suggestions!
    i have listed the error below.
    Starting Loading jDriver/Oracle .....
    Error encountered:
    java.sql.SQLException: System.loadLibrary(weblogicoci37) threw java.lang.UnsatisfiedLinkError:
    no we
    blogicoci37 in java.library.path
    at weblogic.jdbc.oci.Driver.loadLibraryIfNeeded(Driver.java:226)
    at weblogic.jdbc.oci.Driver.connect(Driver.java:76)
    at java.sql.DriverManager.getConnection(DriverManager.java:517)
    at java.sql.DriverManager.getConnection(DriverManager.java:146)
    at utils.dbping.main(dbping.java:167)

    found the error, i forgot to add the oci817_8 folder from the weblogic bin directory
    in the path.
    "arif" <[email protected]> wrote:
    >
    Hi all,
    I am tryin to establing connection to the oracle database through weblogic
    6.1.
    the connection starts normally and then it gives me an error stating
    that weblogicoci37
    is not found in the java library path. I tried to find it out in the
    weblogic
    directory but managed to find out some files with ...oci36. Am doing
    something
    weird!!
    I am sure i downloaded the correct driver. My OS is NT and webserver
    6.1 and the
    jdriver is ocirel510sp11 package for oracle. Would be great to have
    some suggestions!
    i have listed the error below.
    Starting Loading jDriver/Oracle .....
    Error encountered:
    java.sql.SQLException: System.loadLibrary(weblogicoci37) threw java.lang.UnsatisfiedLinkError:
    no we
    blogicoci37 in java.library.path
    at weblogic.jdbc.oci.Driver.loadLibraryIfNeeded(Driver.java:226)
    at weblogic.jdbc.oci.Driver.connect(Driver.java:76)
    at java.sql.DriverManager.getConnection(DriverManager.java:517)
    at java.sql.DriverManager.getConnection(DriverManager.java:146)
    at utils.dbping.main(dbping.java:167)

  • Download link error for Logic Pro 9.0.1

    Anyone else have this problem? When I navigate to the right page for Logic Pro update 9.0.1 and click download, the file that actually gets transferred is for Logic Express. The Pro update is 183 mb and express is something more like 135 mb. In my download manager I can see that it is the Express package which has been downloaded.

    [LP9.0.2|http://www.apple.com/downloads/macosx/apple/application_updates/logicpr o902.html]
    A

  • Linker error Multiple definitions for symbol

    Hi,
    I have ported a project from Linux-based DAQmx to LabWindows CVI 2012 on a PXI machine. After making all conversion requirements, and successfully compiling, I am getting tons of the following linker errors for various modules files (just pasting
    a subset of those here):
    Multiple definitions for symbol '_PtrToPtr64' in modules X and Y
    Multiple definitions for symbol '_Ptr64ToPtr' in modules Z and Y
    Multiple definitions for symbol '_HandleToHandle64' in modules X and Y
    Multiple definitions for symbol '_HEAP_MAKE_TAG_FLAGS' in modules X and Y
    Multiple definitions for symbol '_TpInitializeCallbackEnviron' in modules X and Y
    I found this relevant post: http://forums.ni.com/t5/LabWindows-CVI/CVI2010-clang-link-errors-with-Windows-SDK/td-p/1425690
    which points to a known issue in CVI 2010. However the workaround (enabling C99 build option) is already set in my project, so this solution does not apply.
    Any idea what could be causing these windows.h symbols to get redefined?
    Thank you
    Solved!
    Go to Solution.

    Anjelica-W wrote:
    Can you run other examples that are accessing the Windows SDK without linker errors?
    You can also try adding import libraries for functions that are not automatically linked as suggested in this KnowledeBase article.
    Thanks for your reply. Yes I can run some basic apps that use windows.h without these linker errors, but cannot figure out the difference with mine. One more thing that could help diagnose the issue: Some of these fuctions are defined in file basetsd.h
    located in CVI2012\sdk\include, an excerpt of that code is below, which seems to be added by CVI. Is it possible that these are also defined somewhere else, causing the conflict? How can I see the linker options in CVI and find the path that it searches for libraries to link?
    // ADDED TO BY CVI
    #if !(defined (_CVI_) && defined (_INTERACTIVE_WINDOW_BUILD_))
    __inline
    void * POINTER_64
    PtrToPtr64(
    const void *p
    return((void * POINTER_64) (unsigned __int64) (ULONG_PTR)p );
    __inline
    void *
    Ptr64ToPtr(
    const void * POINTER_64 p
    return((void *) (ULONG_PTR) (unsigned __int64) p);
    __inline
    void * POINTER_64
    HandleToHandle64(
    const void *h
    return((void * POINTER_64)(__int64)(LONG_PTR)h );
    __inline
    void *
    Handle64ToHandle(
    const void * POINTER_64 h
    return((void *) (ULONG_PTR) (unsigned __int64) h );
    #endif /* _CVI_ */

  • [CS4]: ICU Locale Link Error

    Hello,
    Has anyone had trouble with link errors for ICU Locale's when porting from InDesign CS3 to CS4 on the Mac? Although the SDK ReadMe says CS4 uses ICU 3.4, upon inspection of the ICU frameworks delivered with the CS4 SDK, they are actually version 3.6. I don't know if the change in version has anything to do with the link error or whether there is an omission somewhere. I've tried putting all the CS4 ICU libraries into the project, but to no avail.
    John H.

    Never mind. I forgot about changing the Frameworks path in the project. It works!
    John H.

  • NiseCfg library link errors - will not compile working code on replicate system

    i have working software trying to install on a replicate system.    it does not compile on the replicate system.   the problem is nise, niseCfg link errors  for example:  
    Undefined symbol:  '_niseCfg_GetVirtualDeviceProperty@20' referenced in "TestSystem_Config.c"
    originally it complained it couldn't find the nise.h and niseCfg.h header files.   i copied the header and some other object and fp files (yeah, yeah, i know :-/ from my working system to the replicate system (in the NI/Shared/CVI directory path).
    it then found the header file and prototypes but now the undefined link errors.   i have nise.dll in my WIndows System directory.
    Please help.   what do i do to fix this?   thanks!

    The CVI IDE needs to know someway where to find the resources your program is using and this can be done in several ways. One of them is loading the instruments in the Instrument menu: this is valid if your instrument is used in only one project of yours or a few one. Another method, which is useful for insrtument you use intensively in all your projects, is to add them to the Library menu (option Customize...): this will make your libraries and FPs available for every project you are working on without need to explicitly add the instruments to the Instrument menu.
    If you are using an instrument and you don't see it in the project it must be loaded in one of the ways I described before: you can check in the original system which method was used.
    Proud to use LW/CVI from 3.1 on.
    My contributions to the Developer Zone Community
    If I have helped you, why not giving me a kudos?

  • Keithley 2701 and _KE2700_in​itwithopti​ons LINK error

    Hi
    My labwindows compiler does not like to compile my programme which used the KE2700_Init or INit with options
    it comes up with Project Link Error for the fuction?
    any ideas?
    Thanks

    I think I had the package
    looking at the two CWS files I noticed the addresses were different, the address to the DLL missing.
    I had to add the .fp fpr Keithley to the CVI. I thought the thing adds itself when it comes up.
    I had the same problem with INI routines and I had to add those too.
    thanks

  • VC++ 6 Linker Errors from converted CVI project

    I am getting numerous LNK2005 link errors for functions within the following .obj files: easytab.obj
    inifile.obj
    toolbar.obj
    The weird thing is that all of them say that the functions are like this:
    toolbar.obj : error LNK2005: _Toolbar_GetCtrlFromDescription already defined in toolbar.obj
    I also get several LNK2001 errors (unresolved external symbol)
    Any help will be greatly appreciated.
    Thanks,
    Richard

    It sounds like you have these OBJ files included twice in the VC++ project. Check and see in the Project->Settings... under the Link tab if they are listed twice. If they are, remove the duplicate entries. Even if they aren't you may want to try removing them from this list in case they are being linked again in another way.
    Best Regards,
    Chris Matthews
    Measurement Studio Support Manager

  • STL linker error  - Very urgent

    Hi,
    I am getting a linking error while building a program, The program is using an object file
    that uses STL <queue> template.
    I am using the compiler SC 5.0 with SunOS 5.6 and I am using the STL that comes with Sun C++ 5.0
    I am getting the below mentioned error while using STL queue template.
    I am not able to identify the problem. If somebody could help me in this regard,
    I would appreciate it.
    In my program, MsgBuf is an instance of a class.
    I am trying to use queue like
    std::queue<MsgBuf *> tmpq
    I also need another clarification, is it possible to use,
    std::queue<MsgBuf> * tmpq = new std::queue<MsgBuf>;
    Undefined first referenced
    symbol in file
    __type_1 std::copy<std::deque<MsgBuf*,std::allocator<MsgBuf*> >::const_iterator,std::back_insert_iterator<std:
    :deque<MsgBuf*,std::allocator<MsgBuf*> > > >(__type_0,__type_0,__type_1) ../sunlib/libMqApi.a(MQ_GuardedQueue.o)
    std::deque<MsgBuf*,std::allocator<MsgBuf*> >::~deque() ../sunlib/libMqApi.a(MQ_GuardedQueue.o)
    unsigned std::deque<MsgBuf*,std::allocator<MsgBuf*> >::__buffer_size() ../sunlib/libMqApi.a(MQ_GuardedQueue.o)
    __type_1 std::copy<std::deque<MsgBuf*,std::allocator<MsgBuf*> ::const_iterator,std::insert_iterator<std::deque<MsgBuf*,std::allocator<MsgBuf*> > > >(__type_0,__type_0,__type_1) ../sunlib/libMqApi.a(MQ_GuardedQueue.o)
    __type_1 std::copy<std::deque<MsgBuf*,std::allocator<MsgBuf*> ::const_iterator,std::deque<MsgBuf*,std::allocator<MsgBuf*> >::iterator>(__type_0,__type_0,__type_1) ../sunlib/libMqApi.a(MQ_GuardedQueue.o)
    std::deque<MsgBuf*,std::allocator<MsgBuf*> >::iterator std::deque<MsgBuf*,std::allocator<MsgBuf*> >::erase(std
    ::deque<MsgBuf*,std::allocator<MsgBuf*> >::iterator,std::deque<MsgBuf*,std::allocator<MsgBuf*> >::iterator) ../sunlib/libMqApi.a(MQ_GuardedQueue.o)
    void std::deque<MsgBuf*,std::allocator<MsgBuf*> >::__allocate_at_end() ../sunlib/libMqApi.a(MQ_GuardedQueue.o)
    void std::deque<MsgBuf*,std::allocator<MsgBuf*> >::__deallocate_at_begin() ../sunlib/libMqApi.a(MQ_GuardedQueu
    e.o)
    ld: fatal: Symbol referencing errors.

    Maybe you forgot to use:
    import java.io.IOException;Post your code for us!!

Maybe you are looking for

  • Video does not work

    Under the camera-when I select the video option-the app switches to video.  I can start the video, but can not stop it by pushing the same button.  After a time period-(varies) the phone freezes up and then reboots. 

  • User id while  creating a purchase order

    Hello all, I would like to know whether there is any option to enter the user id or user name while creating a purchase order. If so could anyone post on how to do that. Thanks, Maxx

  • Are the contents of USERS tablespase in the recyclebin?-----No.140

    I have dropped tablespace USERS. Are the contents of USERS tablespase in the recyclebin?

  • Snow Leopard X Server

    Can the Snow Leopard X Server be installed on a iMac, and then a user use the same iMac for their own use without using any of the server os. Also, will a MacBook Pro connect and work to the network. I ahve a small company and want to connect a MacBo

  • Idvd menu for imovie08

    Hello. I have created an imovie(08) from footage filmed in 3 locations - A, B, and C. I would like to create a menu in idvd so the viewer can skip directly to view scenes A, B, or C separately if they choose. How do I do this? Thanks.