Skip to content

Commit ecffd6b

Browse files
committed
Pass TERMUX_PACKAGES_DIRECTORIES explicitly to the script
Signed-off-by: Aditya Alok <[email protected]>
1 parent 9bcacf8 commit ecffd6b

File tree

2 files changed

+13
-12
lines changed

2 files changed

+13
-12
lines changed

scripts/bionic_buildorder.py

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -288,17 +288,6 @@ def _resolve_dependencies(self, dep: Dependency | AlternativeDependency):
288288
build_mode = BuildMode.ONLINE
289289

290290
repos: List[Path] = args.repos
291-
if not repos:
292-
from json import load as json_load
293-
294-
try:
295-
with open("./repo.json") as f:
296-
repos = []
297-
for d in json_load(f).keys():
298-
if d != "pkg_format":
299-
repos.append(Path(Path.cwd() / d))
300-
except FileNotFoundError:
301-
die("'repo.json' file not found at %s. Check script location." % Path.cwd())
302291

303292
# TEMP
304293
log_dir = Path("./log")
@@ -318,6 +307,18 @@ def _resolve_dependencies(self, dep: Dependency | AlternativeDependency):
318307
""")
319308
# END TEMP
320309

310+
if not repos:
311+
from json import load as json_load
312+
313+
try:
314+
with open("./repo.json") as f:
315+
repos = []
316+
for d in json_load(f).keys():
317+
if d != "pkg_format":
318+
repos.append(Path(Path.cwd() / d))
319+
except FileNotFoundError:
320+
die("'repo.json' file not found at %s. Check script location." % Path.cwd())
321+
321322
for order in BuildOrder(package, repos, build_mode).generate_order():
322323
package_name = order.name
323324

scripts/build/termux_step_get_dependencies_bionic.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,5 +133,5 @@ termux_step_get_dependencies_bionic() {
133133
echo "$dep_version" >"$TERMUX_BUILT_PACKAGES_DIRECTORY/$dep"
134134
fi
135135
fi
136-
done < <(./scripts/bionic_buildorder.py $([[ "${TERMUX_INSTALL_DEPS}" == "true" ]] && echo "-i") "$TERMUX_PKG_NAME" || echo "ERROR")
136+
done < <(./scripts/bionic_buildorder.py $([[ "${TERMUX_INSTALL_DEPS}" == "true" ]] && echo "-i") "$TERMUX_PKG_NAME" $TERMUX_PACKAGES_DIRECTORIES || echo "ERROR")
137137
}

0 commit comments

Comments
 (0)