From d0b1b7d0310cfa6ebda2149a4b00efe757037d52 Mon Sep 17 00:00:00 2001
From: Edwin Lee
Date: Mon, 28 Mar 2022 11:28:33 -0500
Subject: [PATCH 1/4] Check the epin parent directory to get eplaunch working
---
src/EnergyPlus/PluginManager.cc | 20 ++++++++++++++++++--
1 file changed, 18 insertions(+), 2 deletions(-)
diff --git a/src/EnergyPlus/PluginManager.cc b/src/EnergyPlus/PluginManager.cc
index a2a24a00beb..f4e4d24c85d 100644
--- a/src/EnergyPlus/PluginManager.cc
+++ b/src/EnergyPlus/PluginManager.cc
@@ -516,8 +516,9 @@ PluginManager::PluginManager(EnergyPlusData &state) : eplusRunningViaPythonAPI(s
state,
"PluginManager: Search path inputs requested adding epin variable to Python path, but epin variable was empty, skipping.");
} else {
- if (FileSystem::pathExists(epinPathObject)) {
- fs::path sanitizedEnvInputDir = PluginManager::sanitizedPath(epinPathObject);
+ auto epinRootDir = FileSystem::getParentDirectoryPath(fs::path(epinPathObject));
+ if (FileSystem::pathExists(epinRootDir)) {
+ fs::path sanitizedEnvInputDir = PluginManager::sanitizedPath(epinRootDir);
PluginManager::addToPythonPath(state, sanitizedEnvInputDir, true);
} else {
EnergyPlus::ShowWarningMessage(state,
@@ -541,6 +542,21 @@ PluginManager::PluginManager(EnergyPlusData &state) : eplusRunningViaPythonAPI(s
// nothing to do here
}
}
+ } else {
+ // if no search path objects exist, we still need to do the default searching
+ PluginManager::addToPythonPath(state, ".", false);
+ fs::path sanitizedInputFileDir = PluginManager::sanitizedPath(state.dataStrGlobals->inputDirPath);
+ PluginManager::addToPythonPath(state, sanitizedInputFileDir, false);
+ std::string epin_path;
+ get_environment_variable("epin", epin_path);
+ fs::path epinPathObject = fs::path(epin_path);
+ if (!epinPathObject.empty()) {
+ auto epinRootDir = FileSystem::getParentDirectoryPath(fs::path(epinPathObject));
+ if (FileSystem::pathExists(epinRootDir)) {
+ fs::path sanitizedEnvInputDir = PluginManager::sanitizedPath(epinRootDir);
+ PluginManager::addToPythonPath(state, sanitizedEnvInputDir, true);
+ }
+ }
}
// Now read all the actual plugins and interpret them
From 31784d6528ef5b38a0df15f6becff695f1c8a4be Mon Sep 17 00:00:00 2001
From: Edwin Lee
Date: Mon, 28 Mar 2022 12:47:18 -0500
Subject: [PATCH 2/4] Editorial readme tweaks [actions skip]
---
release/readme.html | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/release/readme.html b/release/readme.html
index 1a6247170d5..af9636d80a0 100644
--- a/release/readme.html
+++ b/release/readme.html
@@ -200,8 +200,8 @@ Multiple Version Conversions
energyplushelp.freshdesk.com) to request multiple
- conversion set of programs.
+ Helpdesk to request
+ multiple conversion set of programs.
Documentation
@@ -230,7 +230,7 @@ Weather Data
EnergyPlus uses these files directly for annual simulations. The Weather Converter program that is part of
EnergyPlus can read these weather files and provide .csv (comma separated variable) as well as statistics
reports
- about the included (or other) files. Weather data for more than 2100 locations in more than 100 countries can be
+ about the included (or other) files. Weather data for more than 3000 locations in more than 100 countries can be
downloaded on the EnergyPlus Weather Page.
Highlights of this release (V22.1.0)
@@ -386,13 +386,13 @@ Platforms
Packages changed slightly as of the 9.4 release.
We began building our packages on a new system which adds better support
for newer platforms. During the change, we stepped away from some older OS versions. For example, we are
- not testing on Windows 7 or 8, only 10. However, both our 32-bit and 64-bit packages now include the new
+ not testing on Windows 7 or 8, only 10 and 11. However, both our 32-bit and 64-bit packages now include the new
Python plugin system, rather than just the 64-bit as previously. We have also added packaging and testing
with Ubuntu 20.04 in addition to Ubuntu 18.04. On Mac, we are officially releasing an installer for
OSX 10.15 and moving toward OSX 11 as well.
- - Windows 10
+ - Windows 10 and 11
- Linux (Ubuntu 18.04 and 20.04) 64 bit versions
- Mac OSX 10.15 64 bit versions
- EnergyPlus V22.1 has been tested on all of these platforms
@@ -413,7 +413,7 @@ Known problems
known (and even more unknown) probably remain. Specifics on the remaining known problems can be found on the
GitHub repository issues page. If you are interested in
what has been addressed, the issues resolved in this release are installed similarly in the
- changelog.
+ release details.
Additional steps you may want to consider:
From 2219976a032e8bfb08c876038340521034dbd0e9 Mon Sep 17 00:00:00 2001
From: Julien Marrec
Date: Tue, 29 Mar 2022 13:39:33 +0200
Subject: [PATCH 3/4] Fix kiva build errors on Apple Clang 13.1.6
```shell
c++ --version
Apple clang version 13.1.6 (clang-1316.0.21.2)
Target: arm64-apple-darwin21.4.0
Thread model: posix
InstalledDir: /Library/Developer/CommandLineTools/usr/bin
```
Errors:
```
In file included from /Users/julien/Software/Others/EnergyPlus/third_party/kiva-ep/src/libkiva/Ground.cpp:9:
In file included from /Users/julien/Software/Others/EnergyPlus/third_party/kiva-ep/src/libkiva/Ground.hpp:36:
In file included from /Users/julien/Software/Others/EnergyPlus/third_party/eigen/Eigen/IterativeLinearSolvers:11:
In file included from /Users/julien/Software/Others/EnergyPlus/third_party/eigen/Eigen/SparseCore:11:
In file included from /Users/julien/Software/Others/EnergyPlus/third_party/eigen/Eigen/Core:364:
/Users/julien/Software/Others/EnergyPlus/third_party/eigen/Eigen/src/Core/util/Meta.h:312:25: error: 'result_of (const double &, const double &)>' is deprecated [-Werror,-Wdeprecated-declarations]
typedef typename std::result_of::type type1;
```
```
/Users/julien/Software/Others/EnergyPlus/third_party/kiva-ep/src/libkiva/Ground.cpp:330:27: error: variable 'totalQr' set but not used [-Werror,-Wunused-but-set-variable]
double totalQc = 0.0, totalQr = 0.0;
```
---
third_party/kiva-ep/src/libkiva/Ground.cpp | 5 +++--
third_party/kiva-ep/src/libkiva/Ground.hpp | 1 +
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/third_party/kiva-ep/src/libkiva/Ground.cpp b/third_party/kiva-ep/src/libkiva/Ground.cpp
index 1eacde75777..3a347eccae5 100644
--- a/third_party/kiva-ep/src/libkiva/Ground.cpp
+++ b/third_party/kiva-ep/src/libkiva/Ground.cpp
@@ -327,7 +327,8 @@ void Ground::calculateSurfaceAverages() {
}
double totalQ = 0.0;
- double totalQc = 0.0, totalQr = 0.0;
+ double totalQc = 0.0;
+ // double totalQr = 0.0;
double TA = 0;
double hA = 0.0, hcA = 0.0, hrA = 0.0;
double totalArea = 0.0;
@@ -368,7 +369,7 @@ void Ground::calculateSurfaceAverages() {
hA += Ahc + Ahr;
totalQc += Qc;
- totalQr += Qr;
+ // totalQr += Qr;
totalQ += Qc + Qr + q * A;
TA += TNew[index] * A;
diff --git a/third_party/kiva-ep/src/libkiva/Ground.hpp b/third_party/kiva-ep/src/libkiva/Ground.hpp
index 24e7a257ea4..82c0385c8fc 100644
--- a/third_party/kiva-ep/src/libkiva/Ground.hpp
+++ b/third_party/kiva-ep/src/libkiva/Ground.hpp
@@ -26,6 +26,7 @@
#pragma clang diagnostic push
#if __clang_major__ >= 13
#pragma clang diagnostic ignored "-Wdeprecated-copy"
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
#endif
#elif defined(__GNUC__) && defined(__linux__)
#pragma GCC diagnostic push
From b6b5e9341a312993357acffa95827687ab4427d0 Mon Sep 17 00:00:00 2001
From: Julien Marrec
Date: Tue, 29 Mar 2022 13:51:48 +0200
Subject: [PATCH 4/4] Suppress the many unused-but-set warnings you get with
clang >= 13.0 (they were added at 13.0)
---
cmake/CompilerFlags.cmake | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/cmake/CompilerFlags.cmake b/cmake/CompilerFlags.cmake
index ba764205681..9e37f085484 100644
--- a/cmake/CompilerFlags.cmake
+++ b/cmake/CompilerFlags.cmake
@@ -75,11 +75,15 @@ elseif(CMAKE_COMPILER_IS_GNUCXX OR "${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang" O
target_compile_options(project_warnings INTERFACE -Wno-delete-non-virtual-dtor)
target_compile_options(project_warnings INTERFACE -Wno-missing-braces)
if(CMAKE_COMPILER_IS_GNUCXX) # g++
- target_compile_options(project_warnings INTERFACE -Wno-unused-but-set-parameter -Wno-unused-but-set-variable)
# Suppress unused-but-set warnings until more serious ones are addressed
+ target_compile_options(project_warnings INTERFACE -Wno-unused-but-set-parameter -Wno-unused-but-set-variable)
target_compile_options(project_warnings INTERFACE -Wno-maybe-uninitialized)
target_compile_options(project_warnings INTERFACE -Wno-aggressive-loop-optimizations)
elseif("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang" OR "${CMAKE_CXX_COMPILER_ID}" STREQUAL "AppleClang")
+ if(CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 13.0)
+ # Suppress unused-but-set warnings until more serious ones are addressed
+ target_compile_options(project_warnings INTERFACE -Wno-unused-but-set-parameter -Wno-unused-but-set-variable)
+ endif()
target_compile_options(project_warnings INTERFACE -Wno-vexing-parse)
target_compile_options(project_warnings INTERFACE -Wno-invalid-source-encoding)
endif()