Mail Archives: djgpp/2007/09/24/00:24:02
At 11:46 PM 9/21/2007, you wrote:
>On Tue, 18 Sep 2007 10:43:55 -0400 in comp.os.msdos.djgpp, Ethan
>Rosenberg <ethros AT earthlink DOT net> wrote:
>
> >Dear List -
> >
> >Can someone please help me with the following C code. It aborts with
> >code 1. My apologies for the length of the code.
> >
> >Ethan
> >
> >=============
>
> >}
> >
> > fspacing = (float)spacing;
> > fgain = fspacing/3.0 + 2.0;
> >
> > gain = (int)fgain;
> > if(fgain - gain > 0.5)
> > gain = gain +1;
> >
> > return gain;
> >
> >}
> >======
>
>It doesn't even compile with the above junk at the end.
>Run gcc -Wall -Wextra and fix all complaints first!
>
>--
>Thanks. Take care, Brian Inglis Calgary, Alberta, Canada
>
>Brian DOT Inglis AT CSi DOT com (Brian[dot]Inglis{at}SystematicSW[dot]ab[dot]ca)
> fake address use address above to reply
To ALL of the list - Thank you ever so much for all of your wonderful help.
Brian -
I am a newbie, and can make stupid mistakes.
1] My apologies for the above. I had removed some proprietary code
from the program, and that caused it to hang when you tried to
compile. That issue I fixed ... two misplaced braces.
2] Problem with display solved by using another computer w/o a video
card designed to run two monitors.
3] However... previously when I compiled with RHIDE, the screen would
show the compile commands; eg, gcc bla.c -g bla.o [I am probably not
accurate with what I just wrote, but you have the idea.] Now all it
says it "compiling".
3] If I set a breakpoint, and wish to run till breakpoint [F4], RHIDE
crashes with a diagonal display on the screen showing some of the C
code, and some messages "code not created for ....". I think it is
being compiled w/o debugging code and is being optimized. Is there
any compiler flag that will force the system not to optimize?
4] If I step thru the program, [F7 or Shift F7], the user screen is
never displayed. When the program needs input, there is no way to do it.
FYI - I was using ver 5 of RHIDE [rhid15ab.zip] and was experiencing
the above problems. I switched to an earlier version, [rh1501b.zip]
and the problem persists.
Again, much thanks.
Ethan
- Raw text -