Page 1 of 1

Cannot compile on openSUSE 11.3 anymore

Posted: Fri 8. Oct 2010, 14:39
by jonathan
Hi!
On openSUSE 11.3 (clean install) I cannot compile phc-intel-0.3.2-12-1 or any other version anymore. I am pretty sure I've got all necessary dev packages installed, compiling lots of other sources except phc does work.

Current kernel is:
2.6.34.7-0.3-desktop #1 SMP PREEMPT 2010-09-20 15:27:38 +0200 x86_64 x86_64 x86_64 GNU/Linux

Code: Select all

cd phc-intel-0.3.2-12-1
make

Code: Select all

Makefile detected your kernel version as 2.6.34
***FOUND AVAILABLE PATCHSET. PREPARING.***
patching file phc-intel.c

make -C /lib/modules/`uname -r`/build SUBDIRS=/data/src_extracted/phc-intel-0.3.2-12-1 modules
make[1]: Entering directory `/usr/src/linux-2.6.34.7-0.3-obj/x86_64/desktop'
make -C ../../../linux-2.6.34.7-0.3 O=/usr/src/linux-2.6.34.7-0.3-obj/x86_64/desktop/. modules
  CC [M]  /data/src_extracted/phc-intel-0.3.2-12-1/phc-intel.o
In file included from <command-line>:0:0:
./include/generated/autoconf.h:207:0: warning: "CONFIG_ENABLE_MUST_CHECK" redefined
<command-line>:0:0: note: this is the location of the previous definition
./include/generated/autoconf.h:1698:0: warning: "CONFIG_ENABLE_WARN_DEPRECATED" redefined
<command-line>:0:0: note: this is the location of the previous definition
/data/src_extracted/phc-intel-0.3.2-12-1/phc-intel.c: In function ‘acpi_cpufreq_target’:
/data/src_extracted/phc-intel-0.3.2-12-1/phc-intel.c:377:2: error: too few arguments to function ‘trace_power_frequency’
/usr/src/linux-2.6.34.7-0.3/include/trace/events/power.h:53:1: note: declared here
make[4]: *** [/data/src_extracted/phc-intel-0.3.2-12-1/phc-intel.o] Error 1
make[3]: *** [_module_/data/src_extracted/phc-intel-0.3.2-12-1] Error 2
make[2]: *** [sub-make] Error 2
make[1]: *** [all] Error 2
make[1]: Leaving directory `/usr/src/linux-2.6.34.7-0.3-obj/x86_64/desktop'
make: *** [phc-intel.ko] Error 2
Looking into
/usr/src/linux-2.6.34.7-0.3/include/trace/events/power.h
there indeed seems to be an API mismatch.

On openSUSE 11.2 linux-phc compiled easily and worked very well. Does openSUSE 11.3 deviate from Linux standards? Any suggestions?

Re: Cannot compile on openSUSE 11.3 anymore

Posted: Sun 16. Jan 2011, 11:24
by alexm
Hello!

Change do phc-intel-0.3.2-12-1/inc/2.6.34/acpi-cpufreq.c line 367:
- trace_power_frequency(POWER_PSTATE, data->freq_table[next_state].frequency)
+trace_power_frequency(POWER_PSTATE, data->freq_table[next_state].frequency, freqs.cpu)

Regards

PS phc fine work on opensuse 11.3

Re: Cannot compile on openSUSE 11.3 anymore

Posted: Tue 18. Jan 2011, 11:31
by jonathan
Good job! Thanks for posting! Works for me, too.