meson: standardized config defines to set integer 1
This commit is contained in:
parent
f3958288ac
commit
d8c348e897
2 changed files with 7 additions and 5 deletions
|
@ -66,7 +66,7 @@ if host_machine.system() == 'darwin'
|
||||||
# meson neither supports objcpp_std nor inherits cpp_std https://github.com/mesonbuild/meson/issues/5495
|
# meson neither supports objcpp_std nor inherits cpp_std https://github.com/mesonbuild/meson/issues/5495
|
||||||
add_project_arguments('-std=c++11', language: 'objcpp')
|
add_project_arguments('-std=c++11', language: 'objcpp')
|
||||||
elif host_machine.system() != 'windows'
|
elif host_machine.system() != 'windows'
|
||||||
conf.set('WITH_FONTCONFIG', '1')
|
conf.set('WITH_FONTCONFIG', 1)
|
||||||
deps += dependency('fontconfig')
|
deps += dependency('fontconfig')
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
@ -100,7 +100,7 @@ endif
|
||||||
|
|
||||||
deps += boost_dep
|
deps += boost_dep
|
||||||
if host_machine.system() == 'windows'
|
if host_machine.system() == 'windows'
|
||||||
conf.set('BOOST_USE_WINDOWS_H', '1')
|
conf.set('BOOST_USE_WINDOWS_H', 1)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
deps += dependency('zlib')
|
deps += dependency('zlib')
|
||||||
|
@ -195,7 +195,7 @@ foreach dep: [
|
||||||
optname = dep[0].split('-')[0]
|
optname = dep[0].split('-')[0]
|
||||||
if d.found() and not get_option(optname).disabled()
|
if d.found() and not get_option(optname).disabled()
|
||||||
deps += d
|
deps += d
|
||||||
conf.set('WITH_@0@'.format(dep[0].split('-')[0].to_upper()), '1')
|
conf.set('WITH_@0@'.format(dep[0].split('-')[0].to_upper()), 1)
|
||||||
dep_avail += dep[2]
|
dep_avail += dep[2]
|
||||||
elif get_option(optname).enabled()
|
elif get_option(optname).enabled()
|
||||||
error('@0@ enabled but not found'.format(dep[2]))
|
error('@0@ enabled but not found'.format(dep[2]))
|
||||||
|
@ -218,7 +218,7 @@ if host_machine.system() == 'windows' and not get_option('directsound').disabled
|
||||||
dxguid_dep = cc.find_library('dxguid', required: true)
|
dxguid_dep = cc.find_library('dxguid', required: true)
|
||||||
if dsound_dep.found() and winmm_dep.found() and ole32_dep.found() and dxguid_dep.found() and have_dsound_h
|
if dsound_dep.found() and winmm_dep.found() and ole32_dep.found() and dxguid_dep.found() and have_dsound_h
|
||||||
deps += [dsound_dep, winmm_dep, ole32_dep, dxguid_dep]
|
deps += [dsound_dep, winmm_dep, ole32_dep, dxguid_dep]
|
||||||
conf.set('WITH_DIRECTSOUND', '1')
|
conf.set('WITH_DIRECTSOUND', 1)
|
||||||
dep_avail += 'DirectSound'
|
dep_avail += 'DirectSound'
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
|
@ -214,7 +214,9 @@ elif host_machine.system() == 'windows'
|
||||||
depends: version_h,
|
depends: version_h,
|
||||||
include_directories: [res_inc, version_inc, wx_inc])
|
include_directories: [res_inc, version_inc, wx_inc])
|
||||||
endif
|
endif
|
||||||
elif conf.get('WITH_FONTCONFIG') == '1'
|
endif
|
||||||
|
|
||||||
|
if conf.has('WITH_FONTCONFIG')
|
||||||
aegisub_src += 'font_file_lister_fontconfig.cpp'
|
aegisub_src += 'font_file_lister_fontconfig.cpp'
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue