summaryrefslogtreecommitdiff
path: root/taro/meson.build
blob: a7fa3a19aacc4b654abebbddc58f122cfda408b4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
taro_src = ['ui.c', 'db.c', 'file_ext.c']
taro_deps = [naunet]

notcurses = dependency('notcurses', required: false, allow_fallback: false)
notcurses_core = dependency('notcurses-core', required: false, allow_fallback: false)
if not notcurses.found() or not notcurses_core.found()
  notcurses_opts = cmake.subproject_options()
  notcurses_opts.add_cmake_defines({ 'CMAKE_BUILD_TYPE': is_debug ? 'Debug' : 'Release' })
  notcurses_opts.add_cmake_defines({ 'USE_CXX': false })
  notcurses_opts.add_cmake_defines({ 'USE_DOCTEST': false })
  notcurses_opts.add_cmake_defines({ 'USE_PANDOC': false })
  notcurses_opts.add_cmake_defines({ 'BUILD_EXECUTABLES': false })
  notcurses_opts.add_cmake_defines({ 'BUILD_FFI_LIBRARY': false })
  notcurses_opts.add_cmake_defines({ 'USE_POC': false })
  notcurses_opts.add_cmake_defines({ 'USE_STATIC': true })
  notcurses_opts.add_cmake_defines({ 'USE_MULTIMEDIA': 'ffmpeg' })
  notcurses_proj = cmake.subproject('notcurses', options: notcurses_opts)
  notcurses = notcurses_proj.dependency('notcurses-static')
  notcurses_core = notcurses_proj.dependency('notcurses-core-static')
  libdeflate = dependency('libdeflate', static: true)
  taro_deps += [libdeflate]
endif
taro_deps += [notcurses, notcurses_core]

tarod_src = ['daemon.c', 'file_ext.c']
tarod_deps = [naunet, stela]

executable('taro', taro_src, dependencies: taro_deps, install: true)
executable('tarod', tarod_src, dependencies: tarod_deps, install: true)

if get_option('tests').enabled()
  subdir('tests')
endif