Looks like a simple change made it compile, although I haven't tested to see if 
the libraries actually work.  I just commented out lines 252, 253 and 254, and 
added the HAVE_STRCASECMP definition.

246 #ifdef __MINGW32__
247 #ifdef __cplusplus
248 extern "C" {
249 #endif
250 void __cdecl _fpreset (void);
251 void __cdecl fpreset (void);
252 // #define SetClassLongPtr SetClassLong
253 // #define GCLP_HICON GCL_HICON
254 // #define GCLP_HICONSM GCL_HICONSM
        #define HAVE_STRCASECMP
255 #ifdef __cplusplus
256 }
257 #endif
258 #endif



On Oct 19, 2010, at 4:43 PM, Eric J Korpela wrote:

> In your config_win.h  (or maybe it's boinc_win.h?)  you need to
> "#define HAVE_STRCASECMP  1" .  You'll probably need to put it in an
> #ifdef __MINGW32__ because it's either not there for Visual C++, or
> it's not a problem there for some other reason.
> 
> If that doesn't fix the problem, it means that the header file isn't
> properly being included.  You may have to follow the header chain to
> see where it should have been included.h
> 
> Eric
> 
> On Mon, Oct 18, 2010 at 5:26 PM, Travis Desell <[email protected]> wrote:
>> I've been following the instructions on compiling the boinc libraries using 
>> MinGW from here:
>> 
>> http://boinc.berkeley.edu/trac/wiki/CompileApp
>> 
>> But I'm getting the same error using both Dev C++ (with a modified version 
>> of the SETI .dev file) and in MinGW using make -f Makefile.mingw:
>> 
>> $ make -f Makefile.mingw
>> g++ -c ../api/boinc_api.cpp -o boinc_api.o  -I".." -I"../db" -I"../lib" 
>> -I"../ap
>> i" -I"../zip" -I"../win_build" -D__DEBUG__ -gstabs -g3 --include 
>> ../version.h -D
>> EINSTEINATHOME_CROSS_BUILD -DMINGW_WIN32 -DWIN32 -D_WIN32 
>> -D_WIN32_WINDOWS=0x041
>> 0 -D_MT -DNDEBUG -D_WINDOWS  -DBOINC -DNODB -D_CONSOLE -mtune=pentium-m 
>> -fexcept
>> ions -march=i386 -O2
>> In file included from ../api/boinc_api.cpp:59:0:
>> ./lib/boinc_win.h:252:0: warning: "SetClassLongPtr" redefined
>> c:\mingw\bin\../lib/gcc/mingw32/4.5.0/../../../../include/winuser.h:4471:0: 
>> note
>> : this is the location of the previous definition
>> ./lib/boinc_win.h:253:0: warning: "GCLP_HICON" redefined
>> c:\mingw\bin\../lib/gcc/mingw32/4.5.0/../../../../include/winuser.h:623:0: 
>> note:
>>  this is the location of the previous definition
>>  ../lib/boinc_win.h:254:0: warning: "GCLP_HICONSM" redefined
>>  c:\mingw\bin\../lib/gcc/mingw32/4.5.0/../../../../include/winuser.h:626:0: 
>> note:
>>  this is the location of the previous definition
>>  In file included from ../api/boinc_api.cpp:88:0:
>>  ../lib/str_replace.h: In function 'int strcasecmp(const char*, const 
>> char*)':
>>  ../lib/str_replace.h:40:12: error: redefinition of 'int strcasecmp(const 
>> char*,
>>  const char*)'
>>  c:\mingw\bin\../lib/gcc/mingw32/4.5.0/../../../../include/string.h:98:1: 
>> error:
>>  'int strcasecmp(const char*, const char*)' previously defined here
>>  ../api/boinc_api.cpp: In member function 'void GRAPHICS_APP::run(char*)':
>>  ../api/boinc_api.cpp:833:19: warning: deprecated conversion from string 
>> constant
>>   to 'char*'
>>   ../api/boinc_api.cpp:835:23: warning: deprecated conversion from string 
>> constant
>>    to 'char*'
>>    make: *** [boinc_api.o] Error 1
>> 
>> Any idea what the problem is or what I'm doing wrong?
>> 
>> ----------------------------------------------------------------------------------------------------------
>> Travis Desell
>> <deselt @ cs.rpi.edu>
>> 1-518-867-1054
>> Worldwide Computing Laboratory ( http://wcl.cs.rpi.edu/ )
>> milky...@home ( http://milkyway.cs.rpi.edu/ )
>> Rensselaer Polytechnic Institute, 110 8th Street, Troy NY 12180, USA
>> ----------------------------------------------------------------------------------------------------------
>> 
>> 
>> 
>> _______________________________________________
>> boinc_dev mailing list
>> [email protected]
>> http://lists.ssl.berkeley.edu/mailman/listinfo/boinc_dev
>> To unsubscribe, visit the above URL and
>> (near bottom of page) enter your email address.
>> 

----------------------------------------------------------------------------------------------------------
Travis Desell
<deselt @ cs.rpi.edu>
1-518-867-1054
Worldwide Computing Laboratory ( http://wcl.cs.rpi.edu/ )
milky...@home ( http://milkyway.cs.rpi.edu/ )
Rensselaer Polytechnic Institute, 110 8th Street, Troy NY 12180, USA
----------------------------------------------------------------------------------------------------------



_______________________________________________
boinc_dev mailing list
[email protected]
http://lists.ssl.berkeley.edu/mailman/listinfo/boinc_dev
To unsubscribe, visit the above URL and
(near bottom of page) enter your email address.

Reply via email to