diff options
author | 2017-06-16 11:15:50 +0300 | |
---|---|---|
committer | 2017-06-16 11:15:50 +0300 | |
commit | 2b437de5449558dd44b8966faae9b35d9bca0f88 (patch) | |
tree | f8488991db453baddd3f0fa34cfc06ce9d23d428 /meson.build | |
parent | ce9c8a885fc3bd828565094b06b4d201cd4f2790 (diff) | |
parent | 1cd2cd0ac5fe6ad74e9ef0a4fbf62b74aedbef74 (diff) | |
download | librin-2b437de5449558dd44b8966faae9b35d9bca0f88.tar.gz librin-2b437de5449558dd44b8966faae9b35d9bca0f88.tar.bz2 librin-2b437de5449558dd44b8966faae9b35d9bca0f88.zip |
Merge branch 'meson'
Diffstat (limited to 'meson.build')
-rw-r--r-- | meson.build | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/meson.build b/meson.build new file mode 100644 index 0000000..50073cf --- /dev/null +++ b/meson.build @@ -0,0 +1,35 @@ +project('librin', 'c', + license : 'LGPL2.1', + default_options : 'c_std=gnu89') + +inc = include_directories('include') + +if get_option('gpio') + thread_dep = dependency('threads') +else + thread_dep = [] +endif + +deps = thread_dep + +subdir('include') +subdir('src') + +if ((not get_option('static')) and (not get_option('shared'))) + librin = library('rin', sources, version : '0.0.0', include_directories : inc, install : true, dependencies : deps) +endif + +if get_option('static') + librin = static_library('rin', sources, version : '0.0.0', include_directories : inc, install : true, dependencies : deps) +endif + +if get_option('shared') + librin = shared_library('rin', sources, version : '0.0.0', include_directories : inc, install : true, dependencies : deps) +endif + + +if get_option('tests') + subdir('test') + test_e = executable('test executable', test_sources, include_directories : inc, link_with : librin) + test('librin test', test_e) +endif |