News:

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

Main Menu

Using Code Block for First time?

Started by Newbie C++, October 10, 2010, 11:51:43 PM

Previous topic - Next topic

Newbie C++

Hello everyone

I have install Code Block and do I have install the C++ Complier somewhere?

I going to used Code block for SDL programming...

Is there Code Block Tutorial showing me how to install C++ Complier and also SDL too?


Folco

I think your OS is Open Solaris, isn't it ?
Kernel Extremist - PedroM power ©

Newbie C++


Folco

#3
Ok, this helps. :)

You have two choices :
- Install Code::Blocks and a compiler separately (so download codeblocks-10.05-setup.exe, and a compiler of your choice)
- Install Code::Blocks and MinGW + gcc + all the stuff you need (so download codeblocks-10.05mingw-setup.exe which contains a compiler etc...)

Both are available on the download page : http://www.codeblocks.org/downloads/26
If you have installed codeblocks-10.05mingw-setup.exe, you already have GCC/G++ installed. :)

For SDL, I recommend you to look at the official site and at their FAQ.
Kernel Extremist - PedroM power ©

Newbie C++

thank you :)

I was doing Console Applacations tutorial (there is links below it)

http://www.cprogramming.com/code_blocks/

but i just got one error saying

Id.exe - cannot find lSDLmain

what does that mean?

Folco

Kernel Extremist - PedroM power ©

Newbie C++

here what i have done



when I run the program and i get the error like this :(


MortenMacFly

Quote from: Newbie C++ on October 14, 2010, 07:28:33 PM
when I run the program and i get the error like this :(

Well - the linker clearly tells you what's wrong: It cannot find the library you are asking to link against. So you need to provide the path with to library to the linker under "search directories". While you are at it, move the libraries to the right place under "link libraries" and not "other linker options".
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: [url="https://www.codeblocks.org/docs/main_codeblocks_en.html"]https://www.codeblocks.org/docs/main_codeblocks_en.html[/url]
C::B FAQ: [url="https://wiki.codeblocks.org/index.php?title=FAQ"]https://wiki.codeblocks.org/index.php?title=FAQ[/url]

Newbie C++

the Console app work great :)  Thank you :)

I am working on SDL images but I get the error saying this


what I am doing wrong?

stahta01

#9
This is just a guess; but is the SDL Library you installed compatible with MinGW GCC?
The errors look like it might be MSVC based library install instead of MinGW GCC library.
What Compiler are you using?

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]

Newbie C++

Hiya,

I got the wrong library which you were right as it was MSVC Based library......
So I have install the MinGW GCCC Library and

now it is working fine.....thank you so much :)

Code block IDE With SDL is like a dream....unlike those Viusal express c++ which is like system hogs to me!

Newbie C++

how do I get rid of Console window as I have made the window with Images on it but there is console window behide it.... :?