fixed problems with configuring projects on Windows
This commit is contained in:
parent
87c591d6b2
commit
c7d2686251
3 changed files with 22 additions and 2 deletions
|
@ -43,6 +43,7 @@ class ChooseProjects:
|
||||||
self.llvm_dir = llvm_dir
|
self.llvm_dir = llvm_dir
|
||||||
self.usages = dict() # type: Dict[str,List[str]]
|
self.usages = dict() # type: Dict[str,List[str]]
|
||||||
self.all_projects = [] # type: List[str]
|
self.all_projects = [] # type: List[str]
|
||||||
|
self.excluded_projects = set() # type: Set[str]
|
||||||
self._load_config()
|
self._load_config()
|
||||||
|
|
||||||
|
|
||||||
|
@ -54,6 +55,7 @@ class ChooseProjects:
|
||||||
for used in used_list:
|
for used in used_list:
|
||||||
self.usages.setdefault(used,[]).append(user)
|
self.usages.setdefault(used,[]).append(user)
|
||||||
self.all_projects = config['allprojects']
|
self.all_projects = config['allprojects']
|
||||||
|
self.excluded_projects = set(config['excludedProjects'])
|
||||||
|
|
||||||
def run(self):
|
def run(self):
|
||||||
llvm_dir = os.path.abspath(os.path.expanduser(args.llvmdir))
|
llvm_dir = os.path.abspath(os.path.expanduser(args.llvmdir))
|
||||||
|
@ -70,6 +72,7 @@ class ChooseProjects:
|
||||||
return 0
|
return 0
|
||||||
|
|
||||||
affected_projects = self.get_affected_projects(changed_projects)
|
affected_projects = self.get_affected_projects(changed_projects)
|
||||||
|
affected_projects = affected_projects - self.excluded_projects
|
||||||
print(';'.join(sorted(affected_projects)))
|
print(';'.join(sorted(affected_projects)))
|
||||||
return 0
|
return 0
|
||||||
|
|
||||||
|
|
|
@ -27,13 +27,18 @@ dependencies:
|
||||||
- llvm
|
- llvm
|
||||||
llgo:
|
llgo:
|
||||||
- llvm
|
- llvm
|
||||||
|
- clang
|
||||||
mlir:
|
mlir:
|
||||||
- llvm
|
- llvm
|
||||||
openmp: []
|
openmp:
|
||||||
|
- clang
|
||||||
parallel-libs: []
|
parallel-libs: []
|
||||||
polly:
|
polly:
|
||||||
- llvm
|
- llvm
|
||||||
pstl: []
|
pstl: []
|
||||||
|
debuginfo-tests:
|
||||||
|
- clang
|
||||||
|
- lld
|
||||||
|
|
||||||
# List of all projects in the LLVM monorepository. This list is taken from
|
# List of all projects in the LLVM monorepository. This list is taken from
|
||||||
# llvm/CMakeLists.txt in "set(LLVM_ALL_PROJECTS ..."
|
# llvm/CMakeLists.txt in "set(LLVM_ALL_PROJECTS ..."
|
||||||
|
@ -56,4 +61,10 @@ allprojects:
|
||||||
- parallel-libs
|
- parallel-libs
|
||||||
- polly
|
- polly
|
||||||
- pstl
|
- pstl
|
||||||
- llvm
|
- llvm
|
||||||
|
|
||||||
|
# projects excluded from automatic configuration as they could not be built
|
||||||
|
excludedProjects:
|
||||||
|
# no working with Visual Studio Compiler on Windows
|
||||||
|
- lldb
|
||||||
|
- llgo
|
||||||
|
|
|
@ -25,6 +25,11 @@ if ($projects -eq "default") {
|
||||||
$LLVM_ENABLE_PROJECTS="clang;clang-tools-extra;libcxx;libcxxabi;lld;libunwind;mlir"
|
$LLVM_ENABLE_PROJECTS="clang;clang-tools-extra;libcxx;libcxxabi;lld;libunwind;mlir"
|
||||||
} elseif ($projects -eq "detect") {
|
} elseif ($projects -eq "detect") {
|
||||||
$LLVM_ENABLE_PROJECTS = (git diff | python ${PSScriptRoot}\choose_projects.py . ) | Out-String
|
$LLVM_ENABLE_PROJECTS = (git diff | python ${PSScriptRoot}\choose_projects.py . ) | Out-String
|
||||||
|
$LLVM_ENABLE_PROJECTS = $LLVM_ENABLE_PROJECTS.replace("`n","").replace("`r","")
|
||||||
|
if ($LLVM_ENABLE_PROJECTS -eq "") {
|
||||||
|
Write-Error "Error detecting the affected projects."
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
$LLVM_ENABLE_PROJECTS=$projects
|
$LLVM_ENABLE_PROJECTS=$projects
|
||||||
}
|
}
|
||||||
|
@ -40,6 +45,7 @@ Push-Location build
|
||||||
Invoke-CmdScript "C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\Tools\VsDevCmd.bat" -arch=amd64 -host_arch=amd64
|
Invoke-CmdScript "C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\Tools\VsDevCmd.bat" -arch=amd64 -host_arch=amd64
|
||||||
|
|
||||||
# call CMake
|
# call CMake
|
||||||
|
$ErrorActionPreference="Continue"
|
||||||
Invoke-Call -ScriptBlock {
|
Invoke-Call -ScriptBlock {
|
||||||
cmake ..\llvm -G Ninja -DCMAKE_BUILD_TYPE=Release `
|
cmake ..\llvm -G Ninja -DCMAKE_BUILD_TYPE=Release `
|
||||||
-D LLVM_ENABLE_PROJECTS="${LLVM_ENABLE_PROJECTS}" `
|
-D LLVM_ENABLE_PROJECTS="${LLVM_ENABLE_PROJECTS}" `
|
||||||
|
|
Loading…
Reference in a new issue