! Please note that this is a snapshot of our old Bugzilla server, which is read only since May 29, 2020. Please go to gitlab.xfce.org for our new server !
cpufreq: compile error
Status:
RESOLVED: FIXED
Product:
Xfce4-cpufreq-plugin
Component:
General

Comments

Description Zach Carter 2007-06-22 23:50:39 CEST
User-Agent:       Mozilla/5.0 (X11; U; Linux i686 (x86_64); en-US; rv:1.8.1.3) Gecko/20070309 Firefox/2.0.0.3
Build Identifier: 

xfce4_cpufreq_plugin-xfce4-cpufreq-linux.o: In function `cpufreq_linux_init':
/src/work/goodies/xfce4-cpufreq-plugin/trunk/panel-plugin/xfce4-cpufreq-linux.c:401: undefined reference to `_'
collect2: ld returned 1 exit status
make[2]: *** [xfce4-cpufreq-plugin] Error 1
make[2]: Leaving directory `/src/work/goodies/xfce4-cpufreq-plugin/trunk/panel-plugin'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/src/work/goodies/xfce4-cpufreq-plugin/trunk'
make: *** [all] Error 2
[root@hoth trunk]# 


Reproducible: Always

Steps to Reproduce:
1. download
2. ./autogen.sh && make




will submit a patch for this
Comment 1 Zach Carter 2007-06-22 23:51:42 CEST
Created attachment 1190 
remove underscore
Comment 2 Pavol Rusnak 2007-06-28 13:23:10 CEST
Underscore is OK. Install gettext.
Comment 3 Zach Carter 2007-06-28 14:55:46 CEST
(In reply to comment #2)
> Underscore is OK. Install gettext.
> 

Hmm.  I already have this on my recently installed F7 machine:

gettext-0.16.1-8.fc7


Comment 4 Raymond Myers 2007-08-08 21:58:27 CEST
(In reply to comment #3)
> (In reply to comment #2)
> > Underscore is OK. Install gettext.
> > 
> Hmm.  I already have this on my recently installed F7 machine:
> gettext-0.16.1-8.fc7

Are you sure you have the development version of gettext? Most distros only ship with the version required to RUN programs that use gettext, not the version required to COMPILE programs.
Comment 5 Zach Carter 2007-08-08 22:43:54 CEST
(In reply to comment #4)
> 
> Are you sure you have the development version of gettext? Most distros only
> ship with the version required to RUN programs that use gettext, not the
> version required to COMPILE programs.
> 

Turns out, I didn't have the 'devel' version of the package.  I went ahead and installed it, updated to the latest SVN, and the compile still tanked at the same point:

xfce4_cpufreq_plugin-xfce4-cpufreq-linux.o: In function `cpufreq_linux_init':
/src/work/goodies/xfce4-cpufreq-plugin/trunk/panel-plugin/xfce4-cpufreq-linux.c:401: undefined reference to `_'
collect2: ld returned 1 exit status
make[2]: *** [xfce4-cpufreq-plugin] Error 1
make[2]: Leaving directory `/src/work/goodies/xfce4-cpufreq-plugin/trunk/panel-plugin'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/src/work/goodies/xfce4-cpufreq-plugin/trunk'
make: *** [all] Error 2
[root@hoth trunk]# rpm -qa|grep gettext
gettext-0.16.1-8.fc7
gettext-devel-0.16.1-8.fc7


As before, removing the underscore causes the compile to succeed.  I'll see if I can learn something about gettext and figure this out.
Comment 6 Zach Carter 2007-08-08 23:28:39 CEST
Created attachment 1304 
swapped underscore with gettext

something must be wrong wherever "_" is defined.
Comment 7 Raymond Myers 2007-08-13 01:48:54 CEST
The compile is tanking during linking, since it is working on object files. This could mean that it can't find the devel package. I would simply try:

make distclean

this will remove the makefile, and all of the object files that got compiled earlier, when the gettext-dev package was missing. Then try:

./configure && make

Hopefully this helps.
Comment 8 Zach Carter 2007-08-13 14:55:20 CEST
(In reply to comment #7)
> make distclean
> 
> ./configure && make
> 
> Hopefully this helps.
>

Good idea, but it didn't help.  make distclean && ./configure && make resulted in the same error.   I checkout a brand new copy from SVN, ran ./autogen.sh && make, and got the same error.   

I went ahead and downloaded the latest stable tarball from here:

http://goodies.xfce.org/releases/xfce4-cpufreq-plugin/

That one compiled fine with just a ./configure && make

There must be something different between the SVN version and the tarball.  I'll
see if I can track down what it is.

Comment 9 Raymond Myers 2007-08-14 10:34:54 CEST
(In reply to comment #8)
> I went ahead and downloaded the latest stable tarball from here:
> 
> http://goodies.xfce.org/releases/xfce4-cpufreq-plugin/

Correct me if I'm wrong, but that tarball is around a year old. (14-Sep-2006 07:03)
Comment 10 Enrico Tröger editbugs 2008-02-18 14:40:50 CET
Created attachment 1514 
Patch to fix compilation error because of missing header include

This patch is against current SVN version and fixes the compile error by adding a missing include for a header file.
It also removes some compiler warnings to improve code quality.
Comment 11 Florian Rivoal editbugs 2010-12-28 17:06:41 CET
*** Bug 4981 has been marked as a duplicate of this bug. ***
Comment 12 Florian Rivoal editbugs 2010-12-29 18:38:38 CET
Thanks for the patch. I applied it (after spliting into smaller parts).

Bug #3357

Reported by:
Zach Carter
Reported on: 2007-06-22
Last modified on: 2014-12-07
Duplicates (1):
  • 4981 xfce4-cpufreq-plugin (svn): compilation error

People

Assignee:
Thomas Schreck
CC List:
4 users

Version

Version:
0.0.1 or older

Attachments

remove underscore (616 bytes, patch)
2007-06-22 23:51 CEST , Zach Carter
no flags
swapped underscore with gettext (584 bytes, text/x-patch)
2007-08-08 23:28 CEST , Zach Carter
no flags
Patch to fix compilation error because of missing header include (5.53 KB, patch)
2008-02-18 14:40 CET , Enrico Tröger
no flags

Additional information