Welcome! Log In Create A New Profile

Advanced

C++ and Operating system

Posted by mahangel 
Announcements Last Post
Announcement SoC Curricula 09/30/2017 01:08PM
Announcement Demarcation or scoping of examinations and assessment 02/13/2017 07:59AM
Announcement School of Computing Short Learning Programmes 11/24/2014 08:37AM
Announcement Unisa contact information 07/28/2011 01:28PM
C++ and Operating system
February 17, 2011 01:04PM
Hi,

I have had no luck in getting any cpp files to compile or even run on my machine. I even installed 3 different types of IDE's and downloaded a whole lot of libraries and still no luck. I run Window 7 Home (64 bit). I was wondering if those who use XP are not having the same issues as me. This will help in making a costly descision. I don't want to spend money if there is another way to resolve my issues.

I really would appreciate any input/response/solution.
Thanks
Lerato
avatar Re: C++ and Operating system
February 17, 2011 05:35PM
This is exactly why I am still using my 6yr old computer(XP) and not my new laptop (Win7).

Why don't you call Mr Aron on 012 429 6815 Mon-Fri 08:00 - 16:00
he might be able to help you. Check osprey during these times to see if he is available or in a meeting.
Re: C++ and Operating system
February 18, 2011 10:15AM
LOL....Thanks. Yeah I just send my 5 year old laptop to be fixed and I was told that the harddrive has crahsed. so he suggested upgrading me from win 7 home to ultimate and then install xp so that i can use both OS on my new laptop...I guess that's the route I'll take. thanks a mil smile. if all that fails, will try yje lecturer
Re: C++ and Operating system
February 18, 2011 11:39AM
why don't your files compile? what errors are you getting? Which IDE are you using? The problem is not the OS
Re: C++ and Operating system
February 22, 2011 04:50PM
you have got to be joking...I installed Dev cpp and then codeblocks and then netbeans and none of them compile even the simplest cpp files. i spend days and hours online trying to find libraries, even with what i found, still no luck. i really have run out of ideas. if it's not the OS then what? You cannot imagine how many times I re-installed the software. I am very desperate at present cause I literally can do no work
Re: C++ and Operating system
February 22, 2011 04:52PM
oh errors:

at first there was a missing makefile in the bin directory. now all it says is 'unable to run program file'
avatar Re: C++ and Operating system
February 22, 2011 05:18PM
Are you sure you've told Dev C++ it's a C++ compiler? (Poke around in the properties window, I'd guess).

Just a shot in the dark. Dev C++ might imagine you're trying to do C, and get annoyed when you confuse it with OO constructs.
Anonymous User
Re: C++ and Operating system
February 22, 2011 10:02PM
might be a shot in the dark - anti virus app may prevent the creation of the .exe file. I have AVG on Windows 7 64bit and have to disable the resident shield when building under visual studio...
Re: C++ and Operating system
February 23, 2011 11:58AM
mahangel Wrote:
-------------------------------------------------------
> oh errors:
>
> at first there was a missing makefile in the bin
> directory. now all it says is 'unable to run
> program file'

I assume this error is on the devcpp ide. The 'unable to run program file' error you are getting is possibly indicating that the ide cannot find the compiler executable. Have you installed any sort of compiler at all, like for example mingw?
Re: C++ and Operating system
February 23, 2011 10:35PM
i guess i'm not the only one who has to use my old computer...just last night it refused to work...until i opened the cpu and dusted it...loldrinking smiley
Re: C++ and Operating system
February 27, 2011 12:52PM
hi,

seems i need to run devc++ on winxp as well. Get numerous issues on win7 pro (no tabs at the bottom of the ide for resources / compiler messages, changes to cpp file doesn't always get compiled).

Installed / uninstalled / reinstalled (even with comptability mode). no difference on win7 - except for tabs at bottom of IDE showing in comptability mode for win98/95.

Installed it once on winxp (actually a 2003 server), and it worked like a charm.

been through the theory - now busy with the example applications from appendix A. lets hope there is still time left

Danie van Eeden
------------------------
Re: C++ and Operating system
March 01, 2011 08:08PM
just got my laptop today from the Technician, that is why I have not responded till now. The setup on my pc is win 7 pro and xp runs as a virtual machine. I installed devcpp and mingw, typed the sierpinski gasket program and it also does not compile. So I wasted time and money for nothing. I guess I should accept that I will fail this course....I just feel like throwing myself off a roof. I mean I have tried every possible thing I could think of and spend days online trying to find something that will work. I seriously have no other hope at this stage. But thanks again for all the input. sad smiley
Re: C++ and Operating system
March 01, 2011 08:47PM
@mahangel

Don't dispare....there must be a solution to your situation.

Have you tried to create a new project (a c project, not c++), include the opengl media, copy the code of the gasket into the source file, and run the code?

_______________________________________
Don't be different...be the one making a difference
avatar Re: C++ and Operating system
March 01, 2011 10:09PM
When it doesn't compile, what's the error message. It'll just be bewildering to me, but you'll find there are quite a few people here who could help you. One step at a time.

And as BlaXpydo says: The first thing to make sure of is that you are compiling C. Not C++, but C. If you're using the DevC++ you used for earlier courses, there's a good chance that it (or Mingw, as has been pointed out) considers itself to be a C++ compiler. You have to make sure that it is reconfigured to be a C compiler. You can do this in the Properties tab, I'm sure.

Why not report back on the whole C/ C++ issue first, and then move on to error output from your compiler after that? One step at a time. Try to just get step 1 done. Reduce the complexity of your problem. OK?
Re: C++ and Operating system
March 01, 2011 10:26PM
mahangel Wrote:
-------------------------------------------------------
> oh errors:
>
> at first there was a missing makefile in the bin
> directory. now all it says is 'unable to run
> program file'

Dev-C++ can not find the make.exe. I had to go change my Compiler Settings after installing Mingw and Dev-C++ from the Unisa 2011 CD.

So in Dev-C++ go to "Tools" -> "Compiler Options" from there make sure your following options is correct:


Re: C++ and Operating system
March 02, 2011 06:11PM
SUCCESS!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Thanks everyone thumbs up smiley
avatar Re: C++ and Operating system
March 02, 2011 08:30PM
Excellent! What was the problem? Something completely different?
avatar Re: C++ and Operating system
March 02, 2011 08:56PM
Glad you came right.
Re: C++ and Operating system
March 03, 2011 10:15AM
one more thing, how do you sort out linker errors? I ran my assignment and one of the programs from the textbook and both had linker errors.
avatar Re: C++ and Operating system
March 03, 2011 12:31PM
What was the problem, and how did you solve it? I would imagine a lot of us would like to know.
Re: C++ and Operating system
March 03, 2011 02:24PM
BenVP and Mr Aron gave the solution.
Does anyone know how to get rid of the linker errors? I've been online all day trying to figure that one out. All of them are related to the glut header files. I made sure that I reference them correctly and that the path is also correct, but no luck.

they all have this structure: [Linker error] undefined reference to...
and then it lists a glut function.
any ideas? would truly appreciate it.
Re: C++ and Operating system
March 03, 2011 02:36PM
@mahangel

Why don't you at least tell us what steps you took. It does not help much that you say who helped.

_______________________________________
Don't be different...be the one making a difference
avatar Re: C++ and Operating system
March 03, 2011 02:40PM
Your path is probably wrong. You've told your linker you can look in such and such a directory, and when it seeks, it finds nothing, or doesn't find that directory.

d-_-b's post is probably the place to start.

Oh hang on. You say the path is correct? Hmm... mysterious problem then. Maybe double check? Or maybe you've missed a necessary #include<....>?
Re: C++ and Operating system
March 03, 2011 04:21PM
all sorted now. thanks. it was a silly mistake...the project was not an opengl project. i think i forgot all about that.
avatar Re: C++ and Operating system
March 03, 2011 05:12PM
Happens to most of us. You get focused on the essence of the problem at hand, and assume all the peripherals are fine. So when the problems occur you start from where your focus was, trying to find the fault where you expect some possible faults. I mean the idea that the "environment" is the problem is pretty dire, isn't it? There are then so many possibilities. One could stray far, far away from the path to the goal, losing hours of that scarce time.

Good to hear you got to the bottom of it.
avatar Re: C++ and Operating system
March 25, 2011 10:59PM
I did this course with notepad and gcc and got 80%.

None of the programs you have to write are large enough to require an IDE.. the IDE is more an obstacle than anything else for small programs like those generally required in any UNISA course.

 
  ,= ,-_-. =.
 ((_/)o o(\_))
  `-'(. .)`-'
      \_/
http://ilanpillemer.com
Entia non sunt multiplicanda praeter necessitatem
avatar Re: C++ and Operating system
May 16, 2011 10:30PM
ilanpillemer Wrote:
-------------------------------------------------------
> I did this course with notepad and gcc and got
> 80%.

... and will still be "bragging" about it in 40 years tongue sticking out smiley Jeez Ilan, get over yourself and take a peek at the real world of computer graphics; by now every student on Osprey knows you can render a couple of triangles in OpenGL winking smiley
Re: C++ and Operating system
May 18, 2011 02:38AM
lycium

Drawing the triangles was the easy part, the hard part would be passing this exam.

II just finished with Chapter 4 and 'm at the moment thinking I might pass if I study only the previous exam papers and make sure I understand that and how to do the maths.

I'm making a big assumption that we don't need to know any formulas out of our heads.

Good luck to anybody else writing this Monday, you will need it!
Sorry, only registered users may post in this forum.

Click here to login