summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcel Hollerbach <mail@marcel-hollerbach.de>2020-05-07 19:05:54 +0200
committerStefan Schmidt <s.schmidt@samsung.com>2020-05-27 11:06:43 +0200
commit2d105a7e597a38a31ea88fefc02ac84b8b6e5543 (patch)
tree3ddd46764ffc8c4c2262d6a6a851652efbee0cc0
parent89e34f351ea7c4aebe92abfc84631a0ef6136114 (diff)
build: split up building of libs, bins, modules, benchmark
this is needed as a preparation for more build refactoring. Overall goal to build efl in a single .so. What this commit results in is that *every* lib gets build first, then the modules and binaries of all subprojects. This way of building is needed in order to replace the split up libraries with the efl-one one later. Additionally, the infrastructure is added to set flags on the libraries that should be build together. Reviewed-by: Stefan Schmidt <stefan@datenfreihafen.org> Differential Revision: https://phab.enlightenment.org/D11805
-rw-r--r--meson.build173
1 files changed, 109 insertions, 64 deletions
diff --git a/meson.build b/meson.build
index b0129681cf..330694951c 100644
--- a/meson.build
+++ b/meson.build
@@ -294,54 +294,54 @@ if sys_osx == true and get_option('lua-interpreter') == 'luajit'
294endif 294endif
295 295
296subprojects = [ 296subprojects = [
297# name | option | mod | lib | bin | bench | tests | examples | 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, [], []], 298['evil' ,[] , false, true, false, false, false, false, false, [], []],
299['eina' ,[] , false, true, true, true, true, true, [], []], 299['eina' ,[] , false, true, true, true, true, true, false, [], []],
300['eolian' ,[] , false, true, true, false, true, false, ['eina'], []], 300['eolian' ,[] , false, true, true, false, true, false, false, ['eina'], []],
301['eo' ,[] , false, true, false, true, true, false, ['eina'], []], 301['eo' ,[] , false, true, false, true, true, false, false, ['eina'], []],
302['efl' ,[] , false, true, false, false, true, false, ['eo'], []], 302['efl' ,[] , false, true, false, false, true, false, false, ['eo'], []],
303['emile' ,[] , false, true, false, false, true, true, ['eina', 'efl'], ['lz4', 'rg_etc']], 303['emile' ,[] , false, true, false, false, true, true, false, ['eina', 'efl'], ['lz4', 'rg_etc']],
304['eet' ,[] , false, true, true, false, true, true, ['eina', 'emile', 'efl'], []], 304['eet' ,[] , false, true, true, false, true, true, false, ['eina', 'emile', 'efl'], []],
305['ecore' ,[] , false, true, false, false, false, false, ['eina', 'eo', 'efl'], ['buildsystem']], 305['ecore' ,[] , false, true, false, false, false, false, false, ['eina', 'eo', 'efl'], ['buildsystem']],
306['eldbus' ,[] , false, true, true, false, true, true, ['eina', 'eo', 'efl'], []], 306['eldbus' ,[] , false, true, true, false, true, true, false, ['eina', 'eo', 'efl'], []],
307['ecore' ,[] , true, false, false, false, true, true, ['eina', 'eo', 'efl'], []], #ecores modules depend on eldbus 307['ecore' ,[] , true, false, false, false, true, true, false, ['eina', 'eo', 'efl'], []], #ecores modules depend on eldbus
308['ecore_audio' ,['audio'] , false, true, false, false, false, false, ['eina', 'eo'], []], 308['ecore_audio' ,['audio'] , false, true, false, false, false, false, false, ['eina', 'eo'], []],
309['ecore_avahi' ,['avahi'] , false, true, false, false, false, true, ['eina', 'ecore'], []], 309['ecore_avahi' ,['avahi'] , false, true, false, false, false, true, false, ['eina', 'ecore'], []],
310['ecore_con' ,[] , false, true, true, false, true, false, ['eina', 'eo', 'efl', 'ecore'], ['http-parser']], 310['ecore_con' ,[] , false, true, true, false, true, false, false, ['eina', 'eo', 'efl', 'ecore'], ['http-parser']],
311['ecore_file' ,[] , false, true, false, false, false, false, ['eina'], []], 311['ecore_file' ,[] , false, true, false, false, false, false, false, ['eina'], []],
312['eeze' ,['eeze'] , true, true, true, false, true, false, ['eina', 'efl'], []], 312['eeze' ,['eeze'] , true, true, true, false, true, false, false, ['eina', 'efl'], []],
313['ecore_input' ,[] , false, true, false, false, false, false, ['eina', 'eo'], []], 313['ecore_input' ,[] , false, true, false, false, false, false, false, ['eina', 'eo'], []],
314['ecore_x' ,['x11'] , false, true, false, false, false, false, ['eina', 'efl'], []], 314['ecore_x' ,['x11'] , false, true, false, false, false, false, false, ['eina', 'efl'], []],
315['ecore_fb' ,['fb'] , false, true, false, false, false, false, ['eina'], []], 315['ecore_fb' ,['fb'] , false, true, false, false, false, false, false, ['eina'], []],
316['ecore_wl2' ,['wl'] , true, true, false, false, true, false, ['eina'], ['libdrm']], 316['ecore_wl2' ,['wl'] , true, true, false, false, true, false, false, ['eina'], ['libdrm']],
317['ecore_sdl' ,['sdl'] , false, true, false, false, false, false, ['eina'], []], 317['ecore_sdl' ,['sdl'] , false, true, false, false, false, false, false, ['eina'], []],
318['ecore_win32' ,[] , false, true, false, false, false, false, ['eina'], []], 318['ecore_win32' ,[] , false, true, false, false, false, false, false, ['eina'], []],
319['ecore_ipc' ,[] , false, true, false, false, false, false, ['eina'], []], 319['ecore_ipc' ,[] , false, true, false, false, false, false, false, ['eina'], []],
320['ecore_buffer' ,['buffer'] , true, true, true, false, false, false, ['eina'], []], 320['ecore_buffer' ,['buffer'] , true, true, true, false, false, false, false, ['eina'], []],
321['ector' ,[] , false, true, false, false, true, false, ['eina', 'efl'], ['draw', 'triangulator', 'freetype']], 321['ector' ,[] , false, true, false, false, true, false, false, ['eina', 'efl'], ['draw', 'triangulator', 'freetype']],
322['elput' ,['drm'] , false, true, false, false, true, false, ['eina', 'eldbus'], []], 322['elput' ,['drm'] , false, true, false, false, true, false, false, ['eina', 'eldbus'], []],
323['ecore_drm2' ,['drm'] , false, true, false, false, false, false, ['ecore'], ['libdrm']], 323['ecore_drm2' ,['drm'] , false, true, false, false, false, false, false, ['ecore'], ['libdrm']],
324['ecore_cocoa' ,['cocoa'] , false, true, false, false, false, false, ['eina'], []], 324['ecore_cocoa' ,['cocoa'] , false, true, false, false, false, false, false, ['eina'], []],
325['evas' ,[] , true, true, false, false, true, true, ['eina', 'efl', 'eo'], ['vg_common', 'libunibreak']], 325['evas' ,[] , true, true, false, false, true, true, false, ['eina', 'efl', 'eo'], ['vg_common', 'libunibreak']],
326['efreet' ,[] , false, true, false, false, true, false, ['eina', 'efl', 'eo'], []], 326['efreet' ,[] , false, true, false, false, true, false, false, ['eina', 'efl', 'eo'], []],
327['ecore_input_evas' ,[] , false, true, false, false, false, false, ['eina', 'evas'], []], 327['ecore_input_evas' ,[] , false, true, false, false, false, false, false, ['eina', 'evas'], []],
328['ecore_evas' ,[] , true, true, true, false, false, false, ['evas', 'ector'], []], 328['ecore_evas' ,[] , true, true, true, false, false, false, false, ['evas', 'ector'], []],
329['ecore_imf' ,[] , true, true, false, false, false, false, ['eina'], []], 329['ecore_imf' ,[] , true, true, false, false, false, false, false, ['eina'], []],
330['embryo' ,[] , false, true, true, false, false, false, ['eina', 'efl', 'eo'], []], 330['embryo' ,[] , false, true, true, false, false, false, false, ['eina', 'efl', 'eo'], []],
331['eio' ,[] , false, true, false, false, true, true, ['eina', 'eet'], []], 331['eio' ,[] , false, true, false, false, true, true, false, ['eina', 'eet'], []],
332['efreet' ,[] , false, false, true, false, false, false, ['eina', 'efl', 'eo'], []], 332['efreet' ,[] , false, false, true, false, false, false, false, ['eina', 'efl', 'eo'], []],
333['ecore_imf_evas' ,[] , false, true, false, false, false, false, ['eina', 'efl', 'eo'], []], 333['ecore_imf_evas' ,[] , false, true, false, false, false, false, false, ['eina', 'efl', 'eo'], []],
334['ephysics' ,['physics'] , false, true, false, false, false, false, ['eina', 'efl', 'eo'], []], 334['ephysics' ,['physics'] , false, true, false, false, false, false, false, ['eina', 'efl', 'eo'], []],
335['edje' ,[] , false, true, true, false, true, true, ['evas', 'eo', 'efl', lua_pc_name], []], 335['edje' ,[] , false, true, true, false, true, true, false, ['evas', 'eo', 'efl', lua_pc_name], []],
336['emotion' ,[] , true, true, false, false, true, true, ['eina', 'efl', 'eo'], []], 336['emotion' ,[] , true, true, false, false, true, true, false, ['eina', 'efl', 'eo'], []],
337['ethumb' ,[] , true, true, true, false, false, false, ['eina', 'efl', 'eo'], []], 337['ethumb' ,[] , true, true, true, false, false, false, false, ['eina', 'efl', 'eo'], []],
338['ethumb_client' ,[] , false, true, true, false, false, true, ['eina', 'efl', 'eo', 'ethumb'], []], 338['ethumb_client' ,[] , false, true, true, false, false, true, false, ['eina', 'efl', 'eo', 'ethumb'], []],
339['elementary' ,[] , 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']], 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']],
340['efl_canvas_wl' ,['wl'] , false, true, true, 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, ['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, ['eina'], []], 342['ecore_wayland' ,['wl-deprecated'] , false, true, false, false, false, false, false, ['eina'], []],
343['ecore_drm' ,['drm-deprecated'] , false, true, false, false, false, false, ['eina'], []], 343['ecore_drm' ,['drm-deprecated'] , false, true, false, false, false, false, false, ['eina'], []],
344['exactness' ,[] , false, false, true, false, false, false, ['eina, evas, eet'], []], 344['exactness' ,[] , false, false, true, false, false, false, false, ['eina, evas, eet'], []],
345] 345]
346 346
347# We generate Efl_Config.h and config.h later, they will be available here 347# We generate Efl_Config.h and config.h later, they will be available here
@@ -388,7 +388,7 @@ foreach package : subprojects
388 #use this variable to store custom variables in that should be placed in the .pc file 388 #use this variable to store custom variables in that should be placed in the .pc file
389 package_pc_variables = [] 389 package_pc_variables = []
390 390
391 foreach static_lib : package[9] 391 foreach static_lib : package[10]
392 if get_variable(static_lib, tmp_empty) == tmp_empty 392 if get_variable(static_lib, tmp_empty) == tmp_empty
393 subdir(join_paths('src', 'static_libs', static_lib)) 393 subdir(join_paths('src', 'static_libs', static_lib))
394 endif 394 endif
@@ -407,19 +407,15 @@ foreach package : subprojects
407 set_variable(package_name + '_header_subdirs', package_header_subdirs) 407 set_variable(package_name + '_header_subdirs', package_header_subdirs)
408 set_variable(package_name + '_eo_subdirs', package_eo_subdirs) 408 set_variable(package_name + '_eo_subdirs', package_eo_subdirs)
409 endif 409 endif
410 if (package[2]) 410 #special case for eolian, this is never efl-one, but will be required in the library
411 subdir(join_paths(local_module, package_name)) 411 if (package_name == 'eolian')
412 endif 412 package_c_args = [
413 #package_c_args definition for the rest 413 '-DPACKAGE_DATA_DIR="'+ join_paths(dir_data, package_name)+'"',
414 package_c_args = [ 414 '-DNEED_RUN_IN_TREE=1',
415 '-DPACKAGE_DATA_DIR="'+ join_paths(dir_data, package_name)+'"', 415 ]
416 '-DNEED_RUN_IN_TREE=1', 416 if (package[4])
417 ] 417 subdir(join_paths(local_bin, package_name))
418 if (package[4]) 418 endif
419 subdir(join_paths(local_bin, package_name))
420 endif
421 if (package[5])
422 subdir(join_paths(local_benchmark, package_name))
423 endif 419 endif
424 if (package[6]) 420 if (package[6])
425 test_dirs += [package_name] 421 test_dirs += [package_name]
@@ -446,7 +442,7 @@ foreach package : subprojects
446 subdirs : [package_version_name] + tmp_package_subdirs, 442 subdirs : [package_version_name] + tmp_package_subdirs,
447 version : version_major + '.' + version_minor + '.' + version_micro, 443 version : version_major + '.' + version_minor + '.' + version_micro,
448 libraries : tmp_pub_deps, 444 libraries : tmp_pub_deps,
449 requires : package[8], 445 requires : package[9],
450 variables : package_pc_variables 446 variables : package_pc_variables
451 ) 447 )
452 if package_name == 'ethumb_client' 448 if package_name == 'ethumb_client'
@@ -455,14 +451,63 @@ foreach package : subprojects
455 subdirs : [package_version_name] + tmp_package_subdirs, 451 subdirs : [package_version_name] + tmp_package_subdirs,
456 version : version_major + '.' + version_minor + '.' + version_micro, 452 version : version_major + '.' + version_minor + '.' + version_micro,
457 libraries : tmp_pub_deps, 453 libraries : tmp_pub_deps,
458 requires : package[8], 454 requires : package[9],
459 ) 455 )
460 endif 456 endif
461 endif 457 endif
462 else 458 else
463 message(package_name+' disabled!') 459 message(package_name+' disabled!')
464 endif 460 endif
461endforeach
462
463if (get_option('efl-one'))
464 #building efl-one
465 efl_one_lib = shared_library('efl-one',
466 link_whole : efl_one_parts,
467 install : true,
468 version : meson.project_version(),
469 )
465 470
471 efl_one = declare_dependency(
472 link_with: efl_one_lib,
473 include_directories : efl_one_include_dirs,
474 dependencies : [thread_dep, intl] + efl_one_eo_deps,
475 version: meson.project_version()
476 )
477
478 pkgconfig.generate(
479 name : 'efl-one',
480 description: 'Configureation for efl in one big fat .so',
481 libraries : efl_one,
482 )
483
484 #overwrite all the dependencies of subprojects with efl-one, in order to link the modules and binaries to the correct .so
485 foreach package : subprojects
486 package_name = package[0]
487 if package[1].length() == 0 or get_option(package[1][0])
488 if (package[3])
489 if (package[8] and get_option('efl-one'))
490 set_variable(package_name, efl_one)
491 endif
492 endif
493 endif
494 endforeach
495endif
496
497#delayed build of bin, modules, and benchmarks
498foreach package : subprojects
499 package_name = package[0]
500 if package[1].length() == 0 or get_option(package[1][0])
501 if (package[2])
502 subdir(join_paths(local_module, package_name))
503 endif
504 if (package[4] and package_name != 'eolian')
505 subdir(join_paths(local_bin, package_name))
506 endif
507 if (package[5])
508 subdir(join_paths(local_benchmark, package_name))
509 endif
510 endif
466endforeach 511endforeach
467 512
468#build this later, as the debug services are depending on ecore 513#build this later, as the debug services are depending on ecore