News:

Accounts with zero posts and zero activity during the last months will be deleted periodically to fight SPAM!

Main Menu

using the official MinGW

Started by MoonKid, May 14, 2008, 02:25:29 PM

Previous topic - Next topic

MoonKid

I want to use the official MinGW compiler not the Code::Blocks inside.

I just setup the compiler settings to the new path "C:\MinGW".

Compiling the project work fine.
But the next linker find undefinied references __cpu__feauters_init.

Using the Code::Blocks build-in MinGW work fine.

[output]
mingw32-g++.exe -LC:\wxWidgets\lib\gcc_dll -LC:\Programme\CodeBlocks\lib  -o .\blackfiskDd.exe .out\objs_debd\src\BFAboutDlg.o .out\objs_debd\src\BFApp.o .out\objs_debd\src\BFBackupInfoCtrl.o .out\objs_debd\src\BFBackupLog.o .out\objs_debd\src\BFBackupProgressDlg.o .out\objs_debd\src\BFBackupQuestionDlg.o .out\objs_debd\src\BFBackupTree.o .out\objs_debd\src\BFCmdLine.o .out\objs_debd\src\BFCore.o .out\objs_debd\src\BFCore_traverser.o .out\objs_debd\src\BFDestinationCtrl.o .out\objs_debd\src\BFDestinationDlg.o .out\objs_debd\src\BFDirCtrl.o .out\objs_debd\src\BFExcludeCtrl.o .out\objs_debd\src\BFHelpCtrl.o .out\objs_debd\src\BFHyperlinkCtrl.o .out\objs_debd\src\BFIconTable.o .out\objs_debd\src\BFIsWorkingCtrl.o .out\objs_debd\src\BFLog.o .out\objs_debd\src\BFLogBase.o .out\objs_debd\src\BFLogViewDlg.o .out\objs_debd\src\BFMainFrame.o .out\objs_debd\src\BFMessageDlg.o .out\objs_debd\src\BFMsgObserver.o .out\objs_debd\src\BFPlaceholderButton.o .out\objs_debd\src\BFProcessMsgDlg.o .out\objs_debd\src\BFProcessMsgSubject.o .out\objs_debd\src\BFProgressCtrl.o .out\objs_debd\src\BFProjectSettings.o .out\objs_debd\src\BFProjectSettingsCtrl.o .out\objs_debd\src\BFProjectSettingsDlg.o .out\objs_debd\src\BFRootTask.o .out\objs_debd\src\BFRootTaskApp.o .out\objs_debd\src\BFSettings.o .out\objs_debd\src\BFSettingsDlg.o .out\objs_debd\src\BFSystem.o .out\objs_debd\src\BFTask.o .out\objs_debd\src\BFTaskBase.o .out\objs_debd\src\BFTaskDlg.o .out\objs_debd\src\BFTaskListCtrl.o .out\objs_debd\src\BFThread_ProjectRunner.o .out\objs_debd\src\BFTimeDurationCtrl.o .out\objs_debd\src\BFwxLog.o .out\objs_debd\src\ObserverPattern.o .out\objs_debd\src\Progress.o .out\objs_debd\src\blackfisk.o .out\objs_debd\third-party\wxSerialize\src\wxSerialize.o  .out\objs_debd\blackfisk.res  --subsystem,windows  -lwxzlibd -lwxmsw29ud  -mwindows
C:/Programme/CodeBlocks/MinGW/bin/../lib/gcc/mingw32/3.4.5/../../../crt2.o:crt1.c:(.text+0x167): undefined reference to `___cpu_features_init'
collect2: ld returned 1 exit status
Process terminated with status 1 (0 minutes, 49 seconds)
1 errors, 1 warnings
[/output]

stahta01

#1
You must use only the MinGW in c:\Mingw if it exist!!!

Quote
C:/Programme/CodeBlocks/MinGW/bin/../lib/gcc/mingw32/3.4.5

Above it says it is using the one under Code::Blocks.

Quote
I just setup the compiler settings to the new path "C:\MinGW".

Check both the "Compiler installation directory" and "additional paths"

Also, check the search directory settings, under compiler, linker and resource compiler.



Tim S
C Programmer working to learn more about C++.
On Windows 10 64 bit and Windows 11 64 bit.
--
When in doubt, read the CB WiKi FAQ. [url="http://wiki.codeblocks.org"]http://wiki.codeblocks.org[/url]

MoonKid

Quote from: stahta01 on May 14, 2008, 07:41:01 PM
Also, check the search directory settings, under compiler, linker and resource compiler.

Ah nice, that was the problem.
Thank you very much!!!  :lol: