Need some help compiling something

K

kileran

I used to program. However i'm finding that statment now means as much
as a 40 year old saying "I used to be cool".

I've got a program here, and the code for it, and i want to make a
custom alteration. Very minor at that.

Here's what the program does. It generates a pattern of random lights
on the screen, pauses for a few seconds, then does it again. If during
the pause the "S" key is pressed, it writes the screen contents to a
..bmp file.

All this code is already in place. All i want to do is make it so that
instead of pausing, it calls the sub for writing the bmp automatically,
then continues.

I can even make these modifications to the code myself, it's pretty
simple. The problem i'm having is compiling. It's been about 10 years
since i left school, and therefor about 10.5 years since i've actually
done anything like this.

If anyone is willing to help me get this to work, please reply. I thank
you in advance.
 
K

kleuske

(e-mail address removed) schreef:
If anyone is willing to help me get this to work, please reply. I thank
you in advance.

If I understand correctly you're asking how to compile a program? Don't
you think it's only fair you tell us _what_ compiler you are using (or
trying to use)?

Besides, this is an n.g. on the language 'c', not about specific
implementations, so you may get a better answer if you ask in a n.g.
that's specific for your OS/implementation.
 
S

santosh

I used to program. However i'm finding that statment now means as much
as a 40 year old saying "I used to be cool".

I've got a program here, and the code for it, and i want to make a
custom alteration. Very minor at that.

You've not even specified what language the program is written with.
Since you're posting here, I'm assuming it's C.

If the failure to compile is due to standard C constructs or misuse of
the same then this group can help you, if you post your source along
with compilation details.

Otherwise, it would be better to post to a group specific to the
compiler you're using or the operating system for which you're
compiling. In anycase provide the source code and details of
compilation environment.
 
K

Kileran

Thank you santosh, this is the reply i was hoping to get :)
1) your right in asuming it's a C program
2) Your right in asuming the failure to compile is a misuse of
something

Here is the file, I've got a few links for it, just incase one fails.

http://s1.upload.sc/request/09c260b56de383e3acb00d3d530bdd6e/owner
http://www.filefactory.com/?8269f3

The file contains the source, a compiled version of that source, and a
prefs file.

So the source is pretty plainly laid out. Note, that's the original
version. It does not contain the alterations i want. I discarded them,
because i'm sure that's probably the issue. Like i said originally,
it's been 10 years since i used C++ in my Highschool class.

All i need is for "void screenshot" to be called at the end of the
routine that makes all the pretty images. This will create a looping
program that will create a TON of bmp's until I press ESC. (esc is
already programed as a break)

Thank you so much for your willingness to help.
 
C

CBFalconer

Kileran said:
Thank you santosh, this is the reply i was hoping to get :)
1) your right in asuming it's a C program
2) Your right in asuming the failure to compile is a misuse of
something

Here is the file, I've got a few links for it, just incase one fails.

http://s1.upload.sc/request/09c260b56de383e3acb00d3d530bdd6e/owner
http://www.filefactory.com/?8269f3

The file contains the source, a compiled version of that source, and a
prefs file.

Include context. If you are using a google that has not
implemented automatic quoting, see my sig below. Without context
your post it meaningless to the vast majority, who are not using
the broken google interface to usenet.

--
"If you want to post a followup via groups.google.com, don't use
the broken "Reply" link at the bottom of the article. Click on
"show options" at the top of the article, then click on the
"Reply" at the bottom of the article headers." - Keith Thompson
More details at: <http://cfaj.freeshell.org/google/>
Also see <http://www.safalra.com/special/googlegroupsreply/>
 
W

Walter Roberson

:Thank you santosh, this is the reply i was hoping to get :)
:1) your right in asuming it's a C program
:2) Your right in asuming the failure to compile is a misuse of
:something
Here is the file, I've got a few links for it, just incase one fails.

Sorry, your program requires
<windows.h> and <ddraw.h>, neither of which are standard C.
The problem might be with those. Your program appears to use
Windows specific features: in particular you declare some things
with a CALLBACK attribute; for standard C that would have to be
#define'd into nothingness.

You also have these difficulties:
- <stdlib.h> must be included to define RAND_MAX malloc free exit
- <string.h> must be included to define memset
- you do not define min() or max() anywhere. Those are not defined
in any standard header, so you need ot define them yourself.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,482
Members
44,901
Latest member
Noble71S45

Latest Threads

Top