Remove references to Python2
copy-pasted from pitkajuh. See https://github.com/root-project/cling/pull/519
This commit is contained in:
parent
dac25f50f3
commit
42d2fb1493
@ -11,7 +11,6 @@
|
|||||||
# All configuration values have a default; values that are commented out
|
# All configuration values have a default; values that are commented out
|
||||||
# serve to show the default.
|
# serve to show the default.
|
||||||
|
|
||||||
from __future__ import absolute_import, division, print_function
|
|
||||||
import sys, os
|
import sys, os
|
||||||
from datetime import date
|
from datetime import date
|
||||||
|
|
||||||
|
@ -1,8 +1,7 @@
|
|||||||
#!/usr/bin/env python
|
#!/usr/bin/env python3
|
||||||
|
|
||||||
# A tool to parse cling.pod.in and generate cling.pod dynamically
|
# A tool to parse cling.pod.in and generate cling.pod dynamically
|
||||||
|
|
||||||
from __future__ import print_function
|
|
||||||
import subprocess
|
import subprocess
|
||||||
import sys
|
import sys
|
||||||
import os
|
import os
|
||||||
|
@ -13,13 +13,7 @@ from lit.llvm import llvm_config
|
|||||||
|
|
||||||
# Configuration file for the 'lit' test runner.
|
# Configuration file for the 'lit' test runner.
|
||||||
|
|
||||||
if sys.version_info < (3, 0):
|
from urllib.request import urlopen
|
||||||
# Python 2.x
|
|
||||||
from urllib2 import urlopen
|
|
||||||
input = raw_input
|
|
||||||
else:
|
|
||||||
# Python 3.x
|
|
||||||
from urllib.request import urlopen
|
|
||||||
|
|
||||||
IsWindows = platform.system() == 'Windows'
|
IsWindows = platform.system() == 'Windows'
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
#!/usr/bin/env python
|
#!/usr/bin/env python3
|
||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
# CLING - the C++ LLVM-based InterpreterG :)
|
# CLING - the C++ LLVM-based InterpreterG :)
|
||||||
# author: Min RK
|
# author: Min RK
|
||||||
@ -15,8 +15,6 @@ Cling Kernel for Jupyter
|
|||||||
Talks to Cling via ctypes
|
Talks to Cling via ctypes
|
||||||
"""
|
"""
|
||||||
|
|
||||||
from __future__ import print_function
|
|
||||||
|
|
||||||
__version__ = '0.0.3'
|
__version__ = '0.0.3'
|
||||||
|
|
||||||
import ctypes
|
import ctypes
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
#!/usr/bin/env python
|
#!/usr/bin/env python3
|
||||||
# coding: utf-8
|
# coding: utf-8
|
||||||
|
|
||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
@ -11,8 +11,6 @@
|
|||||||
# LICENSE.TXT for details.
|
# LICENSE.TXT for details.
|
||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
|
|
||||||
from __future__ import print_function
|
|
||||||
|
|
||||||
# the name of the project
|
# the name of the project
|
||||||
name = 'clingkernel'
|
name = 'clingkernel'
|
||||||
|
|
||||||
@ -23,13 +21,11 @@ name = 'clingkernel'
|
|||||||
import sys
|
import sys
|
||||||
|
|
||||||
v = sys.version_info
|
v = sys.version_info
|
||||||
if v[:2] < (2,7) or (v[0] >= 3 and v[:2] < (3,3)):
|
if v[0] >= 3 and v[:2] < (3,3):
|
||||||
error = "ERROR: %s requires Python version 2.7 or 3.3 or above." % name
|
error = "ERROR: %s requires Python version 3.3 or above." % name
|
||||||
print(error, file=sys.stderr)
|
print(error, file=sys.stderr)
|
||||||
sys.exit(1)
|
sys.exit(1)
|
||||||
|
|
||||||
PY3 = (sys.version_info[0] >= 3)
|
|
||||||
|
|
||||||
#-----------------------------------------------------------------------------
|
#-----------------------------------------------------------------------------
|
||||||
# get on with it
|
# get on with it
|
||||||
#-----------------------------------------------------------------------------
|
#-----------------------------------------------------------------------------
|
||||||
|
@ -21,10 +21,6 @@
|
|||||||
|
|
||||||
|
|
||||||
import sys
|
import sys
|
||||||
|
|
||||||
if sys.version_info < (3, 0):
|
|
||||||
raise Exception("cpt needs Python 3")
|
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
import copy
|
import copy
|
||||||
import os
|
import os
|
||||||
@ -100,7 +96,7 @@ def travis_fold_end(tag):
|
|||||||
|
|
||||||
def box_draw_header():
|
def box_draw_header():
|
||||||
msg = 'cling (' + platform.machine() + ')' \
|
msg = 'cling (' + platform.machine() + ')' \
|
||||||
+ formatdate(time.time(), tzinfo())
|
+ formatdate(time.time(), tzinfo())
|
||||||
spaces_no = 80 - len(msg) - 4
|
spaces_no = 80 - len(msg) - 4
|
||||||
spacer = ' ' * spaces_no
|
spacer = ' ' * spaces_no
|
||||||
msg = 'cling (' + platform.machine() + ')' \
|
msg = 'cling (' + platform.machine() + ')' \
|
||||||
@ -1842,7 +1838,7 @@ def make_dmg(CPT_SRC_DIR):
|
|||||||
|
|
||||||
parser = argparse.ArgumentParser(description='Cling Packaging Tool')
|
parser = argparse.ArgumentParser(description='Cling Packaging Tool')
|
||||||
parser.add_argument('--last-stable-build', help='Build the last stable snapshot in one of these formats: tar | deb | nsis | rpm | dmg | pkg')
|
parser.add_argument('--last-stable-build', help='Build the last stable snapshot in one of these formats: tar | deb | nsis | rpm | dmg | pkg')
|
||||||
parser.add_argument('--current-dev-build',
|
parser.add_argument('--current-dev-build',
|
||||||
help=('--current-dev:<tar | deb | nsis | rpm | dmg | pkg> will build the latest development snapshot in the given format'
|
help=('--current-dev:<tar | deb | nsis | rpm | dmg | pkg> will build the latest development snapshot in the given format'
|
||||||
+ '\n--current-dev:branch:<branch> will build <branch> on llvm, clang, and cling'
|
+ '\n--current-dev:branch:<branch> will build <branch> on llvm, clang, and cling'
|
||||||
+ '\n--current-dev:branches:<a,b,c> will build branch <a> on llvm, <b> on clang, and <c> on cling'))
|
+ '\n--current-dev:branches:<a,b,c> will build branch <a> on llvm, <b> on clang, and <c> on cling'))
|
||||||
|
Loading…
Reference in New Issue
Block a user