summaryrefslogtreecommitdiff
path: root/common/meson.build
blob: 51eb939d36c756816b921618259ea64790208c96 (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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
common_inc = include_directories('.')

headers = files(
  'dconf-changeset.h',
  'dconf-enums.h',
  'dconf-paths.h'
)

install_headers(
  headers,
  subdir: join_paths(meson.project_name(), 'common')
)

name = meson.project_name() + '-common'

sources = files(
  'dconf-changeset.c',
  'dconf-error.c',
  'dconf-paths.c'
)

cflags = ['-DG_LOG_DOMAIN="@0@"'.format(meson.project_name())]

libdconf_common = static_library(
  name,
  sources: sources,
  include_directories: top_inc,
  dependencies: glib_dep,
  c_args: cflags,
  pic: true
)

libdconf_common_dep = declare_dependency(
  dependencies: glib_dep,
  link_with: libdconf_common
)

cflags += cc.get_supported_arguments('-fvisibility=hidden')

libdconf_common_hidden = static_library(
  name + '-hidden',
  sources: sources,
  include_directories: top_inc,
  dependencies: glib_dep,
  c_args: cflags,
  pic: true
)

libdconf_common_hidden_dep = declare_dependency(
  dependencies: glib_dep,
  link_with: libdconf_common_hidden
)