Skip to content

Commit 5dfa71d

Browse files
committed
Build system: enable injection of deps with debug information
1 parent 43eb2bf commit 5dfa71d

2 files changed

Lines changed: 15 additions & 5 deletions

File tree

build-system/luxmake/deps.py

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -390,6 +390,12 @@ def main(
390390
action="store_true",
391391
help="Extended presets (including RelWithDebInfo & MinSizeRel)",
392392
)
393+
parser.add_argument(
394+
"-b",
395+
"--build-type",
396+
help="Build type from deps",
397+
default="Release",
398+
)
393399
if call_args is None:
394400
args = parser.parse_args() # Parse command line
395401
else:
@@ -536,6 +542,7 @@ def main(
536542
# Next line is a workaround to replace {{profile_dir}}, which is
537543
# not well handled by deployer...
538544
CONAN_ENV["LUX_PROFILE_DIR"] = str(profile_dir)
545+
build_type = args.build_type or "Release"
539546

540547
logger.info("Conan profile directory is %s", profile_dir)
541548
main_block = [
@@ -545,7 +552,7 @@ def main(
545552
"--deployer=full_deploy",
546553
f"--deployer-folder={output_dir}/dependencies",
547554
f"--output-folder={output_dir}",
548-
"--settings=build_type=Release",
555+
f"--settings=build_type={build_type}",
549556
f"--conf:all=tools.cmake.cmaketoolchain:generator={generator}",
550557
]
551558
if not os.getenv("DEPS_WITHOUT_SUDO"):

build-system/luxmake/wheel.py

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
import platform
1313
import os
1414
import shlex
15+
import itertools
1516
from pathlib import Path
1617

1718
from .constants import PARAMS
@@ -78,8 +79,11 @@ def _compute_platform_tag():
7879
def _get_lib_paths():
7980
"""Get library paths for dependencies."""
8081
base = PARAMS.BINARY_DIR / "dependencies" / "full_deploy" / "host"
81-
paths = (str(p.absolute()) for p in base.rglob("**/bin"))
82-
result = os.pathsep.join(paths)
82+
paths_bin = (str(p.absolute()) for p in base.rglob("**/bin"))
83+
paths_lib = (str(p.absolute()) for p in base.rglob("**/lib"))
84+
paths = itertools.chain(paths_bin, paths_lib)
85+
result = [ ["-l", Path(p)] for p in paths ]
86+
result = list(itertools.chain.from_iterable(result))
8387
return result
8488

8589

@@ -200,8 +204,7 @@ def make_wheel(args):
200204
"repairwheel",
201205
"-l",
202206
wheel_lib_dir,
203-
"-l",
204-
_get_lib_paths(),
207+
*_get_lib_paths(),
205208
"-o",
206209
PARAMS.WHEELHOUSE_DIR,
207210
input_path,

0 commit comments

Comments
 (0)