After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 104935 - Mixer applet icon is broken
Mixer applet icon is broken
Status: RESOLVED INVALID
Product: gnome-applets
Classification: Other
Component: mixer
2.3.x
Other Linux
: High normal
: ---
Assigned To: gnome-applets Maintainers
gnome-applets Maintainers
: 106076 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2003-01-31 20:33 UTC by Mike Kelly
Modified: 2004-12-22 21:47 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Mike Kelly 2003-01-31 20:33:40 UTC
The default icon for the mixer applet shows up as a broken image.  If it
worked correctly, it would show a speaker with "sound waves" indicating the
volume level.  The icon seems to magically work if the current theme is
changed via Applications->Desktop Preferences->Themes, but none of these
themes are particularly pretty (perhaps I'll have to submit another bug
report about this :)

Anyway, I found the problem, it turns out that the mixer applet is looking
for it's images in GNOME_ICONDIR, which is defined as "NONE/share/pixmaps",
a directory, which everyone knows doesn't exist.  A simple workaround is to
give configure the --prefix option, then NONE is correctly replaced with
the prefix and everyone is happy.

The reason that GNOME_ICONDIR isn't set to the correct default value of
"/usr/local/share/pixmaps" is because GNOME_ICONDIR is defined in config.h
before $prefix (which has a default value of NONE) has been changed to
$ac_default_prefix in configure.  The correct way to fix this problem is to
change configure.in and rerun autoconf.  The following patch rearranges the
order of configure.in so that $prefix is properly defined before it is
refereced.

(Note: I origionally made this patch for version 2.1.3, but it applies
cleanly to 2.2.0)

--- gnome-applets-2.1.3/configure.in.orig       Mon Dec 16 14:14:55 2002
+++ gnome-applets-2.1.3/configure.in    Wed Jan 22 21:28:31 2003
@@ -250,15 +250,6 @@
 # Honor aclocal flags
 ACLOCAL="$ACLOCAL $ACLOCAL_FLAGS"
-
-AC_DEFINE_UNQUOTED(GNOME_ICONDIR, "${prefix}/share/pixmaps")
-
-#defined the below to enable help to work for applets 
-
-AC_DEFINE_UNQUOTED(DATADIR, "${prefix}/share")
-AC_DEFINE_UNQUOTED(SYSCONFDIR, "${prefix}/etc")
-AC_DEFINE_UNQUOTED(LIBDIR, "${prefix}/lib")
-AC_DEFINE_UNQUOTED(PREFIX, "$prefix")

 AC_OUTPUT([
 gnome-applets.spec
 Makefile
@@ -313,3 +304,12 @@
 wireless/Makefile
 omf-install/Makefile
 ])
+
+AC_DEFINE_UNQUOTED(GNOME_ICONDIR, "${prefix}/share/pixmaps")
+
+#defined the below to enable help to work for applets 
+
+AC_DEFINE_UNQUOTED(DATADIR, "${prefix}/share")
+AC_DEFINE_UNQUOTED(SYSCONFDIR, "${prefix}/etc")
+AC_DEFINE_UNQUOTED(LIBDIR, "${prefix}/lib")
+AC_DEFINE_UNQUOTED(PREFIX, "$prefix")
Comment 1 Elijah Newren 2003-01-31 20:46:02 UTC
Adding GNOMEVER2.1 keyword, setting priority->high (to help this bug's
visibility), and adding the PATCH keyword.
Comment 2 Mike Kelly 2003-01-31 21:53:40 UTC
Oops.  I could have sworn this patch worked for me, but now that I try
it again, I see that it doesn't.  So this only goes to show that you
should test your patches before you commit your mistakes to the bug
database. (:

Anyway, the problem is still the same, just the patch doesn't work.

ARGH!
Comment 3 Mike Kelly 2003-02-01 23:08:11 UTC
Well, here is a patch that really does fix the problem.  I looked into
several different solutions, and finally setteled on this one.  It is
a bit of a hack, but from what I can tell, this is the way that others
have solved this same problem.  Possibly a better solution would be to
define this stuff in a Makefile and pass it via gcc's -D option.


--- gnome-applets-2.2.0/configure.in.orig       Sun Jan 26 09:39:30 2003
+++ gnome-applets-2.2.0/configure.in    Sat Feb  1 15:00:57 2003
@@ -250,14 +250,17 @@
 # Honor aclocal flags
 ACLOCAL="$ACLOCAL $ACLOCAL_FLAGS"
 
-AC_DEFINE_UNQUOTED(GNOME_ICONDIR, "${prefix}/share/pixmaps")
+PREFIX=$prefix
+test "x$prefix" = xNONE && PREFIX=$ac_default_prefix
+AC_DEFINE_UNQUOTED(PREFIX, "$PREFIX")
+
+AC_DEFINE(GNOME_ICONDIR, PREFIX"/share/pixmaps")
 
 #defined the below to enable help to work for applets 
 
-AC_DEFINE_UNQUOTED(DATADIR, "${prefix}/share")
-AC_DEFINE_UNQUOTED(SYSCONFDIR, "${prefix}/etc")
-AC_DEFINE_UNQUOTED(LIBDIR, "${prefix}/lib")
-AC_DEFINE_UNQUOTED(PREFIX, "$prefix")
+AC_DEFINE(DATADIR, PREFIX"/share")
+AC_DEFINE(SYSCONFDIR, PREFIX"/etc")
+AC_DEFINE(LIBDIR, PREFIX"/lib")
 
 AC_OUTPUT([
 gnome-applets.spec
Comment 4 Kevin Vandersloot 2003-03-11 19:32:19 UTC
*** Bug 106076 has been marked as a duplicate of this bug. ***
Comment 5 Andrew Sobala 2003-07-12 18:23:46 UTC
Is this still applicable?
Comment 6 Kevin Vandersloot 2003-07-13 01:47:20 UTC
Yes it is.

Only affects people who compile themselves and don't do "configure
--prefix=something"
Comment 7 Jakub Steiner 2003-09-09 16:39:15 UTC
could the volume applet use the gnome-icon-theme instead? the
appropriate icon is stock_volume.png
Comment 8 Kjartan Maraas 2004-04-14 10:26:57 UTC
What's up with this? Is the patch ok to go into 2.6.1 and then focus on using
the icon theme for 2.7.x?
Comment 9 Danielle Madeley 2004-08-09 04:09:23 UTC
Checking if this bug is still relevant.
Comment 10 Danielle Madeley 2004-09-21 04:06:31 UTC
GNOME 2.10 will feature a new mixer applet. If this bug is still relevant please
reopen it after testing out the new mixer applet. Thanks.