Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Vc++一直link error...

0 views
Skip to first unread message

Cyber Dreamer

unread,
Mar 22, 1998, 3:00:00 AM3/22/98
to

: nafxcwd.lib(thrdcore.obj) : error LNK2001: unresolved external symbol __endt
: nafxcwd.lib(thrdcore.obj) : error LNK2001: unresolved external symbol __begi
: 請問一下,這倒底是什麼問題啊?

你要 enable multithread 才行,例如加 /MT 這個 option。

--
棄 亂 心 憂
風 骨 清
逸 飛 刀 愁
人 意 散 。

蒼天已死 我心亦夫?

unread,
Mar 22, 1998, 3:00:00 AM3/22/98
to

==> 在 dream...@csie.nctu.edu.tw (Cyber Dreamer) 的文章中提到:

> : nafxcwd.lib(thrdcore.obj) : error LNK2001: unresolved external symbol __endt
> : nafxcwd.lib(thrdcore.obj) : error LNK2001: unresolved external symbol __begi
> : 請問一下,這倒底是什麼問題啊?
> 你要 enable multithread 才行,例如加 /MT 這個 option。
可是我是在IDE的環境下,不是命令列說...
而且當我在命令列下加/MT時,也還是不行說...
--
問世間,情是何物,直教生死相許?
天南地北雙飛客,老翅幾回寒暑?
歡樂趣,離別苦,就中更有痴兒女。
君應有語,渺萬里層雲,千山暮雪,隻影向誰去?
金.元好問
---錄自神雕俠侶
--
* Origin: ★ 交通大學資訊科學系 BBS ★ <bbs.cis.nctu.edu.tw: 140.113.23.3>

pinbin

unread,
Mar 24, 1998, 3:00:00 AM3/24/98
to

==> 在 beba@cis_nctu (蒼天已死 我心亦夫?) 的文章中提到:

> ==> 在 dream...@csie.nctu.edu.tw (Cyber Dreamer) 的文章中提到:
> > 你要 enable multithread 才行,例如加 /MT 這個 option。
> 可是我是在IDE的環境下,不是命令列說...
> 而且當我在命令列下加/MT時,也還是不行說...

可能是你繼承的class有static變數,而你沒有為它設定初值...

想找個洞躲起來

unread,
Mar 24, 1998, 3:00:00 AM3/24/98
to

【 在 beba...@cis.nctu.edu.tw (蒼天已死 我心亦夫?) 的大作中提到: 】

: compile時都沒問題,但在link會出現以下的訊息:
: nafxcwd.lib(thrdcore.obj) : error LNK2001: unresolved external symbol __endthreadex
: nafxcwd.lib(thrdcore.obj) : error LNK2001: unresolved external symbol __beginthreadex
: Debug/Mylove.exe : fatal error LNK1120: 2 unresolved externals
: 請問一下,這倒底是什麼問題啊?
: 我的path都有設...


不是 path 的問題, 請找一下 link 的設定, 有個 multithread dll/lib
的選項(for MFC 及 C 的標準程式庫)...

直接用 SDK 的人可以忽略這個問題, 如果用了 C 的標準程庫則
請設該選項省卻部份麻煩...

--
[m [1;35m※ 來源:‧靜宜大學計算機中心BBS站 bbs.pu.edu.tw‧[FROM: 140.128.2.100] [m

wowo

unread,
Mar 26, 1998, 3:00:00 AM3/26/98
to

==> 於 蒼天已死 我心亦夫? (beba...@cis.nctu.edu.tw) 文中述及:
: 我寫了一個非常簡單的小程式:
: #include <afxwin.h>
: LPCTSTR str ="this is a test";
: class Mylove : public CWinApp
: {
: public:
: Mylove() : CWinApp(str)
: {};
: virtual BOOL Initstance();
: };
: BOOL Mylove::Initstance()
: {
: CFrameWnd * MyFrameWnd = new CFrameWnd();
: m_pMainWnd = MyFrameWnd;
: MyFrameWnd -> Create(NULL,str);
: MyFrameWnd -> ShowWindow(SW_SHOW);
: return TRUE;
: }
: Mylove HiMylove;

: compile時都沒問題,但在link會出現以下的訊息:
: nafxcwd.lib(thrdcore.obj) : error LNK2001: unresolved external symbol __endthreadex
: nafxcwd.lib(thrdcore.obj) : error LNK2001: unresolved external symbol __beginthreadex
: Debug/Mylove.exe : fatal error LNK1120: 2 unresolved externals
: 請問一下,這倒底是什麼問題啊?
: 我的path都有設...

project下的setting選項,fundation class 選USE MFC ...
--
Ξ Origin: 中正大學寂寞芳心小站 <bbs.ccu.edu.tw> [FROM: 140.123.121.71]

0 new messages