472,967 Members | 1,997 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

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

_beginthread build problems

I get a few errors building a prog with _beginthread. I have done the
proper compile options and included libcmt.lib in linking, but I still
get these errors:

libcimtd.lib(streamb.obj) : error LNK2001: unresolved external symbol
"void * __cdecl operator new(unsigned int,int,char const *,int)"
(??2@YAPAXIHPBDH@Z)
libcimtd.lib(iostrini.obj) : error LNK2001: unresolved external symbol
"void * __cdecl operator new(unsigned int,int,char const *,int)"
(??2@YAPAXIHPBDH@Z)
libcimtd.lib(ifstream.obj) : error LNK2001: unresolved external symbol
"void * __cdecl operator new(unsigned int,int,char const *,int)"
(??2@YAPAXIHPBDH@Z)
libcimtd.lib(ofstream.obj) : error LNK2001: unresolved external symbol
"void * __cdecl operator new(unsigned int,int,char const *,int)"
(??2@YAPAXIHPBDH@Z)
libcimtd.lib(filebuf1.obj) : error LNK2001: unresolved external symbol
"void * __cdecl operator new(unsigned int,int,char const *,int)"
(??2@YAPAXIHPBDH@Z)

Feb 23 '06 #1
3 4263
sh****@gmail.com wrote:
I get a few errors building a prog with _beginthread.


Prep such a question with Google Groups before posting it. Google will tell
you the best newsgroup (and might risk answering the question before you
can even post!).

This newsgroup is only qualified to discuss the raw C++ language, not all
its platform-specific libraries.

--
Phlip
http://www.greencheese.org/ZeekLand <-- NOT a blog!!!
Feb 23 '06 #2
sh****@gmail.com wrote:
I get a few errors building a prog with _beginthread. I have done the
proper compile options and included libcmt.lib in linking, but I still
get these errors:

libcimtd.lib(streamb.obj) : error LNK2001: unresolved external symbol
"void * __cdecl operator new(unsigned int,int,char const *,int)"
(??2@YAPAXIHPBDH@Z)
libcimtd.lib(iostrini.obj) : error LNK2001: unresolved external symbol
"void * __cdecl operator new(unsigned int,int,char const *,int)"
(??2@YAPAXIHPBDH@Z)
libcimtd.lib(ifstream.obj) : error LNK2001: unresolved external symbol
"void * __cdecl operator new(unsigned int,int,char const *,int)"
(??2@YAPAXIHPBDH@Z)
libcimtd.lib(ofstream.obj) : error LNK2001: unresolved external symbol
"void * __cdecl operator new(unsigned int,int,char const *,int)"
(??2@YAPAXIHPBDH@Z)
libcimtd.lib(filebuf1.obj) : error LNK2001: unresolved external symbol
"void * __cdecl operator new(unsigned int,int,char const *,int)"
(??2@YAPAXIHPBDH@Z)


I had the very same problem yesterday. Be sure that the function you're
passing to _beginthread is static. Also you have to link your program
with /MT option.
Feb 24 '06 #3

I had the same problem , the solution is by adding #include <Afx.h> in
all header files.
it is responsible for management the ordrer of linking the different
librairies.

Mar 1 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

15
by: cody | last post by:
We have a huge project, the solutuion spans 50 projects growing. Everytime I want to start the project I have to wait nearly over 1 minute for the compiler to complete building. This is...
10
by: Douglas Buchanan | last post by:
I am using the following code instead of a very lengthly select case statement. (I have a lot of lookup tables in a settings form that are selected from a ListBox. The data adapters are given a...
2
by: Felix | last post by:
Out of no where I'm starting to get these problems and my Deployment projects won't build anymore. Does anyone have any idea what's causing this? I've tried copying these files from another...
9
by: liangbowen | last post by:
As i konw, the only way to to terminate a thread started by _beginthread() is to user _endthread() (or return) inside the thread. now i started a thread(TodoThread), and created a listenning...
6
by: dude | last post by:
I am trying to test out _beginthread() but I keep getting an error that: _beginthread : undeclared identifier I am using Visuall C++ with DotNET Studio and am on windows XP. Here is the...
2
by: Altman | last post by:
I have a class called cScale, I have made an array of scale objects and I need to run a method of these objects as a new thread. This is my line of code and I can't get it to run. I am still a...
5
by: JHoletzeck | last post by:
Is it possible to set the stack size for the thread created by BackgroundWorker like in the API call _beginthread? If not is the stack size a default or the one I set for the whole application?...
12
by: David Murmann | last post by:
hi all! i just built revision 41809 under winxp using a rather uncommon setup (at least i think so). since i have no visual studio here, i only used freely available tools: cygwin to get the...
1
by: akoolb | last post by:
_beginthread( function, 0, (void*)(int)num); That's what I'm using, what I need to know is how can I send more than one parameter with it, I've spent a while searching and can't find the answer. ...
0
by: lllomh | last post by:
Define the method first this.state = { buttonBackgroundColor: 'green', isBlinking: false, // A new status is added to identify whether the button is blinking or not } autoStart=()=>{
2
by: DJRhino | last post by:
Was curious if anyone else was having this same issue or not.... I was just Up/Down graded to windows 11 and now my access combo boxes are not acting right. With win 10 I could start typing...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 4 Oct 2023 starting at 18:00 UK time (6PM UTC+1) and finishing at about 19:15 (7.15PM) The start time is equivalent to 19:00 (7PM) in Central...
0
by: Aliciasmith | last post by:
In an age dominated by smartphones, having a mobile app for your business is no longer an option; it's a necessity. Whether you're a startup or an established enterprise, finding the right mobile app...
0
tracyyun
by: tracyyun | last post by:
Hello everyone, I have a question and would like some advice on network connectivity. I have one computer connected to my router via WiFi, but I have two other computers that I want to be able to...
2
by: giovanniandrean | last post by:
The energy model is structured as follows and uses excel sheets to give input data: 1-Utility.py contains all the functions needed to calculate the variables and other minor things (mentions...
4
NeoPa
by: NeoPa | last post by:
Hello everyone. I find myself stuck trying to find the VBA way to get Access to create a PDF of the currently-selected (and open) object (Form or Report). I know it can be done by selecting :...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 1 Nov 2023 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM) Please note that the UK and Europe revert to winter time on...
3
by: nia12 | last post by:
Hi there, I am very new to Access so apologies if any of this is obvious/not clear. I am creating a data collection tool for health care employees to complete. It consists of a number of...

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.