Fix the libcompiler_rt path.

This commit is contained in:
Tim 'mithro' Ansell 2020-02-23 17:04:47 -08:00
parent 1c1c5bcbda
commit 83b2581331
2 changed files with 4 additions and 1 deletions

View File

@ -15,6 +15,7 @@ import struct
import shutil import shutil
from litex.build.tools import write_to_file from litex.build.tools import write_to_file
from litex.data.find import find_data
from litex.soc.integration import export, soc_core from litex.soc.integration import export, soc_core
__all__ = ["soc_software_packages", "soc_directory", __all__ = ["soc_software_packages", "soc_directory",
@ -100,6 +101,8 @@ class Builder:
exec_profiles["EXECUTE_IN_PLACE"] = "1" exec_profiles["EXECUTE_IN_PLACE"] = "1"
for k, v in exec_profiles.items(): for k, v in exec_profiles.items():
define(k, v) define(k, v)
define(
"COMPILER_RT_DIRECTORY", find_data("software", "compiler_rt"))
define("SOC_DIRECTORY", soc_directory) define("SOC_DIRECTORY", soc_directory)
variables_contents.append("export BUILDINC_DIRECTORY\n") variables_contents.append("export BUILDINC_DIRECTORY\n")
define("BUILDINC_DIRECTORY", self.include_dir) define("BUILDINC_DIRECTORY", self.include_dir)

View File

@ -23,7 +23,7 @@ libcompiler_rt.a: $(OBJECTS)
mulsi3.o: $(SOC_DIRECTORY)/software/libcompiler_rt/mulsi3.c mulsi3.o: $(SOC_DIRECTORY)/software/libcompiler_rt/mulsi3.c
$(compile) $(compile)
%.o: $(SOC_DIRECTORY)/software/compiler_rt/lib/builtins/%.c %.o: $(COMPILER_RT_DIRECTORY)/lib/builtins/%.c
$(compile) $(compile)
.PHONY: all clean .PHONY: all clean