From bb4cc6905f2fdec17d3ab02fd23e4aa1ef368f14 Mon Sep 17 00:00:00 2001 From: Martin Beaudoin Date: Thu, 10 May 2012 00:15:37 -0400 Subject: [PATCH 01/14] ThirdParty: fix compilation of ParMetis 3.1.1 on Mac OS X --- .../SOURCES/ParMetis-3.1.1.patch_darwin | 25 ++++++++++++++----- 1 file changed, 19 insertions(+), 6 deletions(-) diff --git a/ThirdParty/rpmBuild/SOURCES/ParMetis-3.1.1.patch_darwin b/ThirdParty/rpmBuild/SOURCES/ParMetis-3.1.1.patch_darwin index 0b4349e44..a6ff2d775 100644 --- a/ThirdParty/rpmBuild/SOURCES/ParMetis-3.1.1.patch_darwin +++ b/ThirdParty/rpmBuild/SOURCES/ParMetis-3.1.1.patch_darwin @@ -1,6 +1,6 @@ diff -ruN ParMetis-3.1.1_orig/METISLib/Makefile ParMetis-3.1.1/METISLib/Makefile --- ParMetis-3.1.1_orig/METISLib/Makefile 2007-03-19 13:46:34.000000000 -0400 -+++ ParMetis-3.1.1/METISLib/Makefile 2010-10-31 17:13:46.000000000 -0400 ++++ ParMetis-3.1.1/METISLib/Makefile 2011-12-24 15:06:49.000000000 -0500 @@ -19,7 +19,7 @@ .c.o: $(CC) $(CFLAGS) -c $*.c @@ -19,10 +19,9 @@ diff -ruN ParMetis-3.1.1_orig/METISLib/Makefile ParMetis-3.1.1/METISLib/Makefile checkin: -Binary files ParMetis-3.1.1_orig/METISLib/libmetis-parmetis.dylib and ParMetis-3.1.1/METISLib/libmetis-parmetis.dylib differ diff -ruN ParMetis-3.1.1_orig/Makefile.in ParMetis-3.1.1/Makefile.in --- ParMetis-3.1.1_orig/Makefile.in 2008-11-17 18:47:06.000000000 -0500 -+++ ParMetis-3.1.1/Makefile.in 2010-10-31 17:20:54.000000000 -0400 ++++ ParMetis-3.1.1/Makefile.in 2011-12-24 15:06:49.000000000 -0500 @@ -10,7 +10,7 @@ INCDIR = @@ -51,7 +50,7 @@ diff -ruN ParMetis-3.1.1_orig/Makefile.in ParMetis-3.1.1/Makefile.in VERNUM = diff -ruN ParMetis-3.1.1_orig/ParMETISLib/Makefile ParMetis-3.1.1/ParMETISLib/Makefile --- ParMetis-3.1.1_orig/ParMETISLib/Makefile 2008-11-17 17:43:23.000000000 -0500 -+++ ParMetis-3.1.1/ParMETISLib/Makefile 2010-10-31 17:13:46.000000000 -0400 ++++ ParMetis-3.1.1/ParMETISLib/Makefile 2011-12-24 15:06:49.000000000 -0500 @@ -22,7 +22,7 @@ $(CC) $(CFLAGS) -c $*.c @@ -70,10 +69,24 @@ diff -ruN ParMetis-3.1.1_orig/ParMETISLib/Makefile ParMetis-3.1.1/ParMETISLib/Ma checkin: -Binary files ParMetis-3.1.1_orig/ParMETISLib/libparmetis.dylib and ParMetis-3.1.1/ParMETISLib/libparmetis.dylib differ +diff -ruN ParMetis-3.1.1_orig/ParMETISLib/stdheaders.h ParMetis-3.1.1/ParMETISLib/stdheaders.h +--- ParMetis-3.1.1_orig/ParMETISLib/stdheaders.h 2008-09-16 17:39:19.000000000 -0400 ++++ ParMetis-3.1.1/ParMETISLib/stdheaders.h 2011-12-24 15:07:42.000000000 -0500 +@@ -13,8 +13,11 @@ + + + #include ++#ifdef __STDC__ + #include ++#else + #include ++#endif + #include + #include + #include diff -ruN ParMetis-3.1.1_orig/Programs/Makefile ParMetis-3.1.1/Programs/Makefile --- ParMetis-3.1.1_orig/Programs/Makefile 2008-11-17 18:47:06.000000000 -0500 -+++ ParMetis-3.1.1/Programs/Makefile 2010-10-31 17:13:46.000000000 -0400 ++++ ParMetis-3.1.1/Programs/Makefile 2011-12-24 15:06:49.000000000 -0500 @@ -6,9 +6,9 @@ CFLAGS = $(COPTIONS) $(OPTFLAGS) $(INCLUDES) From a09f865c8b2d0135111043f17ec84c2d63431f0d Mon Sep 17 00:00:00 2001 From: Martin Beaudoin Date: Thu, 10 May 2012 00:24:54 -0400 Subject: [PATCH 02/14] ThirdParty: fix compilation of ParMGridGen-1.0 on Mac OS X --- .../SOURCES/ParMGridGen-1.0.patch_darwin | 48 +++++++++++++++---- 1 file changed, 39 insertions(+), 9 deletions(-) diff --git a/ThirdParty/rpmBuild/SOURCES/ParMGridGen-1.0.patch_darwin b/ThirdParty/rpmBuild/SOURCES/ParMGridGen-1.0.patch_darwin index 264f9784a..29a9db97c 100644 --- a/ThirdParty/rpmBuild/SOURCES/ParMGridGen-1.0.patch_darwin +++ b/ThirdParty/rpmBuild/SOURCES/ParMGridGen-1.0.patch_darwin @@ -1,6 +1,18 @@ +diff -ruN ParMGridGen-1.0_orig/MGridGen/IMlib/IMlib.h ParMGridGen-1.0/MGridGen/IMlib/IMlib.h +--- ParMGridGen-1.0_orig/MGridGen/IMlib/IMlib.h 2001-11-08 18:41:25.000000000 -0500 ++++ ParMGridGen-1.0/MGridGen/IMlib/IMlib.h 2011-12-24 13:46:41.000000000 -0500 +@@ -43,7 +43,7 @@ + #ifdef DMALLOC + #include + #else +-#include ++#include + #endif + + /************************************************************************* diff -ruN ParMGridGen-1.0_orig/MGridGen/IMlib/Makefile ParMGridGen-1.0/MGridGen/IMlib/Makefile --- ParMGridGen-1.0_orig/MGridGen/IMlib/Makefile 2001-12-04 17:46:56.000000000 -0500 -+++ ParMGridGen-1.0/MGridGen/IMlib/Makefile 2010-10-31 17:29:25.000000000 -0400 ++++ ParMGridGen-1.0/MGridGen/IMlib/Makefile 2011-12-24 13:24:17.000000000 -0500 @@ -33,7 +33,7 @@ .c.o: $(CC) $(CFLAGS) -c $*.c @@ -16,10 +28,9 @@ diff -ruN ParMGridGen-1.0_orig/MGridGen/IMlib/Makefile ParMGridGen-1.0/MGridGen/ realclean: - rm -f *.o ; rm -f ./libIMlib.a + rm -f *.o ; rm -f ./libIMlib.$(LIBEXT) -Binary files ParMGridGen-1.0_orig/MGridGen/IMlib/libIMlib.dylib and ParMGridGen-1.0/MGridGen/IMlib/libIMlib.dylib differ diff -ruN ParMGridGen-1.0_orig/MGridGen/Lib/Makefile ParMGridGen-1.0/MGridGen/Lib/Makefile --- ParMGridGen-1.0_orig/MGridGen/Lib/Makefile 2001-12-04 18:01:00.000000000 -0500 -+++ ParMGridGen-1.0/MGridGen/Lib/Makefile 2010-10-31 17:29:25.000000000 -0400 ++++ ParMGridGen-1.0/MGridGen/Lib/Makefile 2011-12-24 13:24:17.000000000 -0500 @@ -22,7 +22,7 @@ INCLUDES = -I./ -I$(IMLIBDIR) $(INCDIR) CFLAGS = $(COPTIONS) $(OPTFLAGS) $(DEBUGFLAGS) $(INCLUDES) @@ -44,10 +55,21 @@ diff -ruN ParMGridGen-1.0_orig/MGridGen/Lib/Makefile ParMGridGen-1.0/MGridGen/Li realclean: - rm -f *.o ; rm -f ../../libmgrid.a + rm -f *.o ; rm -f ./libMGridGen.$(LIBEXT) -Binary files ParMGridGen-1.0_orig/MGridGen/Lib/libMGridGen.dylib and ParMGridGen-1.0/MGridGen/Lib/libMGridGen.dylib differ +diff -ruN ParMGridGen-1.0_orig/MGridGen/Lib/mgridgen.h ParMGridGen-1.0/MGridGen/Lib/mgridgen.h +--- ParMGridGen-1.0_orig/MGridGen/Lib/mgridgen.h 2001-11-08 18:41:25.000000000 -0500 ++++ ParMGridGen-1.0/MGridGen/Lib/mgridgen.h 2011-12-24 13:48:18.000000000 -0500 +@@ -26,7 +26,7 @@ + #ifdef DMALLOC + #include + #else +-#include ++#include + #endif + + #include "defs.h" diff -ruN ParMGridGen-1.0_orig/MGridGen/Programs/Makefile ParMGridGen-1.0/MGridGen/Programs/Makefile --- ParMGridGen-1.0_orig/MGridGen/Programs/Makefile 2001-12-04 18:02:26.000000000 -0500 -+++ ParMGridGen-1.0/MGridGen/Programs/Makefile 2010-10-31 17:29:25.000000000 -0400 ++++ ParMGridGen-1.0/MGridGen/Programs/Makefile 2011-12-24 13:24:17.000000000 -0500 @@ -1,6 +1,6 @@ include ../../Makefile.in @@ -57,8 +79,16 @@ diff -ruN ParMGridGen-1.0_orig/MGridGen/Programs/Makefile ParMGridGen-1.0/MGridG ifeq ($(ddmalloc),yes) DEBUGFLAGS := $(DEBUGFLAGS) -DDMALLOC -DDEBUG diff -ruN ParMGridGen-1.0_orig/Makefile.in ParMGridGen-1.0/Makefile.in ---- ParMGridGen-1.0_orig/Makefile.in 2001-12-04 19:30:33.000000000 -0500 -+++ ParMGridGen-1.0/Makefile.in 2010-10-31 17:30:58.000000000 -0400 +--- ParMGridGen-1.0_orig/Makefile.in 2011-12-24 13:54:44.000000000 -0500 ++++ ParMGridGen-1.0/Makefile.in 2011-12-24 13:49:26.000000000 -0500 +@@ -1,6 +1,6 @@ + #-------------------------------------------------------------------------- + # Which make to use +-make = gmake ++make = make + + # Which compiler to use + # CC is the compiler for the serial code @@ -12,7 +12,7 @@ OPTFLAGS = -O3 @@ -72,8 +102,9 @@ diff -ruN ParMGridGen-1.0_orig/Makefile.in ParMGridGen-1.0/Makefile.in # In which directories to look for any additional libraries LIBDIR = -L../.. \ +- -L/usr/lib32/ + -L../Lib \ - -L/usr/lib32/ ++ -L/usr/lib/ # Set some flags DEBUGFLAGS = @@ -98,4 +129,3 @@ diff -ruN ParMGridGen-1.0_orig/Makefile.in ParMGridGen-1.0/Makefile.in #-------------------------------------------------------------------------- # -Binary files ParMGridGen-1.0_orig/mgridgen and ParMGridGen-1.0/mgridgen differ From 91073b20d495fa9a14ab55ce4e007dd35f1497a0 Mon Sep 17 00:00:00 2001 From: Martin Beaudoin Date: Thu, 10 May 2012 01:09:42 -0400 Subject: [PATCH 03/14] ThirdParty: fix compilation of libccmio-2.6.1 on Mac OS X --- ThirdParty/rpmBuild/SOURCES/libccmio-2.6.1.patch_0 | 11 +++++++++-- ThirdParty/rpmBuild/SPECS/libccmio-2.6.1.spec | 5 +++-- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/ThirdParty/rpmBuild/SOURCES/libccmio-2.6.1.patch_0 b/ThirdParty/rpmBuild/SOURCES/libccmio-2.6.1.patch_0 index 1a1285b1a..7d1228a4b 100644 --- a/ThirdParty/rpmBuild/SOURCES/libccmio-2.6.1.patch_0 +++ b/ThirdParty/rpmBuild/SOURCES/libccmio-2.6.1.patch_0 @@ -7,11 +7,12 @@ 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,7 @@ +@@ -34,6 +34,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 ;; + i386-apple-darwin10-null) echo i386-apple-darwin10 ;; ++ i386-apple-darwin11-null) echo i386-apple-darwin11 ;; *) echo unknown ;; esac @@ -33,12 +34,18 @@ diff -ruN libccmio-2.6.1_orig/config/config.system libccmio-2.6.1/config/config. # $Id: config.system,v 1.2 2005/09/29 22:19:19 geoffp Exp $ -@@ -87,6 +87,9 @@ +@@ -87,6 +87,15 @@ i386-apple-darwin8.11.1) echo i386-apple-darwin8 ;; + i386-apple-darwin10.5.0 | i386-apple-darwin10.7.0 | i386-apple-darwin10.8.0) + echo i386-apple-darwin10 ;; ++ ++ i386-apple-darwin11.2.0 ) ++ echo i386-apple-darwin11 ;; ++ ++ i386-apple-darwin11.3.0 ) ++ echo i386-apple-darwin11 ;; + *) echo unknown diff --git a/ThirdParty/rpmBuild/SPECS/libccmio-2.6.1.spec b/ThirdParty/rpmBuild/SPECS/libccmio-2.6.1.spec index dac587b5c..69da61f11 100644 --- a/ThirdParty/rpmBuild/SPECS/libccmio-2.6.1.spec +++ b/ThirdParty/rpmBuild/SPECS/libccmio-2.6.1.spec @@ -97,8 +97,9 @@ Patch0: libccmio-2.6.1.patch_0 [ -z "$WM_NCOMPPROCS" ] && WM_NCOMPPROCS=1 %ifos darwin - # Missing configuration for Mac OS X 10 - [ ! -d configi386-apple-darwin10 ] && cp -r config/i386-apple-darwin8 config/i386-apple-darwin10 + # Missing configuration files for Mac OS X + [ ! -d config/i386-apple-darwin10 ] && cp -r config/i386-apple-darwin8 config/i386-apple-darwin10 + [ ! -d config/i386-apple-darwin11 ] && cp -r config/i386-apple-darwin8 config/i386-apple-darwin11 %endif # Warning: # 1: The name of the ADF library will be renamed to libadf_ccmio since this From c4a76be1381ea5cfd5175fb62ae135e853e96313 Mon Sep 17 00:00:00 2001 From: Martin Beaudoin Date: Thu, 10 May 2012 01:48:59 -0400 Subject: [PATCH 04/14] ThirdParty: fix compilation of mesquite-2.1.2 with gcc 4.6.x. Contribution from Philippose Rajan --- ThirdParty/rpmBuild/SOURCES/mesquite-2.1.2_patch0 | 11 +++++++++++ ThirdParty/rpmBuild/SPECS/mesquite-2.1.2.spec | 8 +++++++- 2 files changed, 18 insertions(+), 1 deletion(-) create mode 100644 ThirdParty/rpmBuild/SOURCES/mesquite-2.1.2_patch0 diff --git a/ThirdParty/rpmBuild/SOURCES/mesquite-2.1.2_patch0 b/ThirdParty/rpmBuild/SOURCES/mesquite-2.1.2_patch0 new file mode 100644 index 000000000..3c4c1bd78 --- /dev/null +++ b/ThirdParty/rpmBuild/SOURCES/mesquite-2.1.2_patch0 @@ -0,0 +1,11 @@ +diff -rupN mesquite-2.1.2/include/Mesquite.hpp mesquite-2.1.2_mod/include/Mesquite.hpp +--- mesquite-2.1.2/include/Mesquite.hpp 2012-05-09 20:53:10.558214520 +0200 ++++ mesquite-2.1.2_mod/include/Mesquite.hpp 2012-04-30 10:24:48.000000000 +0200 +@@ -53,6 +53,7 @@ + #define MESQUITE_EXPORT + #endif + ++#include + #include + #include + #include diff --git a/ThirdParty/rpmBuild/SPECS/mesquite-2.1.2.spec b/ThirdParty/rpmBuild/SPECS/mesquite-2.1.2.spec index 492e3d99e..c2ec9c5cf 100644 --- a/ThirdParty/rpmBuild/SPECS/mesquite-2.1.2.spec +++ b/ThirdParty/rpmBuild/SPECS/mesquite-2.1.2.spec @@ -31,6 +31,9 @@ # Author: # Martin Beaudoin, Hydro-Quebec, (2010) # +# Contributor: +# Philippose Rajan : patch0 for gcc 4.6.x +# #------------------------------------------------------------------------------ # We grab the value of WM_THIRD_PARTY and WM_OPTIONS from the environment variable @@ -77,6 +80,7 @@ URL: http://software.sandia.gov/~jakraft Source: %url/%{name}-%{version}.tar.gz Prefix: %{_prefix} Group: Development/Tools +Patch0: mesquite-2.1.2_patch0 %define _installPrefix %{_prefix}/packages/%{name}-%{version}/platforms/%{_WM_OPTIONS} @@ -86,6 +90,8 @@ Group: Development/Tools %prep %setup -q +%patch0 -p1 + %build # export WM settings in a form that GNU configure recognizes [ -n "$WM_CC" ] && export CC="$WM_CC" @@ -111,7 +117,7 @@ Group: Development/Tools [ -e include/Mesquite_all_headers.hpp ] && rm -f include/Mesquite_all_headers.hpp [ -z "$WM_NCOMPPROCS" ] && WM_NCOMPPROCS=1 - make -j $WM_NCOMPPROCS + make -j $WM_NCOMPPROCS OPTFLAGS="-O3 -mtune=native -fPIC" %install make install DESTDIR=$RPM_BUILD_ROOT From 7dc84e1e6270eec12ea738a22c56bccb94862f16 Mon Sep 17 00:00:00 2001 From: Martin Beaudoin Date: Thu, 10 May 2012 02:12:34 -0400 Subject: [PATCH 05/14] ThirdParty: cmake version 2.8.8 --- ThirdParty/AllMake.stage1 | 2 +- ThirdParty/rpmBuild/SPECS/cmake-2.8.8.spec | 151 +++++++++++++++++++++ etc/settings.csh | 4 +- etc/settings.sh | 4 +- 4 files changed, 156 insertions(+), 5 deletions(-) create mode 100644 ThirdParty/rpmBuild/SPECS/cmake-2.8.8.spec diff --git a/ThirdParty/AllMake.stage1 b/ThirdParty/AllMake.stage1 index e3d81e87f..926f02863 100755 --- a/ThirdParty/AllMake.stage1 +++ b/ThirdParty/AllMake.stage1 @@ -89,7 +89,7 @@ echo #( rpm_make -p flex-2.5.35 -s flex-2.5.35.spec -u http://downloads.sourceforge.net/project/flex/flex/flex-2.5.35/flex-2.5.35.tar.gz ) # cmake -( rpm_make -p cmake-2.8.3 -s cmake-2.8.3.spec -u http://www.cmake.org/files/v2.8/cmake-2.8.3.tar.gz ) +( rpm_make -p cmake-2.8.8 -s cmake-2.8.8.spec -u http://www.cmake.org/files/v2.8/cmake-2.8.8.tar.gz ) echo ======================================== echo Done ThirdParty AllMake: Stage1 diff --git a/ThirdParty/rpmBuild/SPECS/cmake-2.8.8.spec b/ThirdParty/rpmBuild/SPECS/cmake-2.8.8.spec new file mode 100644 index 000000000..9f6883def --- /dev/null +++ b/ThirdParty/rpmBuild/SPECS/cmake-2.8.8.spec @@ -0,0 +1,151 @@ +#------------------------------------------------------------------------------ +# ========= | +# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox +# \\ / O peration | +# \\ / A nd | Copyright held by original author +# \\/ M anipulation | +#------------------------------------------------------------------------------ +# License +# This file is part of OpenFOAM. +# +# OpenFOAM is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by the +# Free Software Foundation; either version 2 of the License, or (at your +# option) any later version. +# +# OpenFOAM is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +# for more details. +# +# You should have received a copy of the GNU General Public License +# along with OpenFOAM; if not, write to the Free Software Foundation, +# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +# +# Script +# RPM spec file for cmake-2.8.8 +# +# Description +# RPM spec file for creating a relocatable RPM +# +# Author: +# Martin Beaudoin, Hydro-Quebec, (2010) +# +#------------------------------------------------------------------------------ + +# We grab the value of WM_THIRD_PARTY and WM_OPTIONS from the environment variable +%{expand:%%define _WM_THIRD_PARTY_DIR %(echo $WM_THIRD_PARTY_DIR)} +%{expand:%%define _WM_OPTIONS %(echo $WM_OPTIONS)} + +# Disable the generation of debuginfo packages +%define debug_package %{nil} + +# The topdir needs to point to the $WM_THIRD_PARTY/rpmbuild directory +%define _topdir %{_WM_THIRD_PARTY_DIR}/rpmBuild +%define _tmppath %{_topdir}/tmp + +# Will install the package directly $WM_THIRD_PARTY_DIR +# Some comments about package relocation: +# By using this prefix for the Prefix: parameter in thi file, you will make this +# package relocatable. +# +# This is fine, as long as your software is itself relocatable. +# +# Simply take note that libraries built with libtool are not relocatable because the +# prefix we specify will be hard-coded in the library .la files. +# Ref: http://sourceware.org/autobook/autobook/autobook_80.html +# +# In that case, if you ever change the value of the $WM_THIRD_PARTY_DIR, you will +# not be able to reutilize this RPM, even though it is relocatable. You will need to +# regenerate the RPM. +# +%define _prefix %{_WM_THIRD_PARTY_DIR} + +%define name cmake +%define release %{_WM_OPTIONS} +%define version 2.8.8 + +%define buildroot %{_topdir}/BUILD/%{name}-%{version}-root + +BuildRoot: %{buildroot} +Summary: cmake +License: Unkown +Name: %{name} +Version: %{version} +Release: %{release} +URL: http://www.cmake.org/files/v2.8/ +Source: %url/%{name}-%{version}.tar.gz +Prefix: %{_prefix} +Group: Development/Tools + + +%define _installPrefix %{_prefix}/packages/%{name}-%{version}/platforms/%{_WM_OPTIONS} + +%description +%{summary} + +%prep +%setup -q + +%build + # export WM settings in a form that GNU configure recognizes + [ -n "$WM_CC" ] && export CC="$WM_CC" + [ -n "$WM_CXX" ] && export CXX="$WM_CXX" + [ -n "$WM_CFLAGS" ] && export CFLAGS="$WM_CFLAGS" + [ -n "$WM_CXXFLAGS" ] && export CXXFLAGS="$WM_CXXFLAGS" + [ -n "$WM_LDFLAGS" ] && export LDFLAGS="$WM_LDFLAGS" + + ./configure \ + --prefix=%{_installPrefix} + + [ -z "$WM_NCOMPPROCS" ] && WM_NCOMPPROCS=1 + make -j $WM_NCOMPPROCS + +%install + make install DESTDIR=$RPM_BUILD_ROOT + + # Creation of OpenFOAM specific .csh and .sh files" + + echo "" + echo "Generating OpenFOAM specific .csh and .sh files for the package %{name}-%{version}" + echo "" + # + # Generate package specific .sh file for OpenFOAM + # +mkdir -p $RPM_BUILD_ROOT/%{_installPrefix}/etc +cat << DOT_SH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.sh +# Load %{name}-%{version} libraries and binaries if available +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +export CMAKE_DIR=\$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS +export CMAKE_BIN_DIR=\$CMAKE_DIR/bin + +# Enable access to the runtime package applications +[ -d \$CMAKE_BIN_DIR ] && _foamAddPath \$CMAKE_BIN_DIR +DOT_SH_EOF + + # + # Generate package specific .csh file for OpenFOAM + # +cat << DOT_CSH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.csh +# Load %{name}-%{version} libraries and binaries if available +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +setenv CMAKE_DIR \$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS +setenv CMAKE_BIN_DIR \$CMAKE_DIR/bin + +if ( -e \$CMAKE_BIN_DIR ) then + _foamAddPath \$CMAKE_BIN_DIR +endif +DOT_CSH_EOF + + #finally, generate a .tgz file for systems where using rpm for installing packages + # as a non-root user might be a problem. + (mkdir -p %{_topdir}/TGZS/%{_target_cpu}; cd $RPM_BUILD_ROOT/%{_prefix}; tar -zcvf %{_topdir}/TGZS/%{_target_cpu}/%{name}-%{version}.tgz packages/%{name}-%{version}) + +%clean +rm -rf %{buildroot} + +%files +%defattr(-,root,root) +%{_installPrefix} + diff --git a/etc/settings.csh b/etc/settings.csh index 827de5b1d..35b076bda 100644 --- a/etc/settings.csh +++ b/etc/settings.csh @@ -425,8 +425,8 @@ endif # cmake # ~~~~~ -if ( $?CMAKE_SYSTEM == 0 && -e "$WM_THIRD_PARTY_DIR"/packages/cmake-2.8.5/platforms/$WM_OPTIONS ) then - _foamSource $WM_THIRD_PARTY_DIR/packages/cmake-2.8.5/platforms/$WM_OPTIONS/etc/cmake-2.8.5.csh +if ( $?CMAKE_SYSTEM == 0 && -e "$WM_THIRD_PARTY_DIR"/packages/cmake-2.8.8/platforms/$WM_OPTIONS ) then + _foamSource $WM_THIRD_PARTY_DIR/packages/cmake-2.8.8/platforms/$WM_OPTIONS/etc/cmake-2.8.8.csh endif # Python diff --git a/etc/settings.sh b/etc/settings.sh index b3f38f241..94e94fc1e 100644 --- a/etc/settings.sh +++ b/etc/settings.sh @@ -480,8 +480,8 @@ export MPI_BUFFER_SIZE # Load cmake # ~~~~~~~~~~ -[ -z "$CMAKE_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/cmake-2.8.5/platforms/$WM_OPTIONS ] && { - _foamSource $WM_THIRD_PARTY_DIR/packages/cmake-2.8.5/platforms/$WM_OPTIONS/etc/cmake-2.8.5.sh +[ -z "$CMAKE_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/cmake-2.8.8/platforms/$WM_OPTIONS ] && { + _foamSource $WM_THIRD_PARTY_DIR/packages/cmake-2.8.8/platforms/$WM_OPTIONS/etc/cmake-2.8.8.sh } [ "$FOAM_VERBOSE" -a "$PS1" ] && echo " CMAKE_DIR is initialized to: $CMAKE_DIR" From 1455422a0ab7346154a12e6cbf46756f3bc05c9e Mon Sep 17 00:00:00 2001 From: Martin Beaudoin Date: Thu, 10 May 2012 11:56:29 -0400 Subject: [PATCH 06/14] ThirdParty: add missing files for ParaView-3.12.0. Move QT to version 4.7.4 --- ThirdParty/AllMake.stage4 | 8 +- .../SOURCES/ParaView-3.12.0.patch_darwin | 12 + .../rpmBuild/SPECS/ParaView-3.12.0.spec | 279 ++++++++++++++++++ .../qt-everywhere-opensource-src-4.7.4.spec | 164 ++++++++++ etc/settings.csh | 4 +- etc/settings.sh | 4 +- 6 files changed, 463 insertions(+), 8 deletions(-) create mode 100644 ThirdParty/rpmBuild/SOURCES/ParaView-3.12.0.patch_darwin create mode 100644 ThirdParty/rpmBuild/SPECS/ParaView-3.12.0.spec create mode 100644 ThirdParty/rpmBuild/SPECS/qt-everywhere-opensource-src-4.7.4.spec diff --git a/ThirdParty/AllMake.stage4 b/ThirdParty/AllMake.stage4 index 1a8c94f25..9628154ec 100755 --- a/ThirdParty/AllMake.stage4 +++ b/ThirdParty/AllMake.stage4 @@ -56,10 +56,10 @@ echo Starting ThirdParty AllMake: Stage4 echo ======================================== echo -# qt-everywhere-opensource-src-4.7.0 +# qt-everywhere-opensource-src-4.7.4 if [ ! -z "$QT_THIRD_PARTY" ] then - ( rpm_make -p qt-everywhere-opensource-src-4.7.0 -s qt-everywhere-opensource-src-4.7.0.spec -u http://get.qt.nokia.com/qt/source/qt-everywhere-opensource-src-4.7.0.tar.gz ) + ( rpm_make -p qt-everywhere-opensource-src-4.7.4 -s qt-everywhere-opensource-src-4.7.4.spec -u http://get.qt.nokia.com/qt/source/qt-everywhere-opensource-src-4.7.4.tar.gz ) else echo "Using system installed QT" echo "" @@ -73,12 +73,12 @@ then if [ -d "$QT_BIN_DIR" -a -r "$QT_BIN_DIR"/qmake ] then - ( rpm_make -p ParaView-3.10.1 -s ParaView-3.10.1.spec -u http://www.paraview.org/files/v3.10/ParaView-3.10.1.tar.gz \ + ( rpm_make -p ParaView-3.12.0 -s ParaView-3.12.0.spec -u http://www.paraview.org/files/v3.12/ParaView-3.12.0.tar.gz \ -a --define='_qmakePath $QT_BIN_DIR/qmake' ) else echo "WARNING: " - echo "WARNING: Skipping the installation of ParaView-3.10.1." + echo "WARNING: Skipping the installation of ParaView-3.12.0." echo "WARNING: Please make sure the QT_BIN_DIR environment variable properly" echo "WARNING: initialized in the file prefs.sh or prefs.csh" echo "WARNING: The command \$QT_BIN_DIR/qmake needs to be valid" diff --git a/ThirdParty/rpmBuild/SOURCES/ParaView-3.12.0.patch_darwin b/ThirdParty/rpmBuild/SOURCES/ParaView-3.12.0.patch_darwin new file mode 100644 index 000000000..cc6942b69 --- /dev/null +++ b/ThirdParty/rpmBuild/SOURCES/ParaView-3.12.0.patch_darwin @@ -0,0 +1,12 @@ +diff -ruN ParaView-3.12.0_orig/Applications/ParaView-3.12.0_extra_install_Darwin.cmake ParaView-3.12.0/Applications/ParaView-3.12.0_extra_install_Darwin.cmake +--- ParaView-3.12.0_orig/Applications/ParaView-3.12.0_extra_install_Darwin.cmake 1969-12-31 19:00:00.000000000 -0500 ++++ ParaView-3.12.0/Applications/ParaView-3.12.0_extra_install_Darwin.cmake 2010-11-06 19:34:12.000000000 -0400 +@@ -0,0 +1,8 @@ ++# ++# Additional install rules for Mac OS X platforms ++# ++INSTALL (DIRECTORY ../../buildObj/bin/paraview.app ++ DESTINATION ${PV_INSTALL_BIN_DIR} ++ USE_SOURCE_PERMISSIONS ++ COMPONENT Runtime) ++ diff --git a/ThirdParty/rpmBuild/SPECS/ParaView-3.12.0.spec b/ThirdParty/rpmBuild/SPECS/ParaView-3.12.0.spec new file mode 100644 index 000000000..c2b6ee2db --- /dev/null +++ b/ThirdParty/rpmBuild/SPECS/ParaView-3.12.0.spec @@ -0,0 +1,279 @@ +#------------------------------------------------------------------------------ +# ========= | +# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox +# \\ / O peration | +# \\ / A nd | Copyright held by original author +# \\/ M anipulation | +#------------------------------------------------------------------------------ +# License +# This file is part of OpenFOAM. +# +# OpenFOAM is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by the +# Free Software Foundation; either version 2 of the License, or (at your +# option) any later version. +# +# OpenFOAM is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +# for more details. +# +# You should have received a copy of the GNU General Public License +# along with OpenFOAM; if not, write to the Free Software Foundation, +# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +# +# Script +# RPM spec file for ParaView-3.12.0 +# +# Description +# RPM spec file for creating a relocatable RPM +# +# Author: +# Martin Beaudoin, Hydro-Quebec, (2012) +# +#------------------------------------------------------------------------------ + +# We grab the value of WM_THIRD_PARTY and WM_OPTIONS from the environment variable +%{expand:%%define _WM_THIRD_PARTY_DIR %(echo $WM_THIRD_PARTY_DIR)} +%{expand:%%define _WM_OPTIONS %(echo $WM_OPTIONS)} + +# Disable the generation of debuginfo packages +%define debug_package %{nil} + +# The topdir needs to point to the $WM_THIRD_PARTY/rpmbuild directory +%define _topdir %{_WM_THIRD_PARTY_DIR}/rpmBuild +%define _tmppath %{_topdir}/tmp + +# Will install the package directly $WM_THIRD_PARTY_DIR +# Some comments about package relocation: +# By using this prefix for the Prefix: parameter in thi file, you will make this +# package relocatable. +# +# This is fine, as long as your software is itself relocatable. +# +# Simply take note that libraries built with libtool are not relocatable because the +# prefix we specify will be hard-coded in the library .la files. +# Ref: http://sourceware.org/autobook/autobook/autobook_80.html +# +# In that case, if you ever change the value of the $WM_THIRD_PARTY_DIR, you will +# not be able to reutilize this RPM, even though it is relocatable. You will need to +# regenerate the RPM. +# +%define _prefix %{_WM_THIRD_PARTY_DIR} + +%define name ParaView +%define release %{_WM_OPTIONS} +%define version 3.12.0 + +%define buildroot %{_topdir}/BUILD/%{name}-%{version}-root + +BuildRoot: %{buildroot} +Summary: ParaView +License: Unkown +Name: %{name} +Version: %{version} +Release: %{release} +URL: http://www.paraview.org/files/v3.12/ +Source: %url/%{name}-%{version}.tar.gz +Prefix: %{_prefix} +Group: Development/Tools +Patch0: ParaView-3.12.0.patch_darwin + +%define _installPrefix %{_prefix}/packages/%{name}-%{version}/platforms/%{_WM_OPTIONS} + +#-------------------------------------------------------------------------- +# +# Here, we define default compiling options for cmake +# +# One can override the option on the commande line : --define='MACRO EXPR' +# +%{!?_withVerbose: %define _withVerbose false} +%{!?_withMesa: %define _withMesa false} +%{!?_withMPI: %define _withMPI true} +%{!?_withPython: %define _withPython true} +%{!?_withQt: %define _withQt true} +%{!?_qmakePath: %define _qmakePath Undefined} +%{!?_mesaIncludePath: %define _mesaIncludePath Undefined} +%{!?_mesaLibPath: %define _mesaLibPath Undefined} +%{!?_pythonLibPath: %define _pythonLibPath Undefined} + +#-------------------------------------------------------------------------- + +%description +%{summary} + +%prep +%setup -q + +%ifos darwin +%patch0 -p1 +%endif + +%build +# +# set CMake cache variables +# + addCMakeVariable() + { + while [ -n "$1" ] + do + CMAKE_VARIABLES="$CMAKE_VARIABLES -D$1" + shift + done + } + + # export WM settings in a form that GNU configure recognizes + [ -n "$WM_CC" ] && export CC="$WM_CC" + [ -n "$WM_CXX" ] && export CXX="$WM_CXX" + [ -n "$WM_CFLAGS" ] && export CFLAGS="$WM_CFLAGS" + [ -n "$WM_CXXFLAGS" ] && export CXXFLAGS="$WM_CXXFLAGS" + [ -n "$WM_LDFLAGS" ] && export LDFLAGS="$WM_LDFLAGS" + + set +x + echo "" + echo "Compilation options:" + echo " _withVerbose : %{_withVerbose}" + echo " _withMesa : %{_withMesa}" + echo " _withMPI : %{_withMPI}" + echo " _withPython : %{_withPython}" + echo " _withQt : %{_withQt}" + echo " _qmakePath : %{_qmakePath}" + echo " _mesaIncludePath : %{_mesaIncludePath}" + echo " _mesaLibPath : %{_mesaLibPath}" + echo " _pythonLibPath : %{_pythonLibPath}" + echo "" + set -x + + # start with these general settings + addCMakeVariable VTK_USE_TK:BOOL=OFF + addCMakeVariable BUILD_SHARED_LIBS:BOOL=ON VTK_USE_RPATH:BOOL=OFF + addCMakeVariable CMAKE_BUILD_TYPE:STRING=Release + + # include development files in "make install" + addCMakeVariable PARAVIEW_INSTALL_DEVELOPMENT:BOOL=ON + + # new alternative to "make HTMLDocumentation" + addCMakeVariable PARAVIEW_GENERATE_PROXY_DOCUMENTATION:BOOL=ON + + %ifos darwin + # Additional installation rules for Mac OS X + addCMakeVariable PARAVIEW_EXTRA_INSTALL_RULES_FILE:FILEPATH=%{_topdir}/BUILD/%{name}-%{version}/Applications/ParaView-3.12.0_extra_install_Darwin.cmake +%endif + + # Add the value of _qmakePath for QT_QMAKE_EXECUTABLE + addCMakeVariable QT_QMAKE_EXECUTABLE:FILEPATH=%{_qmakePath} + + echo "CMAKE_VARIABLES: $CMAKE_VARIABLES" + + mkdir -p ./buildObj + cd ./buildObj + + cmake \ + -DCMAKE_INSTALL_PREFIX:PATH=%{_installPrefix} \ + $CMAKE_VARIABLES \ + .. + + [ -z "$WM_NCOMPPROCS" ] && WM_NCOMPPROCS=1 + make -j $WM_NCOMPPROCS + +%install + # On OpenSUSE, rpmbuild, will choke when detecting unreferenced symlinks + # created during installation. + # Qt version 4.6.3 will generate some unreferenced symlinks when + # ParaView is compiled and installed. By enabling the following + # environment variable, the command brp-symlink will still complain + # about missing link targets, but it won't stop rpmbuild from generating + # the final rpm. + # For all other Unix distros, this is a no-op. + export NO_BRP_STALE_LINK_ERROR=yes + + cd buildObj + make install DESTDIR=$RPM_BUILD_ROOT + + # Creation of OpenFOAM specific .csh and .sh files" + + echo "" + echo "Generating OpenFOAM specific .csh and .sh files for the package %{name}-%{version}" + echo "" + # + # Generate package specific .sh file for OpenFOAM + # +mkdir -p $RPM_BUILD_ROOT/%{_installPrefix}/etc +cat << DOT_SH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.sh +# Load %{name}-%{version} libraries and binaries if available +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +export PARAVIEW_DIR=\$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS +export PARAVIEW_BIN_DIR=\$PARAVIEW_DIR/bin +export PARAVIEW_LIB_DIR=\$PARAVIEW_DIR/lib +export PARAVIEW_INCLUDE_DIR=\$PARAVIEW_DIR/include + +export PARAVIEW_VERSION=%{version} + +# NB: It is important to set the PV_PLUGIN_PATH location to a directory containing only the ParaView plugins. +# Otherwise, paraview will try to automatically autoload each and every dynamic library it can find in the +# specified directory to see if a given library is a paraview plugin. +# In the case of \$FOAM_LIBBIN, with over 80 libraries, this is a total waste of time that will slow down the +# startup of paraview or even make paraview crash on startup. +export PV_PLUGIN_PATH=\$FOAM_LIBBIN/paraview_plugins + +[ -d \$PARAVIEW_LIB_DIR/paraview-3.12 ] && _foamAddLib \$PARAVIEW_LIB_DIR/paraview-3.12 + +# Enable access to the package applications if present +[ -d \$PARAVIEW_BIN_DIR ] && _foamAddPath \$PARAVIEW_BIN_DIR + +# Additional binary path if running on Mac OS X +[ -d \$PARAVIEW_BIN_DIR/paraview.app/Contents/MacOS ] && _foamAddPath \$PARAVIEW_BIN_DIR/paraview.app/Contents/MacOS + +DOT_SH_EOF + + # + # Generate package specific .csh file for OpenFOAM + # +cat << DOT_CSH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.csh +# Load %{name}-%{version} libraries and binaries if available +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +setenv PARAVIEW_DIR \$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS +setenv PARAVIEW_BIN_DIR \$PARAVIEW_DIR/bin +setenv PARAVIEW_LIB_DIR \$PARAVIEW_DIR/lib +setenv PARAVIEW_INCLUDE_DIR \$PARAVIEW_DIR/include + +setenv PARAVIEW_VERSION %{version} + +# NB: It is important to set the PV_PLUGIN_PATH location to a directory containing only the ParaView plugins. +# Otherwise, paraview will try to automatically autoload each and every dynamic library it can find in the +# specified directory to see if a given library is a paraview plugin. +# In the case of \$FOAM_LIBBIN, with over 80 libraries, this is a total waste of time that will slow down the +# startup of paraview or even make paraview crash on startup. +setenv PV_PLUGIN_PATH \$FOAM_LIBBIN/paraview_plugins + +if ( -e \$PARAVIEW_BIN_DIR ) then + _foamAddPath \$PARAVIEW_BIN_DIR +endif + +if ( -e \$PARAVIEW_LIB_DIR/paraview-3.12 ) then + _foamAddLib \$PARAVIEW_LIB_DIR/paraview-3.12 +endif + + +# Additional binary path if running on Mac OS X +if ( -e \$PARAVIEW_BIN_DIR/paraview.app/Contents/MacOS ) then + _foamAddPath \$PARAVIEW_BIN_DIR/paraview.app/Contents/MacOS +endif +DOT_CSH_EOF + + #finally, generate a .tgz file for systems where using rpm for installing packages + # as a non-root user might be a problem. + (mkdir -p %{_topdir}/TGZS/%{_target_cpu}; cd $RPM_BUILD_ROOT/%{_prefix}; tar -zcvf %{_topdir}/TGZS/%{_target_cpu}/%{name}-%{version}.tgz packages/%{name}-%{version}) + + # Make sure we clean the installation directory. Somehow, make install generates files there. Need to revisit this eventually. + (rm -rf %{_prefix}/packages/%{name}-%{version} ) + +%clean +rm -rf $RPM_BUILD_ROOT +rm -rf %{_prefix}/packages/%{name}-%{version} + +%files +%defattr(-,root,root) +%{_installPrefix} + diff --git a/ThirdParty/rpmBuild/SPECS/qt-everywhere-opensource-src-4.7.4.spec b/ThirdParty/rpmBuild/SPECS/qt-everywhere-opensource-src-4.7.4.spec new file mode 100644 index 000000000..8b1277278 --- /dev/null +++ b/ThirdParty/rpmBuild/SPECS/qt-everywhere-opensource-src-4.7.4.spec @@ -0,0 +1,164 @@ +#------------------------------------------------------------------------------ +# ========= | +# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox +# \\ / O peration | +# \\ / A nd | Copyright held by original author +# \\/ M anipulation | +#------------------------------------------------------------------------------ +# License +# This file is part of OpenFOAM. +# +# OpenFOAM is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by the +# Free Software Foundation; either version 2 of the License, or (at your +# option) any later version. +# +# OpenFOAM is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +# for more details. +# +# You should have received a copy of the GNU General Public License +# along with OpenFOAM; if not, write to the Free Software Foundation, +# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +# +# Script +# RPM spec file for qt-everywhere-opensource-src-4.7.4 +# +# Description +# RPM spec file for creating a relocatable RPM +# +# Author: +# Martin Beaudoin, Hydro-Quebec, (2012) +# +#------------------------------------------------------------------------------ + +# We grab the value of WM_THIRD_PARTY and WM_OPTIONS from the environment variable +%{expand:%%define _WM_THIRD_PARTY_DIR %(echo $WM_THIRD_PARTY_DIR)} +%{expand:%%define _WM_OPTIONS %(echo $WM_OPTIONS)} + +# Disable the generation of debuginfo packages +%define debug_package %{nil} + +# The topdir needs to point to the $WM_THIRD_PARTY/rpmbuild directory +%define _topdir %{_WM_THIRD_PARTY_DIR}/rpmBuild +%define _tmppath %{_topdir}/tmp + +# Will install the package directly $WM_THIRD_PARTY_DIR +# Some comments about package relocation: +# By using this prefix for the Prefix: parameter in thi file, you will make this +# package relocatable. +# +# This is fine, as long as your software is itself relocatable. +# +# Simply take note that libraries built with libtool are not relocatable because the +# prefix we specify will be hard-coded in the library .la files. +# Ref: http://sourceware.org/autobook/autobook/autobook_80.html +# +# In that case, if you ever change the value of the $WM_THIRD_PARTY_DIR, you will +# not be able to reutilize this RPM, even though it is relocatable. You will need to +# regenerate the RPM. +# +%define _prefix %{_WM_THIRD_PARTY_DIR} + +%define name qt-everywhere-opensource-src +%define release %{_WM_OPTIONS} +%define version 4.7.4 + +%define buildroot %{_topdir}/BUILD/%{name}-%{version}-root + +%define _unpackaged_files_terminate_build 0 +%define _missing_doc_files_terminate_build 0 + +BuildRoot: %{buildroot} +Summary: qt-everywhere-opensource-src +License: Unkown +Name: %{name} +Version: %{version} +Release: %{release} +URL: http://get.qt.nokia.com/qt/source/qt-everywhere-opensource-src +Source: %url/%{name}-%{version}.tar.gz +Prefix: %{_prefix} +Group: Development/Tools + + +%define _installPrefix %{_prefix}/packages/%{name}-%{version}/platforms/%{_WM_OPTIONS} + +%description +%{summary} + +%prep +%setup -q + +%build + # export WM settings in a form that GNU configure recognizes + [ -n "$WM_CC" ] && export CC="$WM_CC" + [ -n "$WM_CXX" ] && export CXX="$WM_CXX" + [ -n "$WM_CFLAGS" ] && export CFLAGS="$WM_CFLAGS" + [ -n "$WM_CXXFLAGS" ] && export CXXFLAGS="$WM_CXXFLAGS" + [ -n "$WM_LDFLAGS" ] && export LDFLAGS="$WM_LDFLAGS" + + ./configure \ + -opensource --confirm-license=yes \ + -release -shared \ + -nomake examples -nomake demos \ + --prefix=%{_installPrefix} + + # Explicitely specify LD_LIBRARY_PATH so it can find QT own libraries + export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:%{_builddir}/%{name}-%{version}/lib + + [ -z "$WM_NCOMPPROCS" ] && WM_NCOMPPROCS=1 + make -j $WM_NCOMPPROCS + +%install + # Makefiles generated by qmake do not to support the DESTDIR= option + # We need to use the INSTALL_ROOT= option instead + make install INSTALL_ROOT=$RPM_BUILD_ROOT + + # Creation of OpenFOAM specific .csh and .sh files" + + echo "" + echo "Generating OpenFOAM specific .csh and .sh files for the package %{name}-%{version}" + echo "" + # + # Generate package specific .sh file for OpenFOAM + # +mkdir -p $RPM_BUILD_ROOT/%{_installPrefix}/etc +cat << DOT_SH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.sh +# Load %{name}-%{version} libraries and binaries if available +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +export QT_DIR=\$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS +export QT_BIN_DIR=\$QT_DIR/bin + +# Enable access to the runtime package applications +[ -d \$QT_BIN_DIR ] && _foamAddPath \$QT_BIN_DIR +DOT_SH_EOF + + # + # Generate package specific .csh file for OpenFOAM + # +cat << DOT_CSH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.csh +# Load %{name}-%{version} libraries and binaries if available +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +setenv QT_DIR \$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS +setenv QT_BIN_DIR \$QT_DIR/bin + +if ( -e \$QT_BIN_DIR ) then + _foamAddPath \$QT_BIN_DIR +endif +DOT_CSH_EOF + + #finally, generate a .tgz file for systems where using rpm for installing packages + # as a non-root user might be a problem. + (mkdir -p %{_topdir}/TGZS/%{_target_cpu}; cd $RPM_BUILD_ROOT/%{_prefix}; tar -zcvf %{_topdir}/TGZS/%{_target_cpu}/%{name}-%{version}.tgz packages/%{name}-%{version}) + + +%clean +rm -rf %{buildroot} + +%files +%defattr(-,root,root) +%{_installPrefix} + + diff --git a/etc/settings.csh b/etc/settings.csh index 35b076bda..ba8c76589 100644 --- a/etc/settings.csh +++ b/etc/settings.csh @@ -437,8 +437,8 @@ endif # QT # ~~~~~ -if ( $?QT_SYSTEM == 0 && -e "$WM_THIRD_PARTY_DIR"/packages/qt-everywhere-opensource-src-4.7.0/platforms/$WM_OPTIONS )then - _foamSource $WM_THIRD_PARTY_DIR/packages/qt-everywhere-opensource-src-4.7.0/platforms/$WM_OPTIONS/etc/qt-everywhere-opensource-src-4.7.0.csh +if ( $?QT_SYSTEM == 0 && -e "$WM_THIRD_PARTY_DIR"/packages/qt-everywhere-opensource-src-4.7.4/platforms/$WM_OPTIONS )then + _foamSource $WM_THIRD_PARTY_DIR/packages/qt-everywhere-opensource-src-4.7.4/platforms/$WM_OPTIONS/etc/qt-everywhere-opensource-src-4.7.4.csh endif # PARAVIEW diff --git a/etc/settings.sh b/etc/settings.sh index 94e94fc1e..fc5f579fb 100644 --- a/etc/settings.sh +++ b/etc/settings.sh @@ -525,8 +525,8 @@ export MPI_BUFFER_SIZE # Load QT # ~~~~~~~ -[ ! -z "$QT_THIRD_PARTY" ] && [ -e $WM_THIRD_PARTY_DIR/packages/qt-everywhere-opensource-src-4.7.0/platforms/$WM_OPTIONS ] && { - _foamSource $WM_THIRD_PARTY_DIR/packages/qt-everywhere-opensource-src-4.7.0/platforms/$WM_OPTIONS/etc/qt-everywhere-opensource-src-4.7.0.sh +[ ! -z "$QT_THIRD_PARTY" ] && [ -e $WM_THIRD_PARTY_DIR/packages/qt-everywhere-opensource-src-4.7.4/platforms/$WM_OPTIONS ] && { + _foamSource $WM_THIRD_PARTY_DIR/packages/qt-everywhere-opensource-src-4.7.4/platforms/$WM_OPTIONS/etc/qt-everywhere-opensource-src-4.7.4.sh } [ "$FOAM_VERBOSE" -a "$PS1" ] && echo " QT_DIR is initialized to: $QT_DIR" From 068bc78dbb66bc551ab001d5b07ffe351957d54a Mon Sep 17 00:00:00 2001 From: Martin Beaudoin Date: Fri, 11 May 2012 08:47:43 -0700 Subject: [PATCH 07/14] Fixing testHarness --- CMakeLists.txt | 8 ++++---- CTestConfig.cmake | 4 ++-- etc/prefs.csh-EXAMPLE | 9 +++++++++ etc/prefs.sh-EXAMPLE | 9 +++++++++ testHarness/OSIG/Turbomachinery/README.txt | 1 + .../1.6-ext/CMakeFiles/CMakeLists.txt | 16 ++++++++++++---- .../CTestConfig.cmake.openfoam-extend | 4 ++-- ...g.cmake.openfoam-extend_of-1.6-ext-testing | 13 ------------- testHarness/OpenFOAM/1.6-ext/README.txt | 4 ++-- testHarness/README.txt | 19 ++++--------------- 10 files changed, 45 insertions(+), 42 deletions(-) delete mode 100644 testHarness/OpenFOAM/1.6-ext/CMakeFiles/CTestConfig.cmake.openfoam-extend_of-1.6-ext-testing diff --git a/CMakeLists.txt b/CMakeLists.txt index 647779e53..aac37fb6d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -24,7 +24,7 @@ # # Description # CMakeLists.txt file for implementing a test harness for the compilation -# and test of OpenFOAM-1.5-dev using Kitware CTest./CMake/CDash +# and test of OpenFOAM-1.6-ext using Kitware CTest./CMake/CDash # # The results will be submitted to the CDash server identified by the file # CTestConfig.cmake @@ -37,7 +37,7 @@ cmake_minimum_required (VERSION 2.8) -PROJECT(OpenFOAM_1.5-dev) +PROJECT(OpenFOAM_1.6-ext) #----------------------------------------------------------------------------- # Initialization of CTest specific variables @@ -92,7 +92,7 @@ SET(BUILDNAME "${BUILDNAME}-$ENV{WM_CC}${COMPILER_VERSION}") # We will support more compilers eventually. # -# Timeout for running all this: 4 hours: 4 x 3600 seconds +# Timeout for running every single test: 4 hours: 4 x 3600 seconds #SET( # DART_TESTING_TIMEOUT 14400 # CACHE STRING "Maximum time allowed (4 hours) before CTest will kill the test." @@ -133,7 +133,7 @@ if(GIT_FOUND) ) message("Git branch (mercurial): ${GIT_BRANCH_NAME}") endif() - SET(BUILDNAME "${BUILDNAME}-git-branch:${GIT_BRANCH_NAME}") + SET(BUILDNAME "${BUILDNAME}-git-branch=${GIT_BRANCH_NAME}") endif() # Some last minute cleanup diff --git a/CTestConfig.cmake b/CTestConfig.cmake index 743c356bb..2808a760d 100644 --- a/CTestConfig.cmake +++ b/CTestConfig.cmake @@ -4,10 +4,10 @@ ## # The following are required to uses Dart and the Cdash dashboard ## ENABLE_TESTING() ## INCLUDE(CTest) -set(CTEST_PROJECT_NAME "OpenFOAM-1.6-ext_testing") +set(CTEST_PROJECT_NAME "OpenFOAM-1.6-ext") set(CTEST_NIGHTLY_START_TIME "00:00:00 EST") set(CTEST_DROP_METHOD "http") set(CTEST_DROP_SITE "openfoam-extend.sourceforge.net") -set(CTEST_DROP_LOCATION "/CDash/submit.php?project=OpenFOAM-1.6-ext_testing") +set(CTEST_DROP_LOCATION "/CDash/submit.php?project=OpenFOAM-1.6-ext") set(CTEST_DROP_SITE_CDASH TRUE) diff --git a/etc/prefs.csh-EXAMPLE b/etc/prefs.csh-EXAMPLE index 97a4a4374..9599a5195 100644 --- a/etc/prefs.csh-EXAMPLE +++ b/etc/prefs.csh-EXAMPLE @@ -146,4 +146,13 @@ #setenv ParaView_VERSION git # eg, cvs/git version #setenv ParaView_MAJOR 3.7 + +# System identifier for the OpenFOAM CDash test harness on openfoam-extend +# +# By default, your system FQN/hostname will be used as the system identifier +# when publishing your test harness results on the OpenFOAM CDash server +# on openfoam-extend. +# You can override your identifier using this environment variable +#setenv CDASH_SUBMIT_LOCAL_HOST_ID choose_your_CDash_system_identifer + # ----------------------------------------------------------------- end-of-file diff --git a/etc/prefs.sh-EXAMPLE b/etc/prefs.sh-EXAMPLE index 18c931580..990207083 100644 --- a/etc/prefs.sh-EXAMPLE +++ b/etc/prefs.sh-EXAMPLE @@ -156,4 +156,13 @@ compilerInstall=System #export ParaView_VERSION=git # eg, cvs/git version #export ParaView_MAJOR=3.7 + +# System identifier for the OpenFOAM CDash test harness on openfoam-extend +# +# By default, your system FQN/hostname will be used as the system identifier +# when publishing your test harness results on the OpenFOAM CDash server +# on openfoam-extend. +# You can override your identifier using this environment variable +#export CDASH_SUBMIT_LOCAL_HOST_ID=choose_your_CDash_system_identifer + # ----------------------------------------------------------------- end-of-file diff --git a/testHarness/OSIG/Turbomachinery/README.txt b/testHarness/OSIG/Turbomachinery/README.txt index 82353e77b..e8e113882 100644 --- a/testHarness/OSIG/Turbomachinery/README.txt +++ b/testHarness/OSIG/Turbomachinery/README.txt @@ -31,6 +31,7 @@ # \*---------------------------------------------------------------------------*/ + Warning #1: Make sure your OpenFOAM environment is properly initialized before running the test harness. diff --git a/testHarness/OpenFOAM/1.6-ext/CMakeFiles/CMakeLists.txt b/testHarness/OpenFOAM/1.6-ext/CMakeFiles/CMakeLists.txt index bd8595535..aac37fb6d 100644 --- a/testHarness/OpenFOAM/1.6-ext/CMakeFiles/CMakeLists.txt +++ b/testHarness/OpenFOAM/1.6-ext/CMakeFiles/CMakeLists.txt @@ -24,7 +24,7 @@ # # Description # CMakeLists.txt file for implementing a test harness for the compilation -# and test of OpenFOAM-1.5-dev using Kitware CTest./CMake/CDash +# and test of OpenFOAM-1.6-ext using Kitware CTest./CMake/CDash # # The results will be submitted to the CDash server identified by the file # CTestConfig.cmake @@ -37,7 +37,7 @@ cmake_minimum_required (VERSION 2.8) -PROJECT(OpenFOAM_1.5-dev) +PROJECT(OpenFOAM_1.6-ext) #----------------------------------------------------------------------------- # Initialization of CTest specific variables @@ -92,7 +92,7 @@ SET(BUILDNAME "${BUILDNAME}-$ENV{WM_CC}${COMPILER_VERSION}") # We will support more compilers eventually. # -# Timeout for running all this: 4 hours: 4 x 3600 seconds +# Timeout for running every single test: 4 hours: 4 x 3600 seconds #SET( # DART_TESTING_TIMEOUT 14400 # CACHE STRING "Maximum time allowed (4 hours) before CTest will kill the test." @@ -125,7 +125,15 @@ if(GIT_FOUND) OUTPUT_VARIABLE GIT_BRANCH_NAME ) message("Git branch: ${GIT_BRANCH_NAME}") - SET(BUILDNAME "${BUILDNAME}-git-branch:${GIT_BRANCH_NAME}") + if (GIT_BRANCH_NAME STREQUAL "") + message("No git-branch. Mercurial?") + EXEC_PROGRAM(hg + ARGS branch + OUTPUT_VARIABLE GIT_BRANCH_NAME + ) + message("Git branch (mercurial): ${GIT_BRANCH_NAME}") + endif() + SET(BUILDNAME "${BUILDNAME}-git-branch=${GIT_BRANCH_NAME}") endif() # Some last minute cleanup diff --git a/testHarness/OpenFOAM/1.6-ext/CMakeFiles/CTestConfig.cmake.openfoam-extend b/testHarness/OpenFOAM/1.6-ext/CMakeFiles/CTestConfig.cmake.openfoam-extend index 12f45f381..2808a760d 100644 --- a/testHarness/OpenFOAM/1.6-ext/CMakeFiles/CTestConfig.cmake.openfoam-extend +++ b/testHarness/OpenFOAM/1.6-ext/CMakeFiles/CTestConfig.cmake.openfoam-extend @@ -4,10 +4,10 @@ ## # The following are required to uses Dart and the Cdash dashboard ## ENABLE_TESTING() ## INCLUDE(CTest) -set(CTEST_PROJECT_NAME "OpenFOAM-1.5-dev") +set(CTEST_PROJECT_NAME "OpenFOAM-1.6-ext") set(CTEST_NIGHTLY_START_TIME "00:00:00 EST") set(CTEST_DROP_METHOD "http") set(CTEST_DROP_SITE "openfoam-extend.sourceforge.net") -set(CTEST_DROP_LOCATION "/CDash/submit.php?project=OpenFOAM-1.5-dev") +set(CTEST_DROP_LOCATION "/CDash/submit.php?project=OpenFOAM-1.6-ext") set(CTEST_DROP_SITE_CDASH TRUE) diff --git a/testHarness/OpenFOAM/1.6-ext/CMakeFiles/CTestConfig.cmake.openfoam-extend_of-1.6-ext-testing b/testHarness/OpenFOAM/1.6-ext/CMakeFiles/CTestConfig.cmake.openfoam-extend_of-1.6-ext-testing deleted file mode 100644 index 743c356bb..000000000 --- a/testHarness/OpenFOAM/1.6-ext/CMakeFiles/CTestConfig.cmake.openfoam-extend_of-1.6-ext-testing +++ /dev/null @@ -1,13 +0,0 @@ -## This file should be placed in the root directory of your project. -## Then modify the CMakeLists.txt file in the root directory of your -## project to incorporate the testing dashboard. -## # The following are required to uses Dart and the Cdash dashboard -## ENABLE_TESTING() -## INCLUDE(CTest) -set(CTEST_PROJECT_NAME "OpenFOAM-1.6-ext_testing") -set(CTEST_NIGHTLY_START_TIME "00:00:00 EST") - -set(CTEST_DROP_METHOD "http") -set(CTEST_DROP_SITE "openfoam-extend.sourceforge.net") -set(CTEST_DROP_LOCATION "/CDash/submit.php?project=OpenFOAM-1.6-ext_testing") -set(CTEST_DROP_SITE_CDASH TRUE) diff --git a/testHarness/OpenFOAM/1.6-ext/README.txt b/testHarness/OpenFOAM/1.6-ext/README.txt index fef16a438..5fc5f9bf5 100644 --- a/testHarness/OpenFOAM/1.6-ext/README.txt +++ b/testHarness/OpenFOAM/1.6-ext/README.txt @@ -48,7 +48,7 @@ a) You can set your local system identifier using the environment variable b) Install the CMakeLists.txt and CTestConfig.cmake files by executing the following commands: cp ./CMakeFiles/CMakeLists.txt $WM_PROJECT_DIR -cp ./CMakeFiles/CTestConfig.cmake.openfoam-extend_of-1.6-ext-testing $WM_PROJECT_DIR/CTestConfig.cmake +cp ./CMakeFiles/CTestConfig.cmake.openfoam-extend $WM_PROJECT_DIR/CTestConfig.cmake c) Run the test harness and push your results on the CDash server on openfoam-extend @@ -74,5 +74,5 @@ To submit your results to the CDash server on openfoam-extend, just use the file CTestConfig.cmake.openfoam-extend. If submitted to the CDash server on openfoam-extend, your results will be displayed here: -http://openfoam-extend.sourceforge.net/CDash/index.php?project=OpenFOAM-1.6-ext_testing +http://openfoam-extend.sourceforge.net/CDash/index.php?project=OpenFOAM-1.6-ext diff --git a/testHarness/README.txt b/testHarness/README.txt index d33bbe545..ba7b67f22 100644 --- a/testHarness/README.txt +++ b/testHarness/README.txt @@ -7,7 +7,7 @@ Directory Structure =================== OpenFOAM : CMake/CTest scripts for compilation and execution test harness for OpenFOAM. -OpenFOAM/1.6-dev : Test harness for OpenFOAM version 1.6-dev. See the file OpenFOAM/1.6-dev/README.txt for more information +OpenFOAM/1.6-ext : Test harness for OpenFOAM version 1.6-ext. See the file OpenFOAM/1.6-ext/README.txt for more information OSIG : CMake/CTest scripts for OpenFOAM Special Interest Group (OSIG) test harness OSIG/TurboMachinery : Test harness for the TurboMachinery OSIG. See the file OSIG/Turbomachinery/README.txt for more information. @@ -42,7 +42,7 @@ Martin Beaudoin, Hydro-Quebec, 2010. All rights reserved. Still, I recommand always checking that these two important files are up-to-date: cp ../CMakeFiles/CMakeLists.txt $WM_PROJECT_DIR - cp ../CMakeFiles/CTestConfig.cmake.openfoam-extend_of-1.6-ext-testing $WM_PROJECT_DIR/CTestConfig.cmake + cp ../CMakeFiles/CTestConfig.cmake.openfoam-extend $WM_PROJECT_DIR/CTestConfig.cmake 7: Next, running the test loop is pretty simple: @@ -55,9 +55,7 @@ Martin Beaudoin, Hydro-Quebec, 2010. All rights reserved. 8: The results will be published on the CDash dashboard on openfoam-extend. To see your results: - URL : http://openfoam-extend.sourceforge.net/CDash/index.php?project=OpenFOAM-1.6-ext_testing - Username : of-1.6-ext@of-extend.cdash - Password : onepasswd4all + URL : http://openfoam-extend.sourceforge.net/CDash/index.php?project=OpenFOAM-1.6-ext 9: You can customize your system identifier on the dashboard using the environment variable $CDASH_SUBMIT_LOCAL_HOST_ID. @@ -71,15 +69,6 @@ Martin Beaudoin, Hydro-Quebec, 2010. All rights reserved. 10: In general, see the file $WM_PROJECT_DIR/testHarness/OpenFOAM/1.6-ext/README.txt for the necessary information about running the test loop. - (NB: I just found out a couple of mistakes in that file, so please use this message for now as per instructions for running the test loop. - I will fix this shortly. Sorry.) -11: As more people will start using these basic steps, I will supply more information about some other features that are available with - the test loop. - - But I need to see those baby steps first... :) - - -12: Please do not hesitate to report any problems, comments, suggestions about the test loop. - This stuff runs great on my systems, but it needs to run even better on yours. +11: Please do not hesitate to report any problems, comments, suggestions about the test loop. From 3020d911e26bd5c3aaca47280fe092147b1c392d Mon Sep 17 00:00:00 2001 From: Martin Beaudoin Date: Sun, 10 Jun 2012 09:01:37 -0400 Subject: [PATCH 08/14] Adding build instructions for various operating systems --- .../5.5/Compilation_Centos_5.5_64bit.txt | 164 ++++++++++++++++++ .../Compilation_Ubuntu_10.04.3_32-bit.txt | 112 ++++++++++++ .../Compilation_Ubuntu_10.04.3_64-bit.txt | 112 ++++++++++++ .../12.04/Compilation_Ubuntu_12.04_64-bit.txt | 117 +++++++++++++ .../12.1/Compilation_openSUSE_12.1_64bit.txt | 124 +++++++++++++ 5 files changed, 629 insertions(+) create mode 100644 doc/buildInstructions/Centos/5.5/Compilation_Centos_5.5_64bit.txt create mode 100644 doc/buildInstructions/Ubuntu/10.04/Compilation_Ubuntu_10.04.3_32-bit.txt create mode 100644 doc/buildInstructions/Ubuntu/10.04/Compilation_Ubuntu_10.04.3_64-bit.txt create mode 100644 doc/buildInstructions/Ubuntu/12.04/Compilation_Ubuntu_12.04_64-bit.txt create mode 100644 doc/buildInstructions/openSUSE/12.1/Compilation_openSUSE_12.1_64bit.txt diff --git a/doc/buildInstructions/Centos/5.5/Compilation_Centos_5.5_64bit.txt b/doc/buildInstructions/Centos/5.5/Compilation_Centos_5.5_64bit.txt new file mode 100644 index 000000000..fdedd1e44 --- /dev/null +++ b/doc/buildInstructions/Centos/5.5/Compilation_Centos_5.5_64bit.txt @@ -0,0 +1,164 @@ +Installation of OpenFOAM-1.6-ext on Centos 5.5 64-bit +-------------------------------------------------------------------------------- + +Network download and installation from: +ftp://mirrors.usc.edu/pub/linux/distributions/centos/5.5/os/x86_64/ + +Basic configuration: + Desktop - Gnome + Packages from CentOS Extras: unchecked + + Complete installation log: /root/install.log + +Run Package updater to update your installation + +-------------------------------------------------------------------------------- + +Add your user as a valid user for the command 'sudo'. + +You will need to use the command 'visudo' as the user root for this. + +I won't go into the details for this, there is a lot of info all over the Net +for doing this relatively minor adjustment. + +In doubt, simply ask your local Unix guru. + +-------------------------------------------------------------------------------- + +# Add the EPEL package repository: +sudo rpm -Uvh http://download.fedora.redhat.com/pub/epel/5/x86_64/epel-release-5-4.noarch.rpm + +-------------------------------------------------------------------------------- + +# Installation of additional system packages: + +sudo yum install git-1.7.4.1-1.el5.x86_64 +sudo yum install gcc.x86_64 gcc-c++.x86_64 +sudo yum install bison.x86_64 +sudo yum install flex.x86_64 +sudo yum install rpm-build-4.4.2.3-22.el5.x86_64 +sudo yum install zlib-devel-1.2.3-3.x86_64 +sudo yum install libX11-devel.x86_64 +sudo yum install libXext-devel.x86_64 +sudo yum install libXrender-devel.x86_64 +sudo yum install libXt-devel-1.0.2-3.2.el5.x86_64 + +# You can also install everything at once: + +sudo yum install \ + git-1.7.4.1-1.el5.x86_64 \ + gcc.x86_64 gcc-c++.x86_64 \ + bison.x86_64 \ + flex.x86_64 \ + rpm-build-4.4.2.3-22.el5.x86_64 \ + zlib-devel-1.2.3-3.x86_64 \ + libX11-devel.x86_64 \ + libXext-devel.x86_64 \ + libXrender-devel.x86_64 \ + libXt-devel-1.0.2-3.2.el5.x86_64 + +-------------------------------------------------------------------------------- + +# Download OpenFOAM-1.6-ext + +mkdir ~/OpenFOAM +cd ~/OpenFOAM +git clone git://openfoam-extend.git.sourceforge.net/gitroot/openfoam-extend/OpenFOAM-1.6-ext + + +-------------------------------------------------------------------------------- + +# We need to tweak our OpenFOAM setup using the prefs.sh file + +cp ~/OpenFOAM/OpenFOAM-1.6-ext/etc/prefs.sh-EXAMPLE \ + ~/OpenFOAM/OpenFOAM-1.6-ext/etc/prefs.sh + +-------------------------------------------------------------------------------- + +# We are going to use version 4.4.5 of gcc, provided by the ThirdParty packages +# +# The versions provided by Centos 5.5 are either too old, or a just a preview +# version of gcc 4.4.0, which is a bit 'green'. +# +# So the system installed compiler will only serve to compile gcc 4.4.5. + +# Modify the etc/prefs.sh file to switch to gcc 4.4.5 +sed -i s/"compilerInstall=System"/"compilerInstall=OpenFOAM\nWM_COMPILER=Gcc44"/g ~/OpenFOAM/OpenFOAM-1.6-ext/etc/prefs.sh + +# Activate the compilation of gcc 4.4.5 in the ThirdParty/AllMake.stage1 file +sed -i 0,/"#( rpm_make -p gmp-5.0.1"/s//"( rpm_make -p gmp-5.0.1"/ ~/OpenFOAM/OpenFOAM-1.6-ext/ThirdParty/AllMake.stage1 +sed -i 0,/"#( rpm_make -p mpfr-3.0.1"/s//"( rpm_make -p mpfr-3.0.1"/ ~/OpenFOAM/OpenFOAM-1.6-ext/ThirdParty/AllMake.stage1 +sed -i 0,/"#( rpm_make -p gcc-4.4.5"/s//"( rpm_make -p gcc-4.4.5"/ ~/OpenFOAM/OpenFOAM-1.6-ext/ThirdParty/AllMake.stage1 + +# Add the wmake rules set for Gcc44 +ln -s ~/OpenFOAM/OpenFOAM-1.6-ext/wmake/rules/linux64Gcc ~/OpenFOAM/OpenFOAM-1.6-ext/wmake/rules/linux64Gcc44 + +-------------------------------------------------------------------------------- + + +# We are going to use the version of QT4 provided by the ThirdParty packages + +# Uncomment and modify the initialization of the variables 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 this initial OpenFOAM environment to get the basic configuration for +# compilation +. ~/OpenFOAM/OpenFOAM-1.6-ext/etc/bashrc + +# You will get some warnings about missing file for gcc-4.4.5, and problem with +# your compiler installation. +# This is quite normal, your gcc-4.4.5 compiler is not even compiled and +# installed yet. Patience patience... + +# Compile the ThirdParty packages, including the gcc 4.4.5 compiler + +cd $WM_PROJECT_DIR/ThirdParty +./AllMake >& log.AllMake & +tail -f log.AllMake # To keep an eye on the compilation process + +-------------------------------------------------------------------------------- + +# 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 + +-------------------------------------------------------------------------------- + +# Execute Allwmake a second time because of a bad library building sequence for +# the library -lfaceDecompositionMotionSolver + +./Allwmake >& log.Allwmake2 & +tail -f log.Allwmake2 # 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 +August 2011 diff --git a/doc/buildInstructions/Ubuntu/10.04/Compilation_Ubuntu_10.04.3_32-bit.txt b/doc/buildInstructions/Ubuntu/10.04/Compilation_Ubuntu_10.04.3_32-bit.txt new file mode 100644 index 000000000..80bd0542d --- /dev/null +++ b/doc/buildInstructions/Ubuntu/10.04/Compilation_Ubuntu_10.04.3_32-bit.txt @@ -0,0 +1,112 @@ +Installation of OpenFOAM-1.6-ext on Ubuntu 10.04.3 32-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-core +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 +qt4: sudo apt-get install libqt4-dev qt4-dev-tools + +libxext: sudo apt-get install libxext-dev +libxt : sudo apt-get install libxt-dev + +# You can also install everything at once: +sudo apt-get install git-core flex bison rpm g++ zlib1g-dev binutils-dev \ + libqt4-dev qt4-dev-tools libxext-dev libxt-dev + +-------------------------------------------------------------------------------- + +# Minor correction for make/gmake +sudo ln -s /usr/bin/make /usr/bin/gmake + +-------------------------------------------------------------------------------- + +# Installation of libstdc++.so.5: + +For Ubuntu 32bit: +----------------- +Grab the package libstdc++5_3.3.6-24_i386.deb from one of the sites listed here: +http://packages.debian.org/lenny/i386/libstdc++5/download + +wget http://ftp.us.debian.org/debian/pool/main/g/gcc-3.3/libstdc++5_3.3.6-24_i386.deb +dpkg-deb -x ./libstdc++5_3.3.6-24_i386.deb /tmp/tmp_dir + +sudo cp /tmp/tmp_dir/usr/lib/libstdc++.so.5.0.7 /usr/lib/ +sudo ln -s /usr/lib/libstdc++.so.5.0.7 /usr/lib/libstdc++.so.5 +rm -rf /tmp/tmp_dir + +-------------------------------------------------------------------------------- + +# Download OpenFOAM-1.6-ext +mkdir ~/OpenFOAM +cd ~/OpenFOAM +git clone git://openfoam-extend.git.sourceforge.net/gitroot/openfoam-extend/OpenFOAM-1.6-ext + +-------------------------------------------------------------------------------- + +# We are going to use the system installed version of QT4 +cp ~/OpenFOAM/OpenFOAM-1.6-ext/etc/prefs.sh-EXAMPLE ~/OpenFOAM/OpenFOAM-1.6-ext/etc/prefs.sh + +#Uncomment and modify the initialization of the variables QT_DIR and QT_BIN_DIR in the file prefs.sh + +sed -i s/"#export QT_DIR=path_to_system_installed_qt"/"export QT_DIR=\/usr"/g ~/OpenFOAM/OpenFOAM-1.6-ext/etc/prefs.sh +sed -i s/"#export QT_BIN_DIR=\$QT_DIR\/bin"/"export QT_BIN_DIR=\$QT_DIR\/bin"/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=/usr +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 >& log.AllMake & +tail -f log.AllMake # To keep an eye on the compilation process + +-------------------------------------------------------------------------------- + +# 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 + +-------------------------------------------------------------------------------- + +# Execute Allwmake a second time because of a bad library building sequence for +# the library -lfaceDecompositionMotionSolver + +./Allwmake >& log.Allwmake2 & +tail -f log.Allwmake2 # 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 +August 2011 diff --git a/doc/buildInstructions/Ubuntu/10.04/Compilation_Ubuntu_10.04.3_64-bit.txt b/doc/buildInstructions/Ubuntu/10.04/Compilation_Ubuntu_10.04.3_64-bit.txt new file mode 100644 index 000000000..037946396 --- /dev/null +++ b/doc/buildInstructions/Ubuntu/10.04/Compilation_Ubuntu_10.04.3_64-bit.txt @@ -0,0 +1,112 @@ +Installation of OpenFOAM-1.6-ext on Ubuntu 10.04.3 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-core +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 +qt4: sudo apt-get install libqt4-dev qt4-dev-tools + +libxext: sudo apt-get install libxext-dev +libxt : sudo apt-get install libxt-dev + +# You can also install everything at once: +sudo apt-get install git-core flex bison rpm g++ zlib1g-dev binutils-dev \ + libqt4-dev qt4-dev-tools libxext-dev libxt-dev + +-------------------------------------------------------------------------------- + +# Minor correction for make/gmake +sudo ln -s /usr/bin/make /usr/bin/gmake + +-------------------------------------------------------------------------------- + +# Installation of libstdc++.so.5: + +For Ubuntu 64bit: +----------------- +Grab the package libstdc++5_3.3.6-24_amd64.deb from one of the sites listed here: +http://packages.debian.org/lenny/amd64/Libstdc++5/download + +wget http://ftp.us.debian.org/debian/pool/main/g/gcc-3.3/libstdc++5_3.3.6-24_amd64.deb +dpkg-deb -x ./libstdc++5_3.3.6-24_amd64.deb /tmp/tmp_dir + +sudo cp /tmp/tmp_dir/usr/lib/libstdc++.so.5.0.7 /usr/lib/ +sudo ln -s /usr/lib/libstdc++.so.5.0.7 /usr/lib/libstdc++.so.5 +rm -rf /tmp/tmp_dir + +-------------------------------------------------------------------------------- + +# Download OpenFOAM-1.6-ext +mkdir ~/OpenFOAM +cd ~/OpenFOAM +git clone git://openfoam-extend.git.sourceforge.net/gitroot/openfoam-extend/OpenFOAM-1.6-ext + +-------------------------------------------------------------------------------- + +# We are going to use the system installed version of QT4 +cp ~/OpenFOAM/OpenFOAM-1.6-ext/etc/prefs.sh-EXAMPLE ~/OpenFOAM/OpenFOAM-1.6-ext/etc/prefs.sh + +#Uncomment and modify the initialization of the variables QT_DIR and QT_BIN_DIR in the file prefs.sh + +sed -i s/"#export QT_DIR=path_to_system_installed_qt"/"export QT_DIR=\/usr"/g ~/OpenFOAM/OpenFOAM-1.6-ext/etc/prefs.sh +sed -i s/"#export QT_BIN_DIR=\$QT_DIR\/bin"/"export QT_BIN_DIR=\$QT_DIR\/bin"/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=/usr +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 >& log.AllMake & +tail -f log.AllMake # To keep an eye on the compilation process + +-------------------------------------------------------------------------------- + +# 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 + +-------------------------------------------------------------------------------- + +# Execute Allwmake a second time because of a bad library building sequence for +# the library -lfaceDecompositionMotionSolver + +./Allwmake >& log.Allwmake2 & +tail -f log.Allwmake2 # 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 +August 2011 diff --git a/doc/buildInstructions/Ubuntu/12.04/Compilation_Ubuntu_12.04_64-bit.txt b/doc/buildInstructions/Ubuntu/12.04/Compilation_Ubuntu_12.04_64-bit.txt new file mode 100644 index 000000000..f63910903 --- /dev/null +++ b/doc/buildInstructions/Ubuntu/12.04/Compilation_Ubuntu_12.04_64-bit.txt @@ -0,0 +1,117 @@ +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 + +# 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 + +-------------------------------------------------------------------------------- + +# 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=/usr +#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 diff --git a/doc/buildInstructions/openSUSE/12.1/Compilation_openSUSE_12.1_64bit.txt b/doc/buildInstructions/openSUSE/12.1/Compilation_openSUSE_12.1_64bit.txt new file mode 100644 index 000000000..02dff6758 --- /dev/null +++ b/doc/buildInstructions/openSUSE/12.1/Compilation_openSUSE_12.1_64bit.txt @@ -0,0 +1,124 @@ +Installation of OpenFOAM-1.6-ext on openSUSE 12.1 64-bit +-------------------------------------------------------------------------------- + +We assume you have a fresh installation of openSUSE 12.1 64-bit, with all the +necessary updates already applied + +-------------------------------------------------------------------------------- + +# Installation of additional system packages: + +sudo zypper install git +sudo zypper install openmpi-devel +sudo zypper install gnuplot +sudo zypper install -t pattern devel_qt4 + +-------------------------------------------------------------------------------- + +# Download OpenFOAM-1.6-ext + +mkdir ~/OpenFOAM +cd ~/OpenFOAM +git clone git://openfoam-extend.git.sourceforge.net/gitroot/openfoam-extend/OpenFOAM-1.6-ext + + +-------------------------------------------------------------------------------- + +# We need to tweak our OpenFOAM setup using the prefs.sh file + +cp ~/OpenFOAM/OpenFOAM-1.6-ext/etc/prefs.sh-EXAMPLE \ + ~/OpenFOAM/OpenFOAM-1.6-ext/etc/prefs.sh + +-------------------------------------------------------------------------------- + +# We are going to use version system installed version of gcc 4.6.2 + +# Modify the etc/prefs.sh file to switch to gcc 4.6.2 +sed -i s/"compilerInstall=System"/"compilerInstall=System\nWM_COMPILER=Gcc46"/g ~/OpenFOAM/OpenFOAM-1.6-ext/etc/prefs.sh + +-------------------------------------------------------------------------------- + +# We are going to use the system installed version of openmpi-1.4.3 +# +# No need to run AllMake.stage2 +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\/lib64\/mpi\/gcc\/openmpi"/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 + + +-------------------------------------------------------------------------------- + +# We are going to use the system installed development version of Qt (Version: 4.7.4-19.6.1) + +# Uncomment and modify the initialization of the variables QT_DIR and QT_BIN_DIR in the +# file prefs.sh + +sed -i s/"#export QT_DIR=path_to_system_installed_qt"/"export QT_DIR=\/usr"/g ~/OpenFOAM/OpenFOAM-1.6-ext/etc/prefs.sh +sed -i s/"#export QT_BIN_DIR=\$QT_DIR\/bin"/"export QT_BIN_DIR=\$QT_DIR\/bin"/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=/usr +export QT_BIN_DIR=$QT_DIR/bin + +-------------------------------------------------------------------------------- + +# ParaView: +# +# Version 3.8.1 of ParaView does not compile with gcc 4.6.2 on openSUSE 12.1 +# +# I suggest you switch to ParaView 12.1 +# +-------------------------------------------------------------------------------- + +# Source this initial 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.stage3 >& log.AllMake.stage3 +./AllMake.stage4 >& log.AllMake.stage4 + +# You can keep an eye on the compilation process with the command tail e.g: +# tail -f log.AllMake.stage1 + +-------------------------------------------------------------------------------- + +# 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 + +-------------------------------------------------------------------------------- + +# Execute Allwmake a second time because of a bad library building sequence for +# the library -lfaceDecompositionMotionSolver +# Warning: Not sure if this is still necessary... MB 05/2012 + +./Allwmake >& log.Allwmake2 & +tail -f log.Allwmake2 # 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 From 85daa4a8cc998ff4e329fa60b0cc52d687eb7391 Mon Sep 17 00:00:00 2001 From: Martin Beaudoin Date: Sun, 10 Jun 2012 21:27:30 -0400 Subject: [PATCH 09/14] Fixes for gcc-4.5.1 --- ThirdParty/rpmBuild/SPECS/gcc-4.5.1.spec | 9 +-------- etc/settings.csh | 7 +++++++ etc/settings.sh | 7 +++++++ wmake/rules/linux64Gcc45/ARCHITECTURE_TESTED | 2 ++ wmake/rules/linux64Gcc45/X | 3 +++ wmake/rules/linux64Gcc45/c | 16 +++++++++++++++ wmake/rules/linux64Gcc45/c++ | 21 ++++++++++++++++++++ wmake/rules/linux64Gcc45/c++Debug | 2 ++ wmake/rules/linux64Gcc45/c++Opt | 4 ++++ wmake/rules/linux64Gcc45/c++Prof | 2 ++ wmake/rules/linux64Gcc45/cDebug | 2 ++ wmake/rules/linux64Gcc45/cOpt | 2 ++ wmake/rules/linux64Gcc45/cProf | 2 ++ wmake/rules/linux64Gcc45/general | 10 ++++++++++ wmake/rules/linux64Gcc45/mplib | 3 +++ wmake/rules/linux64Gcc45/mplibGAMMA | 3 +++ wmake/rules/linux64Gcc45/mplibHPMPI | 3 +++ wmake/rules/linux64Gcc45/mplibMPICH | 3 +++ wmake/rules/linux64Gcc45/mplibMPICH-GM | 3 +++ wmake/rules/linux64Gcc45/mplibOPENMPI | 3 +++ wmake/rules/linux64Gcc45/mplibQSMPI | 4 ++++ wmake/rules/linux64Gcc45/mplibSYSTEMOPENMPI | 1 + wmake/rules/linuxGcc45/X | 3 +++ wmake/rules/linuxGcc45/c | 16 +++++++++++++++ wmake/rules/linuxGcc45/c++ | 21 ++++++++++++++++++++ wmake/rules/linuxGcc45/c++Debug | 2 ++ wmake/rules/linuxGcc45/c++Opt | 2 ++ wmake/rules/linuxGcc45/c++Prof | 2 ++ wmake/rules/linuxGcc45/cDebug | 2 ++ wmake/rules/linuxGcc45/cOpt | 2 ++ wmake/rules/linuxGcc45/cProf | 2 ++ wmake/rules/linuxGcc45/general | 10 ++++++++++ wmake/rules/linuxGcc45/mplib | 3 +++ wmake/rules/linuxGcc45/mplibGAMMA | 3 +++ wmake/rules/linuxGcc45/mplibHPMPI | 3 +++ wmake/rules/linuxGcc45/mplibMPICH | 3 +++ wmake/rules/linuxGcc45/mplibMPICH-GM | 3 +++ wmake/rules/linuxGcc45/mplibOPENMPI | 3 +++ wmake/rules/linuxGcc45/mplibSYSTEMOPENMPI | 1 + 39 files changed, 185 insertions(+), 8 deletions(-) create mode 100644 wmake/rules/linux64Gcc45/ARCHITECTURE_TESTED create mode 100644 wmake/rules/linux64Gcc45/X create mode 100644 wmake/rules/linux64Gcc45/c create mode 100644 wmake/rules/linux64Gcc45/c++ create mode 100644 wmake/rules/linux64Gcc45/c++Debug create mode 100644 wmake/rules/linux64Gcc45/c++Opt create mode 100644 wmake/rules/linux64Gcc45/c++Prof create mode 100644 wmake/rules/linux64Gcc45/cDebug create mode 100644 wmake/rules/linux64Gcc45/cOpt create mode 100644 wmake/rules/linux64Gcc45/cProf create mode 100644 wmake/rules/linux64Gcc45/general create mode 100644 wmake/rules/linux64Gcc45/mplib create mode 100644 wmake/rules/linux64Gcc45/mplibGAMMA create mode 100644 wmake/rules/linux64Gcc45/mplibHPMPI create mode 100644 wmake/rules/linux64Gcc45/mplibMPICH create mode 100644 wmake/rules/linux64Gcc45/mplibMPICH-GM create mode 100644 wmake/rules/linux64Gcc45/mplibOPENMPI create mode 100644 wmake/rules/linux64Gcc45/mplibQSMPI create mode 100644 wmake/rules/linux64Gcc45/mplibSYSTEMOPENMPI create mode 100644 wmake/rules/linuxGcc45/X create mode 100644 wmake/rules/linuxGcc45/c create mode 100644 wmake/rules/linuxGcc45/c++ create mode 100644 wmake/rules/linuxGcc45/c++Debug create mode 100644 wmake/rules/linuxGcc45/c++Opt create mode 100644 wmake/rules/linuxGcc45/c++Prof create mode 100644 wmake/rules/linuxGcc45/cDebug create mode 100644 wmake/rules/linuxGcc45/cOpt create mode 100644 wmake/rules/linuxGcc45/cProf create mode 100644 wmake/rules/linuxGcc45/general create mode 100644 wmake/rules/linuxGcc45/mplib create mode 100644 wmake/rules/linuxGcc45/mplibGAMMA create mode 100644 wmake/rules/linuxGcc45/mplibHPMPI create mode 100644 wmake/rules/linuxGcc45/mplibMPICH create mode 100644 wmake/rules/linuxGcc45/mplibMPICH-GM create mode 100644 wmake/rules/linuxGcc45/mplibOPENMPI create mode 100644 wmake/rules/linuxGcc45/mplibSYSTEMOPENMPI diff --git a/ThirdParty/rpmBuild/SPECS/gcc-4.5.1.spec b/ThirdParty/rpmBuild/SPECS/gcc-4.5.1.spec index 88dd5fabe..89e946098 100644 --- a/ThirdParty/rpmBuild/SPECS/gcc-4.5.1.spec +++ b/ThirdParty/rpmBuild/SPECS/gcc-4.5.1.spec @@ -166,12 +166,5 @@ rm -rf %{buildroot} %files %defattr(-,root,root) -%{_installPrefix}/bin -%{_installPrefix}/etc -%{_installPrefix}/include -%{_installPrefix}/info -%{_installPrefix}/lib -%{_installPrefix}/libexec -%{_installPrefix}/man -%{_installPrefix}/share +%{_installPrefix} diff --git a/etc/settings.csh b/etc/settings.csh index ba8c76589..ddca7e38c 100644 --- a/etc/settings.csh +++ b/etc/settings.csh @@ -101,6 +101,13 @@ case OpenFOAM: _foamAddLib $WM_THIRD_PARTY_DIR/mpfr-2.4.1/platforms/$WM_ARCH$WM_COMPILER_ARCH/lib _foamAddLib $WM_THIRD_PARTY_DIR/gmp-4.2.4/platforms/$WM_ARCH$WM_COMPILER_ARCH/lib breaksw + case Gcc45: + setenv WM_COMPILER_DIR $WM_THIRD_PARTY_DIR/packages/gcc-4.5.1/platforms/$WM_OPTIONS + _foamSource $WM_THIRD_PARTY_DIR/packages/gmp-5.0.1/platforms/$WM_OPTIONS/etc/gmp-5.0.1.csh + _foamSource $WM_THIRD_PARTY_DIR/packages/mpfr-3.0.1/platforms/$WM_OPTIONS/etc/mpfr-3.0.1.csh + _foamSource $WM_THIRD_PARTY_DIR/packages/mpc-0.8.2/platforms/$WM_OPTIONS/etc/mpc-0.8.2.csh + _foamSource $WM_THIRD_PARTY_DIR/packages/gcc-4.5.1/platforms/$WM_OPTIONS/etc/gcc-4.5.1.csh + breaksw case Gcc44: _foamSource $WM_THIRD_PARTY_DIR/packages/mpfr-3.0.1/platforms/$WM_OPTIONS/etc/mpfr-3.0.1.csh _foamSource $WM_THIRD_PARTY_DIR/packages/gmp-5.0.1/platforms/$WM_OPTIONS/etc/gmp-5.0.1.csh diff --git a/etc/settings.sh b/etc/settings.sh index fc5f579fb..e7a52ea05 100644 --- a/etc/settings.sh +++ b/etc/settings.sh @@ -136,6 +136,13 @@ OpenFOAM) _foamAddLib $WM_THIRD_PARTY_DIR/mpfr-2.4.1/platforms/$WM_ARCH$WM_COMPILER_ARCH/lib _foamAddLib $WM_THIRD_PARTY_DIR/gmp-4.2.4/platforms/$WM_ARCH$WM_COMPILER_ARCH/lib ;; + Gcc45) + export WM_COMPILER_DIR=$WM_THIRD_PARTY_DIR/packages/gcc-4.5.1/platforms/$WM_OPTIONS + _foamSource $WM_THIRD_PARTY_DIR/packages/gmp-5.0.1/platforms/$WM_OPTIONS/etc/gmp-5.0.1.sh + _foamSource $WM_THIRD_PARTY_DIR/packages/mpfr-3.0.1/platforms/$WM_OPTIONS/etc/mpfr-3.0.1.sh + _foamSource $WM_THIRD_PARTY_DIR/packages/mpc-0.8.2/platforms/$WM_OPTIONS/etc/mpc-0.8.2.sh + _foamSource $WM_THIRD_PARTY_DIR/packages/gcc-4.5.1/platforms/$WM_OPTIONS/etc/gcc-4.5.1.sh + ;; Gcc44) _foamSource $WM_THIRD_PARTY_DIR/packages/mpfr-3.0.1/platforms/$WM_OPTIONS/etc/mpfr-3.0.1.sh _foamSource $WM_THIRD_PARTY_DIR/packages/gmp-5.0.1/platforms/$WM_OPTIONS/etc/gmp-5.0.1.sh diff --git a/wmake/rules/linux64Gcc45/ARCHITECTURE_TESTED b/wmake/rules/linux64Gcc45/ARCHITECTURE_TESTED new file mode 100644 index 000000000..72c1dd80f --- /dev/null +++ b/wmake/rules/linux64Gcc45/ARCHITECTURE_TESTED @@ -0,0 +1,2 @@ +by bgschaid. 2010-10-06 on Centos 5.5 with gcc 4.1 + diff --git a/wmake/rules/linux64Gcc45/X b/wmake/rules/linux64Gcc45/X new file mode 100644 index 000000000..5d1f9c5cc --- /dev/null +++ b/wmake/rules/linux64Gcc45/X @@ -0,0 +1,3 @@ +XFLAGS = +XINC = $(XFLAGS) -I/usr/X11R6/include +XLIBS = -L/usr/X11R6/lib64 -lXext -lX11 diff --git a/wmake/rules/linux64Gcc45/c b/wmake/rules/linux64Gcc45/c new file mode 100644 index 000000000..f4114be31 --- /dev/null +++ b/wmake/rules/linux64Gcc45/c @@ -0,0 +1,16 @@ +.SUFFIXES: .c .h + +cWARN = -Wall + +cc = gcc -m64 + +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 diff --git a/wmake/rules/linux64Gcc45/c++ b/wmake/rules/linux64Gcc45/c++ new file mode 100644 index 000000000..72ba3bf12 --- /dev/null +++ b/wmake/rules/linux64Gcc45/c++ @@ -0,0 +1,21 @@ +.SUFFIXES: .C .cxx .cc .cpp + +c++WARN = -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor + +CC = g++ -m64 + +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 diff --git a/wmake/rules/linux64Gcc45/c++Debug b/wmake/rules/linux64Gcc45/c++Debug new file mode 100644 index 000000000..19bdb9c33 --- /dev/null +++ b/wmake/rules/linux64Gcc45/c++Debug @@ -0,0 +1,2 @@ +c++DBUG = -ggdb3 -DFULLDEBUG +c++OPT = -O0 -fdefault-inline diff --git a/wmake/rules/linux64Gcc45/c++Opt b/wmake/rules/linux64Gcc45/c++Opt new file mode 100644 index 000000000..3446f7f58 --- /dev/null +++ b/wmake/rules/linux64Gcc45/c++Opt @@ -0,0 +1,4 @@ +c++DBUG = +c++OPT = -O3 +#c++OPT = -march=nocona -O3 +# -ftree-vectorize -ftree-vectorizer-verbose=3 diff --git a/wmake/rules/linux64Gcc45/c++Prof b/wmake/rules/linux64Gcc45/c++Prof new file mode 100644 index 000000000..3bda4dad5 --- /dev/null +++ b/wmake/rules/linux64Gcc45/c++Prof @@ -0,0 +1,2 @@ +c++DBUG = -pg +c++OPT = -O2 diff --git a/wmake/rules/linux64Gcc45/cDebug b/wmake/rules/linux64Gcc45/cDebug new file mode 100644 index 000000000..72b638f45 --- /dev/null +++ b/wmake/rules/linux64Gcc45/cDebug @@ -0,0 +1,2 @@ +cDBUG = -ggdb -DFULLDEBUG +cOPT = -O1 -fdefault-inline -finline-functions diff --git a/wmake/rules/linux64Gcc45/cOpt b/wmake/rules/linux64Gcc45/cOpt new file mode 100644 index 000000000..a8b063547 --- /dev/null +++ b/wmake/rules/linux64Gcc45/cOpt @@ -0,0 +1,2 @@ +cDBUG = +cOPT = -O3 diff --git a/wmake/rules/linux64Gcc45/cProf b/wmake/rules/linux64Gcc45/cProf new file mode 100644 index 000000000..ca3ac9bf5 --- /dev/null +++ b/wmake/rules/linux64Gcc45/cProf @@ -0,0 +1,2 @@ +cDBUG = -pg +cOPT = -O2 diff --git a/wmake/rules/linux64Gcc45/general b/wmake/rules/linux64Gcc45/general new file mode 100644 index 000000000..740c6a58a --- /dev/null +++ b/wmake/rules/linux64Gcc45/general @@ -0,0 +1,10 @@ +CPP = cpp -traditional-cpp +LD = ld + +PROJECT_LIBS = -l$(WM_PROJECT) -liberty -ldl + +include $(GENERAL_RULES)/standard + +include $(RULES)/X +include $(RULES)/c +include $(RULES)/c++ diff --git a/wmake/rules/linux64Gcc45/mplib b/wmake/rules/linux64Gcc45/mplib new file mode 100644 index 000000000..8a84b4014 --- /dev/null +++ b/wmake/rules/linux64Gcc45/mplib @@ -0,0 +1,3 @@ +PFLAGS = +PINC = +PLIBS = diff --git a/wmake/rules/linux64Gcc45/mplibGAMMA b/wmake/rules/linux64Gcc45/mplibGAMMA new file mode 100644 index 000000000..d62c6250f --- /dev/null +++ b/wmake/rules/linux64Gcc45/mplibGAMMA @@ -0,0 +1,3 @@ +PFLAGS = +PINC = -I$(MPI_ARCH_PATH)/include +PLIBS = -L$(MPI_ARCH_PATH)/lib -lgamma diff --git a/wmake/rules/linux64Gcc45/mplibHPMPI b/wmake/rules/linux64Gcc45/mplibHPMPI new file mode 100644 index 000000000..574492a23 --- /dev/null +++ b/wmake/rules/linux64Gcc45/mplibHPMPI @@ -0,0 +1,3 @@ +PFLAGS = +PINC = -I$(MPI_ARCH_PATH)/include -D_MPICC_H +PLIBS = -L$(MPI_ARCH_PATH)/lib/linux_amd64 -lmpi diff --git a/wmake/rules/linux64Gcc45/mplibMPICH b/wmake/rules/linux64Gcc45/mplibMPICH new file mode 100644 index 000000000..ac17f7c1d --- /dev/null +++ b/wmake/rules/linux64Gcc45/mplibMPICH @@ -0,0 +1,3 @@ +PFLAGS = +PINC = -I$(MPI_ARCH_PATH)/include +PLIBS = -L$(MPI_ARCH_PATH)/lib -lmpich -lrt diff --git a/wmake/rules/linux64Gcc45/mplibMPICH-GM b/wmake/rules/linux64Gcc45/mplibMPICH-GM new file mode 100644 index 000000000..88493ebc7 --- /dev/null +++ b/wmake/rules/linux64Gcc45/mplibMPICH-GM @@ -0,0 +1,3 @@ +PFLAGS = +PINC = -I$(MPI_ARCH_PATH)/include +PLIBS = -L$(MPI_ARCH_PATH)/lib -lmpich -L$(GM_LIB_PATH) -lgm diff --git a/wmake/rules/linux64Gcc45/mplibOPENMPI b/wmake/rules/linux64Gcc45/mplibOPENMPI new file mode 100644 index 000000000..834d2d3e2 --- /dev/null +++ b/wmake/rules/linux64Gcc45/mplibOPENMPI @@ -0,0 +1,3 @@ +PFLAGS = -DOMPI_SKIP_MPICXX +PINC = -I$(MPI_ARCH_PATH)/include +PLIBS = -L$(MPI_ARCH_PATH)/lib -lmpi diff --git a/wmake/rules/linux64Gcc45/mplibQSMPI b/wmake/rules/linux64Gcc45/mplibQSMPI new file mode 100644 index 000000000..95ea32737 --- /dev/null +++ b/wmake/rules/linux64Gcc45/mplibQSMPI @@ -0,0 +1,4 @@ +PFLAGS = +PINC = -I$(MPI_ARCH_PATH)/include +PLIBS = -L$(MPI_ARCH_PATH)/lib -lmpi + diff --git a/wmake/rules/linux64Gcc45/mplibSYSTEMOPENMPI b/wmake/rules/linux64Gcc45/mplibSYSTEMOPENMPI new file mode 100644 index 000000000..98fa814ce --- /dev/null +++ b/wmake/rules/linux64Gcc45/mplibSYSTEMOPENMPI @@ -0,0 +1 @@ +PFLAGS = -DOMPI_SKIP_MPICXX diff --git a/wmake/rules/linuxGcc45/X b/wmake/rules/linuxGcc45/X new file mode 100644 index 000000000..bed8bfedd --- /dev/null +++ b/wmake/rules/linuxGcc45/X @@ -0,0 +1,3 @@ +XFLAGS = +XINC = $(XFLAGS) -I/usr/X11R6/include +XLIBS = -L/usr/X11R6/lib -lXext -lX11 diff --git a/wmake/rules/linuxGcc45/c b/wmake/rules/linuxGcc45/c new file mode 100644 index 000000000..d914fcd37 --- /dev/null +++ b/wmake/rules/linuxGcc45/c @@ -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 diff --git a/wmake/rules/linuxGcc45/c++ b/wmake/rules/linuxGcc45/c++ new file mode 100644 index 000000000..2f19f3a34 --- /dev/null +++ b/wmake/rules/linuxGcc45/c++ @@ -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 \ No newline at end of file diff --git a/wmake/rules/linuxGcc45/c++Debug b/wmake/rules/linuxGcc45/c++Debug new file mode 100644 index 000000000..19bdb9c33 --- /dev/null +++ b/wmake/rules/linuxGcc45/c++Debug @@ -0,0 +1,2 @@ +c++DBUG = -ggdb3 -DFULLDEBUG +c++OPT = -O0 -fdefault-inline diff --git a/wmake/rules/linuxGcc45/c++Opt b/wmake/rules/linuxGcc45/c++Opt new file mode 100644 index 000000000..4cb95b5b3 --- /dev/null +++ b/wmake/rules/linuxGcc45/c++Opt @@ -0,0 +1,2 @@ +c++DBUG = +c++OPT = -O3 diff --git a/wmake/rules/linuxGcc45/c++Prof b/wmake/rules/linuxGcc45/c++Prof new file mode 100644 index 000000000..3bda4dad5 --- /dev/null +++ b/wmake/rules/linuxGcc45/c++Prof @@ -0,0 +1,2 @@ +c++DBUG = -pg +c++OPT = -O2 diff --git a/wmake/rules/linuxGcc45/cDebug b/wmake/rules/linuxGcc45/cDebug new file mode 100644 index 000000000..72b638f45 --- /dev/null +++ b/wmake/rules/linuxGcc45/cDebug @@ -0,0 +1,2 @@ +cDBUG = -ggdb -DFULLDEBUG +cOPT = -O1 -fdefault-inline -finline-functions diff --git a/wmake/rules/linuxGcc45/cOpt b/wmake/rules/linuxGcc45/cOpt new file mode 100644 index 000000000..a8b063547 --- /dev/null +++ b/wmake/rules/linuxGcc45/cOpt @@ -0,0 +1,2 @@ +cDBUG = +cOPT = -O3 diff --git a/wmake/rules/linuxGcc45/cProf b/wmake/rules/linuxGcc45/cProf new file mode 100644 index 000000000..ca3ac9bf5 --- /dev/null +++ b/wmake/rules/linuxGcc45/cProf @@ -0,0 +1,2 @@ +cDBUG = -pg +cOPT = -O2 diff --git a/wmake/rules/linuxGcc45/general b/wmake/rules/linuxGcc45/general new file mode 100644 index 000000000..886bf6748 --- /dev/null +++ b/wmake/rules/linuxGcc45/general @@ -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++ diff --git a/wmake/rules/linuxGcc45/mplib b/wmake/rules/linuxGcc45/mplib new file mode 100644 index 000000000..8a84b4014 --- /dev/null +++ b/wmake/rules/linuxGcc45/mplib @@ -0,0 +1,3 @@ +PFLAGS = +PINC = +PLIBS = diff --git a/wmake/rules/linuxGcc45/mplibGAMMA b/wmake/rules/linuxGcc45/mplibGAMMA new file mode 100644 index 000000000..d62c6250f --- /dev/null +++ b/wmake/rules/linuxGcc45/mplibGAMMA @@ -0,0 +1,3 @@ +PFLAGS = +PINC = -I$(MPI_ARCH_PATH)/include +PLIBS = -L$(MPI_ARCH_PATH)/lib -lgamma diff --git a/wmake/rules/linuxGcc45/mplibHPMPI b/wmake/rules/linuxGcc45/mplibHPMPI new file mode 100644 index 000000000..8aff40632 --- /dev/null +++ b/wmake/rules/linuxGcc45/mplibHPMPI @@ -0,0 +1,3 @@ +PFLAGS = +PINC = -I$(MPI_ARCH_PATH)/include -D_MPICC_H +PLIBS = -L$(MPI_ARCH_PATH)/lib/linux_ia32 -lmpi diff --git a/wmake/rules/linuxGcc45/mplibMPICH b/wmake/rules/linuxGcc45/mplibMPICH new file mode 100644 index 000000000..e5a38a8e3 --- /dev/null +++ b/wmake/rules/linuxGcc45/mplibMPICH @@ -0,0 +1,3 @@ +PFLAGS = -DMPICH_SKIP_MPICXX +PINC = -I$(MPI_ARCH_PATH)/include +PLIBS = -L$(MPI_ARCH_PATH)/lib -lmpich -lrt diff --git a/wmake/rules/linuxGcc45/mplibMPICH-GM b/wmake/rules/linuxGcc45/mplibMPICH-GM new file mode 100644 index 000000000..88493ebc7 --- /dev/null +++ b/wmake/rules/linuxGcc45/mplibMPICH-GM @@ -0,0 +1,3 @@ +PFLAGS = +PINC = -I$(MPI_ARCH_PATH)/include +PLIBS = -L$(MPI_ARCH_PATH)/lib -lmpich -L$(GM_LIB_PATH) -lgm diff --git a/wmake/rules/linuxGcc45/mplibOPENMPI b/wmake/rules/linuxGcc45/mplibOPENMPI new file mode 100644 index 000000000..834d2d3e2 --- /dev/null +++ b/wmake/rules/linuxGcc45/mplibOPENMPI @@ -0,0 +1,3 @@ +PFLAGS = -DOMPI_SKIP_MPICXX +PINC = -I$(MPI_ARCH_PATH)/include +PLIBS = -L$(MPI_ARCH_PATH)/lib -lmpi diff --git a/wmake/rules/linuxGcc45/mplibSYSTEMOPENMPI b/wmake/rules/linuxGcc45/mplibSYSTEMOPENMPI new file mode 100644 index 000000000..98fa814ce --- /dev/null +++ b/wmake/rules/linuxGcc45/mplibSYSTEMOPENMPI @@ -0,0 +1 @@ +PFLAGS = -DOMPI_SKIP_MPICXX From b622e1269ff7d6eb91a3dd62cfaa44557ed8e75c Mon Sep 17 00:00:00 2001 From: Martin Beaudoin Date: Mon, 11 Jun 2012 21:01:25 -0400 Subject: [PATCH 10/14] Adding missing wmake files gor gcc 4.6.x --- wmake/rules/linux64Gcc46/ARCHITECTURE_TESTED | 2 ++ wmake/rules/linux64Gcc46/X | 3 +++ wmake/rules/linux64Gcc46/c | 16 +++++++++++++++ wmake/rules/linux64Gcc46/c++ | 21 ++++++++++++++++++++ wmake/rules/linux64Gcc46/c++Debug | 2 ++ wmake/rules/linux64Gcc46/c++Opt | 4 ++++ wmake/rules/linux64Gcc46/c++Prof | 2 ++ wmake/rules/linux64Gcc46/cDebug | 2 ++ wmake/rules/linux64Gcc46/cOpt | 2 ++ wmake/rules/linux64Gcc46/cProf | 2 ++ wmake/rules/linux64Gcc46/general | 10 ++++++++++ wmake/rules/linux64Gcc46/mplib | 3 +++ wmake/rules/linux64Gcc46/mplibGAMMA | 3 +++ wmake/rules/linux64Gcc46/mplibHPMPI | 3 +++ wmake/rules/linux64Gcc46/mplibMPICH | 3 +++ wmake/rules/linux64Gcc46/mplibMPICH-GM | 3 +++ wmake/rules/linux64Gcc46/mplibOPENMPI | 3 +++ wmake/rules/linux64Gcc46/mplibQSMPI | 4 ++++ wmake/rules/linux64Gcc46/mplibSYSTEMOPENMPI | 1 + 19 files changed, 89 insertions(+) create mode 100644 wmake/rules/linux64Gcc46/ARCHITECTURE_TESTED create mode 100644 wmake/rules/linux64Gcc46/X create mode 100644 wmake/rules/linux64Gcc46/c create mode 100644 wmake/rules/linux64Gcc46/c++ create mode 100644 wmake/rules/linux64Gcc46/c++Debug create mode 100644 wmake/rules/linux64Gcc46/c++Opt create mode 100644 wmake/rules/linux64Gcc46/c++Prof create mode 100644 wmake/rules/linux64Gcc46/cDebug create mode 100644 wmake/rules/linux64Gcc46/cOpt create mode 100644 wmake/rules/linux64Gcc46/cProf create mode 100644 wmake/rules/linux64Gcc46/general create mode 100644 wmake/rules/linux64Gcc46/mplib create mode 100644 wmake/rules/linux64Gcc46/mplibGAMMA create mode 100644 wmake/rules/linux64Gcc46/mplibHPMPI create mode 100644 wmake/rules/linux64Gcc46/mplibMPICH create mode 100644 wmake/rules/linux64Gcc46/mplibMPICH-GM create mode 100644 wmake/rules/linux64Gcc46/mplibOPENMPI create mode 100644 wmake/rules/linux64Gcc46/mplibQSMPI create mode 100644 wmake/rules/linux64Gcc46/mplibSYSTEMOPENMPI diff --git a/wmake/rules/linux64Gcc46/ARCHITECTURE_TESTED b/wmake/rules/linux64Gcc46/ARCHITECTURE_TESTED new file mode 100644 index 000000000..72c1dd80f --- /dev/null +++ b/wmake/rules/linux64Gcc46/ARCHITECTURE_TESTED @@ -0,0 +1,2 @@ +by bgschaid. 2010-10-06 on Centos 5.5 with gcc 4.1 + diff --git a/wmake/rules/linux64Gcc46/X b/wmake/rules/linux64Gcc46/X new file mode 100644 index 000000000..5d1f9c5cc --- /dev/null +++ b/wmake/rules/linux64Gcc46/X @@ -0,0 +1,3 @@ +XFLAGS = +XINC = $(XFLAGS) -I/usr/X11R6/include +XLIBS = -L/usr/X11R6/lib64 -lXext -lX11 diff --git a/wmake/rules/linux64Gcc46/c b/wmake/rules/linux64Gcc46/c new file mode 100644 index 000000000..f4114be31 --- /dev/null +++ b/wmake/rules/linux64Gcc46/c @@ -0,0 +1,16 @@ +.SUFFIXES: .c .h + +cWARN = -Wall + +cc = gcc -m64 + +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 diff --git a/wmake/rules/linux64Gcc46/c++ b/wmake/rules/linux64Gcc46/c++ new file mode 100644 index 000000000..72ba3bf12 --- /dev/null +++ b/wmake/rules/linux64Gcc46/c++ @@ -0,0 +1,21 @@ +.SUFFIXES: .C .cxx .cc .cpp + +c++WARN = -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor + +CC = g++ -m64 + +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 diff --git a/wmake/rules/linux64Gcc46/c++Debug b/wmake/rules/linux64Gcc46/c++Debug new file mode 100644 index 000000000..19bdb9c33 --- /dev/null +++ b/wmake/rules/linux64Gcc46/c++Debug @@ -0,0 +1,2 @@ +c++DBUG = -ggdb3 -DFULLDEBUG +c++OPT = -O0 -fdefault-inline diff --git a/wmake/rules/linux64Gcc46/c++Opt b/wmake/rules/linux64Gcc46/c++Opt new file mode 100644 index 000000000..3446f7f58 --- /dev/null +++ b/wmake/rules/linux64Gcc46/c++Opt @@ -0,0 +1,4 @@ +c++DBUG = +c++OPT = -O3 +#c++OPT = -march=nocona -O3 +# -ftree-vectorize -ftree-vectorizer-verbose=3 diff --git a/wmake/rules/linux64Gcc46/c++Prof b/wmake/rules/linux64Gcc46/c++Prof new file mode 100644 index 000000000..3bda4dad5 --- /dev/null +++ b/wmake/rules/linux64Gcc46/c++Prof @@ -0,0 +1,2 @@ +c++DBUG = -pg +c++OPT = -O2 diff --git a/wmake/rules/linux64Gcc46/cDebug b/wmake/rules/linux64Gcc46/cDebug new file mode 100644 index 000000000..72b638f45 --- /dev/null +++ b/wmake/rules/linux64Gcc46/cDebug @@ -0,0 +1,2 @@ +cDBUG = -ggdb -DFULLDEBUG +cOPT = -O1 -fdefault-inline -finline-functions diff --git a/wmake/rules/linux64Gcc46/cOpt b/wmake/rules/linux64Gcc46/cOpt new file mode 100644 index 000000000..a8b063547 --- /dev/null +++ b/wmake/rules/linux64Gcc46/cOpt @@ -0,0 +1,2 @@ +cDBUG = +cOPT = -O3 diff --git a/wmake/rules/linux64Gcc46/cProf b/wmake/rules/linux64Gcc46/cProf new file mode 100644 index 000000000..ca3ac9bf5 --- /dev/null +++ b/wmake/rules/linux64Gcc46/cProf @@ -0,0 +1,2 @@ +cDBUG = -pg +cOPT = -O2 diff --git a/wmake/rules/linux64Gcc46/general b/wmake/rules/linux64Gcc46/general new file mode 100644 index 000000000..740c6a58a --- /dev/null +++ b/wmake/rules/linux64Gcc46/general @@ -0,0 +1,10 @@ +CPP = cpp -traditional-cpp +LD = ld + +PROJECT_LIBS = -l$(WM_PROJECT) -liberty -ldl + +include $(GENERAL_RULES)/standard + +include $(RULES)/X +include $(RULES)/c +include $(RULES)/c++ diff --git a/wmake/rules/linux64Gcc46/mplib b/wmake/rules/linux64Gcc46/mplib new file mode 100644 index 000000000..8a84b4014 --- /dev/null +++ b/wmake/rules/linux64Gcc46/mplib @@ -0,0 +1,3 @@ +PFLAGS = +PINC = +PLIBS = diff --git a/wmake/rules/linux64Gcc46/mplibGAMMA b/wmake/rules/linux64Gcc46/mplibGAMMA new file mode 100644 index 000000000..d62c6250f --- /dev/null +++ b/wmake/rules/linux64Gcc46/mplibGAMMA @@ -0,0 +1,3 @@ +PFLAGS = +PINC = -I$(MPI_ARCH_PATH)/include +PLIBS = -L$(MPI_ARCH_PATH)/lib -lgamma diff --git a/wmake/rules/linux64Gcc46/mplibHPMPI b/wmake/rules/linux64Gcc46/mplibHPMPI new file mode 100644 index 000000000..574492a23 --- /dev/null +++ b/wmake/rules/linux64Gcc46/mplibHPMPI @@ -0,0 +1,3 @@ +PFLAGS = +PINC = -I$(MPI_ARCH_PATH)/include -D_MPICC_H +PLIBS = -L$(MPI_ARCH_PATH)/lib/linux_amd64 -lmpi diff --git a/wmake/rules/linux64Gcc46/mplibMPICH b/wmake/rules/linux64Gcc46/mplibMPICH new file mode 100644 index 000000000..ac17f7c1d --- /dev/null +++ b/wmake/rules/linux64Gcc46/mplibMPICH @@ -0,0 +1,3 @@ +PFLAGS = +PINC = -I$(MPI_ARCH_PATH)/include +PLIBS = -L$(MPI_ARCH_PATH)/lib -lmpich -lrt diff --git a/wmake/rules/linux64Gcc46/mplibMPICH-GM b/wmake/rules/linux64Gcc46/mplibMPICH-GM new file mode 100644 index 000000000..88493ebc7 --- /dev/null +++ b/wmake/rules/linux64Gcc46/mplibMPICH-GM @@ -0,0 +1,3 @@ +PFLAGS = +PINC = -I$(MPI_ARCH_PATH)/include +PLIBS = -L$(MPI_ARCH_PATH)/lib -lmpich -L$(GM_LIB_PATH) -lgm diff --git a/wmake/rules/linux64Gcc46/mplibOPENMPI b/wmake/rules/linux64Gcc46/mplibOPENMPI new file mode 100644 index 000000000..834d2d3e2 --- /dev/null +++ b/wmake/rules/linux64Gcc46/mplibOPENMPI @@ -0,0 +1,3 @@ +PFLAGS = -DOMPI_SKIP_MPICXX +PINC = -I$(MPI_ARCH_PATH)/include +PLIBS = -L$(MPI_ARCH_PATH)/lib -lmpi diff --git a/wmake/rules/linux64Gcc46/mplibQSMPI b/wmake/rules/linux64Gcc46/mplibQSMPI new file mode 100644 index 000000000..95ea32737 --- /dev/null +++ b/wmake/rules/linux64Gcc46/mplibQSMPI @@ -0,0 +1,4 @@ +PFLAGS = +PINC = -I$(MPI_ARCH_PATH)/include +PLIBS = -L$(MPI_ARCH_PATH)/lib -lmpi + diff --git a/wmake/rules/linux64Gcc46/mplibSYSTEMOPENMPI b/wmake/rules/linux64Gcc46/mplibSYSTEMOPENMPI new file mode 100644 index 000000000..98fa814ce --- /dev/null +++ b/wmake/rules/linux64Gcc46/mplibSYSTEMOPENMPI @@ -0,0 +1 @@ +PFLAGS = -DOMPI_SKIP_MPICXX From d706e1a5216ea5cf8e5cac518846021ab1bdc985 Mon Sep 17 00:00:00 2001 From: Martin Beaudoin Date: Tue, 12 Jun 2012 11:45:12 -0400 Subject: [PATCH 11/14] ThirdParty: mesquite 2.1.2: forcing the installation of the libraries under lib. Under some OSes, lib64 will be chosen by default --- ThirdParty/rpmBuild/SPECS/mesquite-2.1.2.spec | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/ThirdParty/rpmBuild/SPECS/mesquite-2.1.2.spec b/ThirdParty/rpmBuild/SPECS/mesquite-2.1.2.spec index c2ec9c5cf..0d659deee 100644 --- a/ThirdParty/rpmBuild/SPECS/mesquite-2.1.2.spec +++ b/ThirdParty/rpmBuild/SPECS/mesquite-2.1.2.spec @@ -101,15 +101,16 @@ Patch0: mesquite-2.1.2_patch0 [ -n "$WM_LDFLAGS" ] && export LDFLAGS="$WM_LDFLAGS" ./configure \ - --prefix=%{_installPrefix} \ - --enable-release \ - --disable-debug-assertions \ - --disable-igeom \ - --disable-imesh \ - --disable-irel \ - --enable-shared \ - --without-cppunit \ - --enable-trap-fpe \ + --prefix=%{_installPrefix} \ + --libdir=%{_installPrefix}/lib \ + --enable-release \ + --disable-debug-assertions \ + --disable-igeom \ + --disable-imesh \ + --disable-irel \ + --enable-shared \ + --without-cppunit \ + --enable-trap-fpe \ --disable-function-timers # Remove the file include/Mesquite_all_headers.hpp From 0e0052604b71b0aa1553d9570ac595feaebdc2a0 Mon Sep 17 00:00:00 2001 From: Martin Beaudoin Date: Wed, 20 Jun 2012 00:27:44 -0400 Subject: [PATCH 12/14] libscotchDecomp : no library librt for Mac OS X --- src/decompositionMethods/scotchDecomp/Make/options | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/decompositionMethods/scotchDecomp/Make/options b/src/decompositionMethods/scotchDecomp/Make/options index 5f7145bab..89f07e7a8 100644 --- a/src/decompositionMethods/scotchDecomp/Make/options +++ b/src/decompositionMethods/scotchDecomp/Make/options @@ -2,7 +2,13 @@ EXE_INC = \ -I$(SCOTCH_INCLUDE_DIR) \ -I../decompositionMethods/lnInclude +ifeq ($(WM_ARCH_BASE), darwin) +/* No librt for Mac OS X */ LIB_LIBS = \ -L$(SCOTCH_LIB_DIR) -lscotch \ - -L$(SCOTCH_LIB_DIR) -lscotcherrexit \ - -lrt + -L$(SCOTCH_LIB_DIR) -lscotcherrexit +else +LIB_LIBS = \ + -L$(SCOTCH_LIB_DIR) -lscotch \ + -L$(SCOTCH_LIB_DIR) -lscotcherrexit -lrt +endif From 4ebf8c586f29e842538d867d3824340d8a9ef20b Mon Sep 17 00:00:00 2001 From: Martin Beaudoin Date: Fri, 6 Jul 2012 14:14:28 -0400 Subject: [PATCH 13/14] ThirdParty: adjustments for Ubuntu 12.04 32 bit --- .../rpmBuild/SOURCES/libccmio-2.6.1.patch_0 | 10 +- .../rpmBuild/SOURCES/scotch-5.1.10b_patch_0 | 2 +- .../qt-everywhere-opensource-src-4.7.4.spec | 7 + .../12.04/Compilation_Ubuntu_12.04_32-bit.txt | 120 ++++++++++++++++++ .../12.04/Compilation_Ubuntu_12.04_64-bit.txt | 4 +- wmake/rules/linuxGcc46/X | 3 + wmake/rules/linuxGcc46/c | 16 +++ wmake/rules/linuxGcc46/c++ | 21 +++ wmake/rules/linuxGcc46/c++Debug | 2 + wmake/rules/linuxGcc46/c++Opt | 2 + wmake/rules/linuxGcc46/c++Prof | 2 + wmake/rules/linuxGcc46/cDebug | 2 + wmake/rules/linuxGcc46/cOpt | 2 + wmake/rules/linuxGcc46/cProf | 2 + wmake/rules/linuxGcc46/general | 10 ++ wmake/rules/linuxGcc46/mplib | 3 + wmake/rules/linuxGcc46/mplibGAMMA | 3 + wmake/rules/linuxGcc46/mplibHPMPI | 3 + wmake/rules/linuxGcc46/mplibMPICH | 3 + wmake/rules/linuxGcc46/mplibMPICH-GM | 3 + wmake/rules/linuxGcc46/mplibOPENMPI | 3 + wmake/rules/linuxGcc46/mplibSYSTEMOPENMPI | 1 + 22 files changed, 221 insertions(+), 3 deletions(-) create mode 100644 doc/buildInstructions/Ubuntu/12.04/Compilation_Ubuntu_12.04_32-bit.txt create mode 100644 wmake/rules/linuxGcc46/X create mode 100644 wmake/rules/linuxGcc46/c create mode 100644 wmake/rules/linuxGcc46/c++ create mode 100644 wmake/rules/linuxGcc46/c++Debug create mode 100644 wmake/rules/linuxGcc46/c++Opt create mode 100644 wmake/rules/linuxGcc46/c++Prof create mode 100644 wmake/rules/linuxGcc46/cDebug create mode 100644 wmake/rules/linuxGcc46/cOpt create mode 100644 wmake/rules/linuxGcc46/cProf create mode 100644 wmake/rules/linuxGcc46/general create mode 100644 wmake/rules/linuxGcc46/mplib create mode 100644 wmake/rules/linuxGcc46/mplibGAMMA create mode 100644 wmake/rules/linuxGcc46/mplibHPMPI create mode 100644 wmake/rules/linuxGcc46/mplibMPICH create mode 100644 wmake/rules/linuxGcc46/mplibMPICH-GM create mode 100644 wmake/rules/linuxGcc46/mplibOPENMPI create mode 100644 wmake/rules/linuxGcc46/mplibSYSTEMOPENMPI diff --git a/ThirdParty/rpmBuild/SOURCES/libccmio-2.6.1.patch_0 b/ThirdParty/rpmBuild/SOURCES/libccmio-2.6.1.patch_0 index 7d1228a4b..ee15dd21a 100644 --- a/ThirdParty/rpmBuild/SOURCES/libccmio-2.6.1.patch_0 +++ b/ThirdParty/rpmBuild/SOURCES/libccmio-2.6.1.patch_0 @@ -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 ;; diff --git a/ThirdParty/rpmBuild/SOURCES/scotch-5.1.10b_patch_0 b/ThirdParty/rpmBuild/SOURCES/scotch-5.1.10b_patch_0 index 6fd234ff4..29d09cbdc 100644 --- a/ThirdParty/rpmBuild/SOURCES/scotch-5.1.10b_patch_0 +++ b/ThirdParty/rpmBuild/SOURCES/scotch-5.1.10b_patch_0 @@ -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 diff --git a/ThirdParty/rpmBuild/SPECS/qt-everywhere-opensource-src-4.7.4.spec b/ThirdParty/rpmBuild/SPECS/qt-everywhere-opensource-src-4.7.4.spec index 8b1277278..199df02c8 100644 --- a/ThirdParty/rpmBuild/SPECS/qt-everywhere-opensource-src-4.7.4.spec +++ b/ThirdParty/rpmBuild/SPECS/qt-everywhere-opensource-src-4.7.4.spec @@ -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 diff --git a/doc/buildInstructions/Ubuntu/12.04/Compilation_Ubuntu_12.04_32-bit.txt b/doc/buildInstructions/Ubuntu/12.04/Compilation_Ubuntu_12.04_32-bit.txt new file mode 100644 index 000000000..6aad60fa4 --- /dev/null +++ b/doc/buildInstructions/Ubuntu/12.04/Compilation_Ubuntu_12.04_32-bit.txt @@ -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 diff --git a/doc/buildInstructions/Ubuntu/12.04/Compilation_Ubuntu_12.04_64-bit.txt b/doc/buildInstructions/Ubuntu/12.04/Compilation_Ubuntu_12.04_64-bit.txt index f63910903..ff09e2485 100644 --- a/doc/buildInstructions/Ubuntu/12.04/Compilation_Ubuntu_12.04_64-bit.txt +++ b/doc/buildInstructions/Ubuntu/12.04/Compilation_Ubuntu_12.04_64-bit.txt @@ -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 -------------------------------------------------------------------------------- diff --git a/wmake/rules/linuxGcc46/X b/wmake/rules/linuxGcc46/X new file mode 100644 index 000000000..bed8bfedd --- /dev/null +++ b/wmake/rules/linuxGcc46/X @@ -0,0 +1,3 @@ +XFLAGS = +XINC = $(XFLAGS) -I/usr/X11R6/include +XLIBS = -L/usr/X11R6/lib -lXext -lX11 diff --git a/wmake/rules/linuxGcc46/c b/wmake/rules/linuxGcc46/c new file mode 100644 index 000000000..d914fcd37 --- /dev/null +++ b/wmake/rules/linuxGcc46/c @@ -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 diff --git a/wmake/rules/linuxGcc46/c++ b/wmake/rules/linuxGcc46/c++ new file mode 100644 index 000000000..2f19f3a34 --- /dev/null +++ b/wmake/rules/linuxGcc46/c++ @@ -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 \ No newline at end of file diff --git a/wmake/rules/linuxGcc46/c++Debug b/wmake/rules/linuxGcc46/c++Debug new file mode 100644 index 000000000..19bdb9c33 --- /dev/null +++ b/wmake/rules/linuxGcc46/c++Debug @@ -0,0 +1,2 @@ +c++DBUG = -ggdb3 -DFULLDEBUG +c++OPT = -O0 -fdefault-inline diff --git a/wmake/rules/linuxGcc46/c++Opt b/wmake/rules/linuxGcc46/c++Opt new file mode 100644 index 000000000..4cb95b5b3 --- /dev/null +++ b/wmake/rules/linuxGcc46/c++Opt @@ -0,0 +1,2 @@ +c++DBUG = +c++OPT = -O3 diff --git a/wmake/rules/linuxGcc46/c++Prof b/wmake/rules/linuxGcc46/c++Prof new file mode 100644 index 000000000..3bda4dad5 --- /dev/null +++ b/wmake/rules/linuxGcc46/c++Prof @@ -0,0 +1,2 @@ +c++DBUG = -pg +c++OPT = -O2 diff --git a/wmake/rules/linuxGcc46/cDebug b/wmake/rules/linuxGcc46/cDebug new file mode 100644 index 000000000..72b638f45 --- /dev/null +++ b/wmake/rules/linuxGcc46/cDebug @@ -0,0 +1,2 @@ +cDBUG = -ggdb -DFULLDEBUG +cOPT = -O1 -fdefault-inline -finline-functions diff --git a/wmake/rules/linuxGcc46/cOpt b/wmake/rules/linuxGcc46/cOpt new file mode 100644 index 000000000..a8b063547 --- /dev/null +++ b/wmake/rules/linuxGcc46/cOpt @@ -0,0 +1,2 @@ +cDBUG = +cOPT = -O3 diff --git a/wmake/rules/linuxGcc46/cProf b/wmake/rules/linuxGcc46/cProf new file mode 100644 index 000000000..ca3ac9bf5 --- /dev/null +++ b/wmake/rules/linuxGcc46/cProf @@ -0,0 +1,2 @@ +cDBUG = -pg +cOPT = -O2 diff --git a/wmake/rules/linuxGcc46/general b/wmake/rules/linuxGcc46/general new file mode 100644 index 000000000..886bf6748 --- /dev/null +++ b/wmake/rules/linuxGcc46/general @@ -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++ diff --git a/wmake/rules/linuxGcc46/mplib b/wmake/rules/linuxGcc46/mplib new file mode 100644 index 000000000..8a84b4014 --- /dev/null +++ b/wmake/rules/linuxGcc46/mplib @@ -0,0 +1,3 @@ +PFLAGS = +PINC = +PLIBS = diff --git a/wmake/rules/linuxGcc46/mplibGAMMA b/wmake/rules/linuxGcc46/mplibGAMMA new file mode 100644 index 000000000..d62c6250f --- /dev/null +++ b/wmake/rules/linuxGcc46/mplibGAMMA @@ -0,0 +1,3 @@ +PFLAGS = +PINC = -I$(MPI_ARCH_PATH)/include +PLIBS = -L$(MPI_ARCH_PATH)/lib -lgamma diff --git a/wmake/rules/linuxGcc46/mplibHPMPI b/wmake/rules/linuxGcc46/mplibHPMPI new file mode 100644 index 000000000..8aff40632 --- /dev/null +++ b/wmake/rules/linuxGcc46/mplibHPMPI @@ -0,0 +1,3 @@ +PFLAGS = +PINC = -I$(MPI_ARCH_PATH)/include -D_MPICC_H +PLIBS = -L$(MPI_ARCH_PATH)/lib/linux_ia32 -lmpi diff --git a/wmake/rules/linuxGcc46/mplibMPICH b/wmake/rules/linuxGcc46/mplibMPICH new file mode 100644 index 000000000..e5a38a8e3 --- /dev/null +++ b/wmake/rules/linuxGcc46/mplibMPICH @@ -0,0 +1,3 @@ +PFLAGS = -DMPICH_SKIP_MPICXX +PINC = -I$(MPI_ARCH_PATH)/include +PLIBS = -L$(MPI_ARCH_PATH)/lib -lmpich -lrt diff --git a/wmake/rules/linuxGcc46/mplibMPICH-GM b/wmake/rules/linuxGcc46/mplibMPICH-GM new file mode 100644 index 000000000..88493ebc7 --- /dev/null +++ b/wmake/rules/linuxGcc46/mplibMPICH-GM @@ -0,0 +1,3 @@ +PFLAGS = +PINC = -I$(MPI_ARCH_PATH)/include +PLIBS = -L$(MPI_ARCH_PATH)/lib -lmpich -L$(GM_LIB_PATH) -lgm diff --git a/wmake/rules/linuxGcc46/mplibOPENMPI b/wmake/rules/linuxGcc46/mplibOPENMPI new file mode 100644 index 000000000..834d2d3e2 --- /dev/null +++ b/wmake/rules/linuxGcc46/mplibOPENMPI @@ -0,0 +1,3 @@ +PFLAGS = -DOMPI_SKIP_MPICXX +PINC = -I$(MPI_ARCH_PATH)/include +PLIBS = -L$(MPI_ARCH_PATH)/lib -lmpi diff --git a/wmake/rules/linuxGcc46/mplibSYSTEMOPENMPI b/wmake/rules/linuxGcc46/mplibSYSTEMOPENMPI new file mode 100644 index 000000000..98fa814ce --- /dev/null +++ b/wmake/rules/linuxGcc46/mplibSYSTEMOPENMPI @@ -0,0 +1 @@ +PFLAGS = -DOMPI_SKIP_MPICXX From 58a3297f6bc13fc2ad2c84f1f45c8a1f6a0f4b40 Mon Sep 17 00:00:00 2001 From: Martin Beaudoin Date: Thu, 12 Jul 2012 07:34:07 -0400 Subject: [PATCH 14/14] ThirdParty: build instructions for Ubuntu 12.04 32 bit: fixing typo --- .../Ubuntu/12.04/Compilation_Ubuntu_12.04_32-bit.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/buildInstructions/Ubuntu/12.04/Compilation_Ubuntu_12.04_32-bit.txt b/doc/buildInstructions/Ubuntu/12.04/Compilation_Ubuntu_12.04_32-bit.txt index 6aad60fa4..65c90b1ef 100644 --- a/doc/buildInstructions/Ubuntu/12.04/Compilation_Ubuntu_12.04_32-bit.txt +++ b/doc/buildInstructions/Ubuntu/12.04/Compilation_Ubuntu_12.04_32-bit.txt @@ -1,4 +1,4 @@ -Installation of OpenFOAM-1.6-ext on Ubuntu 12.04 64-bit +Installation of OpenFOAM-1.6-ext on Ubuntu 12.04 32-bit - Proceed with the installation of the OS - Update your OS installation using "Update Manager".