[evolution-data-server/wip/mcrha/libical-glib] Add introspection and vala definitions for libedata-cal
- From: Milan Crha <mcrha src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution-data-server/wip/mcrha/libical-glib] Add introspection and vala definitions for libedata-cal
- Date: Tue, 12 Feb 2019 17:08:59 +0000 (UTC)
commit 9c9bdf2f86d54d21cc90738e303f084313ff4bb2
Author: Milan Crha <mcrha redhat com>
Date: Tue Feb 12 18:08:57 2019 +0100
Add introspection and vala definitions for libedata-cal
Also correct vala for libecal, to be built.
src/calendar/libedata-cal/CMakeLists.txt | 42 +++++++++++++++++++++++++++++++-
src/vala/CMakeLists.txt | 36 +++++++++++++++++++++++++++
src/vala/EDataCal-2.0.metadata | 0
src/vala/libedata-cal-2.0.deps | 3 +++
4 files changed, 80 insertions(+), 1 deletion(-)
---
diff --git a/src/calendar/libedata-cal/CMakeLists.txt b/src/calendar/libedata-cal/CMakeLists.txt
index f7ccef3b5..9132e4dd8 100644
--- a/src/calendar/libedata-cal/CMakeLists.txt
+++ b/src/calendar/libedata-cal/CMakeLists.txt
@@ -89,6 +89,45 @@ install(FILES ${HEADERS}
DESTINATION ${privincludedir}/libedata-cal
)
+set(gir_sources ${SOURCES} ${HEADERS})
+set(gir_identifies_prefixes EDataCal ECal)
+set(gir_includes GObject-2.0 Gio-2.0 Soup-2.4 libxml2-2.0 ICalGLib-3.0)
+set(gir_cflags
+ -DLIBEDATA_CAL_COMPILATION
+ -I${CMAKE_BINARY_DIR}/src/calendar
+ -I${CMAKE_SOURCE_DIR}/src/calendar
+)
+set(gir_libdirs
+ ${CMAKE_BINARY_DIR}/src/camel
+ ${CMAKE_BINARY_DIR}/src/libedataserver
+ ${CMAKE_BINARY_DIR}/src/calendar/libecal
+ ${CMAKE_BINARY_DIR}/src/calendar/libedata-cal
+)
+set(gir_libs
+ ecal
+ edata-cal
+ 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/calendar/libecal/ECal-${CAL_API_VERSION}.gir
+)
+
+gir_add_introspection_simple(
+ EDataCal
+ libedata-cal
+ ${CAL_API_VERSION}
+ "libedata-cal/libdata-ecal.h"
+ gir_identifies_prefixes
+ gir_includes
+ gir_cflags
+ gir_libdirs
+ gir_libs
+ gir_deps
+ gir_sources
+)
+
set(DEPENDENCIES
ebackend
edataserver
@@ -97,7 +136,8 @@ set(DEPENDENCIES
)
add_executable(evolution-calendar-factory-subprocess
- evolution-calendar-factory-subprocess.c)
+ evolution-calendar-factory-subprocess.c
+)
target_compile_definitions(evolution-calendar-factory-subprocess PRIVATE
-DG_LOG_DOMAIN=\"evolution-calendar-factory-subprocess\"
diff --git a/src/vala/CMakeLists.txt b/src/vala/CMakeLists.txt
index 0eaf6e07f..a16b4ef3e 100644
--- a/src/vala/CMakeLists.txt
+++ b/src/vala/CMakeLists.txt
@@ -7,6 +7,10 @@ set(valafiles
${CMAKE_CURRENT_BINARY_DIR}/libebook-${API_VERSION}.vapi
${CMAKE_CURRENT_SOURCE_DIR}/libebook-contacts-${API_VERSION}.deps
${CMAKE_CURRENT_BINARY_DIR}/libebook-contacts-${API_VERSION}.vapi
+ ${CMAKE_CURRENT_SOURCE_DIR}/libecal-${CAL_API_VERSION}.deps
+ ${CMAKE_CURRENT_BINARY_DIR}/libecal-${CAL_API_VERSION}.vapi
+ ${CMAKE_CURRENT_SOURCE_DIR}/libedata-cal-${CAL_API_VERSION}.deps
+ ${CMAKE_CURRENT_BINARY_DIR}/libedata-cal-${CAL_API_VERSION}.vapi
)
if(HAVE_GTK)
@@ -196,6 +200,38 @@ add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/libecal-${CAL_API_VERSION}
${gir_deps}
)
+# ***********************************
+# libedata-cal
+# ***********************************
+
+set(gir_fullname ${CMAKE_BINARY_DIR}/src/calendar/libedata-cal/EDataCal-${CAL_API_VERSION}.gir)
+gir_girfilename_to_target(gir_deps EDataCal-${CAL_API_VERSION}.gir)
+
+add_dependencies(vala ${gir_deps})
+
+add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/libedata-cal-${CAL_API_VERSION}.vapi
+ 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/calendar/libecal
+ --pkg libedataserver-${API_VERSION}
+ --pkg libecal-${CAL_API_VERSION}
+ --pkg gio-2.0
+ --pkg libxml-2.0
+ --pkg libsoup-2.4
+ --pkg posix
+ --library libedata-cal-${CAL_API_VERSION}
+ --metadatadir=${CMAKE_CURRENT_SOURCE_DIR}
+ ${gir_fullname}
+ DEPENDS libedata-cal-${CAL_API_VERSION}.deps
+ ${CMAKE_CURRENT_BINARY_DIR}/libedataserver-${API_VERSION}.vapi
+ ${CMAKE_CURRENT_BINARY_DIR}/libecal-${CAL_API_VERSION}.vapi
+ ${gir_fullname}
+ ${gir_deps}
+)
+
# ***********************************
# Install all VAPI files
# ***********************************
diff --git a/src/vala/EDataCal-2.0.metadata b/src/vala/EDataCal-2.0.metadata
new file mode 100644
index 000000000..e69de29bb
diff --git a/src/vala/libedata-cal-2.0.deps b/src/vala/libedata-cal-2.0.deps
new file mode 100644
index 000000000..1c0917349
--- /dev/null
+++ b/src/vala/libedata-cal-2.0.deps
@@ -0,0 +1,3 @@
+libecal-2.0
+libxml-2.0
+gio-2.0
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]