User forums > Using Code::Blocks

Compile errors from mingw32's math.h of Code::Blocks v10.05 rev 6283

<< < (2/2)

ouch:
I would re-install, something got messed up if the default headers don't compile.

stahta01:
You most likely have a wrong config file "config.h" for the library/compiler configuration fix it.

You can confirm by defining "HAVE_LOG2F" to see if the error changes.

This is NOT a Code::Blocks problem or even likely a Compiler problem.

From math.h starting with line 562

--- Code: ---/* 7.12.6.10 */
extern double __cdecl log2 (double);
extern float __cdecl log2f (float);
extern long double __cdecl log2l (long double);

--- End code ---

From osdep.h http://git.videolan.org/?p=x264.git;a=blob;f=common/osdep.h;h=6249dbe0c53085167a4556ce85c4a8136abbfc90;hb=HEAD#l43

--- Code: ---  43 #if !HAVE_LOG2F
  44 #define log2f(x) (logf(x)/0.693147180559945f)
  45 #define log2(x) (log(x)/0.693147180559945)
  46 #endif

--- End code ---

Tim S.

ophiuchus18:

--- Quote from: stahta01 on July 20, 2011, 07:07:15 pm ---You most likely have a wrong config file "config.h" for the library/compiler configuration fix it.

You can confirm by defining "HAVE_LOG2F" to see if the error changes.

This is NOT a Code::Blocks problem or even likely a Compiler problem.

From math.h starting with line 562

--- Code: ---/* 7.12.6.10 */
extern double __cdecl log2 (double);
extern float __cdecl log2f (float);
extern long double __cdecl log2l (long double);

--- End code ---

From osdep.h http://git.videolan.org/?p=x264.git;a=blob;f=common/osdep.h;h=6249dbe0c53085167a4556ce85c4a8136abbfc90;hb=HEAD#l43

--- Code: ---  43 #if !HAVE_LOG2F
  44 #define log2f(x) (logf(x)/0.693147180559945f)
  45 #define log2(x) (log(x)/0.693147180559945)
  46 #endif

--- End code ---

Tim S.

--- End quote ---

I think you have right with the config.h, it's an autogenerated file.

I downloaded cross-mingw.gcc453, MSYS.exe, Git-1.7.6.exe and yasm.exe and it's ok now. I made the .exe thing.

Thank you.

Navigation

[0] Message Index

[*] Previous page

Go to full version