Improve meson build.
-Add all required packages as wrap dependencies -Move source lsitnings to separate files -Proper dependencies declarations -Set global D compiler arguments -Add few asserts -Add test exe -Other small improvements Tested with dmd with betterC, demos executable has to be run from 'demos' directory to properly load assets.
This commit is contained in:
parent
00386ed529
commit
66b5807368
16 changed files with 314 additions and 104 deletions
24
subprojects/packagefiles/bindbc-loader/meson.build
Normal file
24
subprojects/packagefiles/bindbc-loader/meson.build
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
project('bindbc-loader', 'd', version : '0.3.2', default_options: ['default_library=static'])
|
||||
|
||||
# Files
|
||||
src = files(
|
||||
'source/bindbc/loader/package.d',
|
||||
'source/bindbc/loader/sharedlib.d',
|
||||
'source/bindbc/loader/system.d',
|
||||
)
|
||||
|
||||
inc = include_directories('source')
|
||||
|
||||
# Dependencies
|
||||
lib = library('bindbc-loader', src,
|
||||
include_directories : [inc],
|
||||
pic : true,
|
||||
d_module_versions: ['BindBC_Static'],
|
||||
)
|
||||
|
||||
bindbc_loader_dep = declare_dependency(
|
||||
include_directories : [inc],
|
||||
link_with : lib,
|
||||
)
|
||||
|
||||
meson.override_dependency('bindbc-loader', bindbc_loader_dep)
|
||||
72
subprojects/packagefiles/bindbc-sdl/meson.build
Normal file
72
subprojects/packagefiles/bindbc-sdl/meson.build
Normal file
|
|
@ -0,0 +1,72 @@
|
|||
project('bindbc-sdl', 'd', version : '0.19.2', default_options: ['default_library=static'])
|
||||
|
||||
# Files
|
||||
src = files(
|
||||
'source/bindbc/sdl/bind/package.d',
|
||||
'source/bindbc/sdl/bind/sdl.d',
|
||||
'source/bindbc/sdl/bind/sdlassert.d',
|
||||
'source/bindbc/sdl/bind/sdlatomic.d',
|
||||
'source/bindbc/sdl/bind/sdlaudio.d',
|
||||
'source/bindbc/sdl/bind/sdlblendmode.d',
|
||||
'source/bindbc/sdl/bind/sdlclipboard.d',
|
||||
'source/bindbc/sdl/bind/sdlcpuinfo.d',
|
||||
'source/bindbc/sdl/bind/sdlerror.d',
|
||||
'source/bindbc/sdl/bind/sdlevents.d',
|
||||
'source/bindbc/sdl/bind/sdlfilesystem.d',
|
||||
'source/bindbc/sdl/bind/sdlgamecontroller.d',
|
||||
'source/bindbc/sdl/bind/sdlgesture.d',
|
||||
'source/bindbc/sdl/bind/sdlhaptic.d',
|
||||
'source/bindbc/sdl/bind/sdlhints.d',
|
||||
'source/bindbc/sdl/bind/sdljoystick.d',
|
||||
'source/bindbc/sdl/bind/sdlkeyboard.d',
|
||||
'source/bindbc/sdl/bind/sdlkeycode.d',
|
||||
'source/bindbc/sdl/bind/sdlloadso.d',
|
||||
'source/bindbc/sdl/bind/sdllog.d',
|
||||
'source/bindbc/sdl/bind/sdlmessagebox.d',
|
||||
'source/bindbc/sdl/bind/sdlmouse.d',
|
||||
'source/bindbc/sdl/bind/sdlmutex.d',
|
||||
'source/bindbc/sdl/bind/sdlpixels.d',
|
||||
'source/bindbc/sdl/bind/sdlplatform.d',
|
||||
'source/bindbc/sdl/bind/sdlpower.d',
|
||||
'source/bindbc/sdl/bind/sdlrect.d',
|
||||
'source/bindbc/sdl/bind/sdlrender.d',
|
||||
'source/bindbc/sdl/bind/sdlrwops.d',
|
||||
'source/bindbc/sdl/bind/sdlscancode.d',
|
||||
'source/bindbc/sdl/bind/sdlshape.d',
|
||||
'source/bindbc/sdl/bind/sdlstdinc.d',
|
||||
'source/bindbc/sdl/bind/sdlsurface.d',
|
||||
'source/bindbc/sdl/bind/sdlsystem.d',
|
||||
'source/bindbc/sdl/bind/sdlsyswm.d',
|
||||
'source/bindbc/sdl/bind/sdlthread.d',
|
||||
'source/bindbc/sdl/bind/sdltimer.d',
|
||||
'source/bindbc/sdl/bind/sdltouch.d',
|
||||
'source/bindbc/sdl/bind/sdlversion.d',
|
||||
'source/bindbc/sdl/bind/sdlvideo.d',
|
||||
'source/bindbc/sdl/bind/sdlvulkan.d',
|
||||
'source/bindbc/sdl/config.d',
|
||||
'source/bindbc/sdl/dynload.d',
|
||||
'source/bindbc/sdl/image.d',
|
||||
'source/bindbc/sdl/mixer.d',
|
||||
'source/bindbc/sdl/net.d',
|
||||
'source/bindbc/sdl/package.d',
|
||||
'source/bindbc/sdl/ttf.d',
|
||||
)
|
||||
|
||||
inc = include_directories('source')
|
||||
|
||||
# Dependencies
|
||||
bindbc_loader_dep = dependency('bindbc-loader')
|
||||
|
||||
lib = library('bindbc-sdl', src,
|
||||
dependencies : bindbc_loader_dep,
|
||||
include_directories : [inc],
|
||||
d_module_versions: ['BindBC_Static'],
|
||||
pic : true,
|
||||
)
|
||||
|
||||
bindbc_sdl_dep = declare_dependency(
|
||||
include_directories : [inc],
|
||||
link_with : lib,
|
||||
)
|
||||
|
||||
meson.override_dependency('bindbc-sdl', bindbc_sdl_dep)
|
||||
29
subprojects/packagefiles/cimgui/meson.build
Normal file
29
subprojects/packagefiles/cimgui/meson.build
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
project('cimgui', 'cpp', version : '1.73.0', default_options: ['default_library=shared', 'warning_level=1'])
|
||||
|
||||
# Files
|
||||
src = [
|
||||
'cimgui.cpp',
|
||||
'imgui/imgui.cpp',
|
||||
'imgui/imgui_draw.cpp',
|
||||
'imgui/imgui_demo.cpp',
|
||||
'imgui/imgui_widgets.cpp',
|
||||
]
|
||||
|
||||
inc = [ '.' ]
|
||||
pub_inc = [ 'imgui' ]
|
||||
|
||||
# Dependencies
|
||||
# bindbc_loader_dep = dependency('bindbc-loader')
|
||||
|
||||
lib = shared_library('cimgui', src,
|
||||
# dependencies : bindbc_loader_dep,
|
||||
include_directories : [inc, pub_inc],
|
||||
# pic : true,
|
||||
)
|
||||
|
||||
cimgui_dep = declare_dependency(
|
||||
include_directories : [pub_inc],
|
||||
link_with : lib,
|
||||
)
|
||||
|
||||
meson.override_dependency('cimgui', cimgui_dep)
|
||||
Loading…
Add table
Add a link
Reference in a new issue