aboutsummaryrefslogtreecommitdiff
path: root/bindings
diff options
context:
space:
mode:
Diffstat (limited to 'bindings')
-rw-r--r--bindings/mono/Makefile.am52
-rw-r--r--bindings/mono/Makefile.in49
-rw-r--r--bindings/mono/app-indicator.sources.xml8
-rw-r--r--bindings/mono/libappindicator-api.raw192
-rw-r--r--bindings/mono/policy.0.0.appindicator-sharp.config.in10
5 files changed, 100 insertions, 211 deletions
diff --git a/bindings/mono/Makefile.am b/bindings/mono/Makefile.am
index 4d2d8b4..98fe6f9 100644
--- a/bindings/mono/Makefile.am
+++ b/bindings/mono/Makefile.am
@@ -10,11 +10,33 @@ MIDDLE_API = libappindicator-api.middle
RAW_API = libappindicator-api.raw
METADATA = libappindicator-api.metadata
ASSEMBLY_NAME = appindicator-sharp
-ASSEMBLY = appindicator-sharp.dll
-TARGET = $(ASSEMBLY) $(ASSEMBLY).config
+ASSEMBLY_VERSION = 0.1.0.0
+ASSEMBLY = $(ASSEMBLY_NAME).dll
+POLICY = policy.$(POLICY_VERSION).$(ASSEMBLY_NAME)
+POLICY_VERSION = 0.0
+DLLPOLICY = $(POLICY).dll
+
+TARGET = \
+ $(ASSEMBLY) \
+ $(ASSEMBLY).config \
+ $(DLLPOLICY) \
+ $(POLICY).config
+
assemblydir = $(libdir)/cli/appindicator-sharp-0.1
assembly_DATA = $(TARGET)
-CLEANFILES = $(ASSEMBLY) $(ASSEMBLY).mdb generated-stamp generated/*.cs $(API) $(MIDDLE_API) $(RAW_API) $(TEST)
+
+CLEANFILES = \
+ $(ASSEMBLY) \
+ $(ASSEMBLY).mdb \
+ generated-stamp \
+ generated/*.cs \
+ $(API) \
+ $(MIDDLE_API) \
+ $(RAW_API) \
+ $(TEST) \
+ $(DLLPOLICY) \
+ $(POLICY).config
+
DISTCLEANFILES = $(ASSEMBLY).config
TEST_SOURCES = TestIndicator.cs
customs = ApplicationIndicator.custom
@@ -26,10 +48,11 @@ EXTRA_DIST = \
appindicator-sharp.dll.config.in \
app-indicator.sources.xml \
$(ASSEMBLY_NAME).snk \
+ $(POLICY).config.in \
$(customs) \
$(TEST_SOURCES)
-GACUTIL_FLAGS="-package $(ASSEMBLY_NAME) -root $(DESTDIR)$(prefix)/lib"
+GACUTIL_FLAGS=-package $(ASSEMBLY_NAME) -root $(DESTDIR)$(prefix)/lib
references = $(GTK_SHARP_LIBS)
test_references = $(GTK_SHARP_LIBS) $(NUNIT_LIBS) -r:$(ASSEMBLY)
@@ -72,14 +95,27 @@ $(ASSEMBLY): generated-stamp $(srcdir)/AssemblyInfo.cs
$(CSC) $(CSFLAGS) -keyfile:$(srcdir)/$(ASSEMBLY_NAME).snk -nowarn:0169,0612,0618 -unsafe -out:$(ASSEMBLY) -target:library $(references) $(builddir)/$(GENERATED_SOURCES) $(srcdir)/AssemblyInfo.cs
install-data-local:
- echo "$(GACUTIL) -i $(ASSEMBLY_NAME).dll -package $(ASSEMBLY_NAME) -root $(DESTDIR)$(prefix)/lib"; \
- $(GACUTIL) -i $(ASSEMBLY_NAME).dll -package $(ASSEMBLY_NAME) -root $(DESTDIR)$(prefix)/lib || exit 1;
+ echo "$(GACUTIL) -i $(ASSEMBLY_NAME).dll $(GACUTIL_FLAGS)"; \
+ $(GACUTIL) -i $(ASSEMBLY_NAME).dll $(GACUTIL_FLAGS) || exit 1;
+ echo "$(GACUTIL) -i $(DLLPOLICY) $(GACUTIL_FLAGS)"; \
+ $(GACUTIL) -i $(DLLPOLICY) $(GACUTIL_FLAGS) || exit 1;
uninstall-local:
- echo "$(GACUTIL) -u $(ASSEMBLY_NAME) -package $(ASSEMBLY_NAME) -root $(DESTDIR)$(prefix)/lib"; \
- $(GACUTIL) -u $(ASSEMBLY_NAME) -package $(ASSEMBLY_NAME) -root $(DESTDIR)$(prefix)/lib || exit 1;
+ echo "$(GACUTIL) -u $(ASSEMBLY_NAME) $(GACUTIL_FLAGS)"; \
+ $(GACUTIL) -u $(ASSEMBLY_NAME) $(GACUTIL_FLAGS) || exit 1;
+ echo "$(GACUTIL) -u $(DLLPOLICY) $(GACUTIL_FLAGS)"; \
+ $(GACUTIL) -u $(POLICY) $(GACUTIL_FLAGS) || exit 1;
$(TEST): $(ASSEMBLY) $(TEST_SOURCES)
$(CSC) -out:$(TEST) -target:library $(test_references) $(srcdir)/$(TEST_SOURCES)
all: $(TEST)
+
+$(POLICY).config: $(POLICY).config.in Makefile
+ sed -e "s|@ASSEMBLY_NAME@|$(ASSEMBLY_NAME)|" \
+ -e "s|@ASSEMBLY_VERSION@|$(ASSEMBLY_VERSION)|g" \
+ $< > $@
+
+$(DLLPOLICY): $(POLICY).config $(ASSEMBLY_NAME).snk Makefile
+ $(AL) -link:$(POLICY).config -out:$(DLLPOLICY) -keyfile:$(srcdir)/$(ASSEMBLY_NAME).snk
+
diff --git a/bindings/mono/Makefile.in b/bindings/mono/Makefile.in
index bb51068..7c36f5d 100644
--- a/bindings/mono/Makefile.in
+++ b/bindings/mono/Makefile.in
@@ -296,11 +296,31 @@ MIDDLE_API = libappindicator-api.middle
RAW_API = libappindicator-api.raw
METADATA = libappindicator-api.metadata
ASSEMBLY_NAME = appindicator-sharp
-ASSEMBLY = appindicator-sharp.dll
-TARGET = $(ASSEMBLY) $(ASSEMBLY).config
+ASSEMBLY_VERSION = 0.1.0.0
+ASSEMBLY = $(ASSEMBLY_NAME).dll
+POLICY = policy.$(POLICY_VERSION).$(ASSEMBLY_NAME)
+POLICY_VERSION = 0.0
+DLLPOLICY = $(POLICY).dll
+TARGET = \
+ $(ASSEMBLY) \
+ $(ASSEMBLY).config \
+ $(DLLPOLICY) \
+ $(POLICY).config
+
assemblydir = $(libdir)/cli/appindicator-sharp-0.1
assembly_DATA = $(TARGET)
-CLEANFILES = $(ASSEMBLY) $(ASSEMBLY).mdb generated-stamp generated/*.cs $(API) $(MIDDLE_API) $(RAW_API) $(TEST)
+CLEANFILES = \
+ $(ASSEMBLY) \
+ $(ASSEMBLY).mdb \
+ generated-stamp \
+ generated/*.cs \
+ $(API) \
+ $(MIDDLE_API) \
+ $(RAW_API) \
+ $(TEST) \
+ $(DLLPOLICY) \
+ $(POLICY).config
+
DISTCLEANFILES = $(ASSEMBLY).config
TEST_SOURCES = TestIndicator.cs
customs = ApplicationIndicator.custom
@@ -312,10 +332,11 @@ EXTRA_DIST = \
appindicator-sharp.dll.config.in \
app-indicator.sources.xml \
$(ASSEMBLY_NAME).snk \
+ $(POLICY).config.in \
$(customs) \
$(TEST_SOURCES)
-GACUTIL_FLAGS = "-package $(ASSEMBLY_NAME) -root $(DESTDIR)$(prefix)/lib"
+GACUTIL_FLAGS = -package $(ASSEMBLY_NAME) -root $(DESTDIR)$(prefix)/lib
references = $(GTK_SHARP_LIBS)
test_references = $(GTK_SHARP_LIBS) $(NUNIT_LIBS) -r:$(ASSEMBLY)
api_includes = $(GTK_SHARP_CFLAGS)
@@ -754,18 +775,30 @@ $(ASSEMBLY): generated-stamp $(srcdir)/AssemblyInfo.cs
$(CSC) $(CSFLAGS) -keyfile:$(srcdir)/$(ASSEMBLY_NAME).snk -nowarn:0169,0612,0618 -unsafe -out:$(ASSEMBLY) -target:library $(references) $(builddir)/$(GENERATED_SOURCES) $(srcdir)/AssemblyInfo.cs
install-data-local:
- echo "$(GACUTIL) -i $(ASSEMBLY_NAME).dll -package $(ASSEMBLY_NAME) -root $(DESTDIR)$(prefix)/lib"; \
- $(GACUTIL) -i $(ASSEMBLY_NAME).dll -package $(ASSEMBLY_NAME) -root $(DESTDIR)$(prefix)/lib || exit 1;
+ echo "$(GACUTIL) -i $(ASSEMBLY_NAME).dll $(GACUTIL_FLAGS)"; \
+ $(GACUTIL) -i $(ASSEMBLY_NAME).dll $(GACUTIL_FLAGS) || exit 1;
+ echo "$(GACUTIL) -i $(DLLPOLICY) $(GACUTIL_FLAGS)"; \
+ $(GACUTIL) -i $(DLLPOLICY) $(GACUTIL_FLAGS) || exit 1;
uninstall-local:
- echo "$(GACUTIL) -u $(ASSEMBLY_NAME) -package $(ASSEMBLY_NAME) -root $(DESTDIR)$(prefix)/lib"; \
- $(GACUTIL) -u $(ASSEMBLY_NAME) -package $(ASSEMBLY_NAME) -root $(DESTDIR)$(prefix)/lib || exit 1;
+ echo "$(GACUTIL) -u $(ASSEMBLY_NAME) $(GACUTIL_FLAGS)"; \
+ $(GACUTIL) -u $(ASSEMBLY_NAME) $(GACUTIL_FLAGS) || exit 1;
+ echo "$(GACUTIL) -u $(DLLPOLICY) $(GACUTIL_FLAGS)"; \
+ $(GACUTIL) -u $(POLICY) $(GACUTIL_FLAGS) || exit 1;
$(TEST): $(ASSEMBLY) $(TEST_SOURCES)
$(CSC) -out:$(TEST) -target:library $(test_references) $(srcdir)/$(TEST_SOURCES)
all: $(TEST)
+$(POLICY).config: $(POLICY).config.in Makefile
+ sed -e "s|@ASSEMBLY_NAME@|$(ASSEMBLY_NAME)|" \
+ -e "s|@ASSEMBLY_VERSION@|$(ASSEMBLY_VERSION)|g" \
+ $< > $@
+
+$(DLLPOLICY): $(POLICY).config $(ASSEMBLY_NAME).snk Makefile
+ $(AL) -link:$(POLICY).config -out:$(DLLPOLICY) -keyfile:$(srcdir)/$(ASSEMBLY_NAME).snk
+
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
.NOEXPORT:
diff --git a/bindings/mono/app-indicator.sources.xml b/bindings/mono/app-indicator.sources.xml
index 0d82430..2649eb4 100644
--- a/bindings/mono/app-indicator.sources.xml
+++ b/bindings/mono/app-indicator.sources.xml
@@ -2,10 +2,10 @@
<api filename="libappindicator-api.raw">
<library name="libappindicator.so.0">
<namespace name="AppIndicator">
- <directory path="../../src">
- <exclude>app-indicator-enum-types.h.in</exclude>
- <exclude>app-indicator-enum-types.c.in</exclude>
- </directory>
+ <file>../../src/app-indicator.c</file>
+ <file>../../src/app-indicator-enum-types.c</file>
+ <file>../../src/app-indicator-enum-types.h</file>
+ <file>../../src/app-indicator.h</file>
</namespace>
</library>
</api>
diff --git a/bindings/mono/libappindicator-api.raw b/bindings/mono/libappindicator-api.raw
index a42560c..1609613 100644
--- a/bindings/mono/libappindicator-api.raw
+++ b/bindings/mono/libappindicator-api.raw
@@ -19,182 +19,12 @@
<member cname="APP_INDICATOR_STATUS_ACTIVE" name="Active" />
<member cname="APP_INDICATOR_STATUS_ATTENTION" name="Attention" />
</enum>
- <callback name="OrgAyatanaIndicatorApplicationServiceGetApplicationsReply" cname="org_ayatana_indicator_application_service_get_applications_reply">
- <return-type type="void" />
- <parameters>
- <parameter type="DBusGProxy*" name="proxy" />
- <parameter type="GPtrArray*" name="OUT_applications" />
- <parameter type="GError*" name="error" />
- <parameter type="gpointer" name="userdata" />
- </parameters>
- </callback>
- <callback name="OrgFreedesktop_DBus_PropertiesGetAllReply" cname="org_freedesktop_DBus_Properties_get_all_reply">
- <return-type type="void" />
- <parameters>
- <parameter type="DBusGProxy*" name="proxy" />
- <parameter type="GHashTable*" name="OUT_Properties" />
- <parameter type="GError*" name="error" />
- <parameter type="gpointer" name="userdata" />
- </parameters>
- </callback>
- <callback name="OrgFreedesktop_DBus_PropertiesGetReply" cname="org_freedesktop_DBus_Properties_get_reply">
- <return-type type="void" />
- <parameters>
- <parameter type="DBusGProxy*" name="proxy" />
- <parameter type="GValue" name="OUT_Value" />
- <parameter type="GError*" name="error" />
- <parameter type="gpointer" name="userdata" />
- </parameters>
- </callback>
- <callback name="OrgFreedesktop_DBus_PropertiesSetReply" cname="org_freedesktop_DBus_Properties_set_reply">
- <return-type type="void" />
- <parameters>
- <parameter type="DBusGProxy*" name="proxy" />
- <parameter type="GError*" name="error" />
- <parameter type="gpointer" name="userdata" />
- </parameters>
- </callback>
- <callback name="OrgKde_StatusNotifierWatcherIsNotificationHostRegisteredReply" cname="org_kde_StatusNotifierWatcher_is_notification_host_registered_reply">
- <return-type type="void" />
- <parameters>
- <parameter type="DBusGProxy*" name="proxy" />
- <parameter type="gboolean" name="OUT_hasHost" />
- <parameter type="GError*" name="error" />
- <parameter type="gpointer" name="userdata" />
- </parameters>
- </callback>
- <callback name="OrgKde_StatusNotifierWatcherProtocolVersionReply" cname="org_kde_StatusNotifierWatcher_protocol_version_reply">
- <return-type type="void" />
- <parameters>
- <parameter type="DBusGProxy*" name="proxy" />
- <parameter type="char*" name="OUT_version" />
- <parameter type="GError*" name="error" />
- <parameter type="gpointer" name="userdata" />
- </parameters>
- </callback>
- <callback name="OrgKde_StatusNotifierWatcherRegisterNotificationHostReply" cname="org_kde_StatusNotifierWatcher_register_notification_host_reply">
- <return-type type="void" />
- <parameters>
- <parameter type="DBusGProxy*" name="proxy" />
- <parameter type="GError*" name="error" />
- <parameter type="gpointer" name="userdata" />
- </parameters>
- </callback>
- <callback name="OrgKde_StatusNotifierWatcherRegisterStatusNotifierItemReply" cname="org_kde_StatusNotifierWatcher_register_status_notifier_item_reply">
- <return-type type="void" />
- <parameters>
- <parameter type="DBusGProxy*" name="proxy" />
- <parameter type="GError*" name="error" />
- <parameter type="gpointer" name="userdata" />
- </parameters>
- </callback>
- <callback name="OrgKde_StatusNotifierWatcherRegisteredStatusNotifierItemsReply" cname="org_kde_StatusNotifierWatcher_registered_status_notifier_items_reply">
- <return-type type="void" />
- <parameters>
- <parameter type="DBusGProxy*" name="proxy" />
- <parameter type="char*" name="*" />
- <parameter type="GError*" name="error" />
- <parameter type="gpointer" name="userdata" />
- </parameters>
- </callback>
- <object name="ApplicationServiceAppstore" cname="ApplicationServiceAppstore" parent="GObject">
- <signal name="ApplicationAdded" cname="application-added" when="LAST" field_name="application_added">
- <return-type type="void" />
- <parameters>
- <parameter type="ApplicationServiceAppstore*" name="appstore" />
- <parameter type="gchar*" name="arg2" />
- <parameter type="gint" name="arg3" />
- <parameter type="gchar*" name="arg4" />
- <parameter type="gchar*" name="arg5" />
- <parameter type="gpointer" name="arg6" />
- </parameters>
- </signal>
- <signal name="ApplicationRemoved" cname="application-removed" when="LAST" field_name="application_removed">
- <return-type type="void" />
- <parameters>
- <parameter type="ApplicationServiceAppstore*" name="appstore" />
- <parameter type="gint" name="arg2" />
- <parameter type="gpointer" name="arg3" />
- </parameters>
- </signal>
- <signal name="ApplicationIconChanged" cname="application-icon-changed" when="LAST" field_name="application_icon_changed">
- <return-type type="void" />
- <parameters>
- <parameter type="ApplicationServiceAppstore*" name="appstore" />
- <parameter type="gint" name="arg2" />
- <parameter type="const-gchar*" name="arg3" />
- <parameter type="gpointer" name="arg4" />
- </parameters>
- </signal>
- <method name="ApplicationAdd" cname="application_service_appstore_application_add">
- <return-type type="void" />
- <parameters>
- <parameter type="const-gchar*" name="dbus_name" />
- <parameter type="const-gchar*" name="dbus_object" />
- </parameters>
- </method>
- <method name="ApplicationRemove" cname="application_service_appstore_application_remove">
- <return-type type="void" />
- <parameters>
- <parameter type="const-gchar*" name="dbus_name" />
- <parameter type="const-gchar*" name="dbus_object" />
- </parameters>
- </method>
- <method name="GetType" cname="application_service_appstore_get_type" shared="true">
- <return-type type="GType" />
- </method>
- <constructor cname="application_service_appstore_new">
- <parameters>
- <parameter type="AppLruFile*" name="lrufile" />
- </parameters>
- </constructor>
- </object>
- <object name="ApplicationServiceWatcher" cname="ApplicationServiceWatcher" parent="GObject">
- <signal name="ServiceRegistered" cname="service-registered" when="LAST" field_name="service_registered">
- <return-type type="void" />
- <parameters>
- <parameter type="ApplicationServiceWatcher*" name="watcher" />
- <parameter type="gchar*" name="object" />
- <parameter type="gpointer" name="data" />
- </parameters>
- </signal>
- <signal name="ServiceUnregistered" cname="service-unregistered" when="LAST" field_name="service_unregistered">
- <return-type type="void" />
- <parameters>
- <parameter type="ApplicationServiceWatcher*" name="watcher" />
- <parameter type="gchar*" name="object" />
- <parameter type="gpointer" name="data" />
- </parameters>
- </signal>
- <signal name="NotificationHostRegistered" cname="notification-host-registered" when="LAST" field_name="notification_host_registered">
- <return-type type="void" />
- <parameters>
- <parameter type="ApplicationServiceWatcher*" name="watcher" />
- <parameter type="gpointer" name="data" />
- </parameters>
- </signal>
- <signal name="NotificationHostUnregistered" cname="notification-host-unregistered" when="LAST" field_name="notification_host_unregistered">
- <return-type type="void" />
- <parameters>
- <parameter type="ApplicationServiceWatcher*" name="watcher" />
- <parameter type="gpointer" name="data" />
- </parameters>
- </signal>
- <method name="GetType" cname="application_service_watcher_get_type" shared="true">
- <return-type type="GType" />
- </method>
- <constructor cname="application_service_watcher_new">
- <parameters>
- <parameter type="ApplicationServiceAppstore*" name="appstore" />
- </parameters>
- </constructor>
- </object>
<object name="AppIndicator" cname="AppIndicator" parent="GObject">
<field name="Priv" cname="priv" type="AppIndicatorPrivate*" />
<property name="PROP_ID_S" cname="PROP_ID_S" type="gchar*" readable="true" writeable="true" construct-only="true" />
<property name="PROP_CATEGORY_S" cname="PROP_CATEGORY_S" type="gchar*" readable="true" writeable="true" construct-only="true" />
<property name="PROP_STATUS_S" cname="PROP_STATUS_S" type="gchar*" readable="true" writeable="true" />
- <property name="PROP_ICON_NAME_S" cname="PROP_ICON_NAME_S" type="gchar*" readable="true" writeable="true" construct="true" />
+ <property name="PROP_ICON_NAME_S" cname="PROP_ICON_NAME_S" type="gchar*" readable="true" writeable="true" />
<property name="PROP_ATTENTION_ICON_NAME_S" cname="PROP_ATTENTION_ICON_NAME_S" type="gchar*" readable="true" writeable="true" />
<property name="PROP_ICON_THEME_PATH_S" cname="PROP_ICON_THEME_PATH_S" type="gchar*" readable="true" writeable="true" construct-only="true" />
<property name="PROP_MENU_S" cname="PROP_MENU_S" type="DbusGObjectPath" readable="true" />
@@ -303,25 +133,5 @@
</parameters>
</method>
</object>
- <object name="AppLruFile" cname="AppLruFile" parent="GObject">
- <method name="GetType" cname="app_lru_file_get_type" shared="true">
- <return-type type="GType" />
- </method>
- <constructor cname="app_lru_file_new" />
- <method name="Sort" cname="app_lru_file_sort">
- <return-type type="gint" />
- <parameters>
- <parameter type="const-gchar*" name="id_a" />
- <parameter type="const-gchar*" name="id_b" />
- </parameters>
- </method>
- <method name="Touch" cname="app_lru_file_touch">
- <return-type type="void" />
- <parameters>
- <parameter type="const-gchar*" name="id" />
- <parameter type="const-gchar*" name="category" />
- </parameters>
- </method>
- </object>
</namespace>
</api> \ No newline at end of file
diff --git a/bindings/mono/policy.0.0.appindicator-sharp.config.in b/bindings/mono/policy.0.0.appindicator-sharp.config.in
new file mode 100644
index 0000000..95c21ed
--- /dev/null
+++ b/bindings/mono/policy.0.0.appindicator-sharp.config.in
@@ -0,0 +1,10 @@
+<configuration>
+ <runtime>
+ <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
+ <dependentAssembly>
+ <assemblyIdentity name="@ASSEMBLY_NAME@" publicKeyToken="bcae265d1c7ab4c2" />
+ <bindingRedirect oldVersion="0.0.0.0-@ASSEMBLY_VERSION@" newVersion="@ASSEMBLY_VERSION@"/>
+ </dependentAssembly>
+ </assemblyBinding>
+ </runtime>
+</configuration>