geary/src/CMakeLists.txt

496 lines
14 KiB
Text
Raw Normal View History

# Geary build script
# Copyright 2011-2012 Yorba Foundation
set(COMMON_SRC
common/common-arrays.vala
common/common-async.vala
common/common-date.vala
common/common-files.vala
common/common-international.vala
common/common-yorba-application.vala
)
set(ENGINE_SRC
engine/abstract/geary-abstract-account.vala
engine/abstract/geary-abstract-folder.vala
engine/api/geary-account.vala
engine/api/geary-account-information.vala
Remove SQLHeavy: Closes #5034 It is done. Initial implementation of the new database subsystem These pieces represent the foundation for ticket #5034 Expanded transactions, added VersionedDatabase Further expansions of the async code. Moved async pool logic into Database, where it realistically belongs. Further improvements. Introduced geary-db-test. Added SQL create and update files for Geary.Db version-001 to version-003 are exact copies of the SQLHeavy scripts to ensure no slight changes when migrating. version-004 upgrades the database to remove the ImapFolderPropertiesTable and ImapMessagePropertiesTable, now that the database code is pure IMAP. When we support other messaging systems (such as POP3), those subsystems will need to code their own database layers OR rely on the IMAP schema and simply ignore the IMAP-specific fields. ImapDB.Account fleshed out ImapDB.Folder is commented out, however. Need to port next. ImapDB.Folder fleshed out MessageTable, MessageLocationTable, and AttachementTable are now handled inside ImapDB.Folder. chmod -x imap-db-database.vala OutboxEmailIdentifier/Properties -> SmtpOutboxEmailIdentifier/Properties Moved SmtpOutboxFolderRoot into its own source file SmtpOutboxFolder ported to new database code Move Engine implementations to ImapDB. Integration and cleanup of new database code with main source This commit performs the final integration steps to move Geary completely over to the new database model. This also cleans out the old SQLHeavy-based code and fixes a handful of small bugs that were detected during basic test runs. Moved Outbox to ImapDB As the Outbox is tied to the database that ImapDB runs, move the Outbox code into that folder. Outbox fixes and better parameter checking Bumped Database thread pool count and made them exclusive My reasoning is that there may be a need for a lot of threads at once (when a big batch of commands comes in, especially at startup). If performance looks ok, we might consider relaxing this later.
2012-06-14 14:47:53 -07:00
engine/api/geary-account-settings.vala
engine/api/geary-attachment.vala
engine/api/geary-composed-email.vala
engine/api/geary-contact.vala
engine/api/geary-contact-importance.vala
engine/api/geary-contact-store.vala
engine/api/geary-conversation.vala
engine/api/geary-conversation-monitor.vala
engine/api/geary-credentials.vala
engine/api/geary-email-flag.vala
engine/api/geary-email-flags.vala
engine/api/geary-email-identifier.vala
engine/api/geary-email-properties.vala
engine/api/geary-email.vala
engine/api/geary-endpoint.vala
engine/api/geary-engine-account.vala
engine/api/geary-engine-error.vala
engine/api/geary-engine.vala
engine/api/geary-folder.vala
engine/api/geary-folder-path.vala
engine/api/geary-folder-supports-archive.vala
engine/api/geary-folder-supports-copy.vala
engine/api/geary-folder-supports-create.vala
engine/api/geary-folder-supports-mark.vala
engine/api/geary-folder-supports-move.vala
engine/api/geary-folder-supports-remove.vala
engine/api/geary-logging.vala
engine/api/geary-service-provider.vala
engine/api/geary-special-folder-type.vala
engine/common/common-message-data.vala
Remove SQLHeavy: Closes #5034 It is done. Initial implementation of the new database subsystem These pieces represent the foundation for ticket #5034 Expanded transactions, added VersionedDatabase Further expansions of the async code. Moved async pool logic into Database, where it realistically belongs. Further improvements. Introduced geary-db-test. Added SQL create and update files for Geary.Db version-001 to version-003 are exact copies of the SQLHeavy scripts to ensure no slight changes when migrating. version-004 upgrades the database to remove the ImapFolderPropertiesTable and ImapMessagePropertiesTable, now that the database code is pure IMAP. When we support other messaging systems (such as POP3), those subsystems will need to code their own database layers OR rely on the IMAP schema and simply ignore the IMAP-specific fields. ImapDB.Account fleshed out ImapDB.Folder is commented out, however. Need to port next. ImapDB.Folder fleshed out MessageTable, MessageLocationTable, and AttachementTable are now handled inside ImapDB.Folder. chmod -x imap-db-database.vala OutboxEmailIdentifier/Properties -> SmtpOutboxEmailIdentifier/Properties Moved SmtpOutboxFolderRoot into its own source file SmtpOutboxFolder ported to new database code Move Engine implementations to ImapDB. Integration and cleanup of new database code with main source This commit performs the final integration steps to move Geary completely over to the new database model. This also cleans out the old SQLHeavy-based code and fixes a handful of small bugs that were detected during basic test runs. Moved Outbox to ImapDB As the Outbox is tied to the database that ImapDB runs, move the Outbox code into that folder. Outbox fixes and better parameter checking Bumped Database thread pool count and made them exclusive My reasoning is that there may be a need for a lot of threads at once (when a big batch of commands comes in, especially at startup). If performance looks ok, we might consider relaxing this later.
2012-06-14 14:47:53 -07:00
engine/db/db.vala
engine/db/db-connection.vala
engine/db/db-context.vala
engine/db/db-database.vala
engine/db/db-database-error.vala
Remove SQLHeavy: Closes #5034 It is done. Initial implementation of the new database subsystem These pieces represent the foundation for ticket #5034 Expanded transactions, added VersionedDatabase Further expansions of the async code. Moved async pool logic into Database, where it realistically belongs. Further improvements. Introduced geary-db-test. Added SQL create and update files for Geary.Db version-001 to version-003 are exact copies of the SQLHeavy scripts to ensure no slight changes when migrating. version-004 upgrades the database to remove the ImapFolderPropertiesTable and ImapMessagePropertiesTable, now that the database code is pure IMAP. When we support other messaging systems (such as POP3), those subsystems will need to code their own database layers OR rely on the IMAP schema and simply ignore the IMAP-specific fields. ImapDB.Account fleshed out ImapDB.Folder is commented out, however. Need to port next. ImapDB.Folder fleshed out MessageTable, MessageLocationTable, and AttachementTable are now handled inside ImapDB.Folder. chmod -x imap-db-database.vala OutboxEmailIdentifier/Properties -> SmtpOutboxEmailIdentifier/Properties Moved SmtpOutboxFolderRoot into its own source file SmtpOutboxFolder ported to new database code Move Engine implementations to ImapDB. Integration and cleanup of new database code with main source This commit performs the final integration steps to move Geary completely over to the new database model. This also cleans out the old SQLHeavy-based code and fixes a handful of small bugs that were detected during basic test runs. Moved Outbox to ImapDB As the Outbox is tied to the database that ImapDB runs, move the Outbox code into that folder. Outbox fixes and better parameter checking Bumped Database thread pool count and made them exclusive My reasoning is that there may be a need for a lot of threads at once (when a big batch of commands comes in, especially at startup). If performance looks ok, we might consider relaxing this later.
2012-06-14 14:47:53 -07:00
engine/db/db-result.vala
engine/db/db-statement.vala
engine/db/db-synchronous-mode.vala
engine/db/db-transaction-async-job.vala
engine/db/db-transaction-outcome.vala
engine/db/db-transaction-type.vala
engine/db/db-versioned-database.vala
engine/imap/api/imap-account.vala
engine/imap/api/imap-email-flags.vala
engine/imap/api/imap-email-identifier.vala
engine/imap/api/imap-email-properties.vala
engine/imap/api/imap-folder-properties.vala
engine/imap/api/imap-folder.vala
engine/imap/command/imap-command-response.vala
engine/imap/command/imap-commands.vala
engine/imap/command/imap-command.vala
engine/imap/command/imap-fetch-command.vala
engine/imap/decoders/imap-capabilities.vala
engine/imap/decoders/imap-capability-results.vala
engine/imap/decoders/imap-command-results.vala
engine/imap/decoders/imap-fetch-data-decoder.vala
engine/imap/decoders/imap-fetch-results.vala
engine/imap/decoders/imap-list-results.vala
engine/imap/decoders/imap-select-examine-results.vala
engine/imap/decoders/imap-status-results.vala
engine/imap/imap-error.vala
engine/imap/message/imap-data-format.vala
engine/imap/message/imap-fetch-data-type.vala
engine/imap/message/imap-fetch-body-data-type.vala
engine/imap/message/imap-flag.vala
engine/imap/message/imap-message-data.vala
engine/imap/message/imap-message-set.vala
engine/imap/message/imap-parameter.vala
engine/imap/message/imap-tag.vala
engine/imap/response/imap-continuation-response.vala
engine/imap/response/imap-response-code-type.vala
engine/imap/response/imap-response-code.vala
engine/imap/response/imap-server-data-type.vala
engine/imap/response/imap-server-data.vala
engine/imap/response/imap-server-response.vala
engine/imap/response/imap-status-data-type.vala
engine/imap/response/imap-status-response.vala
engine/imap/response/imap-status.vala
engine/imap/response/imap-unsolicited-server-data.vala
engine/imap/transport/imap-client-connection.vala
engine/imap/transport/imap-client-session-manager.vala
engine/imap/transport/imap-client-session.vala
engine/imap/transport/imap-deserializer.vala
engine/imap/transport/imap-mailbox.vala
engine/imap/transport/imap-serializable.vala
engine/imap/transport/imap-serializer.vala
Remove SQLHeavy: Closes #5034 It is done. Initial implementation of the new database subsystem These pieces represent the foundation for ticket #5034 Expanded transactions, added VersionedDatabase Further expansions of the async code. Moved async pool logic into Database, where it realistically belongs. Further improvements. Introduced geary-db-test. Added SQL create and update files for Geary.Db version-001 to version-003 are exact copies of the SQLHeavy scripts to ensure no slight changes when migrating. version-004 upgrades the database to remove the ImapFolderPropertiesTable and ImapMessagePropertiesTable, now that the database code is pure IMAP. When we support other messaging systems (such as POP3), those subsystems will need to code their own database layers OR rely on the IMAP schema and simply ignore the IMAP-specific fields. ImapDB.Account fleshed out ImapDB.Folder is commented out, however. Need to port next. ImapDB.Folder fleshed out MessageTable, MessageLocationTable, and AttachementTable are now handled inside ImapDB.Folder. chmod -x imap-db-database.vala OutboxEmailIdentifier/Properties -> SmtpOutboxEmailIdentifier/Properties Moved SmtpOutboxFolderRoot into its own source file SmtpOutboxFolder ported to new database code Move Engine implementations to ImapDB. Integration and cleanup of new database code with main source This commit performs the final integration steps to move Geary completely over to the new database model. This also cleans out the old SQLHeavy-based code and fixes a handful of small bugs that were detected during basic test runs. Moved Outbox to ImapDB As the Outbox is tied to the database that ImapDB runs, move the Outbox code into that folder. Outbox fixes and better parameter checking Bumped Database thread pool count and made them exclusive My reasoning is that there may be a need for a lot of threads at once (when a big batch of commands comes in, especially at startup). If performance looks ok, we might consider relaxing this later.
2012-06-14 14:47:53 -07:00
engine/imap-db/imap-db-account.vala
engine/imap-db/imap-db-contact.vala
Remove SQLHeavy: Closes #5034 It is done. Initial implementation of the new database subsystem These pieces represent the foundation for ticket #5034 Expanded transactions, added VersionedDatabase Further expansions of the async code. Moved async pool logic into Database, where it realistically belongs. Further improvements. Introduced geary-db-test. Added SQL create and update files for Geary.Db version-001 to version-003 are exact copies of the SQLHeavy scripts to ensure no slight changes when migrating. version-004 upgrades the database to remove the ImapFolderPropertiesTable and ImapMessagePropertiesTable, now that the database code is pure IMAP. When we support other messaging systems (such as POP3), those subsystems will need to code their own database layers OR rely on the IMAP schema and simply ignore the IMAP-specific fields. ImapDB.Account fleshed out ImapDB.Folder is commented out, however. Need to port next. ImapDB.Folder fleshed out MessageTable, MessageLocationTable, and AttachementTable are now handled inside ImapDB.Folder. chmod -x imap-db-database.vala OutboxEmailIdentifier/Properties -> SmtpOutboxEmailIdentifier/Properties Moved SmtpOutboxFolderRoot into its own source file SmtpOutboxFolder ported to new database code Move Engine implementations to ImapDB. Integration and cleanup of new database code with main source This commit performs the final integration steps to move Geary completely over to the new database model. This also cleans out the old SQLHeavy-based code and fixes a handful of small bugs that were detected during basic test runs. Moved Outbox to ImapDB As the Outbox is tied to the database that ImapDB runs, move the Outbox code into that folder. Outbox fixes and better parameter checking Bumped Database thread pool count and made them exclusive My reasoning is that there may be a need for a lot of threads at once (when a big batch of commands comes in, especially at startup). If performance looks ok, we might consider relaxing this later.
2012-06-14 14:47:53 -07:00
engine/imap-db/imap-db-database.vala
engine/imap-db/imap-db-folder.vala
engine/imap-db/imap-db-message-addresses.vala
Remove SQLHeavy: Closes #5034 It is done. Initial implementation of the new database subsystem These pieces represent the foundation for ticket #5034 Expanded transactions, added VersionedDatabase Further expansions of the async code. Moved async pool logic into Database, where it realistically belongs. Further improvements. Introduced geary-db-test. Added SQL create and update files for Geary.Db version-001 to version-003 are exact copies of the SQLHeavy scripts to ensure no slight changes when migrating. version-004 upgrades the database to remove the ImapFolderPropertiesTable and ImapMessagePropertiesTable, now that the database code is pure IMAP. When we support other messaging systems (such as POP3), those subsystems will need to code their own database layers OR rely on the IMAP schema and simply ignore the IMAP-specific fields. ImapDB.Account fleshed out ImapDB.Folder is commented out, however. Need to port next. ImapDB.Folder fleshed out MessageTable, MessageLocationTable, and AttachementTable are now handled inside ImapDB.Folder. chmod -x imap-db-database.vala OutboxEmailIdentifier/Properties -> SmtpOutboxEmailIdentifier/Properties Moved SmtpOutboxFolderRoot into its own source file SmtpOutboxFolder ported to new database code Move Engine implementations to ImapDB. Integration and cleanup of new database code with main source This commit performs the final integration steps to move Geary completely over to the new database model. This also cleans out the old SQLHeavy-based code and fixes a handful of small bugs that were detected during basic test runs. Moved Outbox to ImapDB As the Outbox is tied to the database that ImapDB runs, move the Outbox code into that folder. Outbox fixes and better parameter checking Bumped Database thread pool count and made them exclusive My reasoning is that there may be a need for a lot of threads at once (when a big batch of commands comes in, especially at startup). If performance looks ok, we might consider relaxing this later.
2012-06-14 14:47:53 -07:00
engine/imap-db/imap-db-message-row.vala
engine/imap-db/outbox/smtp-outbox-email-identifier.vala
engine/imap-db/outbox/smtp-outbox-email-properties.vala
engine/imap-db/outbox/smtp-outbox-folder.vala
engine/imap-db/outbox/smtp-outbox-folder-root.vala
engine/imap-engine/imap-engine-batch-operations.vala
engine/imap-engine/imap-engine-email-flag-watcher.vala
engine/imap-engine/imap-engine-email-prefetcher.vala
engine/imap-engine/imap-engine-generic-account.vala
engine/imap-engine/imap-engine-generic-folder.vala
engine/imap-engine/imap-engine-receive-replay-operation.vala
engine/imap-engine/imap-engine-replay-operation.vala
engine/imap-engine/imap-engine-replay-queue.vala
engine/imap-engine/imap-engine-send-replay-operation.vala
engine/imap-engine/gmail/imap-engine-gmail-account.vala
engine/imap-engine/gmail/imap-engine-gmail-folder.vala
engine/imap-engine/other/imap-engine-other-account.vala
engine/imap-engine/other/imap-engine-other-folder.vala
engine/imap-engine/replay-ops/imap-engine-copy-email.vala
engine/imap-engine/replay-ops/imap-engine-expunge-email.vala
engine/imap-engine/replay-ops/imap-engine-fetch-email.vala
engine/imap-engine/replay-ops/imap-engine-list-email.vala
engine/imap-engine/replay-ops/imap-engine-list-email-by-id.vala
engine/imap-engine/replay-ops/imap-engine-list-email-by-sparse-id.vala
engine/imap-engine/replay-ops/imap-engine-mark-email.vala
engine/imap-engine/replay-ops/imap-engine-move-email.vala
engine/imap-engine/replay-ops/imap-engine-replay-append.vala
engine/imap-engine/replay-ops/imap-engine-replay-disconnect.vala
engine/imap-engine/replay-ops/imap-engine-replay-removal.vala
engine/imap-engine/yahoo/imap-engine-yahoo-account.vala
engine/imap-engine/yahoo/imap-engine-yahoo-folder.vala
engine/nonblocking/nonblocking-abstract-semaphore.vala
engine/nonblocking/nonblocking-batch.vala
engine/nonblocking/nonblocking-mailbox.vala
engine/nonblocking/nonblocking-mutex.vala
engine/nonblocking/nonblocking-variants.vala
engine/rfc822/rfc822-error.vala
2012-06-27 15:30:29 -07:00
engine/rfc822/rfc822-gmime-filter-flowed.vala
engine/rfc822/rfc822-mailbox-addresses.vala
engine/rfc822/rfc822-mailbox-address.vala
engine/rfc822/rfc822-message.vala
engine/rfc822/rfc822-message-data.vala
engine/rfc822/rfc822-utils.vala
engine/smtp/smtp-abstract-authenticator.vala
engine/smtp/smtp-authenticator.vala
engine/smtp/smtp-capabilities.vala
engine/smtp/smtp-client-connection.vala
engine/smtp/smtp-client-session.vala
engine/smtp/smtp-command.vala
engine/smtp/smtp-data-format.vala
engine/smtp/smtp-error.vala
engine/smtp/smtp-greeting.vala
engine/smtp/smtp-login-authenticator.vala
engine/smtp/smtp-plain-authenticator.vala
engine/smtp/smtp-request.vala
engine/smtp/smtp-response.vala
engine/smtp/smtp-response-code.vala
engine/smtp/smtp-response-line.vala
engine/state/state-machine-descriptor.vala
engine/state/state-machine.vala
engine/state/state-mapping.vala
engine/util/util-collection.vala
engine/util/util-converter.vala
engine/util/util-generic-capabilities.vala
engine/util/util-html.vala
engine/util/util-inet.vala
engine/util/util-interfaces.vala
engine/util/util-memory.vala
engine/util/util-numeric.vala
engine/util/util-reference-semantics.vala
engine/util/util-scheduler.vala
engine/util/util-singleton.vala
engine/util/util-stream.vala
engine/util/util-string.vala
engine/util/util-timer-pool.vala
engine/util/util-trillian.vala
)
set(CLIENT_SRC
client/geary-application.vala
client/geary-config.vala
client/geary-controller.vala
client/main.vala
client/notification/libindicate.vala
client/notification/new-messages-indicator.vala
client/notification/new-messages-monitor.vala
client/notification/notification-bubble.vala
client/notification/null-indicator.vala
client/notification/unity-launcher.vala
client/ui/composer-window.vala
client/ui/contact-entry-completion.vala
client/ui/geary-login.vala
client/ui/email-entry.vala
client/ui/icon-factory.vala
client/ui/folder-list.vala
client/ui/folder-menu.vala
client/ui/main-toolbar.vala
client/ui/main-window.vala
client/ui/message-list-cell-renderer.vala
client/ui/message-list-store.vala
client/ui/message-list-view.vala
client/ui/message-viewer.vala
client/ui/message-web-view.vala
client/ui/password-dialog.vala
client/ui/preferences-dialog.vala
client/ui/webview-edit-fixer.vala
client/ui/sidebar/sidebar-branch.vala
client/ui/sidebar/sidebar-common.vala
client/ui/sidebar/sidebar-entry.vala
client/ui/sidebar/sidebar-tree.vala
client/util/util-email.vala
client/util/util-gravatar.vala
client/util/util-keyring.vala
client/util/util-menu.vala
client/util/util-webkit.vala
)
set(CONSOLE_SRC
console/main.vala
)
set(MAILER_SRC
mailer/main.vala
)
set(DBUSSERVICE_SRC
dbusservice/controller.vala
dbusservice/database.vala
dbusservice/dbus-conversation.vala
dbusservice/dbus-conversations.vala
dbusservice/dbus-email.vala
dbusservice/main.vala
)
# Vala
find_package(Vala REQUIRED)
include(ValaVersion)
2012-08-07 11:52:36 -07:00
ensure_vala_version("0.17.4" MINIMUM)
include(ValaPrecompile)
# Packages
find_package(PkgConfig)
pkg_check_modules(LIBINDICATE QUIET indicate-0.7>=0.6.1)
if (LIBINDICATE_FOUND)
message(STATUS "Unity messaging menu support: ON")
set(EXTRA_CLIENT_PKG_CONFIG
${EXTRA_CLIENT_PKG_CONFIG}
indicate-0.7
)
set(EXTRA_CLIENT_PACKAGES
${EXTRA_CLIENT_PACKAGES}
Dbusmenu-0.4
Indicate-0.7
)
set(EXTRA_VALA_OPTIONS
${EXTRA_VALA_OPTIONS}
-D HAVE_LIBINDICATE
)
else ()
message(STATUS "Unity messaging menu support: OFF")
endif ()
pkg_check_modules(LIBUNITY QUIET unity>=5.12.0)
if (LIBUNITY_FOUND)
message(STATUS "Unity launcher support: ON")
set(EXTRA_CLIENT_PKG_CONFIG
${EXTRA_CLIENT_PKG_CONFIG}
unity
)
set(EXTRA_CLIENT_PACKAGES
${EXTRA_CLIENT_PACKAGES}
unity
)
set(EXTRA_VALA_OPTIONS
${EXTRA_VALA_OPTIONS}
-D HAVE_LIBUNITY
)
else ()
message(STATUS "Unity launcher support: OFF")
endif ()
pkg_check_modules(DEPS REQUIRED QUIET
gthread-2.0
glib-2.0>=2.30.0
gio-2.0>=2.28.0
gtk+-3.0>=3.2.0
gee-1.0>=0.6.0
unique-3.0>=3.0.0
libnotify>=0.7.5
libcanberra>=0.28
sqlite3>=3.7.4
2012-04-26 18:45:37 -07:00
gmime-2.6>=2.6.0
gnome-keyring-1>=3.2.2
2012-08-15 09:23:21 -07:00
webkitgtk-3.0>=1.8.0
${EXTRA_CLIENT_PKG_CONFIG}
)
set(ENGINE_PACKAGES
Remove SQLHeavy: Closes #5034 It is done. Initial implementation of the new database subsystem These pieces represent the foundation for ticket #5034 Expanded transactions, added VersionedDatabase Further expansions of the async code. Moved async pool logic into Database, where it realistically belongs. Further improvements. Introduced geary-db-test. Added SQL create and update files for Geary.Db version-001 to version-003 are exact copies of the SQLHeavy scripts to ensure no slight changes when migrating. version-004 upgrades the database to remove the ImapFolderPropertiesTable and ImapMessagePropertiesTable, now that the database code is pure IMAP. When we support other messaging systems (such as POP3), those subsystems will need to code their own database layers OR rely on the IMAP schema and simply ignore the IMAP-specific fields. ImapDB.Account fleshed out ImapDB.Folder is commented out, however. Need to port next. ImapDB.Folder fleshed out MessageTable, MessageLocationTable, and AttachementTable are now handled inside ImapDB.Folder. chmod -x imap-db-database.vala OutboxEmailIdentifier/Properties -> SmtpOutboxEmailIdentifier/Properties Moved SmtpOutboxFolderRoot into its own source file SmtpOutboxFolder ported to new database code Move Engine implementations to ImapDB. Integration and cleanup of new database code with main source This commit performs the final integration steps to move Geary completely over to the new database model. This also cleans out the old SQLHeavy-based code and fixes a handful of small bugs that were detected during basic test runs. Moved Outbox to ImapDB As the Outbox is tied to the database that ImapDB runs, move the Outbox code into that folder. Outbox fixes and better parameter checking Bumped Database thread pool count and made them exclusive My reasoning is that there may be a need for a lot of threads at once (when a big batch of commands comes in, especially at startup). If performance looks ok, we might consider relaxing this later.
2012-06-14 14:47:53 -07:00
glib-2.0 gee-1.0 gio-2.0 gmime-2.6 unique-3.0 posix sqlite3
)
set(CLIENT_PACKAGES
gtk+-3.0 gnome-keyring-1 webkitgtk-3.0 libnotify libcanberra ${EXTRA_CLIENT_PACKAGES}
)
set(CONSOLE_PACKAGES
gtk+-3.0
)
set(DBUSSERVICE_PACKAGES
gee-1.0 glib-2.0
)
set(GSETTINGS_DIR ${CMAKE_SOURCE_DIR}/src/client/misc)
set(CFLAGS
${DEPS_CFLAGS}
${DEPS_CFLAGS_OTHER}
-D_VERSION=\"${VERSION}\"
-D_INSTALL_PREFIX=\"${CMAKE_INSTALL_PREFIX}\"
-D_SOURCE_ROOT_DIR=\"${CMAKE_SOURCE_DIR}\"
-D_GSETTINGS_DIR=\"${CMAKE_BINARY_DIR}/gsettings\"
-DGETTEXT_PACKAGE=\"${GETTEXT_PACKAGE}\"
-DLANGUAGE_SUPPORT_DIRECTORY=\"${LANGUAGE_SUPPORT_DIRECTORY}\"
-g
)
set(LIB_PATHS ${DEPS_LIBRARY_DIRS})
link_directories(${LIB_PATHS})
add_definitions(${CFLAGS})
set(VALAC_OPTIONS
--vapidir=${CMAKE_SOURCE_DIR}/vapi
--thread
--enable-checking
--debug
--fatal-warnings
${EXTRA_VALA_OPTIONS}
)
# Engine (static library used for building)
#################################################
vala_precompile(ENGINE_VALA_C geary-static
${ENGINE_SRC}
${COMMON_SRC}
PACKAGES
${CONSOLE_PACKAGES}
${ENGINE_PACKAGES}
GENERATE_VAPI
geary-static
OPTIONS
${VALAC_OPTIONS}
)
add_library(geary-static STATIC ${ENGINE_VALA_C})
target_link_libraries(geary-static ${DEPS_LIBRARIES} gthread-2.0)
# Geary client app
#################################################
vala_precompile(GEARY_VALA_C geary
${CLIENT_SRC}
PACKAGES
${CLIENT_PACKAGES}
${ENGINE_PACKAGES}
CUSTOM_VAPIS
"${CMAKE_BINARY_DIR}/src/geary-static.vapi"
OPTIONS
${VALAC_OPTIONS}
--vapidir=${CMAKE_BINARY_DIR}/src
)
add_executable(geary ${GEARY_VALA_C})
target_link_libraries(geary ${DEPS_LIBRARIES} gthread-2.0 geary-static)
install(TARGETS geary RUNTIME DESTINATION bin)
add_custom_command(
TARGET
geary
POST_BUILD
COMMAND
${CMAKE_COMMAND} -E copy geary ${CMAKE_BINARY_DIR}/
)
add_subdirectory(client)
# Console app
#################################################
vala_precompile(CONSOLE_VALA_C geary-console
${CONSOLE_SRC}
PACKAGES
${CONSOLE_PACKAGES}
${ENGINE_PACKAGES}
CUSTOM_VAPIS
"${CMAKE_BINARY_DIR}/src/geary-static.vapi"
OPTIONS
${VALAC_OPTIONS}
--vapidir=${CMAKE_BINARY_DIR}/src
)
add_executable(geary-console ${CONSOLE_VALA_C})
target_link_libraries(geary-console ${DEPS_LIBRARIES} gthread-2.0 geary-static)
add_custom_command(
TARGET
geary-console
POST_BUILD
COMMAND
${CMAKE_COMMAND} -E copy geary-console ${CMAKE_BINARY_DIR}/
)
# Mailer app
#################################################
vala_precompile(MAILER_VALA_C geary-mailer
${MAILER_SRC}
PACKAGES
${ENGINE_PACKAGES}
CUSTOM_VAPIS
"${CMAKE_BINARY_DIR}/src/geary-static.vapi"
OPTIONS
${VALAC_OPTIONS}
--vapidir=${CMAKE_BINARY_DIR}/src
)
add_executable(geary-mailer ${MAILER_VALA_C})
target_link_libraries(geary-mailer ${DEPS_LIBRARIES} gthread-2.0 geary-static)
add_custom_command(
TARGET
geary-mailer
POST_BUILD
COMMAND
${CMAKE_COMMAND} -E copy geary-mailer ${CMAKE_BINARY_DIR}/
)
# DBus Service
#################################################
vala_precompile(DBUS_VALA_C gearyd
${DBUSSERVICE_SRC}
PACKAGES
${DBUSSERVICE_PACKAGES}
${ENGINE_PACKAGES}
CUSTOM_VAPIS
"${CMAKE_BINARY_DIR}/src/geary-static.vapi"
OPTIONS
${VALAC_OPTIONS}
--vapidir=${CMAKE_BINARY_DIR}/src
)
add_executable(gearyd ${DBUS_VALA_C})
target_link_libraries(gearyd ${DEPS_LIBRARIES} gthread-2.0 geary-static)
add_custom_command(
TARGET
gearyd
POST_BUILD
COMMAND
${CMAKE_COMMAND} -E copy gearyd ${CMAKE_BINARY_DIR}/
)
## Make clean: remove copied files
##################################################
set_property(
DIRECTORY ..
APPEND
PROPERTY ADDITIONAL_MAKE_CLEAN_FILES
geary
geary-console
geary-mailer
gearyd
)