Opened 9 years ago
Closed 9 years ago
#3897 closed defect (fixed)
OM Mac build fails
Reported by: | Adam Dershowitz | Owned by: | Willi Braun |
---|---|---|---|
Priority: | high | Milestone: | Future |
Component: | Build Environment | Version: | |
Keywords: | Cc: |
Description
The Mac version of OM is not longer building successfully. I have 1.10.0~dev-507-g8fe1031_0 installed and attempts to upgrade to 1.10.0~dev-563-gcc23305_0 fail.
I see that the Mac versions on Hudson, both build and nightly, have been failing for the last 10 days or so.
I have attached a log of my build attempt.
Attachments (1)
Change History (6)
by , 9 years ago
comment:1 by , 9 years ago
Owner: | changed from | to
---|---|
Status: | new → assigned |
comment:2 by , 9 years ago
I see a few changesets to attempt to fix OSX builds. Now, I can build 1.10.0~dev-580-gb2ea2a5 but, after building, Macports gives an error related to linking:
---> Building openmodelica-devel ---> Staging openmodelica-devel into destroot ---> Deactivating openmodelica-devel @1.10.0~dev-580-gb2ea2a5_0+gfortran5+libraries+modelica3d+omnotebook+qt+sundials ---> Cleaning openmodelica-devel ---> Uninstalling openmodelica-devel @1.10.0~dev-580-gb2ea2a5_0+gfortran5+libraries+modelica3d+omnotebook+qt+sundials ---> Cleaning openmodelica-devel ---> Computing dependencies for openmodelica-devel ---> Installing openmodelica-devel @1.10.0~dev-580-gb2ea2a5_0+gfortran5+libraries+modelica3d+omnotebook+qt+sundials ---> Activating openmodelica-devel @1.10.0~dev-580-gb2ea2a5_0+gfortran5+libraries+modelica3d+omnotebook+qt+sundials ---> Cleaning openmodelica-devel ---> Updating database of binaries ---> Scanning binaries for linking errors ---> Found 10 broken file(s), matching files to ports ---> Found 1 broken port(s), determining rebuild order ---> Rebuilding in order openmodelica-devel @1.10.0~dev-580-gb2ea2a5 +gfortran5+libraries+modelica3d+omnotebook+qt+sundials
It then attempts to build again, and repeats several times before giving up.
This looks like another path problem. If I then do: port -d -y rev-upgrade here are a few lines of the bad links:
DEBUG: Ignoring loadcommand containing @rpath in /opt/local/lib/x86_64-darwin15.4.0/omc/libOpenModelicaFMIRuntimeC.dylib Could not open libsundials_nvecserial.0.dylib: Error opening or reading file (referenced from /opt/local/lib/x86_64-darwin15.4.0/omc/libOpenModelicaFMIRuntimeC.dylib) DEBUG: Marking /opt/local/lib/x86_64-darwin15.4.0/omc/libOpenModelicaFMIRuntimeC.dylib as broken Could not open libsundials_kinsol.1.dylib: Error opening or reading file (referenced from /opt/local/lib/x86_64-darwin15.4.0/omc/libOpenModelicaFMIRuntimeC.dylib) DEBUG: Marking /opt/local/lib/x86_64-darwin15.4.0/omc/libOpenModelicaFMIRuntimeC.dylib as broken Could not open libsundials_ida.2.dylib: Error opening or reading file (referenced from /opt/local/lib/x86_64-darwin15.4.0/omc/libOpenModelicaFMIRuntimeC.dylib) DEBUG: Marking /opt/local/lib/x86_64-darwin15.4.0/omc/libOpenModelicaFMIRuntimeC.dylib as broken
DEBUG: Ignoring loadcommand containing @rpath in /opt/local/lib/x86_64-darwin15.4.0/omc/libSimulationRuntimeC.dylib DEBUG: Marking /opt/local/lib/x86_64-darwin15.4.0/omc/libSimulationRuntimeC.dylib as broken DEBUG: Marking /opt/local/lib/x86_64-darwin15.4.0/omc/libSimulationRuntimeC.dylib as broken DEBUG: Marking /opt/local/lib/x86_64-darwin15.4.0/omc/libSimulationRuntimeC.dylib as broken DEBUG: Ignoring loadcommand containing @rpath in /opt/local/lib/x86_64-darwin15.4.0/omc/libipopt.0.0.0.dylib Could not open libamd.dylib: Error opening or reading file (referenced from /opt/local/lib/x86_64-darwin15.4.0/omc/libklu.dylib) DEBUG: Marking /opt/local/lib/x86_64-darwin15.4.0/omc/libklu.dylib as broken Could not open libcolamd.dylib: Error opening or reading file (referenced from /opt/local/lib/x86_64-darwin15.4.0/omc/libklu.dylib) DEBUG: Marking /opt/local/lib/x86_64-darwin15.4.0/omc/libklu.dylib as broken Could not open libbtf.dylib: Error opening or reading file (referenced from /opt/local/lib/x86_64-darwin15.4.0/omc/libklu.dylib) DEBUG: Marking /opt/local/lib/x86_64-darwin15.4.0/omc/libklu.dylib as broken
DEBUG: Marking /opt/local/lib/x86_64-darwin15.4.0/omc/libumfpack.dylib as broken
comment:3 by , 9 years ago
I have confirmed that it is just a path issue. I added @rpath to a number of the libraries and now OM does open and run. Here are the work-around commands I used:
sudo install_name_tool -change libsundials_ida.2.dylib @rpath/libsundials_ida.2.dylib /opt/local/lib/x86_64-darwin15.4.0/omc/libOpenModelicaFMIRuntimeC.dylib sudo install_name_tool -change libsundials_nvecserial.0.dylib @rpath/libsundials_nvecserial.0.dylib /opt/local/lib/x86_64-darwin15.4.0/omc/libOpenModelicaFMIRuntimeC.dylib sudo install_name_tool -change libsundials_kinsol.1.dylib @rpath/libsundials_kinsol.1.dylib /opt/local/lib/x86_64-darwin15.4.0/omc/libOpenModelicaFMIRuntimeC.dylib sudo install_name_tool -change libamd.dylib @rpath/libamd.dylib /opt/local/lib/x86_64-darwin15.4.0/omc/libklu.dylib sudo install_name_tool -change libcolamd.dylib @rpath/libcolamd.dylib /opt/local/lib/x86_64-darwin15.4.0/omc/libklu.dylib sudo install_name_tool -change libbtf.dylib @rpath/libbtf.dylib /opt/local/lib/x86_64-darwin15.4.0/omc/libklu.dylib sudo install_name_tool -change libamd.dylib @rpath/libamd.dylib /opt/local/lib/x86_64-darwin15.4.0/omc/libumfpack.dylib sudo install_name_tool -change libsundials_ida.2.dylib @rpath/libsundials_ida.2.dylib /opt/local/lib/x86_64-darwin15.4.0/omc/libSimulationRuntimeC.dylib sudo install_name_tool -change libsundials_nvecserial.0.dylib @rpath/libsundials_nvecserial.0.dylib /opt/local/lib/x86_64-darwin15.4.0/omc/libSimulationRuntimeC.dylib sudo install_name_tool -change libsundials_kinsol.1.dylib @rpath/libsundials_kinsol.1.dylib /opt/local/lib/x86_64-darwin15.4.0/omc/libSimulationRuntimeC.dylib
So somewhere in the build command it is missing "@rpath" for a few libraries.
comment:4 by , 9 years ago
It looks like Hudson is now having the same problem with path locations on OSX_NIGHTLY_BUILDhttps://test.openmodelica.org/hudson/job/OpenModelica_OSX_NIGHTLY_BUILD/
comment:5 by , 9 years ago
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
It looks like this has been fixed now. At least it does build and run correctly for me, so I will mark it as fixed.
There is no
cp -u
in POSIX.2003 (BSD/OSX). Seems to have been added for the Sundials installation. Also, were the dylib files updated to fix the install name?