2
# ['eina', 'eolian', 'eo'] those three are build in the root meson.build reason for this is the super special handling
4
['Eina', true, true, false, [eo]],
5
['Eolian', true, true, false, []],
6
['Eo', true, true, false, []],
7
['Efl', true, false, true, []],
8
['Ecore', true, true, true, []],
9
['Eet', true, true, false, []],
10
['Eio', false, false, true, []],
11
['Evas', false, true, true, []],
12
['Edje', false, false, true, []],
13
['Eldbus', true, true, true, []],
14
['Elementary', true, true, true, []]
17
increased_dependency = []
20
foreach lib : cxx_sublibs
21
package_name = lib[0].to_lower()
22
package_top_header = lib[3]
23
package_has_tests = lib[2]
24
package_manual_binded = lib[1]
25
package_version_name = '-'.join(package_name.split('_')) + '-cxx-' + version_major
26
tmp_package_subdirs = [package_version_name]
29
'-DPACKAGE_DATA_DIR="'+ join_paths(dir_data, package_name)+'"',
30
'-DNEED_RUN_IN_TREE=1'
33
dir_package_modules = join_paths(dir_lib, package_name, 'modules')
34
cxx_generator_target = []
36
file_location = join_paths('..', '..', 'lib', package_name)
38
eo_file_subdirs = get_variable(package_name + '_eo_subdirs')
39
#generate files for each .eo files
40
foreach eo_file_subdir : eo_file_subdirs
41
if eo_file_subdir != ''
42
cxx_pub_eot_files = get_variable(package_name + '_' + eo_file_subdir +'_eot_files')
44
cxx_pub_eot_files = get_variable(package_name +'_eot_files')
46
subdir_file_location = join_paths(file_location, eo_file_subdir)
47
foreach cxx_gen_file : cxx_pub_eot_files
48
cxx_generator_target += custom_target('eolian_cxx_gen_'+cxx_gen_file.underscorify()+'',
49
input : join_paths(subdir_file_location, cxx_gen_file),
50
output : [cxx_gen_file + '.hh'],
52
install_dir : join_paths(dir_include, package_version_name, eo_file_subdir),
53
command : [eolian_cxx_gen, '-I', meson.current_source_dir(), eolian_include_directories,
54
'-o', join_paths(meson.current_build_dir(), cxx_gen_file + '.hh'),
56
eo_file_list += files(join_paths(subdir_file_location, cxx_gen_file))
59
if eo_file_subdir != ''
60
cxx_pub_eo_files = get_variable(package_name + '_' + eo_file_subdir +'_eo_files')
62
cxx_pub_eo_files = get_variable(package_name +'_eo_files')
64
subdir_file_location = join_paths(file_location, eo_file_subdir)
65
foreach cxx_gen_file : cxx_pub_eo_files
66
cxx_generator_target += custom_target('eolian_cxx_gen_'+cxx_gen_file.underscorify()+'',
67
input : join_paths(subdir_file_location, cxx_gen_file),
68
output : [cxx_gen_file + '.hh', cxx_gen_file + '.impl.hh'],
70
install_dir : join_paths(dir_include, package_version_name, eo_file_subdir),
71
command : [eolian_cxx_gen, '-I', meson.current_source_dir(), eolian_include_directories,
72
'-o', join_paths(meson.current_build_dir(), cxx_gen_file + '.hh'),
74
eo_file_list += files(join_paths(subdir_file_location, cxx_gen_file))
78
#generate the package.eo.hh file
80
cxx_generator_target += custom_target('eolian_cxx_gen_'+package_name+'.eo.hh',
82
output : [lib[0] + '.eo.hh'],
84
install_dir : join_paths(dir_include, package_version_name),
85
command : [eolian_cxx_gen, '-I', meson.current_source_dir(), eolian_include_directories, '-m',
90
if package_manual_binded
91
inc_dir = include_directories(package_name+'_cxx', '.')
92
subdir(package_name+'_cxx')
94
inc_dir = include_directories(file_location, '.')
95
cxx_header_src += files(join_paths(file_location, lib[0]+'.hh'))
98
dep = declare_dependency(
99
include_directories: inc_dir,
100
sources : cxx_generator_target,
101
dependencies: [get_variable(package_name)] + get_variable(package_name + '_pub_deps') + lib[4] + increased_dependency
104
increased_dependency += dep
106
set_variable(package_name + '_cxx', dep)
109
test_dirs += package_name + '_cxx'
112
foreach subdir : get_variable(package_name + '_eo_subdirs')
113
tmp_package_subdirs += join_paths(package_version_name, subdir)
116
install_headers(cxx_header_src,
117
subdir: package_version_name,
121
name : '-'.join(package_name.split('_')) + '-cxx',
122
description : lib[0]+' cxx bindings',
123
subdirs : tmp_package_subdirs,
124
version : version_major + '.' + version_minor + '.' + version_micro,
126
requires : growing_deps + [package_name],
128
growing_deps += package_name + '-cxx'