Ignore:
Timestamp:
Sep 24, 2018, 10:22:03 PM (6 years ago)
Author:
Paul Brossier <piem@piem.org>
Branches:
feature/autosink, feature/cnn, feature/cnn_org, feature/constantq, feature/crepe, feature/crepe_org, feature/pitchshift, feature/pydocstrings, feature/timestretch, fix/ffmpeg5, master
Children:
981e0a38
Parents:
31742b8
Message:

python/lib/gen_external.py: verbose compiler warnings

File:
1 edited

Legend:

Unmodified
Added
Removed
  • python/lib/gen_external.py

    r31742b8 r073b969  
    107107    err_output = proc.stderr.read()
    108108    if err_output:
    109         print("Warning: preprocessor produced errors or warnings:\n%s" % err_output)
     109        print("Warning: preprocessor produced errors or warnings:\n%s" \
     110                % err_output.decode('utf8'))
    110111    if not cpp_output:
    111         raise Exception("preprocessor output is empty:\n%s" % err_output)
     112        raise_msg = "preprocessor output is empty! Running command " \
     113                + "\"%s\" failed" % " ".join(cpp_cmd)
     114        if err_output:
     115            raise_msg += " with stderr: \"%s\"" % err_output.decode('utf8')
     116        else:
     117            raise_msg += " with no stdout or stderr"
     118        raise Exception(raise_msg)
    112119    if not isinstance(cpp_output, list):
    113120        cpp_output = [l.strip() for l in cpp_output.decode('utf8').split('\n')]
Note: See TracChangeset for help on using the changeset viewer.