vdrift/vdrift-python3.patch
Gwyn Ciesla f6a0856898 Fix FTBFS.
2019-08-03 12:46:15 -05:00

83 lines
3.8 KiB
Diff

--- SConstruct~ 2019-08-02 16:20:27.000000000 -0500
+++ SConstruct 2019-08-02 16:20:59.703964106 -0500
@@ -518,7 +518,7 @@
Export(['env', 'version', 'src_dir', 'bin_dir'])
if 'install' in COMMAND_LINE_TARGETS:
if not os.path.isfile('data/SConscript'):
- raise 'VDrift data not found. Please make sure data is placed in vdrift directory. See README.md and http://wiki.vdrift.net.'
+ print 'VDrift data not found. Please make sure data is placed in vdrift directory. See README.md and http://wiki.vdrift.net.'
SConscript('data/SConscript')
# desktop appdata installation
install_desktop = env.Install(env['destdir'] + env['prefix'] + '/share/applications', 'vdrift.desktop')
--- SConstruct.bak 2019-08-02 16:25:00.652707553 -0500
+++ SConstruct 2019-08-02 16:25:21.205679013 -0500
@@ -92,9 +92,9 @@
for a in env['universal']:
if not sdk_path:
- print 'Building a universal binary require access to an ' + \
+ print('Building a universal binary require access to an ' + \
'SDK that has universal \nbinary support.If you know ' + \
- 'the location of such an SDK, specify it using the \n"SDK" option'
+ 'the location of such an SDK, specify it using the \n"SDK" option')
Exit(1)
env.Append( CCFLAGS = ['-arch', a], LINKFLAGS = ['-arch', a] )
@@ -141,11 +141,11 @@
CC = 'gcc', CXX = 'g++',
options = opts)
# Take environment variables into account
- if os.environ.has_key('CXX'):
+ if 'CXX' in os.environ:
env['CXX'] = os.environ['CXX']
- if os.environ.has_key('CXXFLAGS'):
+ if 'CXXFLAGS' in os.environ:
env['CXXFLAGS'] += SCons.Util.CLVar(os.environ['CXXFLAGS'])
- if os.environ.has_key('LDFLAGS'):
+ if 'LDFLAGS' in os.environ:
env['LINKFLAGS'] += SCons.Util.CLVar(os.environ['LDFLAGS'])
check_headers = ['GL/gl.h', 'SDL2/SDL.h', 'SDL2/SDL_image.h', 'vorbis/vorbisfile.h', 'curl/curl.h', 'bullet/btBulletCollisionCommon.h', 'bullet/btBulletDynamicsCommon.h']
check_libs = []
@@ -232,7 +232,7 @@
def tarballer (target, source, env):
cmd = 'tar -jcf "%s" -C "%s" .' % ( str(target[0]), str(source[0]) )
#cmd = 'tar -jcf ' + str (target[0]) + ' ' + str(source[0]) + " --exclude '*~' "
- print 'running ', cmd, ' ... '
+ print('running ', cmd, ' ... ')
p = os.popen (cmd)
return p.close ()
@@ -362,11 +362,11 @@
conf = Configure(env)
for header in check_headers:
if not conf.CheckCXXHeader(header):
- print 'You do not have the %s headers installed. Exiting.' % header
+ print('You do not have the %s headers installed. Exiting.' % header)
Exit(1)
for lib in check_libs:
if not conf.CheckLibWithHeader(lib[0], lib[1], 'C', lib[2]):
- print lib[3]
+ print(lib[3])
Exit(1)
env = conf.Finish()
@@ -518,7 +518,7 @@
Export(['env', 'version', 'src_dir', 'bin_dir'])
if 'install' in COMMAND_LINE_TARGETS:
if not os.path.isfile('data/SConscript'):
- print 'VDrift data not found. Please make sure data is placed in vdrift directory. See README.md and http://wiki.vdrift.net.'
+ print('VDrift data not found. Please make sure data is placed in vdrift directory. See README.md and http://wiki.vdrift.net.')
SConscript('data/SConscript')
# desktop appdata installation
install_desktop = env.Install(env['destdir'] + env['prefix'] + '/share/applications', 'vdrift.desktop')
--- src/SConscript~ 2014-09-04 15:06:21.000000000 -0500
+++ src/SConscript 2019-08-03 09:51:18.019800029 -0500
@@ -151,7 +151,7 @@
utils.cpp
window.cpp""")
-src.sort(lambda x, y: cmp(x.lower(),y.lower()))
+#src.sort(lambda x, y: cmp(x.lower(),y.lower()))
#------------------------#
# Copy Build Environment #