Enlightenment CVS committal Author : raster Project : e17 Module : libs/embryo
Dir : e17/libs/embryo/src/bin Modified Files: embryo_cc_sc2.c Log Message: warning instead of abort =================================================================== RCS file: /cvsroot/enlightenment/e17/libs/embryo/src/bin/embryo_cc_sc2.c,v retrieving revision 1.5 retrieving revision 1.6 diff -u -3 -r1.5 -r1.6 --- embryo_cc_sc2.c 15 May 2004 05:39:44 -0000 1.5 +++ embryo_cc_sc2.c 2 Jun 2004 02:29:44 -0000 1.6 @@ -18,7 +18,7 @@ * misrepresented as being the original software. * 3. This notice may not be removed or altered from any source distribution. * - * Version: $Id: embryo_cc_sc2.c,v 1.5 2004/05/15 05:39:44 raster Exp $ + * Version: $Id: embryo_cc_sc2.c,v 1.6 2004/06/02 02:29:44 raster Exp $ */ #include <assert.h> #include <stdio.h> @@ -640,8 +640,33 @@ { float test1 = 0.0, test2 = 50.0; - assert(*(int *)&test1 == 0x00000000L - && *(int *)&test2 == 0x42480000L); + if (*(int *)&test1 != 0x00000000L) + { + fprintf(stderr, + "embryo_cc: WARNING! you compiler does not SEEM to interpret IEEE floating\n" + "point math as embryo expects. this could be bad.\n" + "\n" + "(float 0.0 != 0x00000000 bitpattern, 0x%08x instead)\n" + "\n" + "this could be an issue with you compiling embryo with gcc 3.2.x that seems\n" + "to trigger this sanity check. we are not sure why yet, but gcc 3.3.x works\n" + , (int)(*(int *)&test1) + ); + } + else if ((int *)&test2 != 0x42480000L) + { + fprintf(stderr, + "embryo_cc: WARNING! you compiler does not SEEM to interpret IEEE floating\n" + "point math as embryo expects. This could be bad.\n" + "\n" + "(float 50.0 != 0x42480000 bitpattern, 0x%08x instead)\n" + "\n" + "this could be an issue with you compiling embryo with gcc 3.2.x that seems\n" + "to trigger this sanity check. we are not sure why yet, but gcc 3.3.x works\n" + , (int)(*(int *)&test2) + ); + } + } #endif } ------------------------------------------------------- This SF.Net email is sponsored by the new InstallShield X. >From Windows to Linux, servers to mobile, InstallShield X is the one installation-authoring solution that does it all. Learn more and evaluate today! http://www.installshield.com/Dev2Dev/0504 _______________________________________________ enlightenment-cvs mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs