Projects
SLE15
bombono
bombono.scons.patch
Sign Up
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File bombono.scons.patch of Package bombono
--- a/SConstruct +++ b/SConstruct @@ -1,4 +1,5 @@ #!/usr/bin/env python +from __future__ import print_function import string import os import sys @@ -274,13 +275,13 @@ def ParseVariables(user_options): # Config if os.path.exists( BV.CfgFile ): - print "Using config file: " + BV.CfgFile + print ("Using config file: " + BV.CfgFile) user_options = Variables(BV.CfgFile, BV.Args) ParseVariables(user_options) else: - print "Creating new config file: " + BV.CfgFile + print ("Creating new config file: " + BV.CfgFile) user_options = Variables(None, BV.Args) ParseVariables(user_options) @@ -352,20 +353,19 @@ BV.VariantDir(BV.BuildDir, '.', duplicat def GenerateBaseConfigH(target, source, env): cfg_file = open(target[0].path, 'w') - print >> cfg_file, "/* Generated by means of Autoconfig */" + print ("/* Generated by means of Autoconfig */" , file=cfg_file) config_dict = user_options_dict['CONFIGURATION'] - key_list = config_dict.keys() - key_list.sort() + key_list = sorted(config_dict.keys()) for key in key_list: var = config_dict[key] text = var.get('text', None) if text: - print >> cfg_file + print ("", file=cfg_file) BV.AddComment(cfg_file, var) - print >> cfg_file, text + print (text, file=cfg_file) continue BV.AddDefine(cfg_file, key, **var) --- a/tools/scripts/BuildVars.py +++ b/tools/scripts/BuildVars.py @@ -1,4 +1,5 @@ # Global variables for Atom build process +from __future__ import print_function import os import platform @@ -31,9 +32,9 @@ UserOptDict = {} def PrintBright(is_end): if not is_end: print - print "****************************************************" + print ("****************************************************") else: - print "****************************************************" + print ("****************************************************") print def IsDebugCfg(): @@ -68,10 +69,10 @@ def IsBuildOrRunTests(): def CheckSettings(main_env): global Cc, Cxx, BuildDir, Targets, RunTests, BuildTests if RunTests : - print 'Tests: on' + print ("Tests: on") else: if BuildTests: - print 'Tests: on (only building)' + print ("Tests: on (only building)") def_env = GetDefEnv() # for SCons =<0.96 we need to warn that just 'scons' is not enough: @@ -92,9 +93,9 @@ def CheckSettings(main_env): ( (len(BuildDir) >= 1 and BuildDir[0] == '/') or (len(BuildDir) >= 2 and BuildDir[0:2] == '..') ) and \ (Targets == [] or Targets == ['.']) : PrintBright(0) - print 'Warning! "scons" or "scons ." detected while BUILD_DIR is outside "."!' - print 'To build successfully with SCons <= v0.96.1 you may need to run something like ' - print '\t"scons <...> ' + BuildDir + '".' + print ('Warning! "scons" or "scons ." detected while BUILD_DIR is outside "."!') + print ('To build successfully with SCons <= v0.96.1 you may need to run something like ') + print ('\t"scons <...> ' + BuildDir + '".' ) PrintBright(1) # we use TestSConscript() function instead of SConscript() @@ -228,7 +229,7 @@ def SetBriefOutput(env): def ErrorAndExit(msg): PrintBright(0) - print msg + print (msg) PrintBright(1) GetDefEnv().Exit(1) @@ -383,20 +384,20 @@ def AddComment(cfg_file, var): comment = MakeHeaderComment(var['ccomment'], var.get('val') == '1') if comment: - print >> cfg_file, "/* " + comment + " */" + print ("/* " + comment + " */", file=cfg_file) def AddDefine(cfg_file, key, **var): - print >> cfg_file + print ("", file=cfg_file) AddComment(cfg_file, var) if var['is_on']: str = var.get('val', None) if str == None: - print >> cfg_file, "#define %s" % key + print ("#define %s" % key, file=cfg_file) else: - print >> cfg_file, "#define %s %s" % (key, var['val']) + print ("#define %s %s" % (key, var['val']), file=cfg_file) else: - print >> cfg_file, "/* #undef %s */" % key + print ("/* #undef %s */" % key, file=cfg_file) GenFunctionMap = {} @@ -495,7 +496,7 @@ def IsToBuildQuick(): res = True elif not IsReenter(IsToBuildQuick): # warn once only - print 'BUILD_QUICK=true is not supported for current compiler(%s)!' % Cc + print ('BUILD_QUICK=true is not supported for current compiler(%s)!' % Cc) return res @@ -504,7 +505,7 @@ def ExtendEnvVariable(env, name, add_nam def CreateEnvVersion2(**kw): tools = ['default', 'AuxTools'] - if kw.has_key('tools'): + if 'tools' in kw: tools += kw['tools'] kw['tools'] = tools --- a/po/SConscript +++ b/po/SConscript @@ -35,7 +35,7 @@ def po_builder(target,source,env): str(source[0]), str(source[1]), ] - print 'Updating ' + trgt + print ('Updating ' + trgt) return os.spawnvp(os.P_WAIT, 'msgmerge', args) po_bld = Builder (action = po_builder) --- a/libs/mpeg2dec/SConscript +++ b/libs/mpeg2dec/SConscript @@ -1,4 +1,5 @@ #!/usr/bin/env python +from __future__ import print_function ####################### # Port from Automake.am @@ -69,9 +70,7 @@ def AddMpeg2DecDesc(cfg_file): def GenerateMpeg2DecCfg(target, source, env): cfg_file = open(target[0].path, 'w') - print >> cfg_file, "/* Auto-generated header */" - print >> cfg_file - print >> cfg_file, '#include <cfg/config.h>' + print ('#include <cfg/config.h>', file=cfg_file) BuildVars.AddDefine(cfg_file, 'ACCEL_DETECT', is_on = 1, comment = "autodetect accelerations") BuildVars.AddDefine(cfg_file, 'LIBVO_DX', is_on = 0, comment = "libvo DirectX support")
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.