Skip to content
Snippets Groups Projects
Commit dd6fd2c6 authored by Joakim Hunskaar's avatar Joakim Hunskaar
Browse files

clean gui build file

parent bc564132
No related branches found
No related tags found
1 merge request!16Draft: Cleaner build files
...@@ -5,18 +5,9 @@ project('GUI Project', 'cpp', ...@@ -5,18 +5,9 @@ project('GUI Project', 'cpp',
'c_std=c17', 'c_std=c17',
'default_library=static']) 'default_library=static'])
# Windows compilation has no pre-packaged SDL2 available, and compilation takes a while.
# If you want to compile from source, remove everything but the contents of the else clause.
if host_machine.system() == 'windows'
sdl2_dep = subproject('sdl2_windows').get_variable('sdl2_windows_dep')
else
sdl2_dep = dependency('sdl2')
endif
animationwindow_dep = dependency('animationwindow', fallback: ['animationwindow', 'animationwindow_dep']) animationwindow_dep = dependency('animationwindow', fallback: ['animationwindow', 'animationwindow_dep'])
std_lib_facilities_dep = dependency('std_lib_facilities', fallback: ['std_lib_facilities', 'std_lib_facilities_dep']) std_lib_facilities_dep = dependency('std_lib_facilities', fallback: ['std_lib_facilities', 'std_lib_facilities_dep'])
if host_machine.system() == 'linux' if host_machine.system() == 'linux'
compiler_flags = ['-Wconversion', '-fdiagnostics-color=always', '-Werror=return-type'] compiler_flags = ['-Wconversion', '-fdiagnostics-color=always', '-Werror=return-type']
else else
...@@ -25,4 +16,4 @@ endif ...@@ -25,4 +16,4 @@ endif
src = ['main.cpp'] src = ['main.cpp']
exe = executable('program', src, dependencies : [animationwindow_dep, sdl2_dep, std_lib_facilities_dep], cpp_args : compiler_flags) exe = executable('program', src, dependencies : [animationwindow_dep, std_lib_facilities_dep], cpp_args : compiler_flags)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment