1
0
mirror of https://gitlab.com/fdroid/fdroidserver.git synced 2024-07-04 16:30:12 +02:00

Merge branch 'ndk-path-long' into 'master'

metadata.Build.ndk_path(): find long form ndk too

Closes #1099

See merge request fdroid/fdroidserver!1313
This commit is contained in:
Hans-Christoph Steiner 2023-03-20 13:40:10 +00:00
commit 08d4b4671c

View File

@ -21,6 +21,7 @@
import git
from pathlib import Path
import platform
import os
import re
import logging
import importlib
@ -329,7 +330,13 @@ class Build(dict):
ndk = self.ndk
if isinstance(ndk, list):
ndk = self.ndk[0]
return common.config['ndk_paths'].get(ndk, '')
path = common.config['ndk_paths'].get(ndk)
if path:
return path
for vsn, path in common.config['ndk_paths'].items():
if not vsn.endswith("_orig") and path and os.path.basename(path) == ndk:
return path
return ''
flagtypes = {