File tree Expand file tree Collapse file tree 2 files changed +6
-0
lines changed Expand file tree Collapse file tree 2 files changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -112,6 +112,10 @@ fn main() {
112112 println ! ( "cargo:rustc-cfg=llvm_component=\" {}\" " , component) ;
113113 }
114114
115+ if major >= 9 {
116+ println ! ( "cargo:rustc-cfg=llvm_has_msp430_asm_parser" ) ;
117+ }
118+
115119 // Link in our own LLVM shims, compiled with the same flags as LLVM
116120 let mut cmd = Command :: new ( & llvm_config) ;
117121 cmd. arg ( "--cxxflags" ) ;
Original file line number Diff line number Diff line change @@ -76,6 +76,8 @@ pub fn initialize_available_targets() {
7676 LLVMInitializeMSP430Target ,
7777 LLVMInitializeMSP430TargetMC ,
7878 LLVMInitializeMSP430AsmPrinter ) ;
79+ init_target ! ( all( llvm_component = "msp430" , llvm_has_msp430_asm_parser) ,
80+ LLVMInitializeMSP430AsmParser ) ;
7981 init_target ! ( llvm_component = "riscv" ,
8082 LLVMInitializeRISCVTargetInfo ,
8183 LLVMInitializeRISCVTarget ,
You can’t perform that action at this time.
0 commit comments