diff options
author | David Robillard <d@drobilla.net> | 2012-09-10 18:26:52 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2012-09-10 18:26:52 +0000 |
commit | fa1ca60516b48f07e2e414e28aaee3963913f40a (patch) | |
tree | d4ae4e3fd5d7637897133defbf15ba73138cba0e /wscript | |
parent | babb2cb630bcd3a80ba3498ba23631c5002ed149 (diff) | |
download | sratom-fa1ca60516b48f07e2e414e28aaee3963913f40a.tar.gz sratom-fa1ca60516b48f07e2e414e28aaee3963913f40a.tar.bz2 sratom-fa1ca60516b48f07e2e414e28aaee3963913f40a.zip |
Support building against parallel debuggable libraries via pkg-config.
git-svn-id: http://svn.drobilla.net/lad/trunk/sratom@4766 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'wscript')
-rw-r--r-- | wscript | 36 |
1 files changed, 16 insertions, 20 deletions
@@ -1,28 +1,22 @@ #!/usr/bin/env python import os import subprocess - -from waflib.extras import autowaf as autowaf +import waflib.Logs as Logs import waflib.Options as Options +import waflib.extras.autowaf as autowaf -# Version of this package (even if built as a child) -SRATOM_VERSION = '0.4.1' -SRATOM_MAJOR_VERSION = '0' - -# Library version (UNIX style major, minor, micro) +# Library and package version (UNIX style major, minor, micro) # major increment <=> incompatible changes # minor increment <=> compatible changes (additions) # micro increment <=> no interface changes -# Sratom uses the same version number for both library and package -SRATOM_LIB_VERSION = SRATOM_VERSION - -# Variables for 'waf dist' -APPNAME = 'sratom' -VERSION = SRATOM_VERSION +SRATOM_VERSION = '0.4.1' +SRATOM_MAJOR_VERSION = '0' -# Mandatory variables -top = '.' -out = 'build' +# Mandatory waf variables +APPNAME = 'sratom' # Package name for waf dist +VERSION = SRATOM_VERSION # Package version for waf dist +top = '.' # Source directory +out = 'build' # Build directory def options(opt): opt.load('compiler_c') @@ -53,19 +47,21 @@ def configure(conf): define_name='HAVE_GCOV', mandatory=False) - autowaf.check_pkg(conf, 'lv2', atleast_version='1.0.0', uselib_store='LV2') + autowaf.check_pkg(conf, 'lv2', uselib_store='LV2', + atleast_version='1.0.0', mandatory=True) autowaf.check_pkg(conf, 'serd-0', uselib_store='SERD', atleast_version='0.14.0', mandatory=True) autowaf.check_pkg(conf, 'sord-0', uselib_store='SORD', atleast_version='0.8.0', mandatory=True) autowaf.define(conf, 'SRATOM_VERSION', SRATOM_VERSION) + autowaf.set_lib_env(conf, 'sratom', SRATOM_VERSION) conf.write_config_header('sratom_config.h', remove=False) autowaf.display_msg(conf, "Unit tests", str(conf.env.BUILD_TESTS)) print('') -lib_source = [ 'src/sratom.c' ] +lib_source = ['src/sratom.c'] def build(bld): # C Headers @@ -94,7 +90,7 @@ def build(bld): lib = libs, name = 'libsratom', target = 'sratom-%s' % SRATOM_MAJOR_VERSION, - vnum = SRATOM_LIB_VERSION, + vnum = SRATOM_VERSION, install_path = '${LIBDIR}', defines = defines + ['SRATOM_SHARED', 'SRATOM_INTERNAL'], cflags = libflags) @@ -109,7 +105,7 @@ def build(bld): lib = libs, name = 'libsratom_static', target = 'sratom-%s' % SRATOM_MAJOR_VERSION, - vnum = SRATOM_LIB_VERSION, + vnum = SRATOM_VERSION, install_path = '${LIBDIR}', defines = defines + ['SRATOM_INTERNAL']) autowaf.use_lib(bld, obj, 'SERD SORD LV2') |