Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 210624 - x11-misc/fspanel-0.8_beta1-r2 does not compile with --as-needed
Summary: x11-misc/fspanel-0.8_beta1-r2 does not compile with --as-needed
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Desktop Misc. Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: as-needed
  Show dependency tree
 
Reported: 2008-02-18 21:03 UTC by Thomas Kahle (RETIRED)
Modified: 2008-12-07 13:05 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Patch for configure script to make it compile (fspanel-0.8_beta1-configure.patch,976 bytes, patch)
2008-02-20 22:58 UTC, Thomas Kahle (RETIRED)
Details | Diff
Patch for the ebuild (fspanel-0.8_beta1-r2.ebuild.patch,670 bytes, patch)
2008-02-20 22:59 UTC, Thomas Kahle (RETIRED)
Details | Diff
configure.patch (configure.patch,1.81 KB, patch)
2008-12-07 00:42 UTC, Christian Ruppert (idl0r)
Details | Diff
fspanel-0.8_beta1-r2.ebuild.patch (fspanel-0.8_beta1-r2.ebuild.patch,1.00 KB, patch)
2008-12-07 00:43 UTC, Christian Ruppert (idl0r)
Details | Diff
fspanel-0.8_beta1-configure.patch (fspanel-0.8_beta1-configure.patch,2.66 KB, patch)
2008-12-07 12:57 UTC, Santiago M. Mola (RETIRED)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Thomas Kahle (RETIRED) gentoo-dev 2008-02-18 21:03:30 UTC
The messages is:

cc -O2 -march=pentium3m -pipe -fomit-frame-pointer -I/usr/include/freetype2 -I/usr/include -DHAVE_XPM -DXFT -DNOSTDLIB -nostdlib -Wl,-O1 -Wl,--as-needed -L/usr/lib -lX11 -lXpm -lXft fspanel.c -o fspanel
/var/tmp/portage/x11-misc/fspanel-0.8_beta1-r2/temp/ccoPy8sW.o: In function `move_taskbar':
fspanel.c:(.text+0x84): undefined reference to `XMoveWindow'
/var/tmp/portage/x11-misc/fspanel-0.8_beta1-r2/temp/ccoPy8sW.o: In function `del_task':
fspanel.c:(.text+0xdc): undefined reference to `XFree'
fspanel.c:(.text+0xe4): undefined reference to `free'
fspanel.c:(.text+0x105): undefined reference to `XFreePixmap'
fspanel.c:(.text+0x11d): undefined reference to `XFreePixmap'
/var/tmp/portage/x11-misc/fspanel-0.8_beta1-r2/temp/ccoPy8sW.o: In function `toggle_shade':
fspanel.c:(.text+0x197): undefined reference to `XSendEvent'
/var/tmp/portage/x11-misc/fspanel-0.8_beta1-r2/temp/ccoPy8sW.o: In function `gui_init':
fspanel.c:(.text+0x217): undefined reference to `XAllocColor'
fspanel.c:(.text+0x24c): undefined reference to `XftFontOpenName'
.
.
.
and so on...


Reproducible: Always

Steps to Reproduce:
1. emerge fspanel with LDFLAGS containing -Wl,--as-needed
2.
3.

Actual Results:  
linking fails


Portage 2.1.4.4 (default-linux/x86/2007.0/desktop, gcc-4.1.2, glibc-2.6.1-r0, 2.6.23-gentoo-r8 i686)
=================================================================
System uname: 2.6.23-gentoo-r8 i686 Mobile Intel(R) Pentium(R) III CPU - M 1200MHz
Timestamp of tree: Mon, 18 Feb 2008 07:46:01 +0000
distcc 2.18.3 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled]
ccache version 2.4 [enabled]
app-shells/bash:     3.2_p17-r1
dev-java/java-config: 1.3.7, 2.1.4
dev-lang/python:     2.4.4-r6
dev-python/pycrypto: 2.0.1-r6
dev-util/ccache:     2.4-r7
sys-apps/baselayout: 1.12.10-r5
sys-apps/sandbox:    1.2.18.1-r2
sys-devel/autoconf:  2.13, 2.61-r1
sys-devel/automake:  1.5, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10
sys-devel/binutils:  2.18-r1
sys-devel/gcc-config: 1.4.0-r4
sys-devel/libtool:   1.5.26
virtual/os-headers:  2.6.23-r3
ACCEPT_KEYWORDS="x86"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O2 -march=pentium3m -pipe -fomit-frame-pointer"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/kde/4.0/env /usr/kde/4.0/share/config /usr/kde/4.0/shutdown /usr/share/config"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/php/apache2-php5/ext-active//etc/php/cgi-php5/ext-active/ /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/splash /etc/terminfo /etc/texmf/web2c /etc/udev/rules.d"
CXXFLAGS="-O2 -march=pentium3m -pipe -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
FEATURES="ccache distlocks metadata-transfer parallel-fetch sandbox sfperms strict unmerge-orphans userfetch"
GENTOO_MIRRORS="ftp://ftp.uni-erlangen.de/pub/mirrors/gentoo ftp://ftp.wh2.tu-dresden.de/pub/mirrors/gentoo http://mirrors.sec.informatik.tu-darmstadt.de/gentoo/ http://ftp-stud.fht-esslingen.de/pub/Mirrors/gentoo/ http://pandemonium.tiscali.de/pub/gentoo/ "
LANG="en_US.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
LINGUAS="en de ja es fr it"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/portage/local/layman/sunrise /usr/portage/local/layman/tom-overlay"
SYNC="rsync://rsync.de.gentoo.org/gentoo-portage"
USE="X a52 aac acl acpi alsa anthy apache2 arts avahi bash-completion berkdb bitmap-fonts bluetooth bzip2 cairo canna cddb cdparanoia cdr cjk cli cracklib crypt ctype cups curl daap dbus dri dvd dvdr dvdread eds emacs encode esd evo expat fam fbcon ffmpeg firefox flac fortran freewnn ftp gd gdbm gif glut gmp gphoto2 gpm graphviz gstreamer gtk guile hal iconv ieee1394 imagemagick imap imlib ipod ipv6 isdnlog java javascript jpeg kde kerberos ldap leim libnotify lm_sensors m17n-lib mad midi migemo mikmod mime mmx mp3 mp4 mpeg mplayer mudflap mule musicbrainz mysql mysqli ncurses networkmanager nls nptl nptlonly nsplugin obex ocaml ogg oggvorbis openal opengl openmp oss pam pcmcia pcre pdfperl php plotutils png pppd python qt3 qt3support qt4 quicktime readline real reflection samba sasl sdl session slang spell spl sqlite3 sse ssl svg tcpd tetex theora tiff tk truetype truetype-fonts type1-fonts unicode usb vhosts vim vim-syntax visualization vorbis wifi win32codecs wxwindows x86 xine xml xorg xv xvid zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1 emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic auth_digest authn_anon authn_dbd authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock dbd deflate dir disk_cache env expires ext_filter file_cache filter headers ident imagemap include info log_config logio mem_cache mime mime_magic negotiation proxy proxy_ajp proxy_balancer proxy_connect proxy_http rewrite setenvif so speling status unique_id userdir usertrack vhost_alias" ELIBC="glibc" FRITZCAPI_CARDS="fcpcmcia" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en de ja es fr it" USERLAND="GNU" VIDEO_CARDS="i810 vesa"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 Thomas Kahle (RETIRED) gentoo-dev 2008-02-20 22:58:54 UTC
Created attachment 144167 [details, diff]
Patch for configure script to make it compile

Here is a patch to make it work.
Comment 2 Thomas Kahle (RETIRED) gentoo-dev 2008-02-20 22:59:30 UTC
Created attachment 144168 [details, diff]
Patch for the ebuild

And here is a patch for the ebuild to apply the above ...
Comment 3 Thomas Kahle (RETIRED) gentoo-dev 2008-04-22 08:43:58 UTC
Some time has passed. Did anyone read this ?
Anything wrong with this patch ? 
Or is there just nobody who cares about this package ?
Comment 4 Santiago M. Mola (RETIRED) gentoo-dev 2008-04-22 10:17:46 UTC
Thomas, we care (or at least I do), I'm a bit busy lately but I'll look into it when I can. Thanks for the patch.
Comment 5 Diego Elio Pettenò (RETIRED) gentoo-dev 2008-06-07 12:34:05 UTC
This patch does not look right:

- it patches configure (which is not good because it's an autogenerated file);
- it doesn't fix the issue but just adds a second mistake (passing ldflags after the libraries) that hides the first one (passing libraries before object files).
Comment 6 Christian Ruppert (idl0r) gentoo-dev 2008-12-07 00:42:32 UTC
Created attachment 174504 [details, diff]
configure.patch
Comment 7 Christian Ruppert (idl0r) gentoo-dev 2008-12-07 00:43:27 UTC
Created attachment 174506 [details, diff]
fspanel-0.8_beta1-r2.ebuild.patch

here are two patches which should solve the issue.
Comment 8 Christian Ruppert (idl0r) gentoo-dev 2008-12-07 00:47:13 UTC
(In reply to comment #5)
> This patch does not look right:
> 
> - it patches configure (which is not good because it's an autogenerated file);

in thise case it isn't autogenerated so i think the best way is to patch the self-written configure script.
Comment 9 Santiago M. Mola (RETIRED) gentoo-dev 2008-12-07 12:57:25 UTC
Created attachment 174551 [details, diff]
fspanel-0.8_beta1-configure.patch

For reference, that's the applied patch.

Fix --as-needed (Gentoo bug #210624), X11 path, don't strip binary, use pkg-config for Xft, and avoid automagic deps on Xpm and Xft.

It might not be valid for upstream (since I suspect the pkg-config and freetype thing might break compatibility with other platforms) but it's good enough for Gentoo supported arches.
Comment 10 Santiago M. Mola (RETIRED) gentoo-dev 2008-12-07 13:05:18 UTC
Fixed.

+*fspanel-0.8_beta1-r3 (07 Dec 2008)
+
+  07 Dec 2008; Santiago M. Mola <coldwind@gentoo.org>
+  +files/fspanel-0.8_beta1-configure.patch, +fspanel-0.8_beta1-r3.ebuild:
+  Fix --as-needed (bug #210624, thanks to Christian Ruppert), X11 path,
+  don't strip binary, use pkg-config for Xft, and avoid automagic deps on
+  Xpm and Xft.
+

Please, test it and bug me in a month for stabilization ;-)

Thomas, thanks for reporting and the patch, and sorry for the delay.