diff options
3 files changed, 1 insertions, 247 deletions
diff --git a/meta/recipes-kernel/oprofile/oprofileui/dso_linking_change_build_fix.patch b/meta/recipes-kernel/oprofile/oprofileui/dso_linking_change_build_fix.patch deleted file mode 100644 index 39ceb22e39..0000000000 --- a/meta/recipes-kernel/oprofile/oprofileui/dso_linking_change_build_fix.patch +++ /dev/null | |||
| @@ -1,27 +0,0 @@ | |||
| 1 | With dso linking change in gcc, all the libraries are needed to be explicitely specified to linker now. It breaks this package in following way. The libm library needs to be specified explicitely. | ||
| 2 | |||
| 3 | | make[2]: Entering directory `/disk0/pokybuild/build1/tmp/work/i586-poky-linux/oprofileui-0.0+svnr197-r0/trunk/src'^M | ||
| 4 | | ccache i586-poky-linux-gcc -march=i586 --sysroot=/disk0/pokybuild/build1/tmp/sysroots/i586-poky-linux -Wall -g -std=gnu99 -DPKG_DATA_DIR=\""/usr/share/oprofileui"\" -fexpensive-optimizations -fomit-frame-pointer -frename-registers -O2 -ggdb -feliminate-unused-debug-types -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed -o oprofile-viewer main.o client.o archive.o archive_window.o archive_save_window.o view.o report.o parser.o image.o symbol.o module.o symbol_instance.o module_instance.o callee_symbol_instance.o caller_symbol_instance.o state-util.o -pthread -lglade-2.0 -lgtk-x11-2.0 -lgdk-x11-2.0 -latk-1.0 -lgio-2.0 -lpangoft2-1.0 -lgdk_pixbuf-2.0 -lpangocairo-1.0 -lcairo -lpango-1.0 -lfreetype -lfontconfig -lxml2 -lgnomevfs-2 -lgmodule-2.0 -lgconf-2 -ldbus-glib-1 -ldbus-1 -lpthread -lgobject-2.0 -lgthread-2.0 -lrt -lglib-2.0 -pthread -lavahi-ui -lgtk-x11-2.0 -lavahi-common -lavahi-client -lavahi-glib -lgdk-x11-2.0 -latk-1.0 -lgio-2.0 -lpangoft2-1.0 -lgdk_pixbuf-2.0 -lpangocairo-1.0 -lcairo -lpango-1.0 -lfreetype -lfontconfig -lgobject-2.0 -lgmodule-2.0 -lgthread-2.0 -lrt -lglib-2.0 ../protocol/libop.a^M | ||
| 5 | | /disk0/pokybuild/build1/tmp/sysroots/x86_64-linux/usr/libexec/i586-poky-linux/gcc/i586-poky-linux/4.5.1/ld: ^X^B: invalid DSO for symbol `log@@GLIBC_2.0' definition^M | ||
| 6 | | /disk0/pokybuild/build1/tmp/sysroots/i586-poky-linux/lib/libm.so.6: could not read symbols: Bad value^M | ||
| 7 | | collect2: ld returned 1 exit status^M | ||
| 8 | | make[2]: *** [oprofile-viewer] Error 1^M | ||
| 9 | |||
| 10 | Upstream-Status: Inappropriate [configuration] | ||
| 11 | |||
| 12 | Nitin A Kamble <nitin.a.kamble@intel.com> | ||
| 13 | Date: 2011/01/11 | ||
| 14 | |||
| 15 | Index: trunk/src/Makefile.am | ||
| 16 | =================================================================== | ||
| 17 | --- trunk.orig/src/Makefile.am | ||
| 18 | +++ trunk/src/Makefile.am | ||
| 19 | @@ -56,7 +56,7 @@ oprofile_viewer_SOURCES = \ | ||
| 20 | |||
| 21 | oprofile_viewer_LDFLAGS = | ||
| 22 | |||
| 23 | -oprofile_viewer_LDADD = $(OPROFILEUI_LIBS) $(AVAHI_LIBS) $(top_builddir)/protocol/libop.a | ||
| 24 | +oprofile_viewer_LDADD = $(OPROFILEUI_LIBS) -lm $(AVAHI_LIBS) $(top_builddir)/protocol/libop.a | ||
| 25 | |||
| 26 | testparser_SOURCES = \ | ||
| 27 | parser.c \ | ||
diff --git a/meta/recipes-kernel/oprofile/oprofileui/migrate-from-gnomevfs-to-gio.patch b/meta/recipes-kernel/oprofile/oprofileui/migrate-from-gnomevfs-to-gio.patch deleted file mode 100644 index bf3979f0d3..0000000000 --- a/meta/recipes-kernel/oprofile/oprofileui/migrate-from-gnomevfs-to-gio.patch +++ /dev/null | |||
| @@ -1,219 +0,0 @@ | |||
| 1 | migrate from gnome-vfs to gio, as gnome-vfs is obsolete. | ||
| 2 | |||
| 3 | Signed-off-by: Zhai Edwin <edwin.zhai@intel.com> | ||
| 4 | |||
| 5 | Upstream-Status: Pending | ||
| 6 | |||
| 7 | Index: git/src/main.c | ||
| 8 | =================================================================== | ||
| 9 | --- git.orig/src/main.c 2011-06-21 10:35:31.000000000 +0800 | ||
| 10 | +++ git/src/main.c 2011-06-21 10:44:12.000000000 +0800 | ||
| 11 | @@ -44,7 +44,6 @@ | ||
| 12 | #include <gtk/gtk.h> | ||
| 13 | #include <glade/glade.h> | ||
| 14 | #include <glib.h> | ||
| 15 | -#include <libgnomevfs/gnome-vfs.h> | ||
| 16 | #include <gconf/gconf-client.h> | ||
| 17 | #include <glib/gi18n.h> | ||
| 18 | |||
| 19 | @@ -1005,8 +1004,7 @@ | ||
| 20 | /* Cleanup the old archive */ | ||
| 21 | archive_full_cleanup (); | ||
| 22 | |||
| 23 | - if (gnome_vfs_initialized()) | ||
| 24 | - gnome_vfs_shutdown (); | ||
| 25 | + g_type_init(); | ||
| 26 | |||
| 27 | g_free(opui_config->host); | ||
| 28 | g_free(opui_config->opcontrol_params); | ||
| 29 | Index: git/src/archive.c | ||
| 30 | =================================================================== | ||
| 31 | --- git.orig/src/archive.c 2011-06-21 10:38:57.000000000 +0800 | ||
| 32 | +++ git/src/archive.c 2011-06-21 10:54:16.000000000 +0800 | ||
| 33 | @@ -45,7 +45,6 @@ | ||
| 34 | #include <glade/glade.h> | ||
| 35 | #include <glib.h> | ||
| 36 | #include <glib/gstdio.h> | ||
| 37 | -#include <libgnomevfs/gnome-vfs.h> | ||
| 38 | |||
| 39 | #include "oprofileui.h" | ||
| 40 | #include "response.h" | ||
| 41 | @@ -86,56 +85,113 @@ | ||
| 42 | |||
| 43 | if (ret < 0) | ||
| 44 | { | ||
| 45 | - /* Use gnomevfs to copy the file as a fallback */ | ||
| 46 | - GnomeVFSURI *src_uri, *dst_uri; | ||
| 47 | - GnomeVFSResult res; | ||
| 48 | - | ||
| 49 | - src_uri = gnome_vfs_uri_new (gnome_vfs_get_uri_from_local_path(src)); | ||
| 50 | - dst_uri = gnome_vfs_uri_new (gnome_vfs_get_uri_from_local_path(dest)); | ||
| 51 | - res = gnome_vfs_xfer_uri (src_uri, dst_uri, | ||
| 52 | - GNOME_VFS_XFER_DEFAULT | | ||
| 53 | - GNOME_VFS_XFER_NEW_UNIQUE_DIRECTORY, | ||
| 54 | - GNOME_VFS_XFER_ERROR_MODE_ABORT, | ||
| 55 | - GNOME_VFS_XFER_OVERWRITE_MODE_REPLACE, | ||
| 56 | - NULL, NULL); | ||
| 57 | - if (res != GNOME_VFS_OK) | ||
| 58 | + /* Use gio to copy the file as a fallback */ | ||
| 59 | + GFile *src_file, *dst_file; | ||
| 60 | + gboolean res; | ||
| 61 | + GError *error = NULL; | ||
| 62 | + | ||
| 63 | + src_file = g_file_new_for_path (src); | ||
| 64 | + dst_file = g_file_new_for_path (dest); | ||
| 65 | + | ||
| 66 | + res = g_file_copy(src_file, dst_file, | ||
| 67 | + G_FILE_COPY_NOFOLLOW_SYMLINKS | | ||
| 68 | + G_FILE_COPY_OVERWRITE, | ||
| 69 | + NULL, | ||
| 70 | + NULL, | ||
| 71 | + NULL, | ||
| 72 | + &error); | ||
| 73 | + | ||
| 74 | + if (!res && error) | ||
| 75 | { | ||
| 76 | - const gchar *err_string = gnome_vfs_result_to_string (res); | ||
| 77 | + printf ("GIO: error %s (%s to %s)\n", error->message, src, dest); | ||
| 78 | |||
| 79 | - printf ("GNOME-VFS: error %s (%s to %s)\n", err_string, src, dest); | ||
| 80 | + g_error_free(error); | ||
| 81 | } | ||
| 82 | + | ||
| 83 | + g_object_unref(src_file); | ||
| 84 | + g_object_unref(dst_file); | ||
| 85 | + | ||
| 86 | + } | ||
| 87 | +} | ||
| 88 | + | ||
| 89 | +#define IS_IO_ERROR(__error, KIND) (((__error)->domain == G_IO_ERROR && (__error)->code == G_IO_ERROR_ ## KIND)) | ||
| 90 | + | ||
| 91 | +static gboolean | ||
| 92 | +remove_target_recursively(GFile *file) | ||
| 93 | +{ | ||
| 94 | + GFileEnumerator *enumerator; | ||
| 95 | + GError *error = NULL; | ||
| 96 | + GFile *child; | ||
| 97 | + GFileInfo *info; | ||
| 98 | + gboolean stop = FALSE; | ||
| 99 | + | ||
| 100 | + enumerator = g_file_enumerate_children(file, | ||
| 101 | + G_FILE_ATTRIBUTE_STANDARD_NAME, | ||
| 102 | + G_FILE_QUERY_INFO_NOFOLLOW_SYMLINKS, | ||
| 103 | + NULL, | ||
| 104 | + &error); | ||
| 105 | + | ||
| 106 | + if (enumerator) | ||
| 107 | + { | ||
| 108 | + error = NULL; | ||
| 109 | + | ||
| 110 | + while ( (info = g_file_enumerator_next_file(enumerator, NULL, &error)) | ||
| 111 | + != NULL ) { | ||
| 112 | + | ||
| 113 | + child = g_file_get_child(file, g_file_info_get_name(info)); | ||
| 114 | + if (!remove_target_recursively(child)) | ||
| 115 | + { | ||
| 116 | + stop = TRUE; | ||
| 117 | + break; | ||
| 118 | + } | ||
| 119 | + g_object_unref(child); | ||
| 120 | + g_object_unref(info); | ||
| 121 | + } | ||
| 122 | + | ||
| 123 | + g_object_unref(enumerator); | ||
| 124 | + } | ||
| 125 | + else if (IS_IO_ERROR(error, NOT_DIRECTORY)) | ||
| 126 | + { | ||
| 127 | + g_error_free(error); | ||
| 128 | } | ||
| 129 | + else | ||
| 130 | + { | ||
| 131 | + g_error_free(error); | ||
| 132 | + stop = TRUE; | ||
| 133 | + } | ||
| 134 | + | ||
| 135 | + if (stop) | ||
| 136 | + return FALSE; | ||
| 137 | + | ||
| 138 | + error = NULL; | ||
| 139 | + if (!g_file_delete(file, NULL, &error)) | ||
| 140 | + { | ||
| 141 | + char *path = g_file_get_path(file); | ||
| 142 | + printf ("GIO: error %s when deleteing file %s.\n", error->message, path); | ||
| 143 | + g_free(path); | ||
| 144 | + | ||
| 145 | + g_error_free(error); | ||
| 146 | + return FALSE; | ||
| 147 | + } | ||
| 148 | + | ||
| 149 | + return TRUE; | ||
| 150 | + | ||
| 151 | } | ||
| 152 | |||
| 153 | /* Delete the directory specified by path */ | ||
| 154 | static void | ||
| 155 | archive_removedir(gchar *path) | ||
| 156 | { | ||
| 157 | - GnomeVFSResult res; | ||
| 158 | - GnomeVFSURI *src_uri; | ||
| 159 | - GList uri_list; | ||
| 160 | + GFile *src_file; | ||
| 161 | |||
| 162 | if (path == NULL) | ||
| 163 | return; | ||
| 164 | |||
| 165 | - gnome_vfs_init (); | ||
| 166 | - | ||
| 167 | - src_uri = gnome_vfs_uri_new (gnome_vfs_get_uri_from_local_path(path)); | ||
| 168 | - | ||
| 169 | - uri_list.data = src_uri; | ||
| 170 | - uri_list.next = NULL; | ||
| 171 | - uri_list.prev = NULL; | ||
| 172 | + src_file = g_file_new_for_path (path); | ||
| 173 | |||
| 174 | - res = gnome_vfs_xfer_delete_list (&uri_list, | ||
| 175 | - GNOME_VFS_XFER_ERROR_MODE_ABORT, | ||
| 176 | - GNOME_VFS_XFER_EMPTY_DIRECTORIES, | ||
| 177 | - NULL, NULL); | ||
| 178 | - | ||
| 179 | - if (res != GNOME_VFS_OK) | ||
| 180 | + if (! remove_target_recursively(src_file)) | ||
| 181 | { | ||
| 182 | - const gchar *err_string = gnome_vfs_result_to_string (res); | ||
| 183 | - | ||
| 184 | - printf ("GNOME-VFS: error %s\n", err_string); | ||
| 185 | + printf ("GIO:remove %s failed", path); | ||
| 186 | } | ||
| 187 | } | ||
| 188 | |||
| 189 | @@ -242,8 +298,6 @@ | ||
| 190 | gchar **tmp; | ||
| 191 | int i; | ||
| 192 | |||
| 193 | - gnome_vfs_init (); | ||
| 194 | - | ||
| 195 | tmp = g_strsplit (reply->payload, "\n", 0); | ||
| 196 | |||
| 197 | for (i=0; i < g_strv_length (tmp); i++) | ||
| 198 | @@ -436,8 +490,6 @@ | ||
| 199 | { | ||
| 200 | gint counter; | ||
| 201 | |||
| 202 | - gnome_vfs_init (); | ||
| 203 | - | ||
| 204 | downloaded_files = g_slist_append (downloaded_files, g_strdup("/var/lib/oprofile/.converted")); | ||
| 205 | |||
| 206 | archive_save_window_show (g_slist_length (downloaded_files) + | ||
| 207 | Index: git/configure.ac | ||
| 208 | =================================================================== | ||
| 209 | --- git.orig/configure.ac 2011-06-21 10:49:40.000000000 +0800 | ||
| 210 | +++ git/configure.ac 2011-06-21 10:49:58.000000000 +0800 | ||
| 211 | @@ -29,7 +29,7 @@ | ||
| 212 | AM_CONDITIONAL(ENABLE_SERVER, test x$enable_server = xyes) | ||
| 213 | AM_CONDITIONAL(ENABLE_CLIENT, test x$enable_client = xyes) | ||
| 214 | |||
| 215 | -PKG_CHECK_MODULES(OPROFILEUI, [glib-2.0 libglade-2.0 gtk+-2.0 libxml-2.0 gnome-vfs-2.0 gconf-2.0]) | ||
| 216 | +PKG_CHECK_MODULES(OPROFILEUI, [glib-2.0 libglade-2.0 gtk+-2.0 libxml-2.0 gconf-2.0]) | ||
| 217 | AC_SUBST(OPROFILEUI_CFLAGS) | ||
| 218 | AC_SUBST(OPROFILEUI_LIBS) | ||
| 219 | |||
diff --git a/meta/recipes-kernel/oprofile/oprofileui_git.bb b/meta/recipes-kernel/oprofile/oprofileui_git.bb index 2b56981243..3fe9bb4e6a 100644 --- a/meta/recipes-kernel/oprofile/oprofileui_git.bb +++ b/meta/recipes-kernel/oprofile/oprofileui_git.bb | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | require oprofileui.inc | 1 | require oprofileui.inc |
| 2 | 2 | ||
| 3 | SRCREV = "b3116a4f80ae64bd280e6434d66f33ed492d449a" | 3 | SRCREV = "82ecf8c6b53b84f80682a8312f9defa83a95f2a3" |
| 4 | PV = "0.0+git${SRCPV}" | 4 | PV = "0.0+git${SRCPV}" |
| 5 | PR = "r0" | 5 | PR = "r0" |
| 6 | 6 | ||
