From: Nick B. <ni...@sg...> - 2005-03-18 05:07:51
|
Hi, thought it was about time I built e17 for IRIX.... Here is some issues I hit (using MipsPro). Hmmm, it seems that a lot of this is using GNU C specific extensions! :-( These are just some of the problems I've hit... And the fixes are very much hacks, just thought I'd let everyone know that this is not building cleanly at all. Any comments? Is it worth continuing? Or has e17 gone gcc specific? Nick ecore: cc-1077 cc: ERROR File = ./Ecore_Data.h, Line = 312 The indicated declaration has no storage class or type specifier. inline void ecore_print_warning(const char *function, const char *sparam); ^ cc-1065 cc: ERROR File = ./Ecore_Data.h, Line = 312 A semicolon is expected at this point. inline void ecore_print_warning(const char *function, const char *sparam); ^ cc-1018 cc: ERROR File = ./Ecore_Data.h, Line = 328 An unmatched left parentheses "(" appears in an expression. # define DPRINTF(debug, format, args...) \ ^ cc-1077 cc: ERROR File = ./Ecore_Data.h, Line = 467 The indicated declaration has no storage class or type specifier. inline void *ecore_sheap_item(Ecore_Sheap *heap, int i); ^ cc-1065 cc: ERROR File = ./Ecore_Data.h, Line = 467 A semicolon is expected at this point. inline void *ecore_sheap_item(Ecore_Sheap *heap, int i); ^ cc-1166 cc: ERROR File = ./Ecore_Data.h, Line = 497 Expected a declaration. ECORE_DECLARE_LOCKS; ^ cc-1166 cc: ERROR File = ./Ecore_Data.h, Line = 512 Expected a declaration. ECORE_DECLARE_LOCKS; ^ Diff: Index: e17/libs/ecore/src/lib/ecore/Ecore_Data.h =================================================================== RCS file: /cvsroot/enlightenment/e17/libs/ecore/src/lib/ecore/Ecore_Data.h,v retrieving revision 1.12 diff -u -r1.12 Ecore_Data.h --- e17/libs/ecore/src/lib/ecore/Ecore_Data.h 2 Mar 2005 07:06:32 -00001.12 +++ e17/libs/ecore/src/lib/ecore/Ecore_Data.h 18 Mar 2005 05:03:04 -0000 @@ -9,6 +9,13 @@ # ifdef __cplusplus extern "C" { # endif + +#ifdef __sgi +#define __FUNCTION__ "unknown" +#ifndef __cplusplus +#define inline +#endif +#endif # define PRIME_TABLE_MAX 21 # define PRIME_MIN 17 @@ -102,7 +109,7 @@ # else /* No pthreads available */ -# define ECORE_DECLARE_LOCKS struct { } locks +# define ECORE_DECLARE_LOCKS # define ECORE_INIT_LOCKS(structure) # define ECORE_READ_LOCK(structure) # define ECORE_READ_UNLOCK(structure) @@ -325,10 +332,11 @@ * of the message and checks that it is to be printed at the current debugging * level */ # ifndef DPRINTF -# define DPRINTF(debug, format, args...) \ +# define DPRINTF(debug, format, args) \ if (debug >= DEBUG_LEVEL) \ fprintf(stderr, format, args); # endif + /* convenience macros for checking pointer parameters for non-NULL */ # ifndef CHECK_PARAM_POINTER_RETURN IRIX doesn't support variable argument macros, inline's need to be on declarations not prototypes, MipsPro doesn't like empty structure definitions. cc-1079 cc: ERROR File = ecore_ipc_private.h, Line = 24 A type specifier is expected. } __attribute__ ((packed)); ^ e17/libs/ecore/src/lib/ecore_ipc/ecore_ipc_private.h 22 Oct 2004 03:41:48 -0000 1.4 +++ e17/libs/ecore/src/lib/ecore_ipc/ecore_ipc_private.h 18 Mar 2005 05:05:17 -0000 @@ -21,7 +21,11 @@ int ref_to; int response; int size; -} __attribute__ ((packed)); +} +#ifdef _GNU_C_ +__attribute__ ((packed)); +#endif +; struct _Ecore_Ipc_Client { |
From: Carsten H. (T. R. <ra...@ra...> - 2005-03-22 08:20:42
|
On Fri, 18 Mar 2005 16:04:06 +1100 Nick Blievers <ni...@sg...> babbled: > Hi, > thought it was about time I built e17 for IRIX.... Here is some > issues I hit (using MipsPro). > > Hmmm, it seems that a lot of this is using GNU C specific > extensions! :-( These are just some of the problems I've hit... And the > fixes are very much hacks, just thought I'd let everyone know that this > is not building cleanly at all. the problem is some (like vararg macros) just cant be done (sanely) any other way without writing a lot of va_list code to make it a real function. this means we can't just #define it out too... :( the problem is there are things gcc does that save developers a lot of time and effort and typing - but some commercial compilers don't support. > Any comments? Is it worth continuing? Or has e17 gone gcc specific? basically we require features that do exist in compilers outside gcc (varargs macros i THINK are in sun's compiler). the patch you did fro varargs changes wont work universally - it will likely break on all platforms then (if you use anything other than 1 argument) :( but on that note i am not sure DPRINTF belongs in public headers for ecore... nathan... what is the reasoning behind DPRINTF there? (it has no namespacing so ifs a likely candidate for conflicts) > Nick > > > ecore: > cc-1077 cc: ERROR File = ./Ecore_Data.h, Line = 312 > The indicated declaration has no storage class or type specifier. > > inline void ecore_print_warning(const char *function, const char > *sparam); > ^ > > cc-1065 cc: ERROR File = ./Ecore_Data.h, Line = 312 > A semicolon is expected at this point. > > inline void ecore_print_warning(const char *function, const char > *sparam); > ^ > > cc-1018 cc: ERROR File = ./Ecore_Data.h, Line = 328 > An unmatched left parentheses "(" appears in an expression. > > # define DPRINTF(debug, format, args...) \ > ^ > > cc-1077 cc: ERROR File = ./Ecore_Data.h, Line = 467 > The indicated declaration has no storage class or type specifier. > > inline void *ecore_sheap_item(Ecore_Sheap *heap, int i); > ^ > > cc-1065 cc: ERROR File = ./Ecore_Data.h, Line = 467 > A semicolon is expected at this point. > > inline void *ecore_sheap_item(Ecore_Sheap *heap, int i); > ^ > > cc-1166 cc: ERROR File = ./Ecore_Data.h, Line = 497 > Expected a declaration. > > ECORE_DECLARE_LOCKS; > ^ > > cc-1166 cc: ERROR File = ./Ecore_Data.h, Line = 512 > Expected a declaration. > > ECORE_DECLARE_LOCKS; > ^ > > > Diff: > Index: e17/libs/ecore/src/lib/ecore/Ecore_Data.h > =================================================================== > RCS file: /cvsroot/enlightenment/e17/libs/ecore/src/lib/ecore/Ecore_Data.h,v > retrieving revision 1.12 > diff -u -r1.12 Ecore_Data.h > --- e17/libs/ecore/src/lib/ecore/Ecore_Data.h 2 Mar 2005 07:06:32 > -00001.12 > +++ e17/libs/ecore/src/lib/ecore/Ecore_Data.h 18 Mar 2005 05:03:04 -0000 > @@ -9,6 +9,13 @@ > # ifdef __cplusplus > extern "C" { > # endif > + > +#ifdef __sgi > +#define __FUNCTION__ "unknown" > +#ifndef __cplusplus > +#define inline > +#endif > +#endif > > # define PRIME_TABLE_MAX 21 > # define PRIME_MIN 17 > @@ -102,7 +109,7 @@ > > # else /* No pthreads available */ > > -# define ECORE_DECLARE_LOCKS struct { } locks > +# define ECORE_DECLARE_LOCKS > # define ECORE_INIT_LOCKS(structure) > # define ECORE_READ_LOCK(structure) > # define ECORE_READ_UNLOCK(structure) > @@ -325,10 +332,11 @@ > * of the message and checks that it is to be printed at the current > debugging > * level */ > # ifndef DPRINTF > -# define DPRINTF(debug, format, args...) \ > +# define DPRINTF(debug, format, args) \ > if (debug >= DEBUG_LEVEL) \ > fprintf(stderr, format, args); > # endif > + > > /* convenience macros for checking pointer parameters for non-NULL */ > # ifndef CHECK_PARAM_POINTER_RETURN > > > IRIX doesn't support variable argument macros, inline's need to be on > declarations not prototypes, MipsPro doesn't like empty structure > definitions. > > > cc-1079 cc: ERROR File = ecore_ipc_private.h, Line = 24 > A type specifier is expected. > > } __attribute__ ((packed)); > ^ > e17/libs/ecore/src/lib/ecore_ipc/ecore_ipc_private.h 22 Oct 2004 > 03:41:48 -0000 1.4 > +++ e17/libs/ecore/src/lib/ecore_ipc/ecore_ipc_private.h 18 Mar > 2005 05:05:17 -0000 > @@ -21,7 +21,11 @@ > int ref_to; > int response; > int size; > -} __attribute__ ((packed)); > +} > +#ifdef _GNU_C_ > +__attribute__ ((packed)); > +#endif > +; > > struct _Ecore_Ipc_Client > { > > > > ------------------------------------------------------- > SF email is sponsored by - The IT Product Guide > Read honest & candid reviews on hundreds of IT Products from real users. > Discover which products truly live up to the hype. Start reading now. > http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click > _______________________________________________ > enlightenment-devel mailing list > enl...@li... > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel > -- ------------- Codito, ergo sum - "I code, therefore I am" -------------- The Rasterman (Carsten Haitzler) ra...@ra... 裸好多 ra...@de... Tokyo, Japan (東京 日本) |
From: Nathan I. <nin...@gm...> - 2005-03-22 14:09:59
|
No reason for it to be there. I'm guessing when EWD was incorporated into Ecore, it was just copied over. It should go in the private header. On Tue, 22 Mar 2005 17:17:30 +0900, The Rasterman Carsten Haitzler <ra...@ra...> wrote: > On Fri, 18 Mar 2005 16:04:06 +1100 Nick Blievers <ni...@sg...> babbled: >=20 > > Hi, > > thought it was about time I built e17 for IRIX.... Here is some > > issues I hit (using MipsPro). > > > > Hmmm, it seems that a lot of this is using GNU C specific > > extensions! :-( These are just some of the problems I've hit... And the > > fixes are very much hacks, just thought I'd let everyone know that this > > is not building cleanly at all. >=20 > the problem is some (like vararg macros) just cant be done (sanely) any o= ther > way without writing a lot of va_list code to make it a real function. thi= s means > we can't just #define it out too... :( the problem is there are things gc= c does > that save developers a lot of time and effort and typing - but some comme= rcial > compilers don't support. >=20 > > Any comments? Is it worth continuing? Or has e17 gone gcc specific? >=20 > basically we require features that do exist in compilers outside gcc (var= args > macros i THINK are in sun's compiler). the patch you did fro varargs chan= ges > wont work universally - it will likely break on all platforms then (if yo= u use > anything other than 1 argument) :( >=20 > but on that note i am not sure DPRINTF belongs in public headers for ecor= e... >=20 > nathan... what is the reasoning behind DPRINTF there? (it has no namespac= ing so > ifs a likely candidate for conflicts) >=20 > > Nick > > > > > > ecore: > > cc-1077 cc: ERROR File =3D ./Ecore_Data.h, Line =3D 312 > > The indicated declaration has no storage class or type specifier. > > > > inline void ecore_print_warning(const char *function, const char > > *sparam); > > ^ > > > > cc-1065 cc: ERROR File =3D ./Ecore_Data.h, Line =3D 312 > > A semicolon is expected at this point. > > > > inline void ecore_print_warning(const char *function, const char > > *sparam); > > ^ > > > > cc-1018 cc: ERROR File =3D ./Ecore_Data.h, Line =3D 328 > > An unmatched left parentheses "(" appears in an expression. > > > > # define DPRINTF(debug, format, args...) \ > > ^ > > > > cc-1077 cc: ERROR File =3D ./Ecore_Data.h, Line =3D 467 > > The indicated declaration has no storage class or type specifier. > > > > inline void *ecore_sheap_item(Ecore_Sheap *heap, int i); > > ^ > > > > cc-1065 cc: ERROR File =3D ./Ecore_Data.h, Line =3D 467 > > A semicolon is expected at this point. > > > > inline void *ecore_sheap_item(Ecore_Sheap *heap, int i); > > ^ > > > > cc-1166 cc: ERROR File =3D ./Ecore_Data.h, Line =3D 497 > > Expected a declaration. > > > > ECORE_DECLARE_LOCKS; > > ^ > > > > cc-1166 cc: ERROR File =3D ./Ecore_Data.h, Line =3D 512 > > Expected a declaration. > > > > ECORE_DECLARE_LOCKS; > > ^ > > > > > > Diff: > > Index: e17/libs/ecore/src/lib/ecore/Ecore_Data.h > > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > > RCS file: /cvsroot/enlightenment/e17/libs/ecore/src/lib/ecore/Ecore_Dat= a.h,v > > retrieving revision 1.12 > > diff -u -r1.12 Ecore_Data.h > > --- e17/libs/ecore/src/lib/ecore/Ecore_Data.h 2 Mar 2005 07:06:32 > > -00001.12 > > +++ e17/libs/ecore/src/lib/ecore/Ecore_Data.h 18 Mar 2005 05:03:04 -0= 000 > > @@ -9,6 +9,13 @@ > > # ifdef __cplusplus > > extern "C" { > > # endif > > + > > +#ifdef __sgi > > +#define __FUNCTION__ "unknown" > > +#ifndef __cplusplus > > +#define inline > > +#endif > > +#endif > > > > # define PRIME_TABLE_MAX 21 > > # define PRIME_MIN 17 > > @@ -102,7 +109,7 @@ > > > > # else /* No pthreads available */ > > > > -# define ECORE_DECLARE_LOCKS struct { } locks > > +# define ECORE_DECLARE_LOCKS > > # define ECORE_INIT_LOCKS(structure) > > # define ECORE_READ_LOCK(structure) > > # define ECORE_READ_UNLOCK(structure) > > @@ -325,10 +332,11 @@ > > * of the message and checks that it is to be printed at the curren= t > > debugging > > * level */ > > # ifndef DPRINTF > > -# define DPRINTF(debug, format, args...) \ > > +# define DPRINTF(debug, format, args) \ > > if (debug >=3D DEBUG_LEVEL) \ > > fprintf(stderr, format, args); > > # endif > > + > > > > /* convenience macros for checking pointer parameters for non-NULL = */ > > # ifndef CHECK_PARAM_POINTER_RETURN > > > > > > IRIX doesn't support variable argument macros, inline's need to be on > > declarations not prototypes, MipsPro doesn't like empty structure > > definitions. > > > > > > cc-1079 cc: ERROR File =3D ecore_ipc_private.h, Line =3D 24 > > A type specifier is expected. > > > > } __attribute__ ((packed)); > > ^ > > e17/libs/ecore/src/lib/ecore_ipc/ecore_ipc_private.h 22 Oct 200= 4 > > 03:41:48 -0000 1.4 > > +++ e17/libs/ecore/src/lib/ecore_ipc/ecore_ipc_private.h 18 Mar > > 2005 05:05:17 -0000 > > @@ -21,7 +21,11 @@ > > int ref_to; > > int response; > > int size; > > -} __attribute__ ((packed)); > > +} > > +#ifdef _GNU_C_ > > +__attribute__ ((packed)); > > +#endif > > +; > > > > struct _Ecore_Ipc_Client > > { > > > > > > > > ------------------------------------------------------- > > SF email is sponsored by - The IT Product Guide > > Read honest & candid reviews on hundreds of IT Products from real users= . > > Discover which products truly live up to the hype. Start reading now. > > http://ads.osdn.com/?ad_id=3D6595&alloc_id=3D14396&op=3Dclick > > _______________________________________________ > > enlightenment-devel mailing list > > enl...@li... > > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel > > >=20 > -- > ------------- Codito, ergo sum - "I code, therefore I am" -------------- > The Rasterman (Carsten Haitzler) ra...@ra... > =E8=A3=B8=E5=A5=BD=E5=A4=9A raster@deephackm= ode.org > Tokyo, Japan (=E6=9D=B1=E4=BA=AC =E6=97=A5=E6=9C=AC) >=20 >=20 > ------------------------------------------------------- > SF email is sponsored by - The IT Product Guide > Read honest & candid reviews on hundreds of IT Products from real users. > Discover which products truly live up to the hype. Start reading now. > http://ads.osdn.com/?ad_id=3D6595&alloc_id=3D14396&op=3Dclick > _______________________________________________ > enlightenment-devel mailing list > enl...@li... > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel > |
From: Nick B. <ni...@sg...> - 2005-03-22 22:59:09
|
<snip> >>Any comments? Is it worth continuing? Or has e17 gone gcc specific? >> >> > >basically we require features that do exist in compilers outside gcc (varargs >macros i THINK are in sun's compiler). the patch you did fro varargs changes >wont work universally - it will likely break on all platforms then (if you use >anything other than 1 argument) :( > >but on that note i am not sure DPRINTF belongs in public headers for ecore... > >nathan... what is the reasoning behind DPRINTF there? (it has no namespacing so >ifs a likely candidate for conflicts) > > > Right, but varargs macros are not in MipsPro. If its only used for debugging, why not use a function? Nick |
From: Carsten H. (T. R. <ra...@ra...> - 2005-03-23 03:45:25
|
On Wed, 23 Mar 2005 09:54:51 +1100 Nick Blievers <ni...@sg...> babbled: > <snip> > > >>Any comments? Is it worth continuing? Or has e17 gone gcc specific? > >> > >> > > > >basically we require features that do exist in compilers outside gcc (varargs > >macros i THINK are in sun's compiler). the patch you did fro varargs changes > >wont work universally - it will likely break on all platforms then (if you use > >anything other than 1 argument) :( > > > >but on that note i am not sure DPRINTF belongs in public headers for ecore... > > > >nathan... what is the reasoning behind DPRINTF there? (it has no namespacing so > >ifs a likely candidate for conflicts) > > > > > > > Right, but varargs macros are not in MipsPro. If its only used for > debugging, why not use a function? this si where macros win - u can just REMOVe them from the code with a #ifdef... etc. no need to have calls to empty fn calls or lots of #ifdef DEBUG DPRINTF(...) #endif you just blindly call DPRINTf(...) and let the 1 macro definition remove to include debugging. i think you seriously need to put some fire under the mipspro devel team and get the to include such features as it is a huge time and effort saver for developers :) if mipspro doesn't do this it will just end up getting left behind and eventually just wont compile a LOT of open source code. :( -- ------------- Codito, ergo sum - "I code, therefore I am" -------------- The Rasterman (Carsten Haitzler) ra...@ra... 裸好多 ra...@de... Tokyo, Japan (東京 日本) |