Date: Sun, 26 Dec 1999 10:17:57 +0100 (CET) From: Junichi Saito Sender: junichi AT kintaro To: PGCC Mailing List Subject: Re: [2.95.3] c++ compiler problem ? In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Reply-To: pgcc AT delorie DOT com X-Mailing-List: pgcc AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk I wrote: > >Hello, > >While trying to compile MonitorSensors-1.2, gnome front-end for >lm_sensors, I got the following error: > >make[1]: Entering directory `/usr/local/src/MonitorSensors-1.2/src' >c++ -DPACKAGE=\"MonitorSensors\" -DVERSION=\"1.2\" -DHAVE_X11_SM_SMLIB_H=1 >-DHAVE_LIBSM=1 -I. -I. >-I.. -I/opt/gnome/include -I/opt/gnome/include -DNEED_GNOMESUPPORT_H >-I/opt/gnome/lib/gnome-libs/include -I/opt/gnome/lib/glib/include >-I/usr/X11R6/include -I/opt/gnome/lib/gtkmm/include -I/opt/gnome/include >-I/opt/gnome/lib/glib/include -I/usr/X11R6/include >-I/opt/gnome/lib/sigc++/include > -DG_LOG_DOMAIN=\"MonitorSensors\" -I/opt/gnome/lib/glib/include >-I/opt/gnome/include -I/usr/X11R6/include -Wall >-I/usr/local/include/sensors/ -g -O2 -c MonitorSensors.cpp >MonitorSensors.cpp: In method `MonitorWindow::MonitorWindow()': >MonitorSensors.cpp:125: taking the address of a non-static member function >MonitorSensors.cpp:125: to form a pointer to member function, say >`&MonitorWindow::timer' >MonitorSensors.cpp: In method `gint MonitorWindow::timer()': >MonitorSensors.cpp:131: taking the address of a non-static member function >MonitorSensors.cpp:131: to form a pointer to member function, say >`&MonitorWindow::timer' >make[1]: *** [MonitorSensors.o] Error 1 >make[1]: Leaving directory `/usr/local/src/MonitorSensors-1.2/src' >make: *** [all-recursive] Error 1 > >I was told that it could be compiled with egcs 1.1.2. > >Is there a quick fix for this failure ? > >Thank you. > >j. > > Adding '-fpermissive' solved the problem. Seemingly, it's more of a problem with the code itself. j.