diff options
author | David Robillard <d@drobilla.net> | 2015-11-13 20:34:15 -0500 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2015-11-13 20:34:15 -0500 |
commit | be50d4b038e7be89a44957d81f9f23cd1a0c3e30 (patch) | |
tree | 8b5a177f6b721fbb8b7e00312e531854d6df5fbd /wscript | |
parent | 2d0304f4ccdd008c85d160b5e06d0df98d172508 (diff) | |
download | pugl-be50d4b038e7be89a44957d81f9f23cd1a0c3e30.tar.gz pugl-be50d4b038e7be89a44957d81f9f23cd1a0c3e30.tar.bz2 pugl-be50d4b038e7be89a44957d81f9f23cd1a0c3e30.zip |
Clean up wscript
Diffstat (limited to 'wscript')
-rw-r--r-- | wscript | 36 |
1 files changed, 16 insertions, 20 deletions
@@ -1,29 +1,24 @@ #!/usr/bin/env python import glob import os +import subprocess import sys +import waflib.Logs as Logs +import waflib.Options as Options +import waflib.extras.autowaf as autowaf -from waflib.extras import autowaf as autowaf -import waflib.Logs as Logs, waflib.Options as Options - -# Version of this package (even if built as a child) -PUGL_VERSION = '0.2.0' -PUGL_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 -# Pugl uses the same version number for both library and package -PUGL_LIB_VERSION = PUGL_VERSION - -# Variables for 'waf dist' -APPNAME = 'pugl' -VERSION = PUGL_VERSION +PUGL_VERSION = '0.2.0' +PUGL_MAJOR_VERSION = '0' -# Mandatory variables -top = '.' -out = 'build' +# Mandatory waf variables +APPNAME = 'pugl' # Package name for waf dist +VERSION = PUGL_VERSION # Package version for waf dist +top = '.' # Source directory +out = 'build' # Build directory def options(opt): opt.load('compiler_c') @@ -135,7 +130,7 @@ def build(bld): framework = framework, name = 'libpugl', target = 'pugl-%s' % PUGL_MAJOR_VERSION, - vnum = PUGL_LIB_VERSION, + vnum = PUGL_VERSION, install_path = '${LIBDIR}', defines = defines, cflags = libflags + [ '-DPUGL_SHARED', @@ -152,7 +147,7 @@ def build(bld): framework = framework, name = 'libpugl_static', target = 'pugl-%s' % PUGL_MAJOR_VERSION, - vnum = PUGL_LIB_VERSION, + vnum = PUGL_VERSION, install_path = '${LIBDIR}', defines = defines, cflags = ['-DPUGL_INTERNAL']) @@ -193,10 +188,11 @@ def build(bld): doxyfile = 'Doxyfile') def lint(ctx): + "checks code for style issues" subprocess.call('cpplint.py --filter=+whitespace/comments,-whitespace/tab,-whitespace/braces,-whitespace/labels,-build/header_guard,-readability/casting,-readability/todo,-build/include src/* pugl/*', shell=True) +# Alias .m files to be compiled the same as .c files, gcc will do the right thing. from waflib import TaskGen @TaskGen.extension('.m') def m_hook(self, node): - "Alias .m files to be compiled the same as .c files, gcc will do the right thing." return self.create_compiled_task('c', node) |