gnupic: Rep:Re: Rep:Re: Missing #include in gputils (gpreadhex.h)
Subject:
Rep:Re: Rep:Re: Missing #include in gputils (gpreadhex.h)
From:
"Carlos Nieves" ####@####.####
Date:
30 Jan 2003 18:33:46 -0000
Message-Id: <200301301824.1209@th00.opsion.fr>
Yes, I should have checked CVS first..... sorry!
Carlos
-----Mensaje original-----
De: Craig Franklin ####@####.####
Para: Carlos Nieves ####@####.####
Fecha: 30/01/03
Asunto: Re: Rep:Re: Missing #include in gputils (gpreadhex.h)
Craig Franklin wrote:
>
> If you do this, checkout the latest stuff in cvs.
That bug was fixed. That is why I suggested you fetch the latest stuff
from cvs. I should have been more clear.
The directions are on http://gputils.sourceforge.net.
Carlos Nieves wrote:
>
> Ok, despite of it's not really necessary for me, I'm not sure about
this
> issue.
> So I just try out a little program using libgputils.h.
> This is my little program:
> --------------------------------
>
> #include <stdio.h>
> #include <unistd.h>
> #include "libgputils.h"
>
> int main () {
>
> struct hex_data data;
> MemBlock *memory;
> unsigned int i;
>
> memory = i_memory_create();
> data = readhex("/home/cnieves/pic2.hex", memory);
>
> printf ("Error was: %i\n", data.error);
> printf ("Read %i bytes of memory\n", data.size);
> for (i = 0; i <= 10; i++)
> printf ("Address %u: %04X\n", i, i_memory_get (memory, i) );
>
> }
>
> --------------------------------
>
> Compiled it with:
> gcc *.c -o prueba -I . -DHAVE_STRING_H -DHAVE_MALLOC_H
>
> En el fichero incluído de libgputils.h:36,
> de main.c:4:
> gputils/gpreadhex.h:25: el campo `hex_format' tiene tipo de dato
> incompleto
>
> Which is the same error I got yesterday.
> I took the files from gputils-0.10.6.tar.gz from SourceForge.
>
> This error is fixed including gpwritehex, as showed in my first mail.
>
> I think any user trying to use libgputils will have the same
problem....
>
> Regards,
>
> Carlos
>
> -----Mensaje original-----
> De: Craig Franklin ####@####.####
> Para: Carlos Nieves Onega ####@####.####
> Fecha: 29/01/03
> Asunto: Re: Missing #include in gputils (gpreadhex.h)
>
> It's not really an error. I intended users to #include
"libgputils.h",
> if they wanted to use the library. If you do this, checkout the
latest
> stuff in cvs.
>
> A warning to those that choose to use the library: I frequently make
> changes to the content and interface of the library to better serve
> gputils. If you use the library, don't be surprised if things change
in
> the future.
>
> Carlos Nieves Onega wrote:
> >
> > Hi,
> > I just wanted to read hex files in other program, so I pick up
> > gpreadhex*, gpmemory*, and stdhdr.h from gputils (directory
> libgputils)
> > to do it.
> > I got a compilation error in gpreadhex.h, complaining about "enum
> > formats" use in struct hex_data (it was not defined). So I just
added
> a
> > #include "gpwritehex.h" in gpreadhex.h, and pick up gpwritehex*, as
> > follows:
> >
> > --- ../../temp/gputils-0.10.6/libgputils/gpreadhex.h 2002-01-13
> > 18:24:45.000000000 +0100
> > +++ gpreadhex.h 2003-01-28 22:15:39.000000000 +0100
> > @@ -21,6 +21,8 @@
> > #ifndef __GPREADHEX_H__
> > #define __GPREADHEX_H__
> >
> > +#include "gpwritehex.h"
> > +
> > struct hex_data {
> > enum formats hex_format;
> > int size;
> > ---
> >
> > This solved the error. Maybe this will be useful to anyone...
> >
> > Regards,
> >
> > Carlos
> >
> > --
> > Carlos Nieves Onega ####@####.####
> >
> >
---Publicidad--------------------------------------------------------
> > Juega con Ventura24.es, lotería inteligente y multiplica tus
> > posibilidades!! http://www.iespana.es/_reloc/email.ventura
> >
> >
---------------------------------------------------------------------
> > To unsubscribe, e-mail: ####@####.####
> > For additional commands, e-mail: ####@####.####
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ####@####.####
> For additional commands, e-mail: ####@####.####
>
> ---Publicidad--------------------------------------------------------
> Únete a los miles de sin pareja en Meetic... ¡te vas a enamorar!
> http://www.iespana.es/_reloc/email.meetic
>
> ---Publicidad--------------------------------------------------------
> Únete a los miles de sin pareja en Meetic... ¡te vas a enamorar!
> http://www.iespana.es/_reloc/email.meetic
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ####@####.####
> For additional commands, e-mail: ####@####.####
---Publicidad--------------------------------------------------------
Juega con Ventura24.es, lotería inteligente y multiplica tus
posibilidades!! http://www.iespana.es/_reloc/email.ventura
---Publicidad--------------------------------------------------------
Únete a los miles de sin pareja en Meetic... ¡te vas a enamorar!
http://www.iespana.es/_reloc/email.meetic