Skip to content

Commit

Permalink
Bug 482156 - Get rid of (unnecessary) LIBGNOME dependency. r=bsmedber…
Browse files Browse the repository at this point in the history
…g and roc
  • Loading branch information
tonikitoo committed Mar 9, 2009
1 parent 9daedec commit cc56acc
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 24 deletions.
4 changes: 1 addition & 3 deletions config/autoconf.mk.in
Original file line number Diff line number Diff line change
Expand Up @@ -248,16 +248,14 @@ MOZ_ENABLE_STARTUP_NOTIFICATION = @MOZ_ENABLE_STARTUP_NOTIFICATION@
MOZ_STARTUP_NOTIFICATION_CFLAGS = @MOZ_STARTUP_NOTIFICATION_CFLAGS@
MOZ_STARTUP_NOTIFICATION_LIBS = @MOZ_STARTUP_NOTIFICATION_LIBS@

MOZ_ENABLE_GNOMEVFS = @MOZ_ENABLE_GNOMEVFS@
MOZ_GNOMEVFS_CFLAGS = @MOZ_GNOMEVFS_CFLAGS@
MOZ_GNOMEVFS_LIBS = @MOZ_GNOMEVFS_LIBS@

MOZ_ENABLE_GCONF = @MOZ_ENABLE_GCONF@
MOZ_GCONF_CFLAGS = @MOZ_GCONF_CFLAGS@
MOZ_GCONF_LIBS = @MOZ_GCONF_LIBS@

MOZ_LIBGNOME_CFLAGS = @MOZ_LIBGNOME_CFLAGS@
MOZ_LIBGNOME_LIBS = @MOZ_LIBGNOME_LIBS@

MOZ_ENABLE_GNOME_COMPONENT = @MOZ_ENABLE_GNOME_COMPONENT@

MOZ_INSURE = @MOZ_INSURE@
Expand Down
19 changes: 3 additions & 16 deletions configure.in
Original file line number Diff line number Diff line change
Expand Up @@ -5092,7 +5092,6 @@ then
then
MOZ_ENABLE_GNOMEVFS=1
MOZ_ENABLE_GCONF=1
MOZ_ENABLE_LIBGNOME=1
fi

MOZ_ARG_DISABLE_BOOL(gnomevfs,
Expand All @@ -5114,6 +5113,7 @@ then
])
fi

AC_SUBST(MOZ_ENABLE_GNOMEVFS)
AC_SUBST(MOZ_GNOMEVFS_CFLAGS)
AC_SUBST(MOZ_GNOMEVFS_LIBS)

Expand All @@ -5135,24 +5135,11 @@ then
AC_SUBST(MOZ_GCONF_CFLAGS)
AC_SUBST(MOZ_GCONF_LIBS)

if test "$MOZ_ENABLE_LIBGNOME"
then
PKG_CHECK_MODULES(MOZ_LIBGNOME, libgnome-2.0 >= $LIBGNOME_VERSION,[
MOZ_LIBGNOME_LIBS=`echo $MOZ_LIBGNOME_LIBS | sed 's/-llinc\>//'`
MOZ_ENABLE_LIBGNOME=1
],[
MOZ_ENABLE_LIBGNOME=
])
fi

AC_SUBST(MOZ_LIBGNOME_CFLAGS)
AC_SUBST(MOZ_LIBGNOME_LIBS)

# The GNOME component is built if gtk2, gconf, gnome-vfs, and libgnome
# The GNOME component is built if gtk2, gconf and gnome-vfs
# are all available.

if test "$MOZ_ENABLE_GTK2" -a "$MOZ_ENABLE_GCONF" -a \
"$MOZ_ENABLE_GNOMEVFS" -a "$MOZ_ENABLE_LIBGNOME"; then
"$MOZ_ENABLE_GNOMEVFS"; then
MOZ_ENABLE_GNOME_COMPONENT=1
else
MOZ_ENABLE_GNOME_COMPONENT=
Expand Down
2 changes: 0 additions & 2 deletions toolkit/system/gnome/Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,6 @@ EXTRA_DSO_LDOPTS += \
$(NSPR_LIBS) \
$(MOZ_GCONF_LIBS) \
$(MOZ_GNOMEVFS_LIBS) \
$(MOZ_LIBGNOME_LIBS) \
$(GLIB_LIBS) \
$(MOZ_LIBNOTIFY_LIBS) \
$(NULL)
Expand All @@ -89,7 +88,6 @@ include $(topsrcdir)/config/rules.mk
CXXFLAGS += \
$(MOZ_GCONF_CFLAGS) \
$(MOZ_GNOMEVFS_CFLAGS) \
$(MOZ_LIBGNOME_CFLAGS) \
$(GLIB_CFLAGS) \
$(MOZ_LIBNOTIFY_CFLAGS) \
$(NULL)
5 changes: 2 additions & 3 deletions toolkit/system/gnome/nsGnomeVFSService.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ extern "C" {
#include <libgnomevfs/gnome-vfs-mime.h>
#include <libgnomevfs/gnome-vfs-mime-handlers.h>
#include <libgnomevfs/gnome-vfs-mime-info.h>
#include <libgnome/gnome-url.h>
}

class nsGnomeVFSMimeApp : public nsIGnomeVFSMimeApp
Expand Down Expand Up @@ -264,7 +263,7 @@ nsGnomeVFSService::ShowURI(nsIURI *aURI)
nsCAutoString spec;
aURI->GetSpec(spec);

if (gnome_url_show(spec.get(), NULL))
if (gnome_vfs_url_show_with_env(spec.get(), NULL) == GNOME_VFS_OK)
return NS_OK;

return NS_ERROR_FAILURE;
Expand All @@ -276,7 +275,7 @@ nsGnomeVFSService::ShowURIForInput(const nsACString &aUri)
char* spec = gnome_vfs_make_uri_from_input(PromiseFlatCString(aUri).get());
nsresult rv = NS_ERROR_FAILURE;

if (gnome_url_show(spec, NULL))
if (gnome_vfs_url_show_with_env(spec, NULL) == GNOME_VFS_OK)
rv = NS_OK;

if (spec)
Expand Down

0 comments on commit cc56acc

Please sign in to comment.