"Update it, perhaps by running llvm/utils/gn/get.py")
}
+ # Make these apply to all tools below.
+ lib_switch = "-l"
+ lib_dir_switch = "-L"
+
tool("solink") {
outfile = "{{output_dir}}/{{target_output_name}}{{output_extension}}"
if (current_os == "ios" || current_os == "mac") {
}
description = "SOLINK $outfile"
outputs = [ outfile ]
- lib_switch = "-l"
output_prefix = "lib"
default_output_dir = "{{root_out_dir}}/lib"
}
}
description = "SOLINK $outfile"
outputs = [ outfile ]
- lib_switch = "-l"
default_output_dir = "{{root_out_dir}}/lib"
}
}
description = "LINK $outfile"
outputs = [ outfile ]
- lib_switch = "-l"
# Setting this allows targets to override the default executable output by
# setting output_dir.
default_output_dir = "{{root_out_dir}}/lib"
}
+ # Make these apply to all tools below.
+ lib_switch = ""
+ lib_dir_switch = "/LIBPATH:"
+
tool("solink") {
outprefix = "{{output_dir}}/{{target_output_name}}"
dllfile = "$outprefix{{output_extension}}"
dllfile,
libfile,
]
- lib_switch = ""
default_output_extension = ".dll"
restat = true
command = "$link /nologo /dll {{ldflags}} /out:$dllfile /pdb:$pdbfile {{inputs}} {{libs}} "
description = "LINK_MODULE $dllfile"
outputs = [ dllfile ]
- lib_switch = ""
runtime_outputs = outputs
default_output_extension = ".dll"
command = "$link /nologo {{ldflags}} /out:$outfile /pdb:$pdbfile {{inputs}} {{libs}}"
description = "LINK $outfile"
outputs = [ outfile ]
- lib_switch = ""
default_output_extension = ".exe"
# Setting this allows targets to override the default executable output by
dia_lib_path = ""
if (sysroot != "") {
- assert(gn_version >= 1937,
- "Building with sysroot and DIA requires a newer GN. " +
- "Run `python3 llvm\utils\gn\get.py` to update.")
include_dirs = [ "$sysroot/DIA SDK/include" ]
- dia_lib_path = "$sysroot/DIA SDK/lib/" # x86 .lib file is here.
- if (current_cpu == "arm") {
- dia_lib_path += "arm/"
+ dia_lib_path = "$sysroot/DIA SDK/lib" # x86 .lib file is here.
+ if (current_cpu == "/arm") {
+ dia_lib_path += "arm"
} else if (current_cpu == "arm64") {
- dia_lib_path += "arm64/"
+ dia_lib_path += "/arm64"
} else if (current_cpu == "x64") {
- dia_lib_path += "amd64/"
+ dia_lib_path += "/amd64"
}
+ lib_dirs = [ dia_lib_path ]
}
- libs = [ "${dia_lib_path}diaguids.lib" ]
+ libs = [ "diaguids.lib" ]
}
}