ThirdParty: adjustments for Ubuntu 12.04 32 bit
This commit is contained in:
parent
0e0052604b
commit
4ebf8c586f
22 changed files with 221 additions and 3 deletions
|
@ -7,7 +7,15 @@ diff -ruN libccmio-2.6.1_orig/config/config.gnu.to.star libccmio-2.6.1/config/co
|
|||
|
||||
# $Id: config.gnu.to.star,v 1.4 2006/06/05 21:12:16 geoffp Exp $
|
||||
|
||||
@@ -34,6 +34,8 @@
|
||||
@@ -24,6 +24,7 @@
|
||||
mips-sgi-irix64_6-null) echo irix64_6.5-mips4 ;;
|
||||
i586-unknown-linux_2.2-glibc-null) echo linux_2.2-x86-glibc_2.2.0 ;;
|
||||
i586-unknown-linux_2.4-glibc-null) echo linux_2.4-x86-glibc_2.3.2 ;;
|
||||
+ i586-unknown-linux-libc5-null) echo linux_2.4-x86-glibc_2.3.2 ;;
|
||||
ia64-unknown-linux-null) echo linux64_2.4-itanium-glibc_2.2.4 ;;
|
||||
alpha-dec-osf3-null) echo osf1_4.0-com ;;
|
||||
alpha-dec-osf5-null) echo osf1_5.1-com ;;
|
||||
@@ -34,6 +35,8 @@
|
||||
x86_64-unknown-linux-gnu-null) echo linux64_2.4-x86-glibc_2.2.5 ;;
|
||||
ppc64-unknown-linux-gnu-null) echo linux64_2.6-pwr4-glibc_2.3.3 ;;
|
||||
i386-apple-darwin8-null) echo i386-apple-darwin8 ;;
|
||||
|
|
|
@ -39,7 +39,7 @@ diff -ruN scotch_5.1.10b_orig/src/Make.inc/Makefile.inc.i686_pc_linux2.shlib sco
|
|||
-CCD = gcc
|
||||
-CFLAGS = -O3 -DCOMMON_FILE_COMPRESS_GZ -DCOMMON_PTHREAD -DCOMMON_RANDOM_FIXED_SEED -DSCOTCH_RENAME -DSCOTCH_RENAME_PARSER -DSCOTCH_PTHREAD -Drestrict=__restrict
|
||||
-CLIBFLAGS = -shared -fPIC
|
||||
+CCD = gcc -I$(MPI_HOME)/include
|
||||
+CCD = mpicc -I$(MPI_HOME)/include
|
||||
+CFLAGS = -O3 -fPIC -DCOMMON_FILE_COMPRESS_GZ -DCOMMON_PTHREAD -DCOMMON_RANDOM_FIXED_SEED -DSCOTCH_RENAME -DSCOTCH_RENAME_PARSER -DSCOTCH_PTHREAD -Drestrict=__restrict
|
||||
+CLIBFLAGS = -shared
|
||||
LDFLAGS = -lz -lm -lrt
|
||||
|
|
|
@ -130,9 +130,11 @@ cat << DOT_SH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.sh
|
|||
|
||||
export QT_DIR=\$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS
|
||||
export QT_BIN_DIR=\$QT_DIR/bin
|
||||
export QT_LIB_DIR=\$QT_DIR/lib
|
||||
|
||||
# Enable access to the runtime package applications
|
||||
[ -d \$QT_BIN_DIR ] && _foamAddPath \$QT_BIN_DIR
|
||||
[ -d \$QT_LIB_DIR ] && _foamAddLib \$QT_LIB_DIR
|
||||
DOT_SH_EOF
|
||||
|
||||
#
|
||||
|
@ -143,10 +145,15 @@ cat << DOT_CSH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.cs
|
|||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
setenv QT_DIR \$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS
|
||||
setenv QT_BIN_DIR \$QT_DIR/bin
|
||||
setenv QT_LIB_DIR \$QT_DIR/lib
|
||||
|
||||
if ( -e \$QT_BIN_DIR ) then
|
||||
_foamAddPath \$QT_BIN_DIR
|
||||
endif
|
||||
|
||||
if ( -e \$QT_LIB_DIR ) then
|
||||
_foamAddLib \$QT_LIB_DIR
|
||||
endif
|
||||
DOT_CSH_EOF
|
||||
|
||||
#finally, generate a .tgz file for systems where using rpm for installing packages
|
||||
|
|
|
@ -0,0 +1,120 @@
|
|||
Installation of OpenFOAM-1.6-ext on Ubuntu 12.04 64-bit
|
||||
|
||||
- Proceed with the installation of the OS
|
||||
- Update your OS installation using "Update Manager".
|
||||
- If asked to reboot your system, please do so.
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
# Installation of additional system packages:
|
||||
git: sudo apt-get install git
|
||||
flex: sudo apt-get install flex
|
||||
bison: sudo apt-get install bison
|
||||
rpm: sudo apt-get install rpm
|
||||
g++: sudo apt-get install g++
|
||||
libz: sudo apt-get install zlib1g-dev
|
||||
binutils-dev : sudo apt-get install binutils-dev
|
||||
openmpi: sudo apt-get install openmpi-bin libopenmpi-dev
|
||||
libxext: sudo apt-get install libxext-dev
|
||||
libxt : sudo apt-get install libxt-dev
|
||||
libXrender: sudo apt-get install libxrender-dev
|
||||
libstdc++5: sudo apt-get install libstdc++5
|
||||
OpenGL: sudo apt-get install libgl1-mesa-dev libglu1-mesa-dev
|
||||
|
||||
# You can also install everything at once:
|
||||
sudo apt-get install git flex bison rpm g++ zlib1g-dev binutils-dev \
|
||||
openmpi-bin libopenmpi-dev libxext-dev libxt-dev libxrender-dev \
|
||||
libstdc++5 libgl1-mesa-dev libglu1-mesa-dev
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
# If you need to compile swak4Foam, it is a good idea to install Mercurial (hg)
|
||||
# sudo apt-get install mercurial
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
# Minor correction for make/gmake
|
||||
sudo ln -s /usr/bin/make /usr/bin/gmake
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
# Download OpenFOAM-1.6-ext
|
||||
mkdir ~/OpenFOAM
|
||||
cd ~/OpenFOAM
|
||||
git clone git://openfoam-extend.git.sourceforge.net/gitroot/openfoam-extend/OpenFOAM-1.6-ext
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
# Create the file etc/prefs.sh
|
||||
cp ~/OpenFOAM/OpenFOAM-1.6-ext/etc/prefs.sh-EXAMPLE ~/OpenFOAM/OpenFOAM-1.6-ext/etc/prefs.sh
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
# Use the system compiler
|
||||
sed -i s/"compilerInstall=System"/"compilerInstall=System\nWM_COMPILER=Gcc46"/g ~/OpenFOAM/OpenFOAM-1.6-ext/etc/prefs.sh
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
# Use the system installation of OpenMPI
|
||||
sed -i s/"#export WM_MPLIB=SYSTEMOPENMPI"/"export WM_MPLIB=SYSTEMOPENMPI"/g ~/OpenFOAM/OpenFOAM-1.6-ext/etc/prefs.sh
|
||||
sed -i s/"#export OPENMPI_DIR=path_to_system_installed_openmpi"/"export OPENMPI_DIR=\/usr"/g ~/OpenFOAM/OpenFOAM-1.6-ext/etc/prefs.sh
|
||||
sed -i s/"#export OPENMPI_BIN_DIR=\$OPENMPI_DIR\/bin"/"export OPENMPI_BIN_DIR=\$OPENMPI_DIR\/bin"/g ~/OpenFOAM/OpenFOAM-1.6-ext/etc/prefs.sh
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
# About QT4
|
||||
#
|
||||
# Ubuntu 12.04 comes with QT4 version 4.8.1
|
||||
# Even thoug ParaView will compile with this version of QT, ParaView will also generate a bunch of
|
||||
# warnings on the console at runtime. So we will be using the version of QT4 supplied with the
|
||||
# ThirdParty packages.
|
||||
|
||||
#Uncomment the variable QT_THIRD_PARTY in the file prefs.sh
|
||||
|
||||
sed -i s/"#export QT_THIRD_PARTY=1"/"export QT_THIRD_PARTY=1"/g ~/OpenFOAM/OpenFOAM-1.6-ext/etc/prefs.sh
|
||||
|
||||
# This section of the prefs.sh file should now look like this:
|
||||
|
||||
export QT_THIRD_PARTY=1
|
||||
#export QT_DIR=path_to_system_installed_qt
|
||||
#export QT_BIN_DIR=$QT_DIR/bin
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
# Source your OpenFOAM environment to get the basic configuration for
|
||||
# compilation
|
||||
. ~/OpenFOAM/OpenFOAM-1.6-ext/etc/bashrc
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
# Compile the ThirdParty packages
|
||||
cd $WM_PROJECT_DIR/ThirdParty
|
||||
./AllMake.stage1 >& log.AllMake.stage1
|
||||
#./AllMake.stage2 >& log.AllMake.stage2 # No need for this one
|
||||
./AllMake.stage3 >& log.AllMake.stage3
|
||||
./AllMake.stage4 >& log.AllMake.stage4
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
# Update your OpenFOAM environment to get the basic configuration from the newly
|
||||
# compiled ThirdParty packages
|
||||
. ~/OpenFOAM/OpenFOAM-1.6-ext/etc/bashrc
|
||||
|
||||
# Compile OpenFOAM-1.6-ext
|
||||
cd $WM_PROJECT_DIR
|
||||
./Allwmake >& log.Allwmake &
|
||||
tail -f log.Allwmake # To keep an eye on the compilation process
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
# Run a tutorial to check the basic functionality
|
||||
cd $FOAM_TUTORIAL/incompressible/simpleFoam/pitzDaily
|
||||
blockMesh >& log.blockMesh
|
||||
simpleFoam >& log.simpleFoam
|
||||
paraFoam
|
||||
|
||||
# You are done!
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
Martin Beaudoin
|
||||
May 2012
|
|
@ -18,10 +18,12 @@ openmpi: sudo apt-get install openmpi-bin libopenmpi-dev
|
|||
libxext: sudo apt-get install libxext-dev
|
||||
libxt : sudo apt-get install libxt-dev
|
||||
libXrender: sudo apt-get install libxrender-dev
|
||||
OpenGL: sudo apt-get install libgl1-mesa-dev libglu1-mesa-dev
|
||||
|
||||
# You can also install everything at once:
|
||||
sudo apt-get install git flex bison rpm g++ zlib1g-dev binutils-dev \
|
||||
openmpi-bin libopenmpi-dev libxext-dev libxt-dev libxrender-dev
|
||||
openmpi-bin libopenmpi-dev libxext-dev libxt-dev libxrender-dev \
|
||||
libgl1-mesa-dev libglu1-mesa-dev
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
|
|
3
wmake/rules/linuxGcc46/X
Normal file
3
wmake/rules/linuxGcc46/X
Normal file
|
@ -0,0 +1,3 @@
|
|||
XFLAGS =
|
||||
XINC = $(XFLAGS) -I/usr/X11R6/include
|
||||
XLIBS = -L/usr/X11R6/lib -lXext -lX11
|
16
wmake/rules/linuxGcc46/c
Normal file
16
wmake/rules/linuxGcc46/c
Normal file
|
@ -0,0 +1,16 @@
|
|||
.SUFFIXES: .c .h
|
||||
|
||||
cWARN = -Wall
|
||||
|
||||
cc = gcc -m32
|
||||
|
||||
include $(RULES)/c$(WM_COMPILE_OPTION)
|
||||
|
||||
cFLAGS = $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) $(LIB_HEADER_DIRS) -fPIC
|
||||
|
||||
ctoo = $(WM_SCHEDULER) $(cc) $(cFLAGS) -c $$SOURCE -o $@
|
||||
|
||||
LINK_LIBS = $(cDBUG)
|
||||
|
||||
LINKLIBSO = $(cc) -shared
|
||||
LINKEXE = $(cc) -Xlinker --add-needed -Xlinker -z -Xlinker nodefs
|
21
wmake/rules/linuxGcc46/c++
Normal file
21
wmake/rules/linuxGcc46/c++
Normal file
|
@ -0,0 +1,21 @@
|
|||
.SUFFIXES: .C .cxx .cc .cpp
|
||||
|
||||
c++WARN = -Wall -Wextra -Wno-unused-parameter -Wold-style-cast
|
||||
|
||||
CC = g++ -m32
|
||||
|
||||
include $(RULES)/c++$(WM_COMPILE_OPTION)
|
||||
|
||||
ptFLAGS = -DNoRepository -ftemplate-depth-40
|
||||
|
||||
c++FLAGS = $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) $(LIB_HEADER_DIRS) -fPIC
|
||||
|
||||
Ctoo = $(WM_SCHEDULER) $(CC) $(c++FLAGS) -c $$SOURCE -o $@
|
||||
cxxtoo = $(Ctoo)
|
||||
cctoo = $(Ctoo)
|
||||
cpptoo = $(Ctoo)
|
||||
|
||||
LINK_LIBS = $(c++DBUG)
|
||||
|
||||
LINKLIBSO = $(CC) $(c++FLAGS) -shared -Xlinker --add-needed -Xlinker --no-as-needed
|
||||
LINKEXE = $(CC) $(c++FLAGS) -Xlinker --add-needed -Xlinker --no-as-needed
|
2
wmake/rules/linuxGcc46/c++Debug
Normal file
2
wmake/rules/linuxGcc46/c++Debug
Normal file
|
@ -0,0 +1,2 @@
|
|||
c++DBUG = -ggdb3 -DFULLDEBUG
|
||||
c++OPT = -O0 -fdefault-inline
|
2
wmake/rules/linuxGcc46/c++Opt
Normal file
2
wmake/rules/linuxGcc46/c++Opt
Normal file
|
@ -0,0 +1,2 @@
|
|||
c++DBUG =
|
||||
c++OPT = -O3
|
2
wmake/rules/linuxGcc46/c++Prof
Normal file
2
wmake/rules/linuxGcc46/c++Prof
Normal file
|
@ -0,0 +1,2 @@
|
|||
c++DBUG = -pg
|
||||
c++OPT = -O2
|
2
wmake/rules/linuxGcc46/cDebug
Normal file
2
wmake/rules/linuxGcc46/cDebug
Normal file
|
@ -0,0 +1,2 @@
|
|||
cDBUG = -ggdb -DFULLDEBUG
|
||||
cOPT = -O1 -fdefault-inline -finline-functions
|
2
wmake/rules/linuxGcc46/cOpt
Normal file
2
wmake/rules/linuxGcc46/cOpt
Normal file
|
@ -0,0 +1,2 @@
|
|||
cDBUG =
|
||||
cOPT = -O3
|
2
wmake/rules/linuxGcc46/cProf
Normal file
2
wmake/rules/linuxGcc46/cProf
Normal file
|
@ -0,0 +1,2 @@
|
|||
cDBUG = -pg
|
||||
cOPT = -O2
|
10
wmake/rules/linuxGcc46/general
Normal file
10
wmake/rules/linuxGcc46/general
Normal file
|
@ -0,0 +1,10 @@
|
|||
CPP = cpp -traditional-cpp
|
||||
LD = ld -melf_i386
|
||||
|
||||
PROJECT_LIBS = -l$(WM_PROJECT) -ldl
|
||||
|
||||
include $(GENERAL_RULES)/standard
|
||||
|
||||
include $(RULES)/X
|
||||
include $(RULES)/c
|
||||
include $(RULES)/c++
|
3
wmake/rules/linuxGcc46/mplib
Normal file
3
wmake/rules/linuxGcc46/mplib
Normal file
|
@ -0,0 +1,3 @@
|
|||
PFLAGS =
|
||||
PINC =
|
||||
PLIBS =
|
3
wmake/rules/linuxGcc46/mplibGAMMA
Normal file
3
wmake/rules/linuxGcc46/mplibGAMMA
Normal file
|
@ -0,0 +1,3 @@
|
|||
PFLAGS =
|
||||
PINC = -I$(MPI_ARCH_PATH)/include
|
||||
PLIBS = -L$(MPI_ARCH_PATH)/lib -lgamma
|
3
wmake/rules/linuxGcc46/mplibHPMPI
Normal file
3
wmake/rules/linuxGcc46/mplibHPMPI
Normal file
|
@ -0,0 +1,3 @@
|
|||
PFLAGS =
|
||||
PINC = -I$(MPI_ARCH_PATH)/include -D_MPICC_H
|
||||
PLIBS = -L$(MPI_ARCH_PATH)/lib/linux_ia32 -lmpi
|
3
wmake/rules/linuxGcc46/mplibMPICH
Normal file
3
wmake/rules/linuxGcc46/mplibMPICH
Normal file
|
@ -0,0 +1,3 @@
|
|||
PFLAGS = -DMPICH_SKIP_MPICXX
|
||||
PINC = -I$(MPI_ARCH_PATH)/include
|
||||
PLIBS = -L$(MPI_ARCH_PATH)/lib -lmpich -lrt
|
3
wmake/rules/linuxGcc46/mplibMPICH-GM
Normal file
3
wmake/rules/linuxGcc46/mplibMPICH-GM
Normal file
|
@ -0,0 +1,3 @@
|
|||
PFLAGS =
|
||||
PINC = -I$(MPI_ARCH_PATH)/include
|
||||
PLIBS = -L$(MPI_ARCH_PATH)/lib -lmpich -L$(GM_LIB_PATH) -lgm
|
3
wmake/rules/linuxGcc46/mplibOPENMPI
Normal file
3
wmake/rules/linuxGcc46/mplibOPENMPI
Normal file
|
@ -0,0 +1,3 @@
|
|||
PFLAGS = -DOMPI_SKIP_MPICXX
|
||||
PINC = -I$(MPI_ARCH_PATH)/include
|
||||
PLIBS = -L$(MPI_ARCH_PATH)/lib -lmpi
|
1
wmake/rules/linuxGcc46/mplibSYSTEMOPENMPI
Normal file
1
wmake/rules/linuxGcc46/mplibSYSTEMOPENMPI
Normal file
|
@ -0,0 +1 @@
|
|||
PFLAGS = -DOMPI_SKIP_MPICXX
|
Reference in a new issue