@@ -182,29 +182,19 @@ def get_distributions(cls, ctx, extra_dist_dirs=[]):
182182 dists .append (dist )
183183 return dists
184184
185- # def save_info(self):
186- # '''
187- # Save information about the distribution in its dist_dir.
188- # '''
189- # with current_directory(self.dist_dir):
190- # info('Saving distribution info')
191- # with open('dist_info.json', 'w') as fileh:
192- # json.dump({'dist_name': self.name,
193- # 'archs': [arch.arch for arch in self.ctx.archs],
194- # 'ndk_api': self.ctx.ndk_api,
195- # 'recipes': self.ctx.recipe_build_order},
196- # fileh)
197-
198- # def load_info(self):
199- # '''Load information about the dist from the info file that p4a
200- # automatically creates.'''
201- # with current_directory(self.dist_dir):
202- # filen = 'dist_info.json'
203- # if not exists(filen):
204- # return None
205- # with open('dist_info.json', 'r') as fileh:
206- # dist_info = json.load(fileh)
207- # return dist_info
185+ def save_info (self , dirn ):
186+ '''
187+ Save information about the distribution in its dist_dir.
188+ '''
189+ with current_directory (dirn ):
190+ info ('Saving distribution info' )
191+ with open ('dist_info.json' , 'w' ) as fileh :
192+ json .dump ({'dist_name' : self .ctx .dist_name ,
193+ 'bootstrap' : self .ctx .bootstrap .name ,
194+ 'archs' : [arch .arch for arch in self .ctx .archs ],
195+ 'ndk_api' : self .ctx .ndk_api ,
196+ 'recipes' : self .ctx .recipe_build_order + self .ctx .python_modules },
197+ fileh )
208198
209199
210200def pretty_log_dists (dists , log_func = info ):
0 commit comments