Skip to content

Commit

Permalink
fmk - updating makeEXE and DMG script files
Browse files Browse the repository at this point in the history
  • Loading branch information
fmckenna committed Jun 30, 2022
1 parent 8027c34 commit f8451d2
Show file tree
Hide file tree
Showing 2 changed files with 76 additions and 18 deletions.
43 changes: 39 additions & 4 deletions makeDMG.sh
Original file line number Diff line number Diff line change
@@ -1,23 +1,58 @@
# remove & rebuild app and macdeploy it
#!/bin/bash

mkdir -p build
cd build
rm -fr quoFEM.app
rm -fr quoFEM.app quoFEM

#
# build UI
#

conan install .. --build missing
status=$?; if [[ $status != 0 ]]; then echo "conan install failed"; exit $status; fi
qmake ../quoFEM.pro
status=$?; if [[ $status != 0 ]]; then echo "qmake failed"; exit $status; fi
make
macdeployqt ./quoFEM.app
status=$?; if [[ $status != 0 ]]; then echo "make failed"; exit $status; fi

#
# Copy applications from SimCentreBackend
#

mkdir ./quoFEM.app/Contents/MacOS/applications
cp -fr ../../SimCenterBackendApplications/applications/performUQ ./quoFEM.app/Contents/MacOS/applications
cp -fr ../../SimCenterBackendApplications/applications/performFEM ./quoFEM.app/Contents/MacOS/applications
cp -fr ../../SimCenterBackendApplications/applications/Workflow ./quoFEM.app/Contents/MacOS/applications

#
# Copy OpenSees and Dakota
#

mkdir ./quoFEM.app/Contents/MacOS/applications/opensees
mkdir ./quoFEM.app/Contents/MacOS/applications/dakota
cp -fr /Users/fmckenna/bin/OpenSees3.2.2/* ./quoFEM.app/Contents/MacOS/applications/opensees
cp -fr /Users/fmckenna/dakota-6.12.0/* ./quoFEM.app/Contents/MacOS/applications/dakota

#
# Copy Example files
#

cp -fr ../Examples ./quoFEM.app/Contents/MacOS/
cp ../../nataf_gsa_cpp/build/bin/nataf_gsa ./quoFEM.app/Contents/MacOS/applications/performUQ/SimCenterUQ
rm -fr ./quoFEM.app/Contents/MacOS/Examples/.archive
rm -fr ./quoFEM.app/Contents/MacOS/Examples/.aurore
rm -fr ./quoFEM.app/Contents/MacOS/Examples/.gitignore

#
# cd back to were we started
#

macdeployqt ./quoFEM.app



cp ../../nataf_gsa_cpp_mpi/build/bin/nataf_gsa ./quoFEM.app/Contents/MacOS/applications/performUQ/SimCenterUQ
cp /usr/local/opt/libomp/lib/libomp.dylib ./quoFEM.app/Contents/MacOS/applications/performUQ/SimCenterUQ
install_name_tool -change /usr/local/opt/libomp/lib/libomp.dylib @executable_path/libomp.dylib ./quoFEM.app/Contents/MacOS/applications/performUQ/SimCenterUQ/nataf_gsa

#
# now before we codesign and verify, check userID file exists
Expand Down
51 changes: 37 additions & 14 deletions makeEXE.sh
Original file line number Diff line number Diff line change
@@ -1,39 +1,62 @@
#!/bin/bash

#
# build backend
# make build dir, remove old app
#

cd backend
mkdir -p build
cd build
conan install .. --build missing
cmake -DCMAKE_BUILD_TYPE=Release ..
status=$?; if [[ $status != 0 ]]; then echo "cmake failed"; exit $status; fi
make
status=$?; if [[ $status != 0 ]]; then echo "make backend failed"; exit $status; fi
make install
status=$?; if [[ $status != 0 ]]; then echo "install backend failed"; exit $status; fi
rm -fr quoFEM.app quoFEM

#
# build UI
#

cd ..
cd ..
mkdir -p build
cd build
conan install .. --build missing
status=$?; if [[ $status != 0 ]]; then echo "conan install failed"; exit $status; fi
qmake ../quoFEM.pro
status=$?; if [[ $status != 0 ]]; then echo "qmake failed"; exit $status; fi
make
status=$?; if [[ $status != 0 ]]; then echo "make failed"; exit $status; fi

#
# Copy applications from SimCentreBackend
#

mkdir ./quoFEM.app/Contents/MacOS/applications
cp -fr ../../SimCenterBackendApplications/applications/performUQ ./quoFEM.app/Contents/MacOS/applications
cp -fr ../../SimCenterBackendApplications/applications/performFEM ./quoFEM.app/Contents/MacOS/applications
cp -fr ../../SimCenterBackendApplications/applications/Workflow ./quoFEM.app/Contents/MacOS/applications

cp ../../nataf_gsa_cpp_mpi/build/bin/nataf_gsa ./quoFEM.app/Contents/MacOS/applications/performUQ/SimCenterUQ
cp /usr/local/opt/libomp/lib/libomp.dylib ./quoFEM.app/Contents/MacOS/applications/performUQ/SimCenterUQ
install_name_tool -change /usr/local/opt/libomp/lib/libomp.dylib @executable_path/libomp.dylib ./quoFEM.app/Contents/MacOS/applications/performUQ/SimCenterUQ/nataf_gsa


#
# Copy OpenSees and Dakota
#

mkdir ./quoFEM.app/Contents/MacOS/applications/opensees
mkdir ./quoFEM.app/Contents/MacOS/applications/dakota
cp -fr /Users/fmckenna/bin/OpenSees3.2.2/* ./quoFEM.app/Contents/MacOS/applications/opensees
cp -fr /Users/fmckenna/dakota-6.12.0/* ./quoFEM.app/Contents/MacOS/applications/dakota

#
# Copy Example files
#

cp -fr ../Examples ./quoFEM.app/Contents/MacOS/
rm -fr ./quoFEM.app/Contents/MacOS/Examples/.archive
rm -fr ./quoFEM.app/Contents/MacOS/Examples/.aurore
rm -fr ./quoFEM.app/Contents/MacOS/Examples/.gitignore

#
# cd back to were we started
#

cd ..





0 comments on commit f8451d2

Please sign in to comment.