2018-10-28 02:55:12 +02:00
|
|
|
libcubescript_header_src = [
|
|
|
|
'../include/cubescript/cubescript.hh',
|
2021-04-07 01:44:40 +02:00
|
|
|
'../include/cubescript/cubescript_conf.hh',
|
|
|
|
'../include/cubescript/cubescript/callable.hh',
|
|
|
|
'../include/cubescript/cubescript/error.hh',
|
|
|
|
'../include/cubescript/cubescript/ident.hh',
|
|
|
|
'../include/cubescript/cubescript/platform.hh',
|
|
|
|
'../include/cubescript/cubescript/state.hh',
|
|
|
|
'../include/cubescript/cubescript/util.hh',
|
|
|
|
'../include/cubescript/cubescript/value.hh',
|
2018-10-28 02:55:12 +02:00
|
|
|
]
|
|
|
|
|
|
|
|
libcubescript_src = [
|
2021-03-22 21:26:05 +01:00
|
|
|
'cs_bcode.cc',
|
2021-03-22 22:33:01 +01:00
|
|
|
'cs_error.cc',
|
2018-10-28 02:55:12 +02:00
|
|
|
'cs_gen.cc',
|
2021-03-22 22:33:01 +01:00
|
|
|
'cs_ident.cc',
|
2021-03-23 02:00:11 +01:00
|
|
|
'cs_parser.cc',
|
2021-03-23 01:11:21 +01:00
|
|
|
'cs_state.cc',
|
2021-03-25 01:37:13 +01:00
|
|
|
'cs_std.cc',
|
2021-03-23 01:25:47 +01:00
|
|
|
'cs_strman.cc',
|
2021-03-24 22:37:53 +01:00
|
|
|
'cs_thread.cc',
|
2018-10-28 02:55:12 +02:00
|
|
|
'cs_val.cc',
|
|
|
|
'cs_vm.cc',
|
2021-03-23 02:43:00 +01:00
|
|
|
'lib_base.cc',
|
2018-10-28 02:55:12 +02:00
|
|
|
'lib_list.cc',
|
|
|
|
'lib_math.cc',
|
|
|
|
'lib_str.cc'
|
|
|
|
]
|
|
|
|
|
2021-04-01 04:39:13 +02:00
|
|
|
lib_cxxflags = [ '-DLIBCUBESCRIPT_BUILD' ]
|
2021-03-31 01:10:58 +02:00
|
|
|
host_system = host_machine.system()
|
|
|
|
|
|
|
|
if host_system == 'windows' or host_system == 'cygwin'
|
|
|
|
if get_option('default_library') != 'static'
|
|
|
|
lib_cxxflags += '-DLIBCUBESCRIPT_DLL'
|
|
|
|
endif
|
|
|
|
endif
|
|
|
|
|
2021-03-23 02:48:14 +01:00
|
|
|
libcubescript_target = library('cubescript',
|
2018-10-28 02:55:12 +02:00
|
|
|
libcubescript_src,
|
|
|
|
include_directories: libcubescript_includes + [include_directories('.')],
|
2021-03-31 01:10:58 +02:00
|
|
|
cpp_args: extra_cxxflags + lib_cxxflags,
|
2018-10-28 02:55:12 +02:00
|
|
|
install: true,
|
2021-03-23 02:48:14 +01:00
|
|
|
pic: true,
|
2018-10-28 02:55:12 +02:00
|
|
|
version: meson.project_version()
|
|
|
|
)
|
|
|
|
|
|
|
|
libcubescript = declare_dependency(
|
|
|
|
include_directories: libcubescript_includes,
|
2021-03-23 02:48:14 +01:00
|
|
|
link_with: libcubescript_target
|
2018-10-28 02:55:12 +02:00
|
|
|
)
|
|
|
|
|
|
|
|
install_headers(libcubescript_header_src, install_dir: dir_package_include)
|