project('helloworld', 'c', version : '1.0', license : 'GPL-2.0-only') xtra_link_args = [] xtra_c_args = [ '-D_POSIX_C_SOURCE=200809L' ] if get_option('debug') == true xtra_c_args += '-DDEBUG' endif libac_dep = dependency('ac', fallback : ['libacron', 'libac_dep'], default_options: [ 'default_library=static' ] ) sources = [ 'net.c', 'main.c' ] executable('helloworld', sources, dependencies : [ libac_dep ], link_args : xtra_link_args, c_args : xtra_c_args, install : true )