@@ -78,12 +78,12 @@ def get_bootstrap_name():
7878 _bootstrap_name = get_bootstrap_name ()
7979else :
8080 PYTHON = "python3"
81- _bootstrap_name = "sdl2 "
81+ _bootstrap_name = "sdl3 "
8282
8383if PYTHON is not None and not exists (PYTHON ):
8484 PYTHON = None
8585
86- if _bootstrap_name in ('sdl2' , 'webview' , 'service_only' , 'qt' ):
86+ if _bootstrap_name in ('sdl2' , 'sdl3' , ' webview' , 'service_only' , 'qt' ):
8787 WHITELIST_PATTERNS .append ('pyconfig.h' )
8888
8989environment = jinja2 .Environment (loader = jinja2 .FileSystemLoader (
@@ -541,7 +541,7 @@ def make_package(args):
541541 "debug" : "debug" in args .build_mode ,
542542 "native_services" : args .native_services
543543 }
544- if get_bootstrap_name () == "sdl2" :
544+ if get_bootstrap_name () in [ "sdl2" , "sdl3" ] :
545545 render_args ["url_scheme" ] = url_scheme
546546
547547 render (
@@ -596,7 +596,7 @@ def make_package(args):
596596 "args" : args ,
597597 "private_version" : hashlib .sha1 (private_version .encode ()).hexdigest ()
598598 }
599- if get_bootstrap_name () == "sdl2" :
599+ if get_bootstrap_name () in [ "sdl2" , "sdl3" ] :
600600 render_args ["url_scheme" ] = url_scheme
601601 render (
602602 'strings.tmpl.xml' ,
@@ -769,7 +769,7 @@ def create_argument_parser():
769769 ap .add_argument ('--private' , dest = 'private' ,
770770 help = 'the directory with the app source code files' +
771771 ' (containing your main.py entrypoint)' ,
772- required = (get_bootstrap_name () != "sdl2" ))
772+ required = (get_bootstrap_name () not in [ "sdl2" , "sdl3" ] ))
773773 ap .add_argument ('--package' , dest = 'package' ,
774774 help = ('The name of the java package the project will be'
775775 ' packaged under.' ),
@@ -787,7 +787,7 @@ def create_argument_parser():
787787 'same number of groups of numbers as previous '
788788 'versions.' ),
789789 required = True )
790- if get_bootstrap_name () == "sdl2" :
790+ if get_bootstrap_name () in [ "sdl2" , "sdl3" ] :
791791 ap .add_argument ('--launcher' , dest = 'launcher' , action = 'store_true' ,
792792 help = ('Provide this argument to build a multi-app '
793793 'launcher, rather than a single app.' ))
@@ -1044,7 +1044,7 @@ def _read_configuration():
10441044 args .orientation , args .manifest_orientation
10451045 )
10461046
1047- if get_bootstrap_name () == "sdl2" :
1047+ if get_bootstrap_name () in [ "sdl2" , "sdl3" ] :
10481048 args .sdl_orientation_hint = get_sdl_orientation_hint (args .orientation )
10491049
10501050 if args .res_xmls and isinstance (args .res_xmls [0 ], list ):
@@ -1074,9 +1074,9 @@ def _read_configuration():
10741074 WHITELIST_PATTERNS += patterns
10751075
10761076 if args .private is None and \
1077- get_bootstrap_name () == 'sdl2' and args .launcher is None :
1077+ get_bootstrap_name () in [ 'sdl2' , 'sdl3' ] and args .launcher is None :
10781078 print ('Need --private directory or ' +
1079- '--launcher (SDL2 bootstrap only)' +
1079+ '--launcher (SDL2/SDL3 bootstrap only)' +
10801080 'to have something to launch inside the .apk!' )
10811081 sys .exit (1 )
10821082 make_package (args )
0 commit comments