From fb1d5440eaaa8f984f8c8d2fe6f7a38f13547f5e Mon Sep 17 00:00:00 2001 From: Thomas Nagy Date: Thu, 12 Mar 2015 19:24:02 +0100 Subject: [PATCH] cleanup --- ChangeLog | 5 +++ waf-light | 2 +- waflib/Context.py | 6 ++-- waflib/ansiterm.py | 4 +-- waflib/extras/dumbpreproc.py | 61 ------------------------------------ wscript | 28 ++--------------- 6 files changed, 13 insertions(+), 93 deletions(-) delete mode 100644 waflib/extras/dumbpreproc.py diff --git a/ChangeLog b/ChangeLog index 02acc055..851ea06a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +NEW IN WAF 1.8.8 +---------------- +* Fixed a regression in Fortran builds #1546 +* Doxygen tool enhancements + NEW IN WAF 1.8.7 ---------------- * Fixed the default libdir installation suffix on Redhat 64-bit systems #1536 diff --git a/waf-light b/waf-light index 39ac5fad..320745f6 100755 --- a/waf-light +++ b/waf-light @@ -32,7 +32,7 @@ POSSIBILITY OF SUCH DAMAGE. import os, sys, inspect -VERSION="1.8.7" +VERSION="1.8.8" REVISION="x" GIT="x" INSTALL="x" diff --git a/waflib/Context.py b/waflib/Context.py index 762dfda3..974df0c7 100644 --- a/waflib/Context.py +++ b/waflib/Context.py @@ -11,13 +11,13 @@ from waflib import Utils, Errors, Logs import waflib.Node # the following 3 constants are updated on each new release (do not touch) -HEXVERSION=0x1080700 +HEXVERSION=0x1080800 """Constant updated on new releases""" -WAFVERSION="1.8.7" +WAFVERSION="1.8.8" """Constant updated on new releases""" -WAFREVISION="e5056b9ade7bb224f53baab13a0ce136344ab602" +WAFREVISION="cca30e91f4e1796b6a9c204b1604ac52315fad56" """Git revision when the waf version is updated""" ABI = 98 diff --git a/waflib/ansiterm.py b/waflib/ansiterm.py index 28add846..e7a4ce75 100644 --- a/waflib/ansiterm.py +++ b/waflib/ansiterm.py @@ -12,9 +12,9 @@ console commands. """ import os, re, sys -from waflib.Utils import threading +from waflib import Utils -wlock = threading.Lock() +wlock = Utils.threading.Lock() try: from ctypes import Structure, windll, c_short, c_ushort, c_ulong, c_int, byref, c_wchar, POINTER, c_long diff --git a/waflib/extras/dumbpreproc.py b/waflib/extras/dumbpreproc.py deleted file mode 100644 index 62463019..00000000 --- a/waflib/extras/dumbpreproc.py +++ /dev/null @@ -1,61 +0,0 @@ -#!/usr/bin/env python -# encoding: utf-8 -# Thomas Nagy, 2006-2010 (ita) - -""" -Dumb C/C++ preprocessor for finding dependencies - -It will look at all include files it can find after removing the comments, so the following -will always add the dependency on both "a.h" and "b.h":: - - #include "a.h" - #ifdef B - #include "b.h" - #endif - int main() { - return 0; - } - -To use:: - - def configure(conf): - conf.load('compiler_c') - conf.load('c_dumbpreproc') -""" - -import re, sys, os, string, traceback -from waflib import Logs, Build, Utils, Errors -from waflib.Logs import debug, error -from waflib.Tools import c_preproc - -re_inc = re.compile( - '^[ \t]*(#|%:)[ \t]*(include)[ \t]*[<"](.*)[>"]\r*$', - re.IGNORECASE | re.MULTILINE) - -def lines_includes(node): - code = node.read() - if c_preproc.use_trigraphs: - for (a, b) in c_preproc.trig_def: code = code.split(a).join(b) - code = c_preproc.re_nl.sub('', code) - code = c_preproc.re_cpp.sub(c_preproc.repl, code) - return [(m.group(2), m.group(3)) for m in re.finditer(re_inc, code)] - -parser = c_preproc.c_parser -class dumb_parser(parser): - def addlines(self, node): - if node in self.nodes[:-1]: - return - self.currentnode_stack.append(node.parent) - self.lines = lines_includes(node) + [(c_preproc.POPFILE, '')] + self.lines - - def start(self, node, env): - self.addlines(node) - while self.lines: - (x, y) = self.lines.pop(0) - if x == c_preproc.POPFILE: - self.currentnode_stack.pop() - continue - self.tryfind(y) - -c_preproc.c_parser = dumb_parser - diff --git a/wscript b/wscript index 38e08e1e..fbd71447 100644 --- a/wscript +++ b/wscript @@ -10,14 +10,13 @@ To add a tool that does not exist in the folder compat15, pass an absolute path: """ -VERSION="1.8.7" +VERSION="1.8.8" APPNAME='waf' REVISION='' top = '.' out = 'build' -demos = ['cpp', 'qt4', 'tex', 'ocaml', 'kde3', 'adv', 'cc', 'idl', 'docbook', 'xmlwaf', 'gnome'] zip_types = ['bz2', 'gz', 'xz'] PRELUDE = '' @@ -118,29 +117,6 @@ def options(opt): opt.add_option('--prelude', action='store', help='Code to execute before calling waf', dest='prelude', default=PRELUDE) opt.load('python') -def compute_revision(): - global REVISION - - def visit(arg, dirname, names): - for pos, name in enumerate(names): - if name[0] == '.' or name in ('_build_', 'build'): - del names[pos] - elif name.endswith('.py'): - arg.append(os.path.join(dirname, name)) - sources = [] - os.path.walk('waflib', visit, sources) - sources.sort() - m = md5() - for source in sources: - f = open(source,'rb') - readBytes = 100000 - while (readBytes): - readString = f.read(readBytes) - m.update(readString) - readBytes = len(readString) - f.close() - REVISION = m.hexdigest() - def process_tokens(tokens): accu = [] prev = tokenize.NEWLINE @@ -369,7 +345,7 @@ def create_waf(self, *k, **kw): return (kd.replace(ch.encode(), s.encode()), s) raise - # The reverse order prevent collisions + # The reverse order prevents collisions (cnt, C3) = find_unused(cnt, '\x00') (cnt, C2) = find_unused(cnt, '\r') (cnt, C1) = find_unused(cnt, '\n')