diff options
author | David Robillard <d@drobilla.net> | 2008-10-02 00:37:58 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2008-10-02 00:37:58 +0000 |
commit | cdc04eddccf36eed3a43d696da073a523a9af559 (patch) | |
tree | ce0022bb81ef98832a17429c999d0d9abe14c7fd | |
parent | e94bb5bb095283fd2f5c5c601ec3e13ef1a5e499 (diff) | |
download | patchage-cdc04eddccf36eed3a43d696da073a523a9af559.tar.gz patchage-cdc04eddccf36eed3a43d696da073a523a9af559.tar.bz2 patchage-cdc04eddccf36eed3a43d696da073a523a9af559.zip |
Add option system to autowaf (place for consistent global options e.g. prefix).
Factor out message pretty printing from Patchage and add status printing to autowaf.
git-svn-id: http://svn.drobilla.net/lad/trunk/patchage@1577 a436a847-0d15-0410-975c-d299462d15a1
-rw-r--r-- | wscript | 27 |
1 files changed, 9 insertions, 18 deletions
@@ -2,7 +2,7 @@ # Parts from LADI Patchage by Nedko Arnaudov import os import Params -from Configure import g_maxlen +import autowaf # Version of this package (even if built as a child) PATCHAGE_VERSION = '0.4.2' @@ -29,15 +29,6 @@ def set_options(opt): opt.add_option('--no-alsa', action='store_true', default=False, dest='no_alsa', help="Do not build Alsa Sequencer support") -def display_msg(msg, status = None, color = None): - global g_maxlen - g_maxlen = max(g_maxlen, len(msg)) - if status: - print "%s :" % msg.ljust(g_maxlen), - Params.pprint(color, status) - else: - print "%s" % msg.ljust(g_maxlen) - def configure(conf): if not conf.env['CXX']: conf.check_tool('compiler_cxx') @@ -97,15 +88,15 @@ def configure(conf): conf.write_config_header('waf-config.h') - print + autowaf.print_summary(conf) + print 'Patchage Configuration:' - display_msg("Install prefix", conf.env['PREFIX'], 'CYAN') - display_msg("Install name", "'" + conf.env['APP_INSTALL_NAME'] + "'", 'CYAN') - display_msg("App human name", "'" + conf.env['APP_HUMAN_NAME'] + "'", 'CYAN') - display_msg("Jack (D-Bus)", str(bool(conf.env['HAVE_JACK_DBUS'])), 'YELLOW') - display_msg("LASH (D-Bus)", str(bool(conf.env['HAVE_LASH'])), 'YELLOW') - display_msg("Jack (libjack)", str(bool(conf.env['USE_LIBJACK'])), 'YELLOW') - display_msg("Alsa Sequencer", str(bool(conf.env['HAVE_ALSA'])), 'YELLOW') + autowaf.display_msg("Install name", "'" + conf.env['APP_INSTALL_NAME'] + "'", 'CYAN') + autowaf.display_msg("App human name", "'" + conf.env['APP_HUMAN_NAME'] + "'", 'CYAN') + autowaf.display_msg("Jack (D-Bus)", str(bool(conf.env['HAVE_JACK_DBUS'])), 'YELLOW') + autowaf.display_msg("LASH (D-Bus)", str(bool(conf.env['HAVE_LASH'])), 'YELLOW') + autowaf.display_msg("Jack (libjack)", str(bool(conf.env['USE_LIBJACK'])), 'YELLOW') + autowaf.display_msg("Alsa Sequencer", str(bool(conf.env['HAVE_ALSA'])), 'YELLOW') print def build(bld): |