File: meson.build

package info (click to toggle)
gimp 3.0.4-3
  • links: PTS, VCS
  • area: main
  • in suites: sid, trixie
  • size: 210,076 kB
  • sloc: ansic: 842,287; lisp: 10,761; python: 10,318; cpp: 7,238; perl: 4,355; sh: 1,043; xml: 963; yacc: 609; lex: 348; javascript: 150; makefile: 43
file content (154 lines) | stat: -rw-r--r-- 3,162 bytes parent folder | download
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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
if platform_osx
  add_project_arguments('-ObjC', language : 'c')
endif

gimpversion = configure_file(
  input : 'gimpversion.h.in',
  output: 'gimpversion.h',
  configuration: versionconfig,
)

stamp_base_enums = custom_target('stamp-gimpbaseenums.h',
  input : [
    files(
      'gimpbaseenums.h'
    ),
  ],
  output: [ 'stamp-gimpbaseenums.h', ],
  command: [
    mkenums_wrap, perl,
    meson.project_source_root(), meson.current_source_dir(),
    meson.current_build_dir(),
    'gimpbase',
    '#include <glib-object.h>\n'       +
    '#include "gimpbasetypes.h"\n'     +
    '#include "libgimp/libgimp-intl.h"\n',
    '',
    libgimp_mkenums_dtails
  ],
  build_by_default: true
)

stamp_compat_enums = custom_target('stamp-gimpcompatenums.h',
  input : [
    files(
      'gimpcompatenums.h'
    ),
  ],
  output: [ 'stamp-gimpcompatenums.h', ],
  command: [
    mkenums_wrap, perl,
    meson.project_source_root(), meson.current_source_dir(), meson.current_build_dir(),
    'gimpcompat',
    '#include <glib-object.h>\n'       +
    '#include "gimpbasetypes.h"\n',
    '#include "libgimp/libgimp-intl.h"',
  ],
  build_by_default: true
)

libgimpbase_sources_introspectable = files(
  'gimpbasetypes.c',
  'gimpchecks.c',
  'gimpchoice.c',
  'gimpcpuaccel.c',
  'gimpenv.c',
  'gimpexportoptions.c',
  'gimpmemsize.c',
  'gimpmetadata.c',
  'gimpparamspecs.c',
  'gimpparasite.c',
  'gimpparasiteio.c',
  'gimprectangle.c',
  'gimpunit.c',
  'gimputils.c',
  'gimpvaluearray.c',
)

libgimpbase_sources = [
  libgimpbase_sources_introspectable,
  'gimpbase-private.c',
  'gimpprotocol.c',
  'gimpreloc.c',
  'gimpsignal.c',
  'gimpwire.c',

  'gimpbaseenums.c',
  stamp_base_enums,

  'gimpcompatenums.c',
  stamp_compat_enums
]

libgimpbase_headers_introspectable = files(
  'gimpbaseenums.h',
  'gimpbasetypes.h',
  'gimpchecks.h',
  'gimpchoice.h',
  'gimpcpuaccel.h',
  'gimpenv.h',
  'gimpexportoptions.h',
  'gimplimits.h',
  'gimpmemsize.h',
  'gimpmetadata.h',
  'gimpparamspecs.h',
  'gimpparasite.h',
  'gimpparasiteio.h',
  'gimprectangle.h',
  'gimpunit.h',
  'gimputils.h',
  'gimpvaluearray.h',
) + [
  gimpversion,
]

libgimpbase_headers = [
  libgimpbase_headers_introspectable,
  'gimpbase.h',
  gimpversion,
]

libgimpbase_introspectable = [
  libgimpbase_sources_introspectable,
  libgimpbase_headers_introspectable,
]

libgimpbase = library('gimpbase-' + gimp_api_version,
  libgimpbase_sources,
  include_directories: rootInclude,
  dependencies: [
    gegl, gexiv2, gio, math,
    # optionally depend on libexecinfo on platforms where it is not
    # internal to the libc.
    opt_execinfo,
  ],
  c_args: [
    '-DG_LOG_DOMAIN="LibGimpBase"',
    '-DGIMP_BASE_COMPILATION',
  ],
  vs_module_defs: 'gimpbase.def',
  install: true,
  version: so_version,
)

install_headers(
  libgimpbase_headers,
  subdir: gimp_api_name / 'libgimpbase',
)

# Test program, not installed
executable('test-cpu-accel',
  'test-cpu-accel.c',
  include_directories: rootInclude,
  dependencies: [
    glib,
  ],
  c_args: [
    '-DG_LOG_DOMAIN="LibGimpBase"',
    '-DGIMP_BASE_COMPILATION',
  ],
  link_with: [
    libgimpbase,
  ],
  install: false,
)