summaryrefslogtreecommitdiff
path: root/backend/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'backend/CMakeLists.txt')
-rw-r--r--backend/CMakeLists.txt56
1 files changed, 56 insertions, 0 deletions
diff --git a/backend/CMakeLists.txt b/backend/CMakeLists.txt
new file mode 100644
index 0000000..f2eae86
--- /dev/null
+++ b/backend/CMakeLists.txt
@@ -0,0 +1,56 @@
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at https://mozilla.org/MPL/2.0/.
+
+find_package(PkgConfig REQUIRED)
+pkg_check_modules(deps REQUIRED IMPORTED_TARGET glib-2.0)
+
+add_library(backend)
+target_sources(backend
+ INTERFACE job.h utils.h pkgtools.h slackpkg.h dl.h
+ PRIVATE job.cc utils.cc pkgtools.cc slackpkg.cc dl.cc
+)
+
+target_link_libraries(backend PkgConfig::deps)
+# curl_dep = meson.get_compiler('c').find_library('curl')
+# bzip2_dep = dependency('bzip2')
+
+# packagekit_backend_slack_module = shared_module(
+# 'pk_backend_slack',
+# 'pk-backend-slack.cc',
+# 'utils.cc',
+# 'pkgtools.cc',
+# 'slackpkg.cc',
+# 'dl.cc',
+# 'job.cc',
+# include_directories: packagekit_src_include,
+# dependencies: [
+# packagekit_glib2_dep,
+# curl_dep,
+# gmodule_dep,
+# sqlite3_dep,
+# bzip2_dep,
+# ],
+# cpp_args: [
+# '-DG_LOG_DOMAIN="PackageKit-Slackware"',
+# '-DLOCALSTATEDIR="@0@"'.format(join_paths(get_option('prefix'), get_option('localstatedir'))),
+# '-DLIBDIR="@0@"'.format(join_paths(get_option('prefix'), get_option('libdir'))),
+# '-DSYSCONFDIR="@0@"'.format(get_option('sysconfdir')),
+# ],
+# override_options: ['c_std=c14', 'cpp_std=c++14'],
+# install: true,
+# install_dir: pk_plugin_dir,
+# )
+
+# configure_file(
+# input: 'Slackware.conf.in',
+# output: 'Slackware.conf',
+# configuration: slackware_config_data,
+# install: true,
+# install_dir: join_paths(get_option('sysconfdir'), 'PackageKit'),
+# )
+
+# install_data(
+# 'metadata.db',
+# install_dir: join_paths(get_option('localstatedir'), 'cache', 'PackageKit', 'metadata'),
+# )