summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcel Hollerbach <mail@marcel-hollerbach.de>2020-05-10 14:43:28 +0200
committerStefan Schmidt <s.schmidt@samsung.com>2020-05-27 11:06:48 +0200
commit92b049b4d7e70666b790ba78480da8f19c795b1c (patch)
tree317064f8099bae0d2d15b941b84b877fd912e657
parent8e3606698eb439eecd7302a885504365aca7e564 (diff)
build: time for efl-one
this is building parts of efl into a single .so and links all modules and binaries to it. The libraries themselfs are build as .a's which are linked together as .so's. Which is required as every subproject has its little custom c_flags, which are somtimes conflicting. After the final .so is then built, all the split up libraries are replaced with the efl-one. After that the modules and binaries are built correctly with the correct link on the efl-one parts. Reviewed-by: Stefan Schmidt <stefan@datenfreihafen.org> Differential Revision: https://phab.enlightenment.org/D11808
-rw-r--r--meson.build129
-rw-r--r--meson_options.txt6
-rw-r--r--src/lib/ecore_evas/meson.build3
-rw-r--r--src/lib/evas/meson.build2
4 files changed, 98 insertions, 42 deletions
diff --git a/meson.build b/meson.build
index 330694951c..1533d984f7 100644
--- a/meson.build
+++ b/meson.build
@@ -295,48 +295,48 @@ endif
295 295
296subprojects = [ 296subprojects = [
297# name | option | mod | lib | bin | bench | tests | examples | true if build in efl-one | pkg-config options | name of static libs 297# name | option | mod | lib | bin | bench | tests | examples | true if build in efl-one | pkg-config options | name of static libs
298['evil' ,[] , false, true, false, false, false, false, false, [], []], 298['evil' ,[] , false, true, false, false, false, false, true, [], []],
299['eina' ,[] , false, true, true, true, true, true, false, [], []], 299['eina' ,[] , false, true, true, true, true, true, true, [], []],
300['eolian' ,[] , false, true, true, false, true, false, false, ['eina'], []], 300['eolian' ,[] , false, true, true, false, true, false, false, ['eina'], []],
301['eo' ,[] , false, true, false, true, true, false, false, ['eina'], []], 301['eo' ,[] , false, true, false, true, true, false, true, ['eina'], []],
302['efl' ,[] , false, true, false, false, true, false, false, ['eo'], []], 302['efl' ,[] , false, true, false, false, true, false, true, ['eo'], []],
303['emile' ,[] , false, true, false, false, true, true, false, ['eina', 'efl'], ['lz4', 'rg_etc']], 303['emile' ,[] , false, true, false, false, true, true, true, ['eina', 'efl'], ['lz4', 'rg_etc']],
304['eet' ,[] , false, true, true, false, true, true, false, ['eina', 'emile', 'efl'], []], 304['eet' ,[] , false, true, true, false, true, true, true, ['eina', 'emile', 'efl'], []],
305['ecore' ,[] , false, true, false, false, false, false, false, ['eina', 'eo', 'efl'], ['buildsystem']], 305['ecore' ,[] , false, true, false, false, false, false, true, ['eina', 'eo', 'efl'], ['buildsystem']],
306['eldbus' ,[] , false, true, true, false, true, true, false, ['eina', 'eo', 'efl'], []], 306['eldbus' ,[] , false, true, true, false, true, true, true, ['eina', 'eo', 'efl'], []],
307['ecore' ,[] , true, false, false, false, true, true, false, ['eina', 'eo', 'efl'], []], #ecores modules depend on eldbus 307['ecore' ,[] , true, false, false, false, true, true, true, ['eina', 'eo', 'efl'], []], #ecores modules depend on eldbus
308['ecore_audio' ,['audio'] , false, true, false, false, false, false, false, ['eina', 'eo'], []], 308['ecore_audio' ,['audio'] , false, true, false, false, false, false, true, ['eina', 'eo'], []],
309['ecore_avahi' ,['avahi'] , false, true, false, false, false, true, false, ['eina', 'ecore'], []], 309['ecore_avahi' ,['avahi'] , false, true, false, false, false, true, false, ['eina', 'ecore'], []],
310['ecore_con' ,[] , false, true, true, false, true, false, false, ['eina', 'eo', 'efl', 'ecore'], ['http-parser']], 310['ecore_con' ,[] , false, true, true, false, true, false, true, ['eina', 'eo', 'efl', 'ecore'], ['http-parser']],
311['ecore_file' ,[] , false, true, false, false, false, false, false, ['eina'], []], 311['ecore_file' ,[] , false, true, false, false, false, false, true, ['eina'], []],
312['eeze' ,['eeze'] , true, true, true, false, true, false, false, ['eina', 'efl'], []], 312['eeze' ,['eeze'] , true, true, true, false, true, false, true, ['eina', 'efl'], []],
313['ecore_input' ,[] , false, true, false, false, false, false, false, ['eina', 'eo'], []], 313['ecore_input' ,[] , false, true, false, false, false, false, true, ['eina', 'eo'], []],
314['ecore_x' ,['x11'] , false, true, false, false, false, false, false, ['eina', 'efl'], []], 314['ecore_x' ,['x11'] , false, true, false, false, false, false, true, ['eina', 'efl'], []],
315['ecore_fb' ,['fb'] , false, true, false, false, false, false, false, ['eina'], []], 315['ecore_fb' ,['fb'] , false, true, false, false, false, false, true, ['eina'], []],
316['ecore_wl2' ,['wl'] , true, true, false, false, true, false, false, ['eina'], ['libdrm']], 316['ecore_wl2' ,['wl'] , true, true, false, false, true, false, true, ['eina'], ['libdrm']],
317['ecore_sdl' ,['sdl'] , false, true, false, false, false, false, false, ['eina'], []], 317['ecore_sdl' ,['sdl'] , false, true, false, false, false, false, true, ['eina'], []],
318['ecore_win32' ,[] , false, true, false, false, false, false, false, ['eina'], []], 318['ecore_win32' ,[] , false, true, false, false, false, false, true, ['eina'], []],
319['ecore_ipc' ,[] , false, true, false, false, false, false, false, ['eina'], []], 319['ecore_ipc' ,[] , false, true, false, false, false, false, true, ['eina'], []],
320['ecore_buffer' ,['buffer'] , true, true, true, false, false, false, false, ['eina'], []], 320['ecore_buffer' ,['buffer'] , true, true, true, false, false, false, true, ['eina'], []],
321['ector' ,[] , false, true, false, false, true, false, false, ['eina', 'efl'], ['draw', 'triangulator', 'freetype']], 321['ector' ,[] , false, true, false, false, true, false, true, ['eina', 'efl'], ['draw', 'triangulator', 'freetype']],
322['elput' ,['drm'] , false, true, false, false, true, false, false, ['eina', 'eldbus'], []], 322['elput' ,['drm'] , false, true, false, false, true, false, true, ['eina', 'eldbus'], []],
323['ecore_drm2' ,['drm'] , false, true, false, false, false, false, false, ['ecore'], ['libdrm']], 323['ecore_drm2' ,['drm'] , false, true, false, false, false, false, true, ['ecore'], ['libdrm']],
324['ecore_cocoa' ,['cocoa'] , false, true, false, false, false, false, false, ['eina'], []], 324['ecore_cocoa' ,['cocoa'] , false, true, false, false, false, false, true, ['eina'], []],
325['evas' ,[] , true, true, false, false, true, true, false, ['eina', 'efl', 'eo'], ['vg_common', 'libunibreak']], 325['evas' ,[] , true, true, false, false, true, true, true, ['eina', 'efl', 'eo'], ['vg_common', 'libunibreak']],
326['efreet' ,[] , false, true, false, false, true, false, false, ['eina', 'efl', 'eo'], []], 326['efreet' ,[] , false, true, false, false, true, false, true, ['eina', 'efl', 'eo'], []],
327['ecore_input_evas' ,[] , false, true, false, false, false, false, false, ['eina', 'evas'], []], 327['ecore_input_evas' ,[] , false, true, false, false, false, false, true, ['eina', 'evas'], []],
328['ecore_evas' ,[] , true, true, true, false, false, false, false, ['evas', 'ector'], []], 328['ecore_evas' ,[] , true, true, true, false, false, false, true, ['evas', 'ector'], []],
329['ecore_imf' ,[] , true, true, false, false, false, false, false, ['eina'], []], 329['ecore_imf' ,[] , true, true, false, false, false, false, true, ['eina'], []],
330['embryo' ,[] , false, true, true, false, false, false, false, ['eina', 'efl', 'eo'], []], 330['embryo' ,[] , false, true, true, false, false, false, true, ['eina', 'efl', 'eo'], []],
331['eio' ,[] , false, true, false, false, true, true, false, ['eina', 'eet'], []], 331['eio' ,[] , false, true, false, false, true, true, true, ['eina', 'eet'], []],
332['efreet' ,[] , false, false, true, false, false, false, false, ['eina', 'efl', 'eo'], []], 332['efreet' ,[] , false, false, true, false, false, false, true, ['eina', 'efl', 'eo'], []],
333['ecore_imf_evas' ,[] , false, true, false, false, false, false, false, ['eina', 'efl', 'eo'], []], 333['ecore_imf_evas' ,[] , false, true, false, false, false, false, true, ['eina', 'efl', 'eo'], []],
334['ephysics' ,['physics'] , false, true, false, false, false, false, false, ['eina', 'efl', 'eo'], []], 334['ephysics' ,['physics'] , false, true, false, false, false, false, true, ['eina', 'efl', 'eo'], []],
335['edje' ,[] , false, true, true, false, true, true, false, ['evas', 'eo', 'efl', lua_pc_name], []], 335['edje' ,[] , false, true, true, false, true, true, true, ['evas', 'eo', 'efl', lua_pc_name], []],
336['emotion' ,[] , true, true, false, false, true, true, false, ['eina', 'efl', 'eo'], []], 336['emotion' ,[] , true, true, false, false, true, true, true, ['eina', 'efl', 'eo'], []],
337['ethumb' ,[] , true, true, true, false, false, false, false, ['eina', 'efl', 'eo'], []], 337['ethumb' ,[] , true, true, true, false, false, false, true, ['eina', 'efl', 'eo'], []],
338['ethumb_client' ,[] , false, true, true, false, false, true, false, ['eina', 'efl', 'eo', 'ethumb'], []], 338['ethumb_client' ,[] , false, true, true, false, false, true, true, ['eina', 'efl', 'eo', 'ethumb'], []],
339['elementary' ,[] , true, true, true, true, true, true, false, ['eina', 'efl', 'eo', 'eet', 'evas', 'ecore', 'ecore-evas', 'ecore-file', 'ecore-input', 'edje', 'ethumb-client', 'emotion', 'ecore-imf', 'ecore-con', 'eldbus', 'efreet', 'efreet-mime', 'efreet-trash', 'eio'], ['atspi']], 339['elementary' ,[] , true, true, true, true, true, true, true, ['eina', 'efl', 'eo', 'eet', 'evas', 'ecore', 'ecore-evas', 'ecore-file', 'ecore-input', 'edje', 'ethumb-client', 'emotion', 'ecore-imf', 'ecore-con', 'eldbus', 'efreet', 'efreet-mime', 'efreet-trash', 'eio'], ['atspi']],
340['efl_canvas_wl' ,['wl'] , false, true, true, false, false, false, false, ['eina', 'efl', 'eo', 'evas', 'ecore'], []], 340['efl_canvas_wl' ,['wl'] , false, true, true, false, false, false, false, ['eina', 'efl', 'eo', 'evas', 'ecore'], []],
341['elua' ,['elua'] , false, true, true, false, true, false, false, ['eina', 'luajit'], []], 341['elua' ,['elua'] , false, true, true, false, true, false, false, ['eina', 'luajit'], []],
342['ecore_wayland' ,['wl-deprecated'] , false, true, false, false, false, false, false, ['eina'], []], 342['ecore_wayland' ,['wl-deprecated'] , false, true, false, false, false, false, false, ['eina'], []],
@@ -357,6 +357,10 @@ ecore_audio = declare_dependency()
357 357
358test_dirs = [] 358test_dirs = []
359example_dirs = [] 359example_dirs = []
360efl_one_parts = []
361efl_one_deps = []
362efl_one_eo_deps = []
363efl_one_include_dirs = []
360tmp_empty = declare_dependency() 364tmp_empty = declare_dependency()
361 365
362foreach package : subprojects 366foreach package : subprojects
@@ -406,6 +410,28 @@ foreach package : subprojects
406 set_variable(package_name + '_eot_files', pub_eo_types_files) 410 set_variable(package_name + '_eot_files', pub_eo_types_files)
407 set_variable(package_name + '_header_subdirs', package_header_subdirs) 411 set_variable(package_name + '_header_subdirs', package_header_subdirs)
408 set_variable(package_name + '_eo_subdirs', package_eo_subdirs) 412 set_variable(package_name + '_eo_subdirs', package_eo_subdirs)
413 if (package[8] and get_option('efl-one'))
414 src = get_variable(package_name+'_src')
415 external_deps = get_variable(package_name+'_ext_deps')
416 efl_one_include_dirs += [include_directories('.'), include_directories(join_paths(local_lib, package_name))]
417
418 foreach subdirs : package_eo_subdirs
419 efl_one_include_dirs += include_directories(join_paths(local_lib, package_name))
420 endforeach
421
422 tmp = static_library('efl_one_part_'+package_name,
423 src, pub_eo_file_target, priv_eo_file_target,
424 include_directories: efl_one_include_dirs,
425 dependencies: external_deps + efl_one_eo_deps,
426 c_args : package_c_args,
427 )
428 # dependency for all the .eo file targets
429 efl_one_eo_deps += declare_dependency(
430 sources: pub_eo_file_target,
431 )
432 efl_one_deps += external_deps
433 efl_one_parts += tmp
434 endif
409 endif 435 endif
410 #special case for eolian, this is never efl-one, but will be required in the library 436 #special case for eolian, this is never efl-one, but will be required in the library
411 if (package_name == 'eolian') 437 if (package_name == 'eolian')
@@ -498,9 +524,20 @@ endif
498foreach package : subprojects 524foreach package : subprojects
499 package_name = package[0] 525 package_name = package[0]
500 if package[1].length() == 0 or get_option(package[1][0]) 526 if package[1].length() == 0 or get_option(package[1][0])
527 dir_package_include = join_paths(dir_include, package_version_name)
528 dir_package_modules = join_paths(dir_lib, package_name, 'modules')
529 package_c_args = [
530 '-DPACKAGE_DATA_DIR="'+ join_paths(dir_data, package_name)+'"',
531 '-DNEED_RUN_IN_TREE=1',
532 '-DEFL_BUILD=1',
533 ]
501 if (package[2]) 534 if (package[2])
502 subdir(join_paths(local_module, package_name)) 535 subdir(join_paths(local_module, package_name))
503 endif 536 endif
537 package_c_args = [
538 '-DPACKAGE_DATA_DIR="'+ join_paths(dir_data, package_name)+'"',
539 '-DNEED_RUN_IN_TREE=1',
540 ]
504 if (package[4] and package_name != 'eolian') 541 if (package[4] and package_name != 'eolian')
505 subdir(join_paths(local_bin, package_name)) 542 subdir(join_paths(local_bin, package_name))
506 endif 543 endif
@@ -523,13 +560,21 @@ if get_option('build-tests')
523 check = dependency('check') 560 check = dependency('check')
524 subdir(join_paths('src', 'tests')) 561 subdir(join_paths('src', 'tests'))
525 foreach test : test_dirs 562 foreach test : test_dirs
526 subdir(join_paths(local_tests, test)) 563 package_c_args = [
564 '-DPACKAGE_DATA_DIR="'+ join_paths(dir_data, test)+'"',
565 '-DNEED_RUN_IN_TREE=1',
566 ]
567 subdir(join_paths(local_tests, test))
527 endforeach 568 endforeach
528endif 569endif
529 570
530if get_option('build-examples') 571if get_option('build-examples')
531 foreach example : example_dirs 572 foreach example : example_dirs
532 subdir(join_paths(local_examples, example)) 573 package_c_args = [
574 '-DPACKAGE_DATA_DIR="'+ join_paths(dir_data, example)+'"',
575 '-DNEED_RUN_IN_TREE=1',
576 ]
577 subdir(join_paths(local_examples, example))
533 endforeach 578 endforeach
534endif 579endif
535 580
diff --git a/meson_options.txt b/meson_options.txt
index 0d07d396fc..159f2c2649 100644
--- a/meson_options.txt
+++ b/meson_options.txt
@@ -364,3 +364,9 @@ option('mono-friend-assemblies',
364 value : [], 364 value : [],
365 description : 'List of friend assemblies that can access efl_mono assembly\'s internal types and members.' 365 description : 'List of friend assemblies that can access efl_mono assembly\'s internal types and members.'
366) 366)
367
368option('efl-one',
369 type: 'boolean',
370 value : false,
371 description : 'Build special set of .so´s as a single .so'
372)
diff --git a/src/lib/ecore_evas/meson.build b/src/lib/ecore_evas/meson.build
index 554c77cf44..2ce2b0fcd2 100644
--- a/src/lib/ecore_evas/meson.build
+++ b/src/lib/ecore_evas/meson.build
@@ -52,3 +52,6 @@ ecore_evas = declare_dependency(
52install_headers(ecore_evas_header_src, 52install_headers(ecore_evas_header_src,
53 install_dir : dir_package_include, 53 install_dir : dir_package_include,
54) 54)
55
56#a custom directory that must be added to efl_one
57efl_one_include_dirs += [include_directories(join_paths('..', '..', 'modules', 'evas', 'engines', 'buffer'))]
diff --git a/src/lib/evas/meson.build b/src/lib/evas/meson.build
index 5799685e87..0ff0535e4f 100644
--- a/src/lib/evas/meson.build
+++ b/src/lib/evas/meson.build
@@ -320,3 +320,5 @@ install_headers(evas_header_src,
320pub_eo_files = [] 320pub_eo_files = []
321package_eo_subdirs += ['canvas', 'gesture'] 321package_eo_subdirs += ['canvas', 'gesture']
322package_header_subdirs += ['canvas', 'gesture'] 322package_header_subdirs += ['canvas', 'gesture']
323#special case becase evas has a more structures subfolder
324efl_one_include_dirs += evas_include_directories