473,387 Members | 1,440 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

How to get rid of multiple definition of _S_node_allocator_lock

Hello,

I recently ported my code to Tornado 2.2 VxWorks5.5 I finaly got all the
projects to build and compile,but in the last stage of the build when I link the application software with the ppc BSP, I get
an multiple definition to items associated with the Standard Template
Libraries. this did not occur with 2.0. The errors are listed below, any
help Please

the multi-definition is:
__default_alloc_template<true, 0>::_S_node_allocator_lock
when I remove all "string" declaration and quotos, the multi-definition disappears.
I guess the threads used by BSP and application software are different,
as MSDN "LNK2005 error" has points out,
but I could not know how to solve this problem, help me!
Aug 12 '07 #1
1 1690
Firecore
114 100+
Hello,

I recently ported my code to Tornado 2.2 VxWorks5.5 I finaly got all the
projects to build and compile,but in the last stage of the build when I link the application software with the ppc BSP, I get
an multiple definition to items associated with the Standard Template
Libraries. this did not occur with 2.0. The errors are listed below, any
help Please

the multi-definition is:
__default_alloc_template<true, 0>::_S_node_allocator_lock
when I remove all "string" declaration and quotos, the multi-definition disappears.
I guess the threads used by BSP and application software are different,
as MSDN "LNK2005 error" has points out,
but I could not know how to solve this problem, help me!
Is all this in a header file?
If it is, you can do something like this:
Expand|Select|Wrap|Line Numbers
  1. #ifndef _HEADER_FILE_DEF_
  2. #define _HEADER_FILE_DEF_
  3.  
  4. #include <whatever>
  5.  
  6. //Prototypes and defines go here
  7.  
  8. #endif
  9.  
  10.  
And finally, in the source file, you include your header file.

did that help?
Aug 12 '07 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Jochen Zeischka | last post by:
Hi everybody! I have a question concerning code organisation. Suppose I have the following header file: #ifndef SOME_NAME #define SOME_NAME namespace N { void F()
11
by: Georg Teichtmeister | last post by:
Hello! We are developing a math - library for realtime applications and want to use some given mathlibraries as base(ipp, MTL, .. ). Our library is a wrapper for those and you should be able to...
5
by: Charles L | last post by:
Can someone explain to me what the following means? "C permits multiple definitions of a variable in any given namespace, provided the definitions are the same and it generates only a single...
9
by: lbj137 | last post by:
I have two files: A.c and B.c. In both files I define a global variable, int xxxx; When I compile with a green hills compiler (and also i think with a GNU compiler) I get no errors or warnings....
60
by: Shawnk | last post by:
Some Sr. colleges and I have had an on going discussion relative to when and if C# will ever support 'true' multiple inheritance. Relevant to this, I wanted to query the C# community (the...
11
by: lars.uffmann | last post by:
Easily described problem: Using g++ version 3.3.5 under suse 9.3, bla.h: ----------- #ifndef myTEST #define myTEST ZFSInt test; #endif
3
by: Student | last post by:
Hi all, While compiling a program I had this message : tools.o(.data+0x0): multiple definition of `VAR_1' main.o(.data+0x0): first defined here tools.o(.data+0x4): multiple definition of...
3
by: Jens Müller | last post by:
I have a file here with several enums: #ifndef PLANARSEP_OPTIMIZE_H #define PLANARSEP_OPTIMIZE_H enum fund_cycle_behavior_t {PASS_MODE_FIRST, PASS_MODE_BEST, PASS_MODE_ALL};
10
by: zfareed | last post by:
Similar problem to the previous post. I have created a project with about 7 files including 3 header files and 3 implementation files. I am getting a multiple definition error when compiling for...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.