[evolution-data-server] Let Camel build its .typelib for the introspection



commit 8d0e29580793ca9dbad6953848177e6f8eacf8e0
Author: Milan Crha <mcrha redhat com>
Date:   Fri Dec 9 12:03:25 2016 +0100

    Let Camel build its .typelib for the introspection
    
    This is related to bug 772459, where the g-ir-compiler crashed
    due to unnamed structures being used inside CamelCipherValidity
    structure. With that fixed the Camel's .gir file can be used on
    appropriate places, which fixes some other warnings, namely
    from the EDataServer .gir generation.

 src/addressbook/libebook-contacts/CMakeLists.txt |    1 +
 src/addressbook/libebook/CMakeLists.txt          |    2 ++
 src/camel/CMakeLists.txt                         |    5 -----
 src/camel/camel-cipher-context.h                 |    4 ++--
 src/libedataserver/CMakeLists.txt                |    4 +++-
 src/vala/CMakeLists.txt                          |    3 +++
 6 files changed, 11 insertions(+), 8 deletions(-)
---
diff --git a/src/addressbook/libebook-contacts/CMakeLists.txt 
b/src/addressbook/libebook-contacts/CMakeLists.txt
index 559e212..2c82e9b 100644
--- a/src/addressbook/libebook-contacts/CMakeLists.txt
+++ b/src/addressbook/libebook-contacts/CMakeLists.txt
@@ -148,6 +148,7 @@ set(gir_libs
        edataserver
 )
 set(gir_deps
+       ${CMAKE_BINARY_DIR}/src/camel/Camel-${API_VERSION}.gir
        ${CMAKE_BINARY_DIR}/src/libedataserver/EDataServer-${API_VERSION}.gir
 )
 
diff --git a/src/addressbook/libebook/CMakeLists.txt b/src/addressbook/libebook/CMakeLists.txt
index 49d3ea6..ffb725a 100644
--- a/src/addressbook/libebook/CMakeLists.txt
+++ b/src/addressbook/libebook/CMakeLists.txt
@@ -107,12 +107,14 @@ set(gir_libdirs
        ${CMAKE_BINARY_DIR}/src/addressbook/libedata-book
 )
 set(gir_libs
+       camel
        ebook
        ebook-contacts
        edata-book
        edataserver
 )
 set(gir_deps
+       ${CMAKE_BINARY_DIR}/src/camel/Camel-${API_VERSION}.gir
        ${CMAKE_BINARY_DIR}/src/libedataserver/EDataServer-${API_VERSION}.gir
        ${CMAKE_BINARY_DIR}/src/addressbook/libebook-contacts/EBookContacts-${API_VERSION}.gir
 )
diff --git a/src/camel/CMakeLists.txt b/src/camel/CMakeLists.txt
index 82e164f..b105f40 100644
--- a/src/camel/CMakeLists.txt
+++ b/src/camel/CMakeLists.txt
@@ -329,11 +329,6 @@ set(gir_libdirs)
 set(gir_libs camel)
 set(gir_deps)
 
-# Remove the below set() once the typelib will be buildable; the gi-r-compiler crashes with
-#    ERROR:girepository/girparser.c:343:state_switch: assertion failed: (ctx->state != newstate)
-gir_construct_names(Camel ${API_VERSION} camel_gir_name camel_gir_vars_prefix)
-set(${camel_gir_vars_prefix}_SKIP_TYPELIB ON)
-
 gir_add_introspection_simple(
        Camel
        camel
diff --git a/src/camel/camel-cipher-context.h b/src/camel/camel-cipher-context.h
index 6ad74b6..88783b2 100644
--- a/src/camel/camel-cipher-context.h
+++ b/src/camel/camel-cipher-context.h
@@ -123,13 +123,13 @@ struct _CamelCipherCertInfo {
 struct _CamelCipherValidity {
        GQueue children;
 
-       struct {
+       struct _sign {
                CamelCipherValiditySign status;
                gchar *description;
                GQueue signers; /* CamelCipherCertInfo's */
        } sign;
 
-       struct {
+       struct _encrypt {
                CamelCipherValidityEncrypt status;
                gchar *description;
                GQueue encrypters;      /* CamelCipherCertInfo's */
diff --git a/src/libedataserver/CMakeLists.txt b/src/libedataserver/CMakeLists.txt
index 7762523..8e26b83 100644
--- a/src/libedataserver/CMakeLists.txt
+++ b/src/libedataserver/CMakeLists.txt
@@ -281,7 +281,9 @@ set(gir_libs
        camel
        edataserver
 )
-set(gir_deps)
+set(gir_deps
+       ${CMAKE_BINARY_DIR}/src/camel/Camel-${API_VERSION}.gir
+)
 
 gir_filter_out_sources(gir_sources e-sexp.h)
 gir_filter_out_sources(gir_sources -private.h)
diff --git a/src/vala/CMakeLists.txt b/src/vala/CMakeLists.txt
index 04439ce..dd2d371 100644
--- a/src/vala/CMakeLists.txt
+++ b/src/vala/CMakeLists.txt
@@ -52,6 +52,7 @@ add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/libedataserver-${API_VERSI
        COMMAND ${VAPIGEN}
                --vapidir=${CMAKE_CURRENT_SOURCE_DIR}
                --vapidir=${CMAKE_CURRENT_BINARY_DIR}
+               --girdir=${CMAKE_BINARY_DIR}/src/camel
                --girdir=${CMAKE_BINARY_DIR}/src/libedataserver
                --pkg gio-2.0
                --pkg libxml-2.0
@@ -78,6 +79,7 @@ add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/libebook-contacts-${API_VE
        COMMAND ${VAPIGEN}
                --vapidir=${CMAKE_CURRENT_SOURCE_DIR}
                --vapidir=${CMAKE_CURRENT_BINARY_DIR}
+               --girdir=${CMAKE_BINARY_DIR}/src/camel
                --girdir=${CMAKE_BINARY_DIR}/src/libedataserver
                --pkg libedataserver-${API_VERSION}
                --pkg gio-2.0
@@ -108,6 +110,7 @@ add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/libebook-${API_VERSION}.va
        COMMAND ${VAPIGEN}
                --vapidir=${CMAKE_CURRENT_SOURCE_DIR}
                --vapidir=${CMAKE_CURRENT_BINARY_DIR}
+               --girdir=${CMAKE_BINARY_DIR}/src/camel
                --girdir=${CMAKE_BINARY_DIR}/src/libedataserver
                --girdir=${CMAKE_BINARY_DIR}/src/addressbook/libebook-contacts
                --pkg libedataserver-${API_VERSION}


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]