Merge lp:~directhex/indicator-application/gapi_is_a_pile_of_shit into lp:indicator-application/0.4

Proposed by Jo Shields
Status: Merged
Merged at revision: 162
Proposed branch: lp:~directhex/indicator-application/gapi_is_a_pile_of_shit
Merge into: lp:indicator-application/0.4
Diff against target: 85 lines (+14/-8)
4 files modified
bindings/mono/ApplicationIndicator.custom (+4/-4)
bindings/mono/Makefile.am (+7/-1)
bindings/mono/app-indicator.sources.xml (+2/-2)
bindings/mono/appindicator-sharp.dll.config.in (+1/-1)
To merge this branch: bzr merge lp:~directhex/indicator-application/gapi_is_a_pile_of_shit
Reviewer Review Type Date Requested Status
Indicator Applet Developers Pending
Review via email: mp+35963@code.launchpad.net

Description of the change

indicator-application stopped working in Mono apps, as it was built against SONAME 0, but the lib was bumped to SONAME 1. Sadly, due to a comedy of errors with the "gapi" code generator used by Mono against GObject, the fix extended far beyond simply fixing indicator-application's SONAME expectations.

This branch fixes the FTBFS problem with the Mono binding, and also (theoretically, I haven't been able to fully test it) fixes the problem with the wrong lib being dlopened by Mono, and also fixes package builds (which currently do not place a dependency on libappindicator1).

To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'bindings/mono/ApplicationIndicator.custom'
2--- bindings/mono/ApplicationIndicator.custom 2010-01-12 04:59:17 +0000
3+++ bindings/mono/ApplicationIndicator.custom 2010-09-19 20:12:49 +0000
4@@ -1,10 +1,10 @@
5-[DllImport ("libappindicator.so.0")]
6+[DllImport ("appindicator.dll")]
7 static extern int app_indicator_get_status (IntPtr i);
8
9-[DllImport ("libappindicator.so.0")]
10+[DllImport ("appindicator.dll")]
11 static extern int app_indicator_get_category (IntPtr i);
12
13-[DllImport ("libappindicator.so.0")]
14+[DllImport ("appindicator.dll")]
15 static extern void app_indicator_set_status (IntPtr i, int s);
16
17 [GLib.Property ("status")]
18@@ -23,4 +23,4 @@
19 get {
20 return (Category) app_indicator_get_category (Handle);
21 }
22- }
23\ No newline at end of file
24+ }
25
26=== modified file 'bindings/mono/Makefile.am'
27--- bindings/mono/Makefile.am 2010-07-07 19:23:37 +0000
28+++ bindings/mono/Makefile.am 2010-09-19 20:12:49 +0000
29@@ -15,6 +15,8 @@
30 POLICY = policy.$(POLICY_VERSION).$(ASSEMBLY_NAME)
31 POLICY_VERSION = 0.0
32 DLLPOLICY = $(POLICY).dll
33+WRAPPER_FREE_BINDING_SRC = ../../src/app-indicator.c
34+WRAPPER_FREE_BINDING = app-indicator.c
35
36 TARGET = \
37 $(ASSEMBLY) \
38@@ -35,6 +37,7 @@
39 $(RAW_API) \
40 $(TEST) \
41 $(DLLPOLICY) \
42+ $(WRAPPER_FREE_BINDING) \
43 $(POLICY).config
44
45 DISTCLEANFILES = $(ASSEMBLY).config
46@@ -57,9 +60,12 @@
47 references = $(GTK_SHARP_LIBS)
48 test_references = $(GTK_SHARP_LIBS) $(NUNIT_LIBS) -r:$(ASSEMBLY)
49
50-$(RAW_API): app-indicator.sources.xml
51+$(RAW_API): app-indicator.sources.xml $(WRAPPER_FREE_BINDING)
52 $(GAPI_PARSER) app-indicator.sources.xml
53
54+$(WRAPPER_FREE_BINDING): $(WRAPPER_FREE_BINDING_SRC)
55+ sed '/signals\[X_NEW_LABEL\] /,+6d' $(WRAPPER_FREE_BINDING_SRC) > $(WRAPPER_FREE_BINDING)
56+
57 $(MIDDLE_API): $(METADATA) $(RAW_API)
58 cp $(srcdir)/$(RAW_API) $(MIDDLE_API)
59 chmod u+w $(MIDDLE_API)
60
61=== modified file 'bindings/mono/app-indicator.sources.xml'
62--- bindings/mono/app-indicator.sources.xml 2010-06-17 17:43:06 +0000
63+++ bindings/mono/app-indicator.sources.xml 2010-09-19 20:12:49 +0000
64@@ -1,8 +1,8 @@
65 <gapi-parser-input>
66 <api filename="libappindicator-api.raw">
67- <library name="libappindicator.so.0">
68+ <library name="appindicator.dll">
69 <namespace name="AppIndicator">
70- <file>../../src/app-indicator.c</file>
71+ <file>app-indicator.c</file>
72 <file>../../src/app-indicator-enum-types.c</file>
73 <file>../../src/app-indicator-enum-types.h</file>
74 <file>../../src/app-indicator.h</file>
75
76=== modified file 'bindings/mono/appindicator-sharp.dll.config.in'
77--- bindings/mono/appindicator-sharp.dll.config.in 2009-12-16 21:15:30 +0000
78+++ bindings/mono/appindicator-sharp.dll.config.in 2010-09-19 20:12:49 +0000
79@@ -1,5 +1,5 @@
80 <configuration>
81- <dllmap dll="appindicator-sharp.dll" target="libappindicator@LIB_PREFIX@.0@LIB_SUFFIX@"/>
82+ <dllmap dll="appindicator.dll" target="libappindicator@LIB_PREFIX@.1@LIB_SUFFIX@"/>
83 <dllmap dll="libgtk-2.0-0.dll" target="libgtk-2.0@LIB_PREFIX@.0@LIB_SUFFIX@"/>
84 <dllmap dll="libglib-2.0-0.dll" target="libglib-2.0@LIB_PREFIX@.0@LIB_SUFFIX@"/>
85 <dllmap dll="libgobject-2.0-0.dll" target="libgobject-2.0@LIB_PREFIX@.0@LIB_SUFFIX@"/>

Subscribers

People subscribed via source and target branches