Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 37720 - gimp (1.3|2.0) segfaults
Summary: gimp (1.3|2.0) segfaults
Status: RESOLVED WORKSFORME
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All All
: High normal (vote)
Assignee: Gentoo Linux Gnome Desktop Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-01-09 11:10 UTC by Michal Januszewski (RETIRED)
Modified: 2004-02-29 08:46 UTC (History)
0 users

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michal Januszewski (RETIRED) gentoo-dev 2004-01-09 11:10:25 UTC
The development versions of gimp segfaults while loading fonts when it's compiled with the -Os flag. I suggest a 'filter-flag -Os' line is added to the ebuild. The protection against overoptimisation (which is now commented out) seems to be a good idea, though I don't know whetver changing -Os to -O2 will work. Filtering -Os out does work (at least for me).
Comment 1 Mike Gardiner (RETIRED) gentoo-dev 2004-01-09 19:39:23 UTC
Please post emerge info, what CFLAGS did you build with ? What gcc version etc.
Comment 2 Michal Januszewski (RETIRED) gentoo-dev 2004-01-10 02:04:07 UTC
emerge info:

System uname: 2.6.0 i686 AMD Athlon(tm) Processor
Gentoo Base System version 1.4.3.12
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CFLAGS="-Os -s -mcpu=athlon-tbird -march=athlon-tbird -mmmx -m3dnow -pipe -fomit-frame-pointer -fforce-addr -DNDEBUG -DG_DISABLE_ASSERT -DTT_CONFIG_OPTION_BYTECODE_INTERPRETER"
CHOST="i686-pc-linux-gnu"
COMPILER="gcc3"
CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /usr/kde/2/share/config /usr/kde/3/share/config /usr/share/config /usr/share/texmf/dvipdfm/config/ /usr/share/texmf/dvips/config/ /usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/ /usr/share/texmf/xdvi/ /var/bind /var/qmail/alias /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/env.d"
CXXFLAGS="-Os -s -mcpu=athlon-tbird -march=athlon-tbird -mmmx -m3dnow -pipe -fforce-addr -DNDEBUG -DG_DISABLE_ASSERT -DTT_CONFIG_OPTION_BYTECODE_INTERPRETER"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs ccache sandbox"
GENTOO_MIRRORS="http://ftp.uni-erlangen.de/pub/mirrors/gentoo http://gentoo.oregonstate.edu/ http://www.ibiblio.org/pub/Linux/distributions/gentoo"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"
USE="3dnow X aalib alsa apache2 apm avi berkdb bindist bonobo cdr crypt cups curl encode esd ethereal fbcon flash foomaticdb gd gdbm gdm gif gnome gpm gtk gtk2 guile imlib ipv6 java jpeg libg++ libwww mad maildir mbox mikmod mmx motif mozilla mpeg mysql ncurses nls oggvorbis opengl oss pam pdflib perl plotutils png python quicktime readline samba scanner sdl slang spell ssl svga tcltk tcpd tetex threads tiff truetype x86 xml xml2 xmms xv zlib"
Comment 3 Mike Gardiner (RETIRED) gentoo-dev 2004-01-10 05:04:15 UTC
Please build with sane CFLAGS, something like:

CFLAGS="-march=i686 -O2 -pipe" emerge gimp
Comment 4 Michal Januszewski (RETIRED) gentoo-dev 2004-01-16 02:36:04 UTC
Ok, here are the results:
-march=i686 -O2 -pipe: works
-O2 -s -mcpu=athlon-tbird -march=athlon-tbird -mmmx -m3dnow -pipe -fomit-frame-pointer -fforce-addr: doesn't work.

Maybe it would be a good idea to filter out any O-flags when -mcpu and -march are set to athlon-tbird? Or just change athlon-tbird to i686?
Comment 5 Yi Quang (RETIRED) gentoo-dev 2004-01-16 07:51:46 UTC
As far as I know -mmmx and -m3dnow is not required since it's already part of -march=archtype.  I agree that it is a good idea to force sane cflags on bigger projects.  
Comment 6 Henning Westerholt 2004-01-31 03:38:34 UTC
I try to emerge gimp-2.0_pre2 with CFLAGS="-march=i686 -O2 -pipe" on my machine
(Athlon XP), but without luck.
A segfault occur while loading the fonts.
Comment 7 Michal Januszewski (RETIRED) gentoo-dev 2004-01-31 04:35:03 UTC
Perhaps it would be best to just have -O2 and -Os replaced with -O1 in the ebuild..
Comment 8 foser (RETIRED) gentoo-dev 2004-02-03 06:38:16 UTC
I don't think so, it's probably some other flag causing this. I can build it just fine with any of the Ox's .

@comment 6 , will lowering your optimizations make it work or is it another problem altogether ?
Comment 9 Michal Januszewski (RETIRED) gentoo-dev 2004-02-13 03:01:57 UTC
Update: gimp-2.0_pre3 works fine with my flags from comment 2. But I'd wait at least till next version before closing this bug. I remember that one of the 1.3.x versions worked too, but the next release had problems again.
Comment 10 foser (RETIRED) gentoo-dev 2004-02-29 08:46:02 UTC
Well i won't wait, reopen if you actually have problems.