@@ -18,6 +18,8 @@ import shutil
18
18
from subprocess import check_call , check_output
19
19
import sys
20
20
from threading import Lock
21
+ from urllib .error import HTTPError
22
+ from urllib .request import urlopen
21
23
22
24
from lib import foreach_repo_parallel , github_post
23
25
from git import git_ids_and_branches , git_timestamp_id , git_datetime_id , git_archive_id
@@ -270,7 +272,7 @@ def dpkg_source(name, git, series):
270
272
271
273
return dsc_path , tar_path
272
274
273
- def dpkg_binary (dsc_path , name , git , series , build_arch , build_all ):
275
+ def dpkg_binary (dsc_path , name , git , series , build_arch , build_all , pockets ):
274
276
with open (dsc_path , "r" ) as fp :
275
277
dsc = Dsc (fp )
276
278
@@ -354,9 +356,19 @@ def dpkg_binary(dsc_path, name, git, series, build_arch, build_all):
354
356
"--extra-repository=deb http://ppa.launchpad.net/" + ppa_proposed + "/ubuntu " + series .codename + " main" ,
355
357
"--extra-repository=deb-src http://ppa.launchpad.net/" + ppa_proposed + "/ubuntu " + series .codename + " main" ,
356
358
"--extra-repository-key=" + path .join (POP_DIR , "scripts" , ppa_key ),
359
+ "--extra-repository-key=" + path .join (POP_DIR , "scripts" , ".pop-os.asc" ),
357
360
"--no-apt-distupgrade" ,
358
361
]
359
362
363
+ for (repo , _ ) in pockets :
364
+ if repo != "master" :
365
+ try :
366
+ urlopen ("http://apt.pop-os.org/staging/{}/dists/{}/Release" .format (repo , series .codename ))
367
+ except HTTPError :
368
+ pass
369
+ else :
370
+ sbuild .append ("--extra-repository=deb http://apt.pop-os.org/staging/{} {} main" .format (repo , series .codename ))
371
+
360
372
if build_all :
361
373
sbuild .append ("--arch-all" )
362
374
@@ -404,7 +416,7 @@ def build_packages_thread(args):
404
416
if dsc_path and tar_path :
405
417
for build_arch in build_archs :
406
418
build_all = build_archs [build_arch ]
407
- deb_paths += dpkg_binary (dsc_path , name , git , series , build_arch , build_all )
419
+ deb_paths += dpkg_binary (dsc_path , name , git , series , build_arch , build_all , pockets )
408
420
return (name , git , series , pockets , dsc_path , tar_path , deb_paths )
409
421
410
422
def build_packages (name ):
0 commit comments