@ -32,25 +32,23 @@ for json_file in work_dir.glob("*.json"):
image_info [ " profiles " ] [ device_id ] [ " images " ] [ 0 ]
image_info [ " profiles " ] [ device_id ] [ " images " ] [ 0 ]
)
)
default_packages , output [ " arch_packages " ] = run (
[
" make " ,
" --no-print-directory " ,
" -C " ,
f " target/linux/ { output [ ' target ' ] . split ( ' / ' ) [ 0 ] } " ,
" val.DEFAULT_PACKAGES " ,
" val.ARCH_PACKAGES " ,
] ,
capture_output = True ,
check = True ,
env = environ . copy ( ) . update ( { " TOPDIR " : Path ( ) . cwd ( ) } ) ,
text = True ,
) . stdout . splitlines ( )
output [ " default_packages " ] = default_packages . split ( )
if output :
if output :
default_packages , output [ " arch_packages " ] = run (
[
" make " ,
" --no-print-directory " ,
" -C " ,
f " target/linux/ { output [ ' target ' ] . split ( ' / ' ) [ 0 ] } " ,
" val.DEFAULT_PACKAGES " ,
" val.ARCH_PACKAGES " ,
] ,
capture_output = True ,
check = True ,
env = environ . copy ( ) . update ( { " TOPDIR " : Path ( ) . cwd ( ) } ) ,
text = True ,
) . stdout . splitlines ( )
output [ " default_packages " ] = default_packages . split ( )
output_path . write_text ( json . dumps ( output , sort_keys = True , separators = ( " , " , " : " ) ) )
output_path . write_text ( json . dumps ( output , sort_keys = True , separators = ( " , " , " : " ) ) )
else :
else :
print ( " JSON info file script could not find any JSON files for target " )
print ( " JSON info file script could not find any JSON files for target " )