X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2Fwrappergen%2Fsrc%2FHXX2SALOME_GENERIC_CLASS_NAME_SRC%2Fpy-compile;h=f0b8e5dc63a065ba37cc71b50b283aea6a4e990e;hb=896e1e052885d1fc49bf852545aec82eb63134f4;hp=d6e900b30e6c0be041761d67eebaf95637253792;hpb=a84e60a749da66dffb73297fa5082b70b9d62f7d;p=modules%2Fyacs.git diff --git a/src/wrappergen/src/HXX2SALOME_GENERIC_CLASS_NAME_SRC/py-compile b/src/wrappergen/src/HXX2SALOME_GENERIC_CLASS_NAME_SRC/py-compile index d6e900b30..f0b8e5dc6 100755 --- a/src/wrappergen/src/HXX2SALOME_GENERIC_CLASS_NAME_SRC/py-compile +++ b/src/wrappergen/src/HXX2SALOME_GENERIC_CLASS_NAME_SRC/py-compile @@ -107,40 +107,32 @@ import sys, os, string, py_compile files = '''$files''' -print 'Byte-compiling python modules...' +print('Byte-compiling python modules...') for file in string.split(files): $pathtrans $filetrans if not os.path.exists(filepath) or not (len(filepath) >= 3 and filepath[-3:] == '.py'): - continue - print file, + continue + print(file, end='') sys.stdout.flush() py_compile.compile(filepath, filepath + 'c', path) -print" || exit $? +print()" || exit $? # this will fail for python < 1.5, but that doesn't matter ... $PYTHON -O -c " import sys, os, string, py_compile files = '''$files''' -print 'Byte-compiling python modules (optimized versions) ...' +print('Byte-compiling python modules (optimized versions) ...') for file in string.split(files): $pathtrans $filetrans if not os.path.exists(filepath) or not (len(filepath) >= 3 and filepath[-3:] == '.py'): - continue - print file, + continue + print(file, end='') sys.stdout.flush() py_compile.compile(filepath, filepath + 'o', path) -print" 2>/dev/null || : - -# Local Variables: -# mode: shell-script -# sh-indentation: 2 -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-end: "$" -# End: +print()" 2>/dev/null || : +