Need some help compiling something

Discussion in 'C Programming' started by kileran@yahoo.com, Jun 11, 2006.

  1. Guest

    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.
     
    , Jun 11, 2006
    #1
    1. Advertising

  2. Guest

    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.
     
    , Jun 11, 2006
    #2
    1. Advertising

  3. Guest

    It's not finished, but if you can't be bothered messing about
    installing compilers you can use an online one called Compilr at
    http://www.caller.me.uk/Compilr - just put the code in textbox and
    click compile.
     
    , Jun 11, 2006
    #3
  4. santosh Guest

    wrote:
    > 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.
     
    santosh, Jun 12, 2006
    #4
  5. Kileran Guest

    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.
     
    Kileran, Jun 12, 2006
    #5
  6. CBFalconer Guest

    Kileran wrote:
    >
    > 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/>
     
    CBFalconer, Jun 12, 2006
    #6
  7. Walter Roberson, Jun 12, 2006
    #7
  8. Kileran Guest

    Kileran, Jun 12, 2006
    #8
  9. In article <>,
    Kileran <> wrote:
    >This one may work better. It's only a 9kb zip file, so slow shouldn't
    >matter


    >http://s1.upload.sc/request/8a5d5f0d5c49ac070d3b0f8eaddef46d


    I had a bunch of trouble getting it to work, but eventually was
    able to do the download.
    --
    Prototypes are supertypes of their clones. -- maplesoft
     
    Walter Roberson, Jun 12, 2006
    #9
  10. In article <>,
    Kileran <> wrote:
    :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.
    --
    If you lie to the compiler, it will get its revenge. -- Henry Spencer
     
    Walter Roberson, Jun 12, 2006
    #10
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Guest
    Replies:
    0
    Views:
    707
    Guest
    Feb 25, 2004
  2. Guest
    Replies:
    4
    Views:
    510
    Guest
    Oct 13, 2004
  3. Domino
    Replies:
    5
    Views:
    416
    dorayme
    Nov 5, 2006
  4. Pekka Järvinen
    Replies:
    2
    Views:
    697
    Richard Tobin
    Apr 29, 2008
  5. Replies:
    4
    Views:
    239
    Tad McClellan
    Jun 1, 2007
Loading...

Share This Page