Jump to content

need a program


matt11504

Recommended Posts

im learning c++ programming and i need a program that can compile c++ programming and build it into a .exe file. i have downloaded codeblocks but it cant build .exe so I downloaded make-3.81 and i dont know how to install in, it gave some folders and a bunch of files and not one install file.

anybody know of any programs that can compile c++ coding into .exe?

Edited by matt11504
Link to comment
Share on other sites

make needs gcc/gpp to work. Try Dev-C++. I've been using it for a few years, and it is by far the best free C/C++ compiler for Windows that I know of.

Prior to filing a bug against any of my code, please consider this response to common concerns.

Link to comment
Share on other sites

That's generally what a compiler does. Well, the compiler portion of it actually just generates object files, but the gcc/gpp based compilers have a built in linker which joins the object files into the .exe or some other binary format. You don't really have to worry about these details for now. Dev-C++ has a nice GUI. You just open a .c/.cpp file with it, and find the Execute->Compile option. (Ctrl+F9 shortcut, I think) It will make a .exe in the same directory that you had your .c/.ccp in. You can also build projects with it, which will auto-generate makefiles to allow you to put together a single .exe file from multiple .cpp files. But you probably don't need to worry about that right now, either.

 

If you do want to learn how to use make utility, Dev-C++ does have its own make.exe in the bin directory which works almost the same as Linux make. The gcc and gpp in that directory also work similar to their Linux counterparts.

Prior to filing a bug against any of my code, please consider this response to common concerns.

Link to comment
Share on other sites

  • 4 weeks later...
thanks.

with some help, i created my first C++ application.

are you old?

You should post such programs with a source. A lot of people will not run such a program from an executable for security reasons. Also, there isn't much point in posting something like that if you don't want coments on your code, and that requires the source.

 

Dev C++ isn't the best but it's good for beginnerish stuff

Do you know of anything better on Windows platform? There is VC++, which can do more stuff, but it is hardly any better when you get right to it. It tends to leave way too much junk in your code, and trying to find all the options to disable all of it is a pain.

 

And I'm only aware of two downsides to Dev-C++. First, it doesn't handle inline assembly in a standard way. Second is that it isn't all that great at optimization. Something along the lines of:

 

c=a+b;

return c;

 

Results in the following lines right before the epilogue:

 

mov ss:[ebp-4],eax

mov eax,ss:[ebp-4]

 

The reason for that, of course, is that it uses eax as both the accumulator for the addition operation and as the return value register.

Prior to filing a bug against any of my code, please consider this response to common concerns.

Link to comment
Share on other sites

Well i hear a lot of stuff for and against both compilers. I heard that VC++ compiles better, faster, more optimised code. But u seem to think that gcc is better. I don't know what to believe. All i know is that sometimes when i use Dev-C++'s auto-complete on functions/variables, it crashes sad.gif. But that's the only bug i know of. Also, Visual Studio's GUI is much nicer, u can drag'n'drop windows and side panels and it automatically hides ones your not using (i hate having to always click close on Dev's bottom window).

Link to comment
Share on other sites

Who uses GUI that comes with compiler, anyways? That's just silly. Personally, I just use a Notepad. I know some people whine about auto-tabs and syntax highlighting. If you are one of these people, get something like Notepad++. VC++ has way too much junk in its GUI.

Prior to filing a bug against any of my code, please consider this response to common concerns.

Link to comment
Share on other sites

NOTEPAD!!! hahaha, lol. lol.gif

Who uses notepad these days!? That would be like building a skyscraper with a hammer (you use a nail gun). I mean, i don't need a fancy GUI nor do i like waiting for it to load. But i at least use something with auto tabbing. TextPad is the best i've seen. Plus it has a useful feature that no other editor has, when u press the down key it goes to the column u were at not the one u are at when u pressed it. So you don't have to keep pressing left to get back, it's too difficult to explain... ok i found a forum that explains it here. It's on an UltraEdit forum but that only serves to highlight how unique it is to TextPad smile.gif

 

Anyway, i was talking about gcc to specifically Dev-Cpp. But i use Dev-Cpp because i can compile with the press of a button (TextPad can do this but it can't handle C/C++ features like linking).

 

 

 

 

 

... notepad! :rofl:

Link to comment
Share on other sites

Well, in K^2's defense, he said he uses a notepad, not Windows's Notepad.

 

I use Programmer's Notepad 2 btw, but mainly for HTML coding.

Link to comment
Share on other sites

... a Notepad.

Oh, ok. Well in that case, i use TextPad which is a notepad. But i really couldn't see how anyone could use MS Notepad, i couldn't live without syntax highlighting. Anyway, i only use TextPad for small projects. If i am going to make a large-ish size C++ application (like 5 or more classes/files) i would use Visual Studio simply because it allows you to jump straight to a function declaration instead of searching through tons of files.

 

 

I know some people whine about auto-tabs and syntax highlighting.

Well he was definitely talking about an editor without syntax highlighting. wow.gif

Link to comment
Share on other sites

No, no. I use Windows' Notepad. It is more than sufficient. If you need something more high tech to program with, it only shows your lack of experience. You don't need highlighting of any sort if you can look at the source and see all the relevant brackets and quotes right away. The only stuff I cannot write with Notepad is straight machine code. I use a hex editor for that. Between Notepad and Hex Editor, you really don't need anything else if you know what you are doing.

 

I've used a combination of Notepad + Hex Editor to write everything from game engines to medical 3D software to audio drivers, as well as have cracked a number of various file formats, including maps for W3D, 3D model files for Deus Ex: Invisible War, and a number of other titles.

 

The only thing that would be kind of nice from an editor is an ability to select bytes to be represented in ASCII, hex, decimal, and float. But I have not seen such an editor. Maybe I should write one.

Prior to filing a bug against any of my code, please consider this response to common concerns.

Link to comment
Share on other sites

...If you need something more high tech to program with, it only shows your lack of experience...

I normally agree with pretty much everything you say, but that's bollocks. Only using Notepad compared to a decent IDE doesn't give you a bigger e-Penis or mean you're a better coder. A decent IDE (cutting away the fluff and superfluous junk) has other advantages than just making coding easier. Even then, making coding easier and more time-efficient isn't a bad thing if your overall productivity is higher. (I.e. I concede an IDE may encourage bad habits such as "lazy" coding/less thinking requiring more rewriting.)

"Face Your Fears, Live Your Dreams" - No Fear


"God was a dream of good government." - Deus Ex Machina


"I contend that we are both atheists. I just believe in one fewer god than you do.


When you understand why you dismiss all the other possible gods,


you will understand why I dismiss yours." - Stephen Roberts

sig.jpg
Link to comment
Share on other sites

Jevon, I'm not saying that a good coder will only code with Notepad. I'm saying that it is a bad coder that feels that something more is necessary to produce good code. If you feel that it makes your life easier, then by all means, but if you feel that you can't code with Notepad, you really should stop using IDEs for a while and learn to.

Prior to filing a bug against any of my code, please consider this response to common concerns.

Link to comment
Share on other sites

Jevon, I'm not saying that a good coder will only code with Notepad. I'm saying that it is a bad coder that feels that something more is necessary to produce good code. If you feel that it makes your life easier, then by all means, but if you feel that you can't code with Notepad, you really should stop using IDEs for a while and learn to.

Fair enough. What you're actually coding has an effect on how helpful an IDE is as well I guess. I use Notepad when forced to do PHP for example.

"Face Your Fears, Live Your Dreams" - No Fear


"God was a dream of good government." - Deus Ex Machina


"I contend that we are both atheists. I just believe in one fewer god than you do.


When you understand why you dismiss all the other possible gods,


you will understand why I dismiss yours." - Stephen Roberts

sig.jpg
Link to comment
Share on other sites

I just hate always having to tab in Notepad, i would prefer an editor that has an auto-tabbing feature. I just like my code to look all neat and well-formatted, it's easier to read that way. And the same goes for syntax highlighting.

 

 

You don't need highlighting of any sort if you can look at the source and see all the relevant brackets and quotes right away.

I admire your ability to be able to read code like that, but after staring at code for a while i'm glad i have syntax highlighting. It's a lot harder to see things like comments without it (especially if the /* and */ are off-screen).

 

 

btw, what was this topic about again? biggrin.gif

Link to comment
Share on other sites

I just hate always having to tab in Notepad, i would prefer an editor that has an auto-tabbing feature.

Ok, I'll give you auto-tabs. That is useful. I think I'm going to write my own text editor.

Prior to filing a bug against any of my code, please consider this response to common concerns.

Link to comment
Share on other sites

Personally, I just use a Notepad. I know some people whine about auto-tabs and syntax highlighting. If you are one of these people, get something like Notepad++. VC++ has way too much junk in its GUI.

What about Regular Expressions! Notepad doesn't support Regular Expression pattern matching. Now don't tell me you don't love RE's wow.gif

Link to comment
Share on other sites

I never really needed regex in my searches. Ability to insert some wild cards would be nice, but full regex support is an overkill. That said, if the editor would have provided regex support, I'm sure I'd end up running a lot of s/.../.../g expressions.

Prior to filing a bug against any of my code, please consider this response to common concerns.

Link to comment
Share on other sites

  • 1 User Currently Viewing
    0 members, 0 Anonymous, 1 Guest

×
×
  • Create New...

Important Information

By using GTAForums.com, you agree to our Terms of Use and Privacy Policy.