GNOME Bugzilla – Bug 138454
gedit should not depend on libeel
Last modified: 2005-12-15 10:36:47 UTC
Running gedit 2.4.0 on an otherwise gnome 2.6 system, I find: pisces:~$ gedit gedit: relocation error: gedit: undefined symbol: eel_input_event_box_new Since libeel's SONAME hasn't changed, its abi should also not change.
I've reproduced this on my system which has the same configuration (gedit 2.4.0 on an otherwise 2.6 system).
If I understand correctly, eel just needs to have that symbol back, just for compatibility?
Assuming that's the only ABI incompatibility, yes.
Eel has no api or abi stability guarantees. Its not really supposed to be used by apps other than nautilus. The widget in question (EelInputEventBox) is now availible in Gtk 2.4 (using the normal GtkEventBox).
The Eel README says: > In order to clearly distinguish useful extensions that could be useful > for other projects, we have decided to put then in their own library. It's used by epiphany, galeon, gnome-control-center, abiword, etc. What's the point of having any SONAME if it's just a Nautilus-internal component and the ABI is broken at will?
For reference, galeon does _not_ use libeel directly, it is pulled in as a library by the nautilus view. I believe that epiphany is the same.
gedit 2.6.x does not use EelInputEventBox. I'd like to remove libeel dependency in one of the next features. BTW, being gedit part of the GNOME desktop, it is supposed to work with the right desktop version (note that gedit also depends on libgnome/ui that are not included in the platform and so have potentially the same problem of libeel). Changing summary
I've removed a couple of easy refernce to eel (s/eel_make_canonical_uri/gnome_vfs_make_canonical_uri). Here is a grep of the remaing uses of eel: gedit/gedit-document.c:#include <eel/eel-vfs-extensions.h> gedit/gedit-document.c: basename = eel_uri_get_basename (doc->priv->uri); gedit/gedit-document.c: utf8_basename = eel_make_valid_utf8 (basename); gedit/gedit-document.c: doc->priv->read_handle = eel_read_file_async (doc->priv->temp_uri, gedit/gedit-document.c: if (!eel_vfs_has_capability (doc->priv->temp_uri, EEL_VFS_CAPABILITY_IS_REMOTE_AND_SLOW)) gedit/gedit-document.c: gchar *temp = eel_uri_get_scheme (uri); gedit/gedit-document.c: scheme_string = eel_make_valid_utf8 (temp); gedit/gedit-file.c:#include <eel/eel-vfs-extensions.h> gedit/gedit-file.c:#include <eel/eel-alert-dialog.h> gedit/gedit-file.c:#include <eel/eel-string.h> gedit/gedit-file.c: fname = eel_uri_get_basename (raw_uri); gedit/gedit-file.c: uri = eel_make_uri_from_shell_arg (file); gedit/gedit-file.c: file_utf8 = eel_format_uri_for_display (uri); gedit/gedit-file.c: msgbox = eel_alert_dialog_new (GTK_WINDOW (gedit_get_active_window ()), gedit/gedit-file.c: full_path = eel_make_uri_from_input (uri); gedit/gedit-file.c: uri_for_display = eel_str_middle_truncate (full_formatted_uri, gedit/gedit-file-selector-util.c:#include <eel/eel-vfs-extensions.h> gedit/gedit-file-selector-util.c:#include <eel/eel-string.h> gedit/gedit-file-selector-util.c:#include <eel/eel-alert-dialog.h> gedit/gedit-file-selector-util.c: uri = eel_make_uri_from_shell_arg (file_name); gedit/gedit-file-selector-util.c: full_formatted_uri = eel_format_uri_for_display (uri); gedit/gedit-file-selector-util.c: uri_for_display = eel_str_middle_truncate (full_formatted_uri, 50); gedit/gedit-file-selector-util.c: msgbox = eel_alert_dialog_new (parent, gedit/gedit-mdi.c:#include <eel/eel-string.h> gedit/gedit-mdi.c:#include <eel/eel-alert-dialog.h> gedit/gedit-mdi.c: docname = eel_str_middle_truncate (uri, MAX_URI_IN_TITLE_LENGTH); gedit/gedit-mdi-child.c:#include <eel/eel-string.h> gedit/gedit-mdi-child.c: docname = eel_str_middle_truncate (name, MAX_DOC_NAME_LENGTH); gedit/gedit-print.c:#include <eel/eel-string.h> gedit/gedit-print.c: name_to_display = eel_str_middle_truncate (doc_name, 60); gedit/gedit-utils.c:#include <eel/eel-gtk-extensions.h> gedit/gedit-utils.c:#include <eel/eel-vfs-extensions.h> gedit/gedit-utils.c:#include <eel/eel-string.h> gedit/gedit-utils.c: res = eel_istr_has_prefix (canonical_uri, "file:"); gedit/gedit-utils.c: button = eel_gtk_button_new_with_stock_icon (text, stock_id); gedit/gedit-utils.c: full_formatted_uri = eel_format_uri_for_display (uri); gedit/gedit-utils.c: uri_for_display = eel_str_middle_truncate (full_formatted_uri, gedit/gedit-utils.c: scheme_string = eel_uri_get_scheme (uri); gedit/gedit-utils.c: host_name = eel_make_valid_utf8 ( gedit/gedit-utils.c: full_formatted_uri = eel_format_uri_for_display (uri); gedit/gedit-utils.c: uri_for_display = eel_str_middle_truncate (full_formatted_uri, gedit/gedit-utils.c: uri_for_display = eel_str_middle_truncate (full_formatted_uri, gedit/gedit-utils.c: scheme_string = eel_uri_get_scheme (uri); gedit/gedit-utils.c: host_name = eel_make_valid_utf8 ( gedit/gedit-utils.c: full_formatted_uri = eel_format_uri_for_display (uri); gedit/gedit-utils.c: uri_for_display = eel_str_middle_truncate (full_formatted_uri, plugins/shell_output/shell_output.c:#include <eel/eel-vfs-extensions.h> plugins/shell_output/shell_output.c: basename = eel_uri_get_basename (tmp); - str_middle_truncate is the most used: may be worth copying in utils. - eel_alert_dialog file should be prolly cut&pasted. It's stable and there's a chance that gtk2.6 will have a HIG compliant alert dialog - the other need to be considered case by case, paying particular attention to the ones dealing with uri conversion (see also bug #141844)
ok, we are almost there: the only remaining reference to eel is in gedit-document.c, where we use eel_read_file_async to load files. unfortunately that is not a simple function that can be cut&pasted somewhere in gedit. Hopefully a replecement for it should show up in gnome-vfs in the 2.10 timeframe.
There's also this: gedit-document.c: if (!eel_vfs_has_capability (doc->priv->temp_uri, EEL_VFS_CAPABILITY_IS_REMOTE_AND_SLOW))
no more eel on HEAD. whoohoo!