Build instructions update: Cesare Guardino
This commit is contained in:
parent
3a6cc671fa
commit
5f6a39a46e
5 changed files with 87 additions and 62 deletions
5
ThirdParty/mingwBuild/clean.sh
vendored
5
ThirdParty/mingwBuild/clean.sh
vendored
|
@ -23,10 +23,11 @@
|
||||||
# along with foam-extend. If not, see <http://www.gnu.org/licenses/>.
|
# along with foam-extend. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#
|
#
|
||||||
# Script
|
# Script
|
||||||
# build.sh
|
# clean.sh
|
||||||
#
|
#
|
||||||
# Description
|
# Description
|
||||||
# Removes previous thirdy-party dependencies build directories (does not remove installed packages directory)
|
# Removes previous thirdy-party dependencies build directories
|
||||||
|
# (does not remove installed packages directory)
|
||||||
#
|
#
|
||||||
# Author:
|
# Author:
|
||||||
# Cesare Guardino, Alstom Power Ltd., (2015)
|
# Cesare Guardino, Alstom Power Ltd., (2015)
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
# along with foam-extend. If not, see <http://www.gnu.org/licenses/>.
|
# along with foam-extend. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#
|
#
|
||||||
# Script
|
# Script
|
||||||
# createReleasePackage.mingw
|
# createWindowsBinaryPackage
|
||||||
#
|
#
|
||||||
# Description
|
# Description
|
||||||
# Creates stand-alone .zip packages for MinGW-based builds on Windows.
|
# Creates stand-alone .zip packages for MinGW-based builds on Windows.
|
||||||
|
@ -36,13 +36,19 @@
|
||||||
cd ${0%/*} || exit 1 # run from this directory
|
cd ${0%/*} || exit 1 # run from this directory
|
||||||
|
|
||||||
create_package() {
|
create_package() {
|
||||||
RELEASE_DIR=$1
|
PACKAGE_DIR=$1
|
||||||
TYPE=$2
|
TYPE=$2
|
||||||
|
|
||||||
PACKAGE_FILE=$RELEASE_DIR.$TYPE
|
|
||||||
echo ""
|
echo ""
|
||||||
|
|
||||||
|
PACKAGE_FILE=$PACKAGE_DIR.$TYPE
|
||||||
|
if [ -f $PACKAGE_FILE ] ; then
|
||||||
|
echo "Removing previous $PACKAGE_FILE ..."
|
||||||
|
rm -f $PACKAGE_FILE
|
||||||
|
fi
|
||||||
|
|
||||||
echo "Creating $PACKAGE_FILE ..."
|
echo "Creating $PACKAGE_FILE ..."
|
||||||
7z -t$TYPE a $PACKAGE_FILE $RELEASE_DIR
|
7z -t$TYPE a $PACKAGE_FILE $PACKAGE_DIR
|
||||||
|
|
||||||
if [ -f $PACKAGE_FILE ] ; then
|
if [ -f $PACKAGE_FILE ] ; then
|
||||||
echo "Successfully created $PACKAGE_FILE"
|
echo "Successfully created $PACKAGE_FILE"
|
||||||
|
@ -52,7 +58,7 @@ create_package() {
|
||||||
}
|
}
|
||||||
|
|
||||||
echo
|
echo
|
||||||
echo "=========== FOAM-EXTEND WINDOWS STAND-ALONE PACKAGE CREATION SCRIPT ==========="
|
echo "=========== FOAM-EXTEND STAND-ALONE PACKAGE CREATION SCRIPT FOR WINDOWS ==========="
|
||||||
|
|
||||||
if [ "$PWD" != "$WM_PROJECT_DIR/bin" ]
|
if [ "$PWD" != "$WM_PROJECT_DIR/bin" ]
|
||||||
then
|
then
|
||||||
|
@ -62,36 +68,43 @@ then
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
RELEASE_DIR=$WM_PROJECT-$WM_FORK-$WM_PROJECT_VERSION-win-x64
|
RELEASE_DIR=$WM_PROJECT_DIR/releasePackages
|
||||||
MPI_VERSION=`basename $FOAM_MPI_LIBBIN`
|
if [ ! -d $RELEASE_DIR ] ; then
|
||||||
if [ -d $RELEASE_DIR ] ; then
|
echo "Creating $RELEASE_DIR ..."
|
||||||
echo "Removing previous $RELEASE_DIR"
|
mkdir $RELEASE_DIR
|
||||||
rm -rf $RELEASE_DIR
|
|
||||||
fi
|
fi
|
||||||
mkdir $RELEASE_DIR
|
|
||||||
|
PACKAGE_DIR=$RELEASE_DIR/$WM_PROJECT-$WM_FORK-$WM_PROJECT_VERSION-win-x64
|
||||||
|
if [ -d $PACKAGE_DIR ] ; then
|
||||||
|
echo "Removing previous $PACKAGE_DIR ..."
|
||||||
|
rm -rf $PACKAGE_DIR
|
||||||
|
fi
|
||||||
|
echo "Creating $PACKAGE_DIR ..."
|
||||||
|
mkdir $PACKAGE_DIR
|
||||||
|
|
||||||
echo "Copying bin directory ..."
|
echo "Copying bin directory ..."
|
||||||
cp -rp $FOAM_APPBIN $RELEASE_DIR/bin
|
cp -rp $FOAM_APPBIN $PACKAGE_DIR/bin
|
||||||
|
|
||||||
echo "Copying DLLs from lib directory ..."
|
echo "Copying DLLs from lib directory ..."
|
||||||
mkdir $RELEASE_DIR/lib
|
mkdir $PACKAGE_DIR/lib
|
||||||
cp -p $FOAM_LIBBIN/*.dll $RELEASE_DIR/lib
|
cp -p $FOAM_LIBBIN/*.dll $PACKAGE_DIR/lib
|
||||||
mkdir $RELEASE_DIR/lib/$MPI_VERSION
|
|
||||||
cp -p $FOAM_MPI_LIBBIN/*.dll $RELEASE_DIR/lib/$MPI_VERSION
|
echo "Copying extra files from bin directory ..."
|
||||||
|
cp -p $WM_PROJECT_DIR/bin/setWindowsEnvironment.bat $PACKAGE_DIR/
|
||||||
|
cp -p $WM_PROJECT_DIR/bin/foamWindowsShell.bat $PACKAGE_DIR/
|
||||||
|
cp -p $WM_PROJECT_DIR/bin/paraFoam.bat $PACKAGE_DIR/bin
|
||||||
|
|
||||||
echo "Copying extra files from etc directory ..."
|
echo "Copying extra files from etc directory ..."
|
||||||
mkdir $RELEASE_DIR/etc
|
mkdir $PACKAGE_DIR/etc
|
||||||
cp -p $WM_PROJECT_DIR/bin/setWindowsEnvironment.bat $RELEASE_DIR/
|
cp -p $WM_PROJECT_DIR/etc/cellModels $PACKAGE_DIR/etc
|
||||||
cp -p $WM_PROJECT_DIR/bin/foamWindowsShell.bat $RELEASE_DIR/
|
cp -rp $WM_PROJECT_DIR/etc/thermoData $PACKAGE_DIR/etc
|
||||||
cp -p $WM_PROJECT_DIR/etc/controlDict-EXAMPLE $RELEASE_DIR/etc
|
|
||||||
cp -p $WM_PROJECT_DIR/etc/cellModels $RELEASE_DIR/etc
|
|
||||||
cp -rp $WM_PROJECT_DIR/etc/thermoData $RELEASE_DIR/etc
|
|
||||||
cp -p $WM_PROJECT_DIR/doc/buildInstructions/Windows/READMEBinaryPackage.txt $RELEASE_DIR/
|
|
||||||
cp -p $WM_PROJECT_DIR/bin/paraFoam.bat $RELEASE_DIR/bin
|
|
||||||
cp -p $WM_PROJECT_DIR/COPYING $RELEASE_DIR/LICENSE.txt
|
|
||||||
unix2dos $RELEASE_DIR/LICENSE.txt
|
|
||||||
|
|
||||||
create_package $RELEASE_DIR zip
|
echo "Copying doc and license files ..."
|
||||||
#create_package $RELEASE_DIR 7z
|
cp -p $WM_PROJECT_DIR/doc/buildInstructions/Windows/READMEBinaryPackage.txt $PACKAGE_DIR/
|
||||||
|
cp -p $WM_PROJECT_DIR/COPYING $PACKAGE_DIR/LICENSE.txt
|
||||||
|
unix2dos $PACKAGE_DIR/LICENSE.txt
|
||||||
|
|
||||||
rm -rf $RELEASE_DIR
|
create_package $PACKAGE_DIR zip
|
||||||
|
create_package $PACKAGE_DIR 7z
|
||||||
|
|
||||||
|
rm -rf $PACKAGE_DIR
|
||||||
|
|
|
@ -37,7 +37,7 @@
|
||||||
|
|
||||||
It is strongly recommended to install all required systems tools and utilities
|
It is strongly recommended to install all required systems tools and utilities
|
||||||
in a directory with no embedded white spaces. You can skip some steps if you
|
in a directory with no embedded white spaces. You can skip some steps if you
|
||||||
already have some of these system tools.
|
already have the correct tools installed on your system.
|
||||||
|
|
||||||
|
|
||||||
2. INSTRUCTIONS FOR BUILDING ON WINDOWS
|
2. INSTRUCTIONS FOR BUILDING ON WINDOWS
|
||||||
|
@ -46,22 +46,32 @@ already have some of these system tools.
|
||||||
1) Download and install 7-Zip (see reference list below). This is necessary to
|
1) Download and install 7-Zip (see reference list below). This is necessary to
|
||||||
be able to unzip the rest of the required packages mentioned in later steps.
|
be able to unzip the rest of the required packages mentioned in later steps.
|
||||||
|
|
||||||
2) Download and install wget, CMake, Git, MinGW-w64, ParaView, PExports, Java, Subversion, Python (see
|
2) Download and install wget, CMake, Git, MinGW-w64, ParaView, PExports, Java,
|
||||||
reference list below). Note that some components (example PExports and GMake)
|
Subversion, Python (see reference list below). Note that some components
|
||||||
may already be available in other packages (such as Strawberry Perl), although
|
(for example PExports and GMake) may already be available in other packages
|
||||||
you need to be careful of the version numbers.
|
(such as Strawberry Perl), although you need to be careful of the
|
||||||
|
version numbers.
|
||||||
|
|
||||||
3) Download and install MSYS (see reference list below). If this is your first
|
3) Download and install MSYS (see reference list below). If this is your first
|
||||||
use of MSYS, create a file fstab in cMinGW/1.0/etc with single-line contents:
|
use of MSYS, create a file fstab in c/MinGW/msys/1.0/etc with single-line
|
||||||
|
contents:
|
||||||
|
|
||||||
c/mingw /mingw
|
c:/mingw /mingw
|
||||||
|
|
||||||
to mount your home directory. From Windows, you will find your home directory
|
to mount your home directory (this assumes you have installed MSYS to the default
|
||||||
under c:/MinGW/msys/1.0/home/<user name>
|
c:/MinGW directory).
|
||||||
|
From Windows, you will find your home directory under
|
||||||
|
c:/MinGW/msys/1.0/home/<user name>
|
||||||
|
|
||||||
4) Download the foam-extend source code from http://sourceforge.net/projects/openfoam-extend/
|
4) Download the foam-extend source code from
|
||||||
|
|
||||||
5) Open a new MSYS shell and chdir to your foam-extend-3.1 source directory.
|
http://sourceforge.net/projects/openfoam-extend/
|
||||||
|
|
||||||
|
using the command:
|
||||||
|
|
||||||
|
git clone --branch nextRelease git://git.code.sf.net/p/openfoam-extend/foam-extend-3.1 foam-extend-3.2
|
||||||
|
|
||||||
|
5) Open a new MSYS shell and chdir to your foam-extend-3.2 source directory.
|
||||||
|
|
||||||
6) Edit the user-modifiable entries in etc/bashrc.mingw to point to the
|
6) Edit the user-modifiable entries in etc/bashrc.mingw to point to the
|
||||||
locations where you have installed the required system tools in the first two
|
locations where you have installed the required system tools in the first two
|
||||||
|
@ -92,9 +102,9 @@ already have some of these system tools.
|
||||||
approach for developers.
|
approach for developers.
|
||||||
|
|
||||||
(b). From a standard Windows CMD.exe command prompt using the created
|
(b). From a standard Windows CMD.exe command prompt using the created
|
||||||
foam-extend-3.1-win-x64.zip stand-alone package. This can be used on any
|
foam-extend-3.2-win-x64.zip stand-alone package. This can be used on any
|
||||||
Windows machine without access to MSYS shells or compilers. See the README.txt
|
Windows machine without access to MSYS shells or compilers. See the
|
||||||
contained within the package for further details.
|
READMEBinaryPackage.txt contained within the package for further details.
|
||||||
|
|
||||||
|
|
||||||
3. EXTERNAL PACKAGE REFERENCE
|
3. EXTERNAL PACKAGE REFERENCE
|
||||||
|
@ -175,22 +185,22 @@ For : Automatically downloading files from internet (eg. for use in automated
|
||||||
git clone --branch nextRelease git://git.code.sf.net/p/openfoam-extend/foam-extend-3.1
|
git clone --branch nextRelease git://git.code.sf.net/p/openfoam-extend/foam-extend-3.1
|
||||||
|
|
||||||
|
|
||||||
4. EXAMPLE OUTPUT FROM SOUCING etc/bashrc.mingw
|
4. EXAMPLE OUTPUT FROM SOURCING etc/bashrc.mingw
|
||||||
===============================================
|
================================================
|
||||||
|
|
||||||
$ . etc/bashrc.mingw
|
$ . etc/bashrc.mingw
|
||||||
Setting environment variables for user-defined installed system tools and utilities ...
|
Setting environment variables for user-defined installed system tools and utilities ...
|
||||||
|
|
||||||
Sourcing: /c/Users/UserName/Git/foam-extend-3.1/etc/bashrc
|
Sourcing: /c/Users/UserName/Git/foam-extend-3.2/etc/bashrc
|
||||||
Sourcing: /c/Users/UserName/Git/foam-extend-3.1/etc/prefs.sh.mingw
|
Sourcing: /c/Users/UserName/Git/foam-extend-3.2/etc/prefs.sh.mingw
|
||||||
Sourcing: /c/Users/UserName/Git/foam-extend-3.1/etc/settings.sh
|
Sourcing: /c/Users/UserName/Git/foam-extend-3.2/etc/settings.sh
|
||||||
MESQUITE_DIR is initialized to: /c/Users/UserName/Git/foam-extend-3.1/ThirdParty/packages/mesquite-2.1.2
|
MESQUITE_DIR is initialized to: /c/Users/UserName/Git/foam-extend-3.2/ThirdParty/packages/mesquite-2.1.2
|
||||||
METIS_DIR is initialized to: /c/Users/UserName/Git/foam-extend-3.1/ThirdParty/packages/metis-5.1.0
|
METIS_DIR is initialized to: /c/Users/UserName/Git/foam-extend-3.2/ThirdParty/packages/metis-5.1.0
|
||||||
PARMETIS_DIR is initialized to: /c/Users/UserName/Git/foam-extend-3.1/ThirdParty/packages/parmetis-4.0.3
|
PARMETIS_DIR is initialized to: /c/Users/UserName/Git/foam-extend-3.2/ThirdParty/packages/parmetis-4.0.3
|
||||||
PARMGRIDGEN_DIR is initialized to: /c/Users/UserName/Git/foam-extend-3.1/ThirdParty/packages/ParMGridGen-1.0
|
PARMGRIDGEN_DIR is initialized to: /c/Users/UserName/Git/foam-extend-3.2/ThirdParty/packages/ParMGridGen-1.0
|
||||||
LIBCCMIO_DIR is initialized to:
|
LIBCCMIO_DIR is initialized to:
|
||||||
SCOTCH_DIR is initialized to: /c/Users/UserName/Git/foam-extend-3.1/ThirdParty/packages/scotch_6.0.0
|
SCOTCH_DIR is initialized to: /c/Users/UserName/Git/foam-extend-3.2/ThirdParty/packages/scotch_6.0.0
|
||||||
SCOTCH_DIR is initialized to: /c/Users/UserName/Git/foam-extend-3.1/ThirdParty/packages/scotch_6.0.0
|
SCOTCH_DIR is initialized to: /c/Users/UserName/Git/foam-extend-3.2/ThirdParty/packages/scotch_6.0.0
|
||||||
CMAKE_DIR is initialized to:
|
CMAKE_DIR is initialized to:
|
||||||
M4_DIR is initialized to:
|
M4_DIR is initialized to:
|
||||||
BISON_DIR is initialized to:
|
BISON_DIR is initialized to:
|
||||||
|
@ -198,13 +208,13 @@ Sourcing: /c/Users/UserName/Git/foam-extend-3.1/etc/settings.sh
|
||||||
ZOLTAN_DIR is initialized to:
|
ZOLTAN_DIR is initialized to:
|
||||||
PYTHON_DIR is initialized to:
|
PYTHON_DIR is initialized to:
|
||||||
PYFOAM_DIR is initialized to:
|
PYFOAM_DIR is initialized to:
|
||||||
PYFOAM_SITE_DIR is initialized to: /c/Users/UserName/Git/foam-extend-3.1/ThirdParty/PyFoamSiteScripts
|
PYFOAM_SITE_DIR is initialized to: /c/Users/UserName/Git/foam-extend-3.2/ThirdParty/PyFoamSiteScripts
|
||||||
HWLOC_DIR is initialized to:
|
HWLOC_DIR is initialized to:
|
||||||
QT_DIR is initialized to:
|
QT_DIR is initialized to:
|
||||||
PARAVIEW_DIR is initialized to:
|
PARAVIEW_DIR is initialized to:
|
||||||
LLVM_DIR is initialized to:
|
LLVM_DIR is initialized to:
|
||||||
MESA_DIR is initialized to:
|
MESA_DIR is initialized to:
|
||||||
Sourcing: /c/Users/UserName/Git/foam-extend-3.1/etc/aliases.sh
|
Sourcing: /c/Users/UserName/Git/foam-extend-3.2/etc/aliases.sh
|
||||||
|
|
||||||
Adding user-defined installed system tools to PATH ...
|
Adding user-defined installed system tools to PATH ...
|
||||||
Setting OpenMPI environment settings ...
|
Setting OpenMPI environment settings ...
|
||||||
|
@ -233,6 +243,6 @@ Wget: /c/Programs/wget-1.11.4-1/bin/wget.exe [GNU Wget 1.11.4 Copyright (
|
||||||
|
|
||||||
|
|
||||||
FOAM_INST_DIR=/c/Users/UserName/Git
|
FOAM_INST_DIR=/c/Users/UserName/Git
|
||||||
WM_PROJECT_DIR=/c/Users/UserName/Git/foam-extend-3.1
|
WM_PROJECT_DIR=/c/Users/UserName/Git/foam-extend-3.2
|
||||||
WM_OSTYPE=MSWindows
|
WM_OSTYPE=MSWindows
|
||||||
ENVIRONMENT SETUP COMPLETE.
|
ENVIRONMENT SETUP COMPLETE.
|
||||||
|
|
|
@ -22,7 +22,7 @@
|
||||||
# along with foam-extend. If not, see <http://www.gnu.org/licenses/>.
|
# along with foam-extend. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#
|
#
|
||||||
# File
|
# File
|
||||||
# README_Windows.txt
|
# READMEBinaryPackage.txt
|
||||||
#
|
#
|
||||||
# Description
|
# Description
|
||||||
# Installation and usage instructions for stand-alone Windows builds.
|
# Installation and usage instructions for stand-alone Windows builds.
|
||||||
|
|
|
@ -22,10 +22,11 @@
|
||||||
# along with foam-extend. If not, see <http://www.gnu.org/licenses/>.
|
# along with foam-extend. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#
|
#
|
||||||
# File
|
# File
|
||||||
# etc/prefs.sh
|
# etc/prefs.sh.mingw
|
||||||
#
|
#
|
||||||
# Description
|
# Description
|
||||||
# Preset variables for the FOAM configuration - POSIX shell syntax.
|
# Preset variables for the FOAM configuration - POSIX shell syntax
|
||||||
|
# for MS Windows
|
||||||
#
|
#
|
||||||
# The prefs.sh file will be sourced by the FOAM etc/bashrc when it is
|
# The prefs.sh file will be sourced by the FOAM etc/bashrc when it is
|
||||||
# found
|
# found
|
||||||
|
|
Reference in a new issue