@@ -48,9 +48,8 @@ def add_file(bundle, src_file, zip_name):
48
48
return file_sector_size
49
49
50
50
51
- def build_bundle (libs , bundle_version , output_filename ,
52
- build_tools_version = "devel" , mpy_cross = None , example_bundle = False ,
53
- pkg_folder_prefix = None ):
51
+ def build_bundle (libs , bundle_version , output_filename , pkg_folder_prefix ,
52
+ build_tools_version = "devel" , mpy_cross = None , example_bundle = False ):
54
53
build_dir = "build-" + os .path .basename (output_filename )
55
54
top_folder = os .path .basename (output_filename ).replace (".zip" , "" )
56
55
build_lib_dir = os .path .join (build_dir , top_folder , "lib" )
@@ -70,7 +69,7 @@ def build_bundle(libs, bundle_version, output_filename,
70
69
success = True
71
70
for library_path in libs :
72
71
try :
73
- build .library (library_path , build_lib_dir , pkg_folder_prefix = pkg_folder_prefix ,
72
+ build .library (library_path , build_lib_dir , pkg_folder_prefix ,
74
73
mpy_cross = mpy_cross , example_bundle = example_bundle )
75
74
except ValueError as e :
76
75
print ("build.library failure:" , library_path )
@@ -159,8 +158,7 @@ def build_bundles(filename_prefix, output_directory, library_location, library_d
159
158
zip_filename = os .path .join (output_directory ,
160
159
filename_prefix + '-py-{VERSION}.zip' .format (
161
160
VERSION = bundle_version ))
162
- build_bundle (libs , bundle_version , zip_filename ,
163
- pkg_folder_prefix = package_folder_prefix ,
161
+ build_bundle (libs , bundle_version , zip_filename , package_folder_prefix ,
164
162
build_tools_version = build_tools_version )
165
163
166
164
# Build .mpy bundle(s)
@@ -177,13 +175,12 @@ def build_bundles(filename_prefix, output_directory, library_location, library_d
177
175
filename_prefix + '-{TAG}-mpy-{VERSION}.zip' .format (
178
176
TAG = version ["name" ],
179
177
VERSION = bundle_version ))
180
- build_bundle (libs , bundle_version , zip_filename , mpy_cross = mpy_cross ,
181
- build_tools_version = build_tools_version ,
182
- pkg_folder_prefix = package_folder_prefix )
178
+ build_bundle (libs , bundle_version , zip_filename , package_folder_prefix ,
179
+ mpy_cross = mpy_cross , build_tools_version = build_tools_version )
183
180
184
181
# Build example bundle
185
182
zip_filename = os .path .join (output_directory ,
186
183
filename_prefix + '-examples-{VERSION}.zip' .format (
187
184
VERSION = bundle_version ))
188
- build_bundle (libs , bundle_version , zip_filename ,
185
+ build_bundle (libs , bundle_version , zip_filename , package_folder_prefix ,
189
186
build_tools_version = build_tools_version , example_bundle = True )
0 commit comments