summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
authorMarcel Hollerbach <mail@marcel-hollerbach.de>2018-12-04 20:38:07 +0100
committerMarcel Hollerbach <mail@marcel-hollerbach.de>2018-12-07 13:05:31 +0100
commit500a36ba3d3d00ed292ed3e85bb9ac40a55bd2a9 (patch)
treed19bbb3272cf471ccda916cf4dc86e0250171392 /src/lib
parent79ded15ad3c0074e1d378cc5a0accad2399fcc24 (diff)
meson: add inital support for windows compilation
Differential Revision: https://phab.enlightenment.org/D7416
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/ecore/meson.build3
-rw-r--r--src/lib/ecore_audio/meson.build7
-rw-r--r--src/lib/eina/meson.build6
-rw-r--r--src/lib/elementary/meson.build7
-rw-r--r--src/lib/evil/meson.build69
-rw-r--r--src/lib/evil/regex/meson.build10
6 files changed, 99 insertions, 3 deletions
diff --git a/src/lib/ecore/meson.build b/src/lib/ecore/meson.build
index 3757bad5f3..b9536b07f4 100644
--- a/src/lib/ecore/meson.build
+++ b/src/lib/ecore/meson.build
@@ -180,11 +180,12 @@ ecore_src = [
180 180
181if sys_windows == true 181if sys_windows == true
182 #nothing for now ... needs testing 182 #nothing for now ... needs testing
183 ecore_src += ['ecore_exe_win32.c']
183else 184else
184 ecore_src += ['ecore_signal.c', 'ecore_exe_posix.c'] 185 ecore_src += ['ecore_signal.c', 'ecore_exe_posix.c']
185endif 186endif
186 187
187if get_option('glib') == true 188if get_option('glib') == true and sys_windows == false
188 ecore_deps += dependency('glib-2.0') 189 ecore_deps += dependency('glib-2.0')
189 ecore_deps += dependency('gthread-2.0') 190 ecore_deps += dependency('gthread-2.0')
190 config_h.set('GLIB_INTEGRATION_ALWAYS', '1') 191 config_h.set('GLIB_INTEGRATION_ALWAYS', '1')
diff --git a/src/lib/ecore_audio/meson.build b/src/lib/ecore_audio/meson.build
index b73d53d81b..bc3215e62c 100644
--- a/src/lib/ecore_audio/meson.build
+++ b/src/lib/ecore_audio/meson.build
@@ -70,6 +70,13 @@ if get_option('pulseaudio')
70 config_h.set('HAVE_PULSE', '1') 70 config_h.set('HAVE_PULSE', '1')
71endif 71endif
72 72
73if sys_windows == true
74 ecore_audio_src += [
75 'ecore_audio_obj_out_wasapi.c'
76 ]
77 ecore_audio_deps += [cc.find_library('ksuser', required: true), cc.find_library('winmm', required: true)]
78endif
79
73ecore_audio_lib = library('ecore_audio', 80ecore_audio_lib = library('ecore_audio',
74 ecore_audio_src, pub_eo_file_target, 81 ecore_audio_src, pub_eo_file_target,
75 dependencies: ecore_audio_pub_deps + [m] + ecore_audio_deps, 82 dependencies: ecore_audio_pub_deps + [m] + ecore_audio_deps,
diff --git a/src/lib/eina/meson.build b/src/lib/eina/meson.build
index 9535391619..a814673e24 100644
--- a/src/lib/eina/meson.build
+++ b/src/lib/eina/meson.build
@@ -1,6 +1,10 @@
1eina_deps = [dl] 1eina_deps = [dl]
2eina_pub_deps = [thread_dep] 2eina_pub_deps = [thread_dep]
3 3
4if sys_windows == true
5 eina_pub_deps += [evil]
6endif
7
4public_sub_headers = [ 8public_sub_headers = [
5'eina_promise.h', 9'eina_promise.h',
6'eina_safety_checks.h', 10'eina_safety_checks.h',
@@ -368,7 +372,7 @@ execinfo = cc.find_library('execinfo', required: false)
368 372
369eina_lib = library('eina', sources, 373eina_lib = library('eina', sources,
370 include_directories : config_dir, 374 include_directories : config_dir,
371 dependencies: [m, rt, dl, execinfo, iconv, eina_deps, thread_dep, eina_mem_pools], 375 dependencies: [m, rt, dl, execinfo, iconv, eina_deps, thread_dep, eina_mem_pools, evil],
372 install: true, 376 install: true,
373 version : meson.project_version() 377 version : meson.project_version()
374) 378)
diff --git a/src/lib/elementary/meson.build b/src/lib/elementary/meson.build
index ac69f99905..335b8f581b 100644
--- a/src/lib/elementary/meson.build
+++ b/src/lib/elementary/meson.build
@@ -914,7 +914,12 @@ config_h.set_quoted('MODULES_PATH', join_paths(dir_lib, 'modules'))
914config_h.set_quoted('ELEMENTARY_BASE_DIR', '.elementary') 914config_h.set_quoted('ELEMENTARY_BASE_DIR', '.elementary')
915config_h.set_quoted('ICON_DIR', join_paths(dir_lib, 'icons')) 915config_h.set_quoted('ICON_DIR', join_paths(dir_lib, 'icons'))
916 916
917elm_options.set('ELM_UNIX', '1') 917if sys_windows == false
918 elm_options.set('ELM_UNIX', '1')
919else
920 elm_options.set('DLL_EXPORT', '1')
921endif
922
918elm_options.set('ELM_ELOCATION', '1') 923elm_options.set('ELM_ELOCATION', '1')
919elm_options.set('ELM_EFREET', '1') 924elm_options.set('ELM_EFREET', '1')
920 925
diff --git a/src/lib/evil/meson.build b/src/lib/evil/meson.build
new file mode 100644
index 0000000000..ff9630aa2b
--- /dev/null
+++ b/src/lib/evil/meson.build
@@ -0,0 +1,69 @@
1evil_deps = []
2evil_pub_deps = []
3if target_machine.system() == 'windows'
4 evil_header_src = [
5 'Evil.h',
6 'evil_dlfcn.h',
7 'evil_fcntl.h',
8 'evil_langinfo.h',
9 'evil_locale.h',
10 'evil_macro.h',
11 'evil_macro_pop.h',
12 'evil_macro_wrapper.h',
13 'evil_main.h',
14 'evil_stdio.h',
15 'evil_stdlib.h',
16 'evil_string.h',
17 'evil_time.h',
18 'evil_unistd.h',
19 'evil_util.h',
20 'dirent.h',
21 'fnmatch.h',
22 'pwd.h',
23 'regex/regex.h'
24 ]
25 evil_header_sys_src = [join_paths('sys','mman.h')]
26
27 evil_src = [
28 'evil_dlfcn.c',
29 'evil_fcntl.c',
30 'evil_fnmatch.c',
31 'evil_fnmatch_list_of_states.c',
32 'evil_langinfo.c',
33 'evil_locale.c',
34 'evil_main.c',
35 'evil_mman.c',
36 'evil_pwd.c',
37 'evil_stdio.c',
38 'evil_stdlib.c',
39 'evil_string.c',
40 'evil_time.c',
41 'evil_unistd.c',
42 'evil_util.c',
43 'evil_private.h',
44 'evil_fnmatch_private.h',
45 ]
46
47 subdir('regex')
48
49 psapi = cc.find_library('psapi')
50 ole32 = cc.find_library('ole32')
51 ws2_32 = cc.find_library('ws2_32')
52 secur32 = cc.find_library('secur32')
53 uuid = cc.find_library('uuid')
54 msvcr100 = cc.find_library('msvcr100')
55
56 evil_lib = library('evil', evil_src,
57 dependencies : [psapi, ole32, ws2_32, secur32, uuid, msvcr100],
58 include_directories : [config_dir, include_directories('regex')],
59 )
60
61 evil = declare_dependency(
62 include_directories: [config_dir, include_directories('regex'), include_directories('.')],
63 dependencies : [psapi, ole32, ws2_32, secur32, uuid, msvcr100],
64 link_with: evil_lib,
65 )
66else
67 evil = declare_dependency()
68 automatic_pkgfile = false
69endif
diff --git a/src/lib/evil/regex/meson.build b/src/lib/evil/regex/meson.build
new file mode 100644
index 0000000000..d04769b72d
--- /dev/null
+++ b/src/lib/evil/regex/meson.build
@@ -0,0 +1,10 @@
1evil_src += files([
2'regcomp.c',
3'regerror.c',
4'regexec.c',
5'regfree.c',
6'cclass.h',
7'cname.h',
8'regex2.h',
9'utils.h'
10])