Makes it work on case-sensitive file systems such as HFS+.
https://bugzilla.gnome.org/show_bug.cgi?id=667405
giscanner/scannerparser.y \
giscanner/grealpath.h
libgiscanner_la_CPPFLAGS = -I$(top_srcdir)/girepository -I$(top_srcdir)/giscanner
-libgiscanner_la_LIBADD = $(GOBJECT_LIBS)
-libgiscanner_la_CFLAGS = $(GOBJECT_CFLAGS)
+libgiscanner_la_LIBADD = $(GOBJECT_LIBS) $(GIO_LIBS)
+libgiscanner_la_CFLAGS = $(GOBJECT_CFLAGS) $(GIO_CFLAGS)
# Python module
pkgpyexecdir = $(pkglibdir)/giscanner
#include <windows.h>
#endif
+#include <glib-object.h>
+
DL_EXPORT(void) init_giscanner(void);
#define NEW_CLASS(ctype, name, cname) \
PyObject *m, *d;
gboolean is_uninstalled;
+ g_type_init ();
+
/* Hack to avoid having to create a fake directory structure; when
* running uninstalled, the module will be in the top builddir,
* with no _giscanner prefix.
#include "sourcescanner.h"
#include <string.h>
+#include <gio/gio.h>
GISourceSymbol *
gi_source_symbol_new (GISourceSymbolType type, const gchar *filename, int line)
{
gboolean found_filename = FALSE;
GList *l;
+ GFile *current_file;
g_assert (scanner->current_filename);
+ current_file = g_file_new_for_path (scanner->current_filename);
+
for (l = scanner->filenames; l != NULL; l = l->next)
{
- if (strcmp (l->data, scanner->current_filename) == 0)
+ GFile *file = g_file_new_for_path (l->data);
+
+ if (g_file_equal (file, current_file))
{
found_filename = TRUE;
+ g_object_unref (file);
break;
}
+ g_object_unref (file);
}
if (found_filename || scanner->macro_scan)
default:
break;
}
+
+ g_object_unref (current_file);
}
GSList *