[Plib-devel] RE: Olivier's js code (LAVIGNE,ERIC), cygwin build problem
Brought to you by:
sjbaker
From: Ima S. <ima...@ve...> - 2004-08-15 12:06:00
|
Eric, Thank you very much for putting this fix in. Sorry, I said cygwin works, but it doesn't. I am getting a build break under cygwin as shown here: if g++ -DPACKAGE_NAME=3D\"\" -DPACKAGE_TARNAME=3D\"\" = -DPACKAGE_VERSION=3D\"\" -DPACKAGE_STRING=3D\"\" = -DPACKAGE_BUGREPORT=3D\"\ -DPACKAGE=3D\"plib\" -DVERSION=3D\"1.8.4\" -DSTDC_HEADERS=3D1 = -DHAVE_SYS_TYPES_H=3D1 -DHAVE_SYS_STAT_H=3D1 -DHAVE_STDLIB_H=3D1 -DH E_STRING_H=3D1 -DHAVE_MEMORY_H=3D1 -DHAVE_STRINGS_H=3D1 = -DHAVE_INTTYPES_H=3D1 -DHAVE_STDINT_H=3D1 -DHAVE_UNISTD_H=3D1 = -DWIN32=3D1 - -I. -I../../src/util -g -O2 -Wall -MT jsWindows.o -MD -MP -MF = ".deps/jsWindows.Tpo" \ -c -o jsWindows.o `test -f 'jsWindows.cxx' || echo './'`jsWindows.cxx; = \ then mv ".deps/jsWindows.Tpo" ".deps/jsWindows.Po"; \ else rm -f ".deps/jsWindows.Tpo"; exit 1; \ fi js.h: In function `bool getOEMProductName(jsJoystick*, char*, int)': js.h:47: error: `int jsJoystick::error' is protected jsWindows.cxx:46: error: within this context js.h:45: error: `os_specific_s*jsJoystick::os' is protected jsWindows.cxx:61: error: within this context js.h:45: error: `os_specific_s*jsJoystick::os' is protected jsWindows.cxx:72: error: within this context I have updated cygwin to the latest cygwin GCC: $ gcc --version gcc (GCC) 3.3.3 (cygwin special) Copyright (C) 2003 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is = NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR = PURPOSE. and the problem still occurs. I can fix the first problem by adding an accessor function in js.h like: int getError () const { return error ; } that is called from within jsWindows.cxx as: if ( joy->getError() ) return false ; but I am not sure how to fix the other two. Can anyone please help? Do = non-Cygwin users on windows also see this problem? How can we safely access os-specific protected data? Do we need to do = all of the getOEMProductName() os-specific processing within a = jsJoystick class member function as is done within = jsJoystick::jsJoystick ( int ident ) in jsLinux.cxx? Thanks, Eric, for putting this fix in, and thanks to any C++/Cygwin = experts that can fix it! Ima |