aboutsummaryrefslogtreecommitdiffstats
path: root/wscript
diff options
context:
space:
mode:
Diffstat (limited to 'wscript')
-rw-r--r--wscript118
1 files changed, 106 insertions, 12 deletions
diff --git a/wscript b/wscript
index af363ca..4562825 100644
--- a/wscript
+++ b/wscript
@@ -7,7 +7,7 @@ from waflib import Options
from waflib.extras import autowaf as autowaf
# Version of this package (even if built as a child)
-JALV_VERSION = '1.6.4'
+JALV_VERSION = '1.6.5'
# Mandatory waf variables
APPNAME = 'jalv' # Package name for waf dist
@@ -42,38 +42,117 @@ def configure(conf):
conf.load('autowaf', cache=True)
autowaf.set_c_lang(conf, 'c99')
- conf.check_pkg('lv2 >= 1.16.0', uselib_store='LV2')
+ if Options.options.ultra_strict:
+ autowaf.add_compiler_flags(conf.env, 'c', {
+ 'clang': [
+ '-Wno-bad-function-cast',
+ '-Wno-missing-noreturn',
+ ],
+ 'gcc': [
+ '-Wno-bad-function-cast',
+ '-Wno-c++-compat',
+ ],
+ })
+
+ autowaf.add_compiler_flags(conf.env, '*', {
+ 'clang': [
+ '-Wno-atomic-implicit-seq-cst',
+ '-Wno-c99-extensions',
+ '-Wno-cast-align',
+ '-Wno-cast-qual',
+ '-Wno-disabled-macro-expansion',
+ '-Wno-documentation-unknown-command',
+ '-Wno-double-promotion',
+ '-Wno-float-conversion',
+ '-Wno-float-equal',
+ '-Wno-format-nonliteral',
+ '-Wno-implicit-fallthrough',
+ '-Wno-implicit-float-conversion',
+ '-Wno-padded',
+ '-Wno-redundant-parens',
+ '-Wno-reserved-id-macro',
+ '-Wno-shorten-64-to-32',
+ '-Wno-sign-conversion',
+ '-Wno-switch-enum',
+ '-Wno-unused-macros',
+ '-Wno-unused-parameter',
+ '-Wno-vla',
+ ],
+ 'gcc': [
+ '-Wno-cast-align',
+ '-Wno-cast-qual',
+ '-Wno-conversion',
+ '-Wno-double-promotion',
+ '-Wno-float-conversion',
+ '-Wno-float-equal',
+ '-Wno-padded',
+ '-Wno-pedantic',
+ '-Wno-stack-protector',
+ '-Wno-switch-enum',
+ '-Wno-unused-macros',
+ '-Wno-unused-parameter',
+ '-Wno-vla',
+ ],
+ })
+
+ autowaf.add_compiler_flags(conf.env, 'cxx', {
+ 'clang': [
+ '-Wno-extra-semi-stmt',
+ '-Wno-old-style-cast',
+ '-Wno-weak-vtables',
+ '-Wno-zero-as-null-pointer-constant',
+ ],
+ 'gcc': [
+ '-Wno-effc++',
+ ],
+ })
+
+ conf.check_pkg('lv2 >= 1.17.2', uselib_store='LV2')
conf.check_pkg('lilv-0 >= 0.24.0', uselib_store='LILV')
conf.check_pkg('serd-0 >= 0.24.0', uselib_store='SERD')
conf.check_pkg('sord-0 >= 0.14.0', uselib_store='SORD')
conf.check_pkg('sratom-0 >= 0.6.0', uselib_store='SRATOM')
if Options.options.portaudio:
conf.check_pkg('portaudio-2.0 >= 2.0.0',
- uselib_store='PORTAUDIO', mandatory=False)
+ uselib_store='PORTAUDIO',
+ system=True,
+ mandatory=False)
else:
- conf.check_pkg('jack >= 0.120.0', uselib_store='JACK')
+ conf.check_pkg('jack >= 0.120.0',
+ uselib_store='JACK',
+ system=True)
if not Options.options.no_gui and not Options.options.no_gtk:
if not Options.options.no_gtk2:
- conf.check_pkg('gtk+-2.0 >= 2.18.0', uselib_store='GTK2',
+ conf.check_pkg('gtk+-2.0 >= 2.18.0',
+ uselib_store='GTK2',
+ system=True,
mandatory=False)
if not Options.options.no_gtkmm:
- conf.check_pkg('gtkmm-2.4 >= 2.20.0', uselib_store='GTKMM2',
+ conf.check_pkg('gtkmm-2.4 >= 2.20.0',
+ uselib_store='GTKMM2',
+ system=True,
mandatory=False)
if not Options.options.no_gtk3:
- conf.check_pkg('gtk+-3.0 >= 3.0.0', uselib_store='GTK3',
+ conf.check_pkg('gtk+-3.0 >= 3.0.0',
+ uselib_store='GTK3',
+ system=True,
mandatory=False)
if not Options.options.no_gui and not Options.options.no_qt:
if not Options.options.no_qt4:
- conf.check_pkg('QtGui >= 4.0.0', uselib_store='QT4',
+ conf.check_pkg('QtGui >= 4.0.0',
+ uselib_store='QT4',
+ system=True,
mandatory=False)
if conf.env.HAVE_QT4:
if not conf.find_program('moc-qt4', var='MOC4', mandatory=False):
conf.find_program('moc', var='MOC4')
if not Options.options.no_qt5:
- conf.check_pkg('Qt5Widgets >= 5.1.0', uselib_store='QT5',
+ conf.check_pkg('Qt5Widgets >= 5.1.0',
+ uselib_store='QT5',
+ system=True,
mandatory=False)
if conf.env.HAVE_QT5:
if not conf.find_program('moc-qt5', var='MOC5', mandatory=False):
@@ -90,12 +169,20 @@ def configure(conf):
header_name = 'jack/jack.h',
define_name = 'HAVE_JACK_PORT_TYPE_GET_BUFFER_SIZE',
uselib = 'JACK',
+ return_type = 'size_t',
+ arg_types = 'jack_client_t*,const char*',
mandatory = False)
conf.check_function('c', 'jack_set_property',
header_name = 'jack/metadata.h',
define_name = 'HAVE_JACK_METADATA',
uselib = 'JACK',
+ return_type = 'int',
+ arg_types = '''jack_client_t*,
+ jack_uuid_t,
+ const char*,
+ const char*,
+ const char*''',
mandatory = False)
defines = ['_POSIX_C_SOURCE=200809L']
@@ -104,29 +191,36 @@ def configure(conf):
header_name = 'unistd.h',
defines = defines,
define_name = 'HAVE_ISATTY',
+ return_type = 'int',
+ arg_types = 'int',
mandatory = False)
conf.check_function('c', 'fileno',
header_name = 'stdio.h',
defines = defines,
define_name = 'HAVE_FILENO',
+ return_type = 'int',
+ arg_types = 'FILE*',
mandatory = False)
conf.check_function('c', 'mlock',
header_name = 'sys/mman.h',
defines = defines,
define_name = 'HAVE_MLOCK',
+ return_type = 'int',
+ arg_types = 'const void*,size_t',
mandatory = False)
conf.check_function('c', 'sigaction',
header_name = 'signal.h',
defines = defines,
define_name = 'HAVE_SIGACTION',
+ return_type = 'int',
+ arg_types = '''int,
+ const struct sigaction*,
+ struct sigaction*''',
mandatory = False)
- if conf.is_defined('HAVE_ISATTY') and conf.is_defined('HAVE_FILENO'):
- conf.env.append_unique('CFLAGS', ['-D_POSIX_C_SOURCE=200809L'])
-
if not Options.options.no_jack_session:
conf.define('JALV_JACK_SESSION', 1)