Closed wenyikuang closed 6 months ago
-- Library backtrace found /root/.conan/data/libbacktrace/cci.20210118/_/_/package/1d877a3df840030e6a8abb74c5ffb9088d08b47a/lib/libbacktrace.a
-- Conan: Adjusting language standard
-- Current conanbuildinfo.cmake directory: /Openstudio/build
-- Conan: Compiler GCC>=5, checking major version 8
-- Conan: Checking correct version: 8
-- openstudio: DONE RUNNING CONAN
CMake Error at CMakeLists.txt:648 (message):
EnergyPlus no longer provides packages for Ubuntu 18.04
If I tried to build it from scratch, raise exception with E+ compatitable issue.
@wenyikuang I have this in the bash script I had used to build OpenStudio on a Centos docker.
cmake -G Ninja [...truncated options...]
echo "Changing shebang line in radiance"
sed -i "s:#\!/usr/local/bin/wish4.0:#\!/usr/bin/env wish:g" radiance-5.0.a.12-Linux/usr/local/radiance/bin/trad
ninja
ninja package
This is also a problem with 3.7.0. Autodesk Insight product uses the CentOS RPM builds.
@wenyikuang Do you want me to address this issue or are you clear? It requires
1) Either :
install(CODE [[ ... ]])
command. This is probably prefered because it means it'll work no matter who builds it2) Rebuilding 3.7.0 centos7. (and maybe 3.6.0)
@wenyikuang I have this in the bash script I had used to build OpenStudio on a Centos docker.
cmake -G Ninja [...truncated options...] echo "Changing shebang line in radiance" sed -i "s:#\!/usr/local/bin/wish4.0:#\!/usr/bin/env wish:g" radiance-5.0.a.12-Linux/usr/local/radiance/bin/trad ninja ninja package
I see! Let me try it. Thanks!
Emmmm even after I use the sed
it still failed: (under the openstudio-cmake-tools:centos7 image)
When I executing ninja
[1235/9183] Building CXX object src/model/CMakeFi...rces.dir/ruby_OpenStudioModelResources_wrap.cxx.o
FAILED: src/model/CMakeFiles/ruby_OpenStudioModelResources.dir/ruby_OpenStudioModelResources_wrap.cxx.o
/opt/rh/devtoolset-10/root/usr/bin/g++ -DBOOST_STACKTRACE_ADDR2LINE_LOCATION=\"/usr/bin/addr2line\" -DBOOST_STACKTRACE_USE_ADDR2LINE -DBOOST_STACKTRACE_USE_BACKTRACE -DBOOST_STACKTRACE_USE_NOOP -DGEOGRAPHICLIB_SHARED_LIB=0 -DHAVE_BZIP2 -DHAVE_UNISTD_H -DLIBXML_STATIC -DLIBXSLT_STATIC -D_GLIBCXX_USE_CXX11_ABI=0 -D_NO_ASYNCRTIMP -D_NO_PPLXIMP -I/Openstudio/src -I/Openstudio/build/src -I/Openstudio -isystem /opt/rh/rh-python38/root/usr/include/python3.8 -isystem /root/.conan/data/openstudio_ruby/2.7.2/nrel/centos/package/9e91ea8bf0bb98e1b35847c4567cb0a3682d2648/include -isystem /root/.conan/data/openstudio_ruby/2.7.2/nrel/centos/package/9e91ea8bf0bb98e1b35847c4567cb0a3682d2648/include/ruby-2.7.0 -isystem /root/.conan/data/openstudio_ruby/2.7.2/nrel/centos/package/9e91ea8bf0bb98e1b35847c4567cb0a3682d2648/include/ruby-2.7.0/x86_64-linux -isystem /root/.conan/data/sqlite3/3.38.5/_/_/package/b7e8530a7ce4dc98890a185b197886c549602572/include -isystem /root/.conan/data/jsoncpp/1.9.5/_/_/package/82ef5eac51c38971dea2fd342dd55ddf2ddfbbc3/include -isystem /root/.conan/data/minizip/1.2.12/_/_/package/50479a03e6a0f0ad7e9baeddeb9019d627aa692f/include -isystem /root/.conan/data/minizip/1.2.12/_/_/package/50479a03e6a0f0ad7e9baeddeb9019d627aa692f/include/minizip -isystem /root/.conan/data/zlib/1.2.12/_/_/package/19729b9559f3ae196cad45cb2b97468ccb75dcd1/include -isystem /root/.conan/data/bzip2/1.0.8/_/_/package/91a8b22c2c5a149bc617cfc06cdd21bf23b12567/include -isystem /root/.conan/data/fmt/9.1.0/_/_/package/1d886ef72d27d7ab9a1a64be277b3d28a290f3e4/include -isystem /root/.conan/data/pugixml/1.12.1/_/_/package/82ef5eac51c38971dea2fd342dd55ddf2ddfbbc3/include -isystem /root/.conan/data/boost/1.79.0/_/_/package/a762cbb0f4f91f9ac21c111bfd58400aa5d97a0b/include -isystem /root/.conan/data/libbacktrace/cci.20210118/_/_/package/19729b9559f3ae196cad45cb2b97468ccb75dcd1/include -isystem /root/.conan/data/cpprestsdk/2.10.18/_/_/package/336065edd5db47193312b10d982fa47c72ef8211/include -isystem /root/.conan/data/openssl/1.1.1o/_/_/package/19729b9559f3ae196cad45cb2b97468ccb75dcd1/include -isystem /root/.conan/data/websocketpp/0.8.2/_/_/package/5ab84d6acfe1f23c4fae0ab88f26e3a396351ac9/include -isystem /root/.conan/data/geographiclib/1.52/_/_/package/2066548edbbda32321eec39c17ddb5f988c7a268/include -isystem /root/.conan/data/libxml2/2.9.14/_/_/package/f9bf12b05a917e3b694bc35eb5037c71fbf6b7ca/include -isystem /root/.conan/data/libxml2/2.9.14/_/_/package/f9bf12b05a917e3b694bc35eb5037c71fbf6b7ca/include/libxml2 -isystem /root/.conan/data/libiconv/1.16/_/_/package/19729b9559f3ae196cad45cb2b97468ccb75dcd1/include -isystem /root/.conan/data/libxslt/1.1.34/_/_/package/d496057d7c19e1765bd39bf20d3383470a1603b0/include -fdiagnostics-color=always -Wall -fPIC -fno-strict-aliasing -Winvalid-pch -Wnon-virtual-dtor -Wno-narrowing -Wno-narrowing -Werror -Wno-overloaded-virtual -Wno-maybe-uninitialized -O3 -DNDEBUG -std=c++2a -Wno-deprecated-declarations -Wno-sign-compare -Wno-register -Wno-conversion-null -Wno-misleading-indentation -fno-gnu-unique -MD -MT src/model/CMakeFiles/ruby_OpenStudioModelResources.dir/ruby_OpenStudioModelResources_wrap.cxx.o -MF src/model/CMakeFiles/ruby_OpenStudioModelResources.dir/ruby_OpenStudioModelResources_wrap.cxx.o.d -o src/model/CMakeFiles/ruby_OpenStudioModelResources.dir/ruby_OpenStudioModelResources_wrap.cxx.o -c /Openstudio/build/src/model/ruby_OpenStudioModelResources_wrap.cxx
g++: fatal error: Killed signal terminated program cc1plus
compilation terminated.
[1244/9183] Building CXX object src/model/CMakeFi...ModelHVAC.dir/ruby_OpenStudioModelHVAC_wrap.cxx.o
ninja: build stopped: subcommand failed.
Emmmm and I tried to run the script in docker-openstudio-centos but not works well. Does it need any pre-request?
Thanks,
That error has nothing to do with the shebang. It happens because it likely runs out of memory during the linking phase.
g++: fatal error: Killed signal terminated program cc1plus
Try redoing ninja
or even ninja -j 1
. And you should go check your docker settings allocations for memory and cpu and see if they make sense.
Your ruby bindings are HUGE files and so it bites through the available memory quickly when done in //. I have an ubuntu latptop with 12 threads and only 16 GB of ram and I get this issue on it. In my case it rarely crashes, because I have a large swap, but the system is often unresponsive
That error has nothing to do with the shebang. It happens because it likely runs out of memory during the linking phase.
g++: fatal error: Killed signal terminated program cc1plus
Try redoing
ninja
or evenninja -j 1
. And you should go check your docker settings allocations for memory and cpu and see if they make sense.Your ruby bindings are HUGE files and so it bites through the available memory quickly when done in //. I have an ubuntu latptop with 12 threads and only 16 GB of ram and I get this issue on it. In my case it rarely crashes, because I have a large swap, but the system is often unresponsive
Yeah finally I made it(build successfully) with limiting the ninja -j 4 and larger ram.
And face the same issue:
Error: Package: openstudio-3.7.0-3.7.0-1.x86_64 (/OpenStudio-3.7.0+1ce97f5651-CentOS-7.9.2009-x86_64)
Requires: /usr/local/bin/wish4.0
You could try using --skip-broken to work around the problem
You could try running: rpm -Va --nofiles --nodigest
Cd build/_CPack_Packages Grep -R wish
I reckon the sed command didn't do the replace.
I reckon the sed command didn't do the replace.
And I didn't find the wish as an interpretor under the /env/ dir.
the result from grep is (I directly grep wish4.0 to skip some random stuff)
root@_CPack_Packages$ grep -R wish4.0
Binary file Linux/RPM/RPMS/OpenStudio-3.7.0+1ce97f5651-CentOS-7.9.2009-x86_64.rpm matches
Linux/RPM/OpenStudio-3.7.0+1ce97f5651-CentOS-7.9.2009-x86_64/usr/local/openstudio-3.7.0/Radiance/bin/trad:#!/usr/local/bin/wish4.0
Linux/RPM/rpmbuildopenstudio-3.7.0.out:Requires: /bin/csh /usr/bin/perl /usr/local/bin/wish4.0 ld-linux-x86-64.so.2()(64bit) ld-linux-x86-64.so.2(GLIBC_2.2.5)(64bit) ld-linux-x86-64.so.2(GLIBC_2.3)(64bit) libX11.so.6()(64bit) libc.so.6()(64bit) libc.so.6(GLIBC_2.10)(64bit) libc.so.6(GLIBC_2.14)(64bit) libc.so.6(GLIBC_2.15)(64bit) libc.so.6(GLIBC_2.17)(64bit) libc.so.6(GLIBC_2.2.5)(64bit) libc.so.6(GLIBC_2.3)(64bit) libc.so.6(GLIBC_2.3.2)(64bit) libc.so.6(GLIBC_2.3.4)(64bit) libc.so.6(GLIBC_2.4)(64bit) libc.so.6(GLIBC_2.6)(64bit) libc.so.6(GLIBC_2.7)(64bit) libc.so.6(GLIBC_2.8)(64bit) libc.so.6(GLIBC_2.9)(64bit) libcrypt.so.1()(64bit) libdl.so.2()(64bit) libdl.so.2(GLIBC_2.2.5)(64bit) libenergyplusapi.so.23.2.0()(64bit) libgcc_s.so.1()(64bit) libgcc_s.so.1(GCC_3.0)(64bit) libgcc_s.so.1(GCC_3.4)(64bit) libgcc_s.so.1(GCC_4.0.0)(64bit) libgomp.so.1()(64bit) libgomp.so.1(GOMP_4.0)(64bit) libgomp.so.1(OMP_1.0)(64bit) libm.so.6()(64bit) libm.so.6(GLIBC_2.2.5)(64bit) libopenstudiolib.so()(64bit) libpthread.so.0()(64bit) libpthread.so.0(GLIBC_2.12)(64bit) libpthread.so.0(GLIBC_2.2.5)(64bit) libpthread.so.0(GLIBC_2.3.2)(64bit) libpthread.so.0(GLIBC_2.3.3)(64bit) libpython3.8.so.rh-python38-1.0()(64bit) librt.so.1()(64bit) librt.so.1(GLIBC_2.2.5)(64bit) librt.so.1(GLIBC_2.3.3)(64bit) libstdc++.so.6()(64bit) libstdc++.so.6(CXXABI_1.3)(64bit) libstdc++.so.6(CXXABI_1.3.1)(64bit) libstdc++.so.6(CXXABI_1.3.2)(64bit) libstdc++.so.6(CXXABI_1.3.3)(64bit) libstdc++.so.6(CXXABI_1.3.5)(64bit) libstdc++.so.6(GLIBCXX_3.4)(64bit) libstdc++.so.6(GLIBCXX_3.4.11)(64bit) libstdc++.so.6(GLIBCXX_3.4.13)(64bit) libstdc++.so.6(GLIBCXX_3.4.14)(64bit) libstdc++.so.6(GLIBCXX_3.4.15)(64bit) libstdc++.so.6(GLIBCXX_3.4.17)(64bit) libstdc++.so.6(GLIBCXX_3.4.18)(64bit) libstdc++.so.6(GLIBCXX_3.4.19)(64bit) libstdc++.so.6(GLIBCXX_3.4.5)(64bit) libstdc++.so.6(GLIBCXX_3.4.6)(64bit) libstdc++.so.6(GLIBCXX_3.4.9)(64bit) libutil.so.1()(64bit) libutil.so.1(GLIBC_2.2.5)(64bit) perl(File::Temp) perl(Math::Trig) perl(POSIX) perl(strict) perl(warnings) rtld(GNU_HASH)
Linux/TGZ/OpenStudio-3.7.0+1ce97f5651-CentOS-7.9.2009-x86_64/usr/local/openstudio-3.7.0/Radiance/bin/trad:#!/usr/local/bin/wish4.0```
Tried to modify radiance-5.0.a.12-Linux/usr/local/radiance/bin/trad
in vi and build again, let's see.
Nice, after I modify the radiance/../trad with vi, the installation works!
TODO:
#!/usr/bin/env xxxx [opts]
is a shebang that just instructs the terminal to look for the executable xxx
in the PATH (and potentially pass opts to it)
It basically resolves it like which xxx
would (with the caveat that it also evaluates anything you have alias
ed first)
get it, but why does it comes from wish4.0? it looks something really old.
and the sed should be:
sed -i 's:^#!/usr/local/bin/wish4.0:#!/usr/bin/env wish:' radiance-5.0.a.12-Linux/usr/local/radiance/bin/trad
We haven't update Radiance in the last 10 years I think We should patch the tar.gz and reupload to s3 to avoid bumping into this again.
As far as sed, it's a nifty but confusing tool, in the sense that there are often major differences in which flavor is installed. The freedesktop one for eg does not support -i without a suffix. And that's the one shipped on many older systems and on macos. Got bit by that this week again while creating a CI workflow.
Also I don't think we ever use that file because afaik wish is a gui. https://en.m.wikipedia.org/wiki/Wish_(Unix_shell)
Here's the Radiance source, which was changed from wish4.0 in 2019...
https://github.com/LBNL-ETA/Radiance/blob/master/src/util/trad.wsh
Enhancement Request
Detailed Description
Under
centos:7
After I downloaded the rpm from the release page. Then install bywill raise an exception for requires: /usr/local/bin/wish4.0.
If you run it with
--skip-broken
flag.It will not raise exception but will:
Possible Implementation