summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2019-08-23 11:08:44 +0200
committerErich Eckner <git@eckner.net>2019-08-23 11:08:44 +0200
commit162a7b0b1bed54ca6e34817e1e48da0700d0412a (patch)
tree613ceedc9daf03781da215718d3bc1fe6a57bed1
parentcf3c20ce7b9afefac53980bb1741af4031125c2e (diff)
downloadbuilder-162a7b0b1bed54ca6e34817e1e48da0700d0412a.tar.xz
bin/get-assignment: (hopefully) fix the toolchain_order logic for scheduling
-rwxr-xr-xbin/get-assignment23
1 files changed, 13 insertions, 10 deletions
diff --git a/bin/get-assignment b/bin/get-assignment
index 5ef88b1..630519b 100755
--- a/bin/get-assignment
+++ b/bin/get-assignment
@@ -338,16 +338,19 @@ next_building=$(
printf ' JOIN `considered_build_assignments_3` AS `e_cba`'
printf ' ON `e_cba`.`id`=`e_ba`.`id`'
printf ' WHERE `late`.`pkgbase`=`package_sources`.`pkgbase`'
-# this might be handy - but we need to mark in `toolchain_order` whether
-# the blocking needs any or all early packages built (first vs. second
-# half of toolchain_order)
-# printf ' AND NOT EXISTS ('
-# printf 'SELECT 1 FROM `binary_packages` AS `e_bp`'
-# mysql_join_binary_packages_binary_packages_in_repositories 'e_bp' 'e_bpir'
-# mysql_join_binary_packages_in_repositories_repositories 'e_bpir' 'e_r'
-# printf ' WHERE `e_bp`.`build_assignment`=`e_ba`.`id`'
-# printf ' AND `e_r`.`is_on_master_mirror`'
-# printf ')'
+ # the toolchain_order-blocked build-assignment
+ printf ' AND ('
+ # must be marked as requires_all_dependencies_built (second half of list)
+ printf '`late`.`requires_all_dependencies_built` OR'
+ # or all blocking dependencies must not yet been built
+ printf 'NOT EXISTS ('
+ printf 'SELECT 1 FROM `binary_packages` AS `e_bp`'
+ mysql_join_binary_packages_binary_packages_in_repositories 'e_bp' 'e_bpir'
+ mysql_join_binary_packages_in_repositories_repositories 'e_bpir' 'e_r'
+ printf ' WHERE `e_bp`.`build_assignment`=`e_ba`.`id`'
+ printf ' AND `e_r`.`is_on_master_mirror`'
+ printf ')'
+ printf ')'
printf ') AS `exists_blocked`,'
printf 'EXISTS ('
printf 'SELECT 1'