Skip to content

Commit

Permalink
Merge pull request ModOrganizer2#122 from ModOrganizer2/dev/clean-and…
Browse files Browse the repository at this point in the history
…-fix

Cleaning and improvements
  • Loading branch information
Holt59 authored Sep 24, 2023
2 parents b31d41b + 13ed5bc commit b2eae1b
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 17 deletions.
12 changes: 9 additions & 3 deletions bootstrap.ps1
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
param([switch]$Verbose)
param(
[switch]
$Verbose,
[ValidateSet("Debug", "RelWithDebInfo", "Release")]
[string]
$Config = "Release"
)

$root = $PSScriptRoot
if (!$root) {
Expand All @@ -23,7 +29,7 @@ if (! $installationPath) {
$opts = ""
$opts += " $root\build\mob.sln"
$opts += " -m"
$opts += " -p:Configuration=Release"
$opts += " -p:Configuration=${Config}"
$opts += " -noLogo"
$opts += " -p:UseMultiToolTask=true"
$opts += " -p:EnforceProcessCountAcrossBuilds=true"
Expand All @@ -45,5 +51,5 @@ if (! $?) {
exit $LastExitCode
}

Copy-Item "$root\build\src\Release\mob.exe" "$root\mob.exe"
Copy-Item "$root\build\src\${Config}\mob.exe" "$root\mob.exe"
Write-Output "run ``.\mob -d prefix/path build`` to start building"
10 changes: 0 additions & 10 deletions patches/ncc/sources/publish.bat.patch

This file was deleted.

7 changes: 6 additions & 1 deletion src/core/conf.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -378,8 +378,13 @@ namespace mob {

MOB_ASSERT(!tasks.empty());

for (auto& t : tasks)
for (auto& t : tasks) {
if (t->name() != task &&
details::find_string_for_task(t->name(), key)) {
continue;
}
details::set_string_for_task(t->name(), key, value);
}
}
else {
// global task option
Expand Down
9 changes: 6 additions & 3 deletions src/tasks/pyqt.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,12 @@ namespace mob::tasks {

url source_url()
{
return "https://pypi.io/packages/source/P/PyQt6/"
"PyQt6-" +
pyqt::version() + ".tar.gz";
const auto version = pyqt::version();
std::string base = "https://pypi.io/packages/source/P/PyQt6/";
if (version.find("dev") != std::string::npos) {
base = "https://riverbankcomputing.com/pypi/packages/PyQt6/";
}
return base + "PyQt6-" + pyqt::version() + ".tar.gz";
}

url prebuilt_url()
Expand Down
3 changes: 3 additions & 0 deletions src/tools/nmake.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,9 @@ namespace mob {
if (f.line.find("Copyright (C) Microsoft Corporation.") !=
std::string::npos)
f.lv = context::level::trace;
if (f.line.find("Microsoft (R) Program Maintenance Utility") !=
std::string::npos)
f.lv = context::level::trace;
})
.arg("/C", process::log_quiet) // silent
.arg("/S", process::log_quiet) // silent
Expand Down

0 comments on commit b2eae1b

Please sign in to comment.