I'm curious if there's another make besides "mingw32-make" that works with MinGW okay? I am really getting annoyed with MinGW anymore, their make is throwing these errors at me quite often:
"makefile.all:248: *** recipe commences before first target. Stop."
And this happens with various makefiles when I try and compile other libraries and such. This never happened before, I am assuming all this crap came into play with MinGW 4.x.x +?
Do I have to go back to an old MinGW or will I be forced to use Visual Studio? I was away from programming for like 2 years and in that short time a lot seems to have been screwed up with GNU compilers and utils. Like enforcing "const char *". I understand a little about this, but come on, it wasn't THAT serious, not in anything I programmed... now so much code is broken it's a pain in the ass to fix. I'm on the virge of throwing in the programming towel, I don't feel like relearning and reprogramming old code and all the rest of this shit all over again. Maybe sticking with Microsoft tools is the best bet.
(Sorry for the rant, I've been trying to get started on a project all night that I had on the back burner and after recompiling old code, redoing old libs etc... for a couple hours and then coming across more problems I get fed up when I haven't written a single line of code for the project I wanted to work on.... gawd)
recompiling old code, redoing old libs etc... for a couple hours and then coming across more problems I get fed up when I haven't written a single line of code for the project I wanted to work on
Programming is like sex. It's sweaty, dirty work, and sometimes nothing comes out.
It may be possible to get Cygwin's make to work with MinGW's compilers, but I don't know if Cygwin actually provides its own make, or if it just uses MinGW's.
I just tried out Visual Studio 10. I've actually had it installed for quite some time now but avoided it in favour of MinGW, but it looks like they're seriously breaking MinGW, so it's time to ditch it and bite the bullet and try VS10 out. Downloaded the binaries for it (I am SO done with compiling this! ) and used the project generator to get started.
I have really tried to motivate myself to get back into programming after wasting my time playing World of Warcraft for a few years. I finally cancelled my account for that a couple months ago and want to get more productive again and they go bugger up MinGW on me.
Thank God Microsoft made their VS free now or I'm not sure what I would do.
I understand how you need to change as time goes on and learn new things, but I have used GNU compilers for years (since the early 90s) and never seen them break code like this. I have compile errors on code that used to compile fine, makefile errors etc... a royal pain.... or used to be anyhow. They just drove me straight into Microsofts arms... I'll never forgive them for that.
Edit: Just in case I wish to edit my old projects... I have Dev-C++ re-installed with MinGW 3.4.2... ahhhh... so refreshing to have it all work again. I'll use MSVC for anything new I think.
Just so you know, a lot of code that would compile fine under GCC may not under MSVC, so you may still have to do some rewriting.
Is this with your own Makefile? Usually you put your defines first, then the target name, and the "recipe". If you post your Makefile here, someone might be able to point out the problem with it.
If this is a Makefile provided by a source distribution or generated by an IDE, it sounds like quite odd behaviour.
I am assuming all this crap came into play with MinGW 4.x.x +?
Why don't you check by running an older version of make. It's only an executable...
Don't use hand-written makefiles.
And this happens with various makefiles when I try and compile other libraries and such. This never happened before, I am assuming all this crap came into play with MinGW 4.x.x +?
Make sure you haven't inadvertently messed up those makefiles. Sometimes windows editors may like to convert the tabs in makefiles to spaces, which is bad.
But you wasn't using DevC++ Right?
Actually, I was trying to compile Allegro 4.2 with the newer MingW 4.5.2 and the messed up makefile was Allegro 4.2's . I also had the exact same problem when trying to compile jpgalleg for use with that version of allegro, same error in their makefile.
When I finally got fed up and DELETED MinGW 4.5.2 and re-installed MinGW 3.4.2 guess what? No more errors. Allegro 4.2 compiled fine, JPGAlleg compiled fine... you get the picture.
After all this, I figured I may as well go all the way and I uninstalled CodeBlocks and put Dev-C++ back on. I can now compile all my projects without headaches. I can finally stop spending days trying to figure out what some idiot changed in the new compilers and make programs and concentrate on actually coding my projects. I realize Dev-C++ is out of date but it works for me... that's all that counts. I'm not completely abandoning new software, I'm going to try coding new stuff with MSVC10 + Allegro 5. But I want my Dev-++/Allegro 4.2 to fall back on. I have coded with that for years with no problems at all...
When you do have to bite the bullet eventually, it'll be harder than ever.
When you do have to bite the bullet eventually, it'll be harder than ever.
No, it won't, because I'll be learning to use MSVC. But when I'm not in the mood to learn the tools, I can fall back to coding with Dev-C++ and an older MinGW. I don't do this for a living so I'll NEVER have to bite the bullet.
GNU compilers broke my code, they didn't give warnings this was coming, they just done it. I NEVER ignore compiler warnings, I always have -Wall on so I can catch anything that is amiss and everything was okay... until now. Doesn't matter because I just won't use newer GNU compilers, at least now for the time being. Anyhow, if I need to bite a bullet and learn something new, it will be MSVC.
Don't use hand-written makefiles.
Heed this advice! Can one write a make file by hand? Sure. But just because you can, doesn't mean you should.
Also, in my experience with cross platform projects, it is definitely worth the effort to set up native project files for each platform:
Makefile via CMake/Scons/etc on *Nix systems.
XCode on Mac (if you're not making a command line utility)
Visual Studio on Windows.
GNU compilers broke my code, they didn't give warnings this was coming, they just done it.
If MinGW hadn't made such an incredibly huge jump it wouldn't be so bad. I have trouble deciphering the error messages from 4.3.3, but that's just a bit of n00bishness (for this version) on my part. After a few more months, those weird error messages will be obvious.
GNU compilers broke my code, they didn't give warnings this was coming, they just done it.
If it actually just errors out, then your code was actually WRONG, and gcc was being too lenient before.
Yeah, except I didn't use a hand written makefile... I HAVE written my own without problems in the past though... no, I used ALLRGRO 4.2 makefile... so if there was a problem it's either whomever made the Allegro 4.2 makefile, or it's MinGW 4.5.2's MinGW32-make.
The problem also exists if you try and compile JPGAlleg with MinGW 4.5.2's MinGW32-make. It has the exact same error. Doesn't sound like the makefile's to me, but with the make program itself. Especially seeing as how MinGW 3.4.2 compiled it just fine!
If it actually just errors out, then your code was actually WRONG, and gcc was being too lenient before.
So it was being so lenient it didn't even bother to warn me?? They just found a problem and decide to go from not warning to giving out errors?! This is good how?
Try some code from 1987 and see if Mingw 3.4.2 likes them.
My code wasn't that fucking old, gawd. I had code I had worked on in 2009, less than two years ago, roughly 16 months ago that suddenly wouldn't compile at all.
Oh, and the irony was, code I had fixed to work with the newer GNU I had to go back and unfix it to compile again with the old GNU! LMAO... ahem, it wasn't being lenient... it didn't warn me, when I coded it the way the newer GNU wanted it didn't like it... It didn't like what the newer GNU now insists upon! That's an ass-backwards way of doing things.
I had code I had worked on in 2009, less than two years ago, roughly 16 months ago that suddenly wouldn't compile at all.
And that code was tuned by definition for a (how many years old?) version of gcc?
In any event, I don't like it, I'm not using it. I'm switching to MSVC. My code is broken with it, Allegro 4.2 is broken with it, JPGAlleg is broken with it etc.. etc... etc... etc.... but it's not GNU's fault... okay, whatever. Believe what you wish. I'll learn MSVC, I may still have to learn a few things, but I may as well learn an industry standard.
Allegro 4.2 is broken with it, JPGAlleg is broken with it
Allegro 4.2 is old. There is Allegro 4.4, with patched versions of everything and no makefiles.
So it was being so lenient it didn't even bother to warn me?? They just found a problem and decide to go from not warning to giving out errors?! This is good how?
You do realize that the version of GCC you were using is like 6+ years old right? They have been steadily increasing the standards conformity and strictness of the compiler for years now. It really isn't GNU's fault that you hadn't upgraded your compiler in 6 years. Mind you its not exactly your fault either since Mingw has been really really slow the past 5 years.
But yeah, Allegro 4.2 is at least as old as the old Mingw, so they definitely work together.
Perhaps I have been out of the loop too long, I don't know. I just know it's been a pain in the butt lately and the older compilers work. They compile code and make executables that work on Windows 7-64bit, so I see no reason to update them. I needed to go back to the older compilers and library if I wanted to work on my old projects rather than spend more time trying to figure out what has changed.
When I want to get up to date and spend time figuring out a compiler, I'll do that with MSVC I think. This way I have something new to learn, and something old that works.
Sorry for the ranting... I'll have to stop posting for a while I think until I have been at this for a few months, then maybe come back to the forums again.
No reason to stop posting or anything. You'll want to note that Allegro 5 doesn't work very well with Mingw GCC 3.x. It really prefers the latest 4.x compilers due to not having broken Thread Local Storage.
Perhaps I have been out of the loop too long, I don't know.
All the more reason to hang out on a.cc. I've learned a metric crapton of stuff, even if it doesn't seem like it.
No reason to stop posting or anything. You'll want to note that Allegro 5 doesn't work very well with Mingw GCC 3.x. It really prefers the latest 4.x compilers due to not having broken Thread Local Storage.
I have MSVC10 + Allegro 5 installed. I needed an excuse to play around with VC10 anyhow I guess. The idea behind sticking with MinGW was that I knew it, there wasn't anything new I needed to learn. MSVC10 is now free, there's no reason to stick with MinGW anymore, so I may as well learn MSVC if I'm going to be learning anything. I'm keeping the old stuff for use with old projects. I'm hoping to eventually port any older projects that I really want to work on over to MSVC + Allegro 5 once I am comfortable with it.
Programming is like sex. It's sweaty, dirty work, and sometimes nothing comes out.
... um... okay. I couldn't stop myself from laughing onto the floor at that. But... wow |-3
[EDIT]
Nevermind. Reading comprehension fail.
[Freakin editting]
After all this, I figured I may as well go all the way and I uninstalled CodeBlocks and put Dev-C++ back on.
That makes no sense at all, since C::B can use whatever compiler you tell it to, and can even import Dev-C++ projects.
My code wasn't that fucking old, gawd. I had code I had worked on in 2009, less than two years ago, roughly 16 months ago that suddenly wouldn't compile at all.
Then it was coded badly. I've got projects going back five years that still compile fine.
I forgot to mention, importing Dev-C++ projects wasn't working very well. The project settings were screwed up to the point that no matter what I did to correct them after an import, I still couldn't compile, I would get strange errors.
BUT, when I created an empty project, then manually imported all my project files and manually set up all the options by hand, they compiled up fine. If I need to go through that much work, I may as well have Dev-C++ back on and load up the actual projects. It may be an old IDE but it works for me, I have never had a problem with it. I also installed the old MinGW to go with it. But keep in mind, this is ONLY so I can load in older projects (I have quite a few, my programming interest vary quite a bit! ) and compile them without having to spend a full day reconfiguring, manually setting up a new project and recoding all of them for a new compiler. I will probably pick a select few projects and port them, but if I do, it will be to MSVC10 which I also have installed and Allegro 5. But I want my old IDE and MinG installed so I can screw around for the time being without the hassles.
Oh, one other hassle, which probably could have been corrected somehow, though I couldn't find a way, was CodeBlocks, when ever I went to add a new library, it would take me to the last project folder I worked on instead of the MinGW/lib folder... then you spend a minute navigating around Windows to find the MinGW/lib folder, this gets very annoying. Like I said, lots of little things all add up and I got fed up.
Note, most of the problems I had were dealing with compiling libraries that were used in some of those projects, not stuff I actually coded (which makes recoding them even worse, I can read my own code, but someone elses?!). And the makefiles that went with them. NOT my own code. Just the odd thing like the "const char *" issues where I needed to change that in a few places, little things. It just all adds up to a huge annoyance. When you correct your own code and it sill won't compile, and hours later you realize it was due to someone else's library/makefile which I absolutely don't feel like reprogramming their code and spending another day when I could just put on the older IDE/compiler... well... you get the picture. (actually, you probably don't, I have repeated myself too many times and wish there was a "delete thread" button).
Note, most of the problems I had were dealing with compiling libraries that were used in some of those projects, not stuff I actually coded (which makes recoding them even worse, I can read my own code, but someone elses?!). And the makefiles that went with them. NOT my own code.
Yeah, I know that pain. I've often found other people's makefiles didn't work, even back in MinGW 3.x days. I usually, just created my own projects with the source and didn't bother with their makefiles.