diff --git a/ThirdParty/AllMake.stage2 b/ThirdParty/AllMake.stage2 index 8c19d6418..2454c2d16 100755 --- a/ThirdParty/AllMake.stage2 +++ b/ThirdParty/AllMake.stage2 @@ -62,11 +62,16 @@ echo Starting ThirdParty AllMake: Stage2 echo ======================================== echo -# MPI -#( rpm_make openmpi-1.4.1 http://www.open-mpi.org/software/ompi/v1.4/downloads/openmpi-1.4.1.tar.gz ) -( rpm_make openmpi-1.4.3 http://www.open-mpi.org/software/ompi/v1.4/downloads/openmpi-1.4.3.tar.gz ) -#( rpm_make openmpi-1.5 http://www.open-mpi.org/software/ompi/v1.5/downloads/openmpi-1.5.tar.gz ) - +if [ "$WM_MPLIB" != "SYSTEMOPENMPI" ] +then + # MPI + #( rpm_make openmpi-1.4.1 http://www.open-mpi.org/software/ompi/v1.4/downloads/openmpi-1.4.1.tar.gz ) + ( rpm_make openmpi-1.4.3 http://www.open-mpi.org/software/ompi/v1.4/downloads/openmpi-1.4.3.tar.gz ) + #( rpm_make openmpi-1.5 http://www.open-mpi.org/software/ompi/v1.5/downloads/openmpi-1.5.tar.gz ) +else + echo "Using system installed OpenMPI" + echo "" +fi echo ======================================== echo Done ThirdParty AllMake: Stage2 echo ======================================== diff --git a/ThirdParty/AllMake.stage3 b/ThirdParty/AllMake.stage3 index 595b4021b..0279c8d29 100755 --- a/ThirdParty/AllMake.stage3 +++ b/ThirdParty/AllMake.stage3 @@ -57,16 +57,40 @@ echo ======================================== echo # Metis -( rpm_make metis-5.0pre2 http://glaros.dtc.umn.edu/gkhome/fetch/sw/metis/metis-5.0pre2.tar.gz ) +if [ -z "$METIS_SYSTEM" ] +then + ( rpm_make metis-5.0pre2 http://glaros.dtc.umn.edu/gkhome/fetch/sw/metis/metis-5.0pre2.tar.gz ) +else + echo "Using system installed Metis" + echo "" +fi # ParMGridGen -( rpm_make ParMGridGen-1.0 http://www.mgnet.org/mgnet/Codes/parmgridgen/ParMGridGen-1.0.tar.gz ) +if [ -z "$PARMGRIDGEN_SYSTEM" ] +then + ( rpm_make ParMGridGen-1.0 http://www.mgnet.org/mgnet/Codes/parmgridgen/ParMGridGen-1.0.tar.gz ) +else + echo "Using system installed ParMGridGen" + echo "" +fi # Libccmio -#( rpm_make libccmio-2.6.1 ) +#if [ -z "$LIBCCMIO_SYSTEM" ] +#then +# ( rpm_make libccmio-2.6.1 ) +#else +# echo "Using system installed Libccmio" +# echo "" +#fi # Mesquite -( rpm_make mesquite-2.1.2 http://software.sandia.gov/~jakraft/mesquite-2.1.2.tar.gz ) +if [ -z "$MESQUITE_SYSTEM" ] +then + ( rpm_make mesquite-2.1.2 http://software.sandia.gov/~jakraft/mesquite-2.1.2.tar.gz ) +else + echo "Using system installed Mesquite" + echo "" +fi # The following two packages depends on the availability of OpenMPI # The macro rpm_make() will make sure to update the ThirdParty environment variables before starting @@ -75,10 +99,22 @@ echo # the AllMake.stage2 script completed correctly # # Scotch -( rpm_make scotch-5.1.10b https://gforge.inria.fr/frs/download.php/27583/scotch-5.1.10b.tar.gz ) +if [ -z "$SCOTCH_SYSTEM" ] +then + ( rpm_make scotch-5.1.10b https://gforge.inria.fr/frs/download.php/27583/scotch-5.1.10b.tar.gz ) +else + echo "Using system installed Scotch" + echo "" +fi # ParMetis -( rpm_make ParMetis-3.1.1 http://glaros.dtc.umn.edu/gkhome/fetch/sw/parmetis/ParMetis-3.1.1.tar.gz ) +if [ -z "$PARMETIS_SYSTEM" ] +then + ( rpm_make ParMetis-3.1.1 http://glaros.dtc.umn.edu/gkhome/fetch/sw/parmetis/ParMetis-3.1.1.tar.gz ) +else + echo "Using system installed ParMetis" + echo "" +fi echo ======================================== echo Done ThirdParty AllMake: Stage3 diff --git a/ThirdParty/AllMake.stage4 b/ThirdParty/AllMake.stage4 index d706853e3..6162e8799 100755 --- a/ThirdParty/AllMake.stage4 +++ b/ThirdParty/AllMake.stage4 @@ -57,19 +57,34 @@ echo ======================================== echo # qt-everywhere-opensource-src-4.7.0 -#( rpm_make qt-everywhere-opensource-src-4.7.0 http://get.qt.nokia.com/qt/source/qt-everywhere-opensource-src-4.7.0.tar.gz ) - -# paraview -if [ -d "$QT_DIR" -a -r "$QT_DIR"/bin/qmake ] +if [ ! -z "$QT_THIRD_PARTY" ] then - ( rpm_make ParaView-3.8.1 http://www.paraview.org/files/v3.8/ParaView-3.8.1.tar.gz \ - -D '_qmakePath $QT_DIR/bin/qmake' - ) + ( rpm_make qt-everywhere-opensource-src-4.7.0 http://get.qt.nokia.com/qt/source/qt-everywhere-opensource-src-4.7.0.tar.gz ) else - echo "WARNING: Skipping the installation of ParaView-3.8.1." - echo "WARNING: Please initialize the QT_DIR environment variable to your QT installation directory." - echo "WARNING: The command \$QT_DIR/bin/qmake needs to be valid" - echo "WARNING: " + echo "Using system installed QT" + echo "" +fi + + +# Paraview +if [ -z "$PARAVIEW_SYSTEM" ] +then + if [ -d "$QT_BIN_DIR" -a -r "$QT_BIN_DIR"/qmake ] + then + ( rpm_make ParaView-3.8.1 http://www.paraview.org/files/v3.8/ParaView-3.8.1.tar.gz \ + -D '_qmakePath $QT_BIN_DIR/qmake' + ) + else + echo "WARNING: " + echo "WARNING: Skipping the installation of ParaView-3.8.1." + 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" + echo "WARNING: " + fi +else + echo "Using system installed ParaView" + echo "" fi echo ======================================== diff --git a/ThirdParty/README.ThirdParty b/ThirdParty/README.ThirdParty index 90cb78350..e01bab901 100644 --- a/ThirdParty/README.ThirdParty +++ b/ThirdParty/README.ThirdParty @@ -1,103 +1,183 @@ A new design for the ThirdParty packages: ========================================= -The main purpose of this new development is to build a complete ThirParty packages set for OpenFOAM 1.6-ext using only the original package source +The main purpose of this new development is to build a complete ThirParty +packages set for OpenFOAM 1.6-ext using only the original package source tarball and some patch files ( when necessary). -A useful by-product of this development is also to provide some kind of binary packaging of the ThirdParty packages. +A useful by-product of this development is also to provide some kind of binary +packaging of the ThirdParty packages. + +The RPM suite of tools was selected to develop a first prototype. +The whole process needs to run and install in user-space, without the need to +be root for installing the packages. -The RPM suite of tools was selected to develop a first prototype. -The whole process needs to run and install in user-space, without the need to be root for installing the packages. - Here is what's available: a: A set of rpm spec files for specific ThirdParty packages. - b: A suite of bash scripts to automate the complete sequence of downloading, compiling, installing and generating RPMs. - c: An empty directory structure pre-configured and ready to proceed with the download, compilation and installation of - chosen ThirdParty packages for OF-1.6-ext. - + b: A suite of bash scripts to automate the complete sequence of downloading, + compiling, installing and generating RPMs. + c: An empty directory structure pre-configured and ready to proceed with the + download, compilation and installation of chosen ThirdParty packages for + OF-1.6-ext. + d: A simple mecanism that allows replacing any of the ThirdParty packages by + a system installed package instead. + + +Pre-requisite: +-------------- +You will need a working installation of the commands 'rpm' and 'rpmbuild' on +your system in order to compile and install the ThirdParty packages. +Please check your system installation first. + + Quick description of the main scripts: -------------------------------------- a: AllMake: - Main wrapper script that will call AllMake.stage0 to AllMake.stage4 scripts in sequence. + Main wrapper script that will call AllMake.stage0 to AllMake.stage4 + scripts in sequence. b: AllMake.stage0: - This script is useful only for populating what I am calling the local "RPM vault" with pre-generated RPMs. - This is the script written to address the use-case: "I have some pre-generated RPM files, now what" - Basically, you call this script with a list of RPMs generated by the AllMake.stage(1-4) in order to populate the local RPMS vault. - Once in place, these are the RPMs will be installed instead of proceeding with the standard compilation process. + This script is useful only for populating what I am calling the local + "RPM vault" with pre-generated RPMs. This is the script written to + address the use-case: "I have some pre-generated RPM files, now what" + Basically, you call this script with a list of RPMs generated by the + AllMake.stage(1-4) in order to populate the local RPMS vault. + Once in place, these are the RPMs will be installed instead of + proceeding with the standard compilation process. c: AllMake.stage1: - This script is taking care of the basic ThirdParty tools like compilers, cmake , python, etc. - If we ever need to override the local version of flex or bison, this is where we will add those additional packages. - This stage will also generate a .sh and .csh file one needs to source in order to initialize the PATH and LD_LIBRARY_PATH env. variable. - If you need to compile the rest of the ThirdParty packages with a new gcc compiler, you will need to source those .sh or .csh file in before activating the other - AllMake.stage(2-4) scripts. + This script is taking care of the basic ThirdParty tools like compilers, + cmake , python, etc. If we ever need to override the local version of + flex or bison, this is where we will add those additional packages. + This stage will also generate a .sh and .csh file one needs to source in + order to initialize the PATH and LD_LIBRARY_PATH env. variable. If you + need to compile the rest of the ThirdParty packages with a new gcc + compiler, you will need to source those .sh or .csh file in before + activating the other AllMake.stage(2-4) scripts. d: AllMake.stage2: - This script is taking care of the MPI communication libraries. Right now, only OpenMPI is supported. - This stage will also generate a .sh and .csh file one needs to source in order to initialize the PATH and LD_LIBRARY_PATH env. variable. - You will need to source those .sh or .csh file in before activating the other AllMake.stage(3-4) scripts because some packages depends on the communication library. + This script is taking care of the MPI communication libraries. Right + now, only OpenMPI is supported. + This stage will also generate a .sh and .csh file one needs to source in + order to initialize the PATH and LD_LIBRARY_PATH env. variable. You will + need to source those .sh or .csh file in before activating the other + AllMake.stage(3-4) scripts because some packages depends on the + communication library. e: AllMake.stage3: - This script is taking care of the "standard" ThirdParty libraries like metis, scotch, mesquite, etc. - This stage will also generate a .sh and .csh file one needs to source in order to initialize the PATH and LD_LIBRARY_PATH env. variable. - You will need to source those .sh or .csh file in before compiling OpenFOAM because some "Make/options" files will refer to environment variable that are - specific to those packages + This script is taking care of the "standard" ThirdParty libraries like + metis, scotch, mesquite, etc. + This stage will also generate a .sh and .csh file one needs to source in + order to initialize the PATH and LD_LIBRARY_PATH env. variable. You will + need to source those .sh or .csh file in before compiling OpenFOAM + because some "Make/options" files will refer to environment variable + that are specific to those packages f: AllMake.stage4: - This script is taking care of Paraview and QT (and takes an awfull long time to compile, honest...). - This stage will also generate a .sh and .csh file one needs to source in order to initialize the PATH and LD_LIBRARY_PATH env. variable. - You will need to source those .sh or .csh file in before compiling OpenFOAM because some "Make/options" files will refer to environment variable that are specific to those packages + This script is taking care of Paraview and QT (and takes an awfull long + time to compile, honest...). + This stage will also generate a .sh and .csh file one needs to source in + order to initialize the PATH and LD_LIBRARY_PATH env. variable. You will + need to source those .sh or .csh file in before compiling OpenFOAM + because some "Make/options" files will refer to environment variable + that are specific to those packages g: tools/makeThirdPartyFunctionsForRPM: - A suite of bash functions useful for wrapping the rpmbuild and rpm commands + A suite of bash functions useful for wrapping the rpmbuild and rpm + commands -For every packages, this is the basic process we will be going through when starting building the ThirdParty packages from scratch:: - a: Verify in the local "RPM vault" if a RPM is available for a given package +For every packages, this is the basic process we will be going through when + starting building the ThirdParty packages from scratch: + a: Verify in the local "RPM vault" if a RPM is available for a given + package b: If it is, simply install this RPM and move on to the next package c: if the RPM is absent: i: verify if the source tarbal is available from the SOURCES "vault" ii: if it is not, download the tarball using the specified URL. - iii: proceed with the extraction, patching, configuration, compilation, RPM generation and installation of the package. The generated RPM is always used for installation. - d: The default installation root directory is "$WM_THIRD_PARTY_DIR". This can be overriden though when installing the RPM. + iii: proceed with the extraction, patching, configuration, + compilation, RPM generation and installation of the package. The + generated RPM is always used for installation. + d: The default installation root directory is "$WM_THIRD_PARTY_DIR". This + can be overriden though when installing the RPM. Relocating the RPM root installation directory: - a: All the generated RPMs can be relocated, meaning that you can override the hard-coded root installation directory when using those RPMs for installation. - b: You can check that the RPM is relocatable by using the command rpm -qip thePackage.rpm. For example, from the cmake-2.8.3 package generated on one of my machine: + a: All the generated RPMs can be relocated, meaning that you can override + the hard-coded root installation directory when using those RPMs for + installation. + b: You can check that the RPM is relocatable by using the command rpm -qip + thePackage.rpm. For example, from the cmake-2.8.3 package generated on + one of my machine: > rpm -qip cmake-2.8.3-darwinIntelGccDPOpt.i386.rpm| grep Relocations - Name : cmake Relocations: /Users/beaudoin/Projets/SAMH/OpenFOAM/ThirdParty-1.6-ext-RPM-based + Name : cmake + Relocations: /Users/beaudoin/Projets/SAMH/OpenFOAM/ThirdParty-1.6-ext-RPM-based - The Relocations path is the actual location pointed by the $WM_THIRD_PARTY_DIR on my laptop when I generated the RPM. - It is the indication that the RPM is relocatable - This path will turn to be hardcoded in the RPM because the environment variable was expanded before generating the RPM.. - This is the default root directory where the RPM will install its "payload" - This can be overridden using the 'rpm' command-line parameter --relocate OLDPATH=NEWPATH . + The Relocations path is the actual location pointed by the + $WM_THIRD_PARTY_DIR on my laptop when I generated the RPM. + It is the indication that the RPM is relocatable. This path will turn to + be hardcoded in the RPM because the environment variable was expanded + before generating the RPM. This is the default root directory where the + RPM will install its "payload". This can be overridden using the 'rpm' + command-line parameter --relocate OLDPATH=NEWPATH . - For example, let's say you want to install the RPM under the root directory /tmp/someDir instead, you will call the 'rpm' command like this: + For example, let's say you want to install the RPM under the root + directory /tmp/someDir instead, you will call the 'rpm' command like this: - rpm -ivh ./cmake-2.8.3-darwinIntelGccDPOpt.i386.rpm --relocate /Users/beaudoin/Projets/SAMH/OpenFOAM/ThirdParty-1.6-ext-RPM-based=/tmp/someDir + rpm -ivh ./cmake-2.8.3-darwinIntelGccDPOpt.i386.rpm \ + --relocate /Users/beaudoin/Projets/SAMH/OpenFOAM/ThirdParty-1.6-ext-RPM-based=/tmp/someDir - Even better, you can dig down the hard-coded path even deeper in order to relocate the whole installation directory, down to the last hard-coded subdirectory. + Even better, you can dig down the hard-coded path even deeper in order to + relocate the whole installation directory, down to the last hard-coded + subdirectory. Just specify the whole path when using the --relocate parameter - So basically, you can install the RPM right under /usr if you want, hence bypassing the default sequence of package subdirectories I have chosen in order to stay - close to the "traditional" ThirdParty layout. + So basically, you can install the RPM right under /usr if you want, hence + bypassing the default sequence of package subdirectories I have chosen in + order to stay close to the "traditional" ThirdParty layout. + +9: Using system installed package + It is possible to replace most of the ThirdParty packages by a system + installed version simply by activating some specific environment variables + in your file prefs.sh or prefs.csh. + + The files prefs.csh-EXAMPLE and prefs.sh-EXAMPLE provides a list of + environment variables you need to activate in order to use a system + installed version of a given package. + + For example, in order to use a system installed version of Scotch, here is + the list of environment variable you must declare in your etc/prefs.sh file + + # System installed Scotch + export SCOTCH_SYSTEM=1 + export SCOTCH_DIR=path_to_system_installed_scotch + export SCOTCH_BIN_DIR=$SCOTCH_DIR/bin + export SCOTCH_LIB_DIR=$SCOTCH_DIR/lib + export SCOTCH_INCLUDE_DIR=$SCOTCH_DIR/include + + When the XXXX_SYSTEM environment variable is activated for package XXXX, + the compilation and installation from the source tarball of the ThirdParty + package will be skipped. Just make sure all the necessary package specific + environment variables are properly initialized, and that the system + installed version of the package is compatible with the version made + available through the source tarball. -9: Things to do: - a: Testing testing testing. This prototype was tested on the following platforms: +10: Things to do: + a: Testing testing testing. This prototype was tested on the following + platforms: - Mac OS X 10.6 (Snow Leopard) (non RPM based) - Ubuntu 10.04 32bit (non RPM based) - Centos 5.5 64bit (RPM based) - OpenSUSE 11.3 64bit (RPM based) + Mac OS X 10.6 (Snow Leopard) (non RPM based) + Ubuntu 10.04 32bit (non RPM based) + Centos 5.5 64bit (RPM based) + OpenSUSE 11.3 64bit (RPM based) - b: Maybe adding some RPM dependencies might be useful. I have not explored this yet. + b: Maybe adding some RPM dependencies might be useful. I have not explored + this yet. To be continued... Martin Beaudoin -Novembre 2010 - \ No newline at end of file + +Last update: December 2010 + diff --git a/ThirdParty/rpmBuild/SPECS/ParMGridGen-1.0.spec b/ThirdParty/rpmBuild/SPECS/ParMGridGen-1.0.spec index bdc9f2949..1318f5e1f 100644 --- a/ThirdParty/rpmBuild/SPECS/ParMGridGen-1.0.spec +++ b/ThirdParty/rpmBuild/SPECS/ParMGridGen-1.0.spec @@ -121,11 +121,13 @@ cat << DOT_SH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.sh # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ export PARMGRIDGEN_DIR=\$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS +export PARMGRIDGEN_BIN_DIR=\$PARMGRIDGEN_DIR/bin +export PARMGRIDGEN_LIB_DIR=\$PARMGRIDGEN_DIR/lib +export PARMGRIDGEN_INCLUDE_DIR=\$PARMGRIDGEN_DIR/include -[ -d \$PARMGRIDGEN_DIR/lib ] && _foamAddLib \$PARMGRIDGEN_DIR/lib - -# Enable access to the package applications if present -[ -d \$PARMGRIDGEN_DIR/bin ] && _foamAddPath \$PARMGRIDGEN_DIR/bin +# Enable access to the runtime package applications and libraries +[ -d \$PARMGRIDGEN_BIN_DIR ] && _foamAddPath \$PARMGRIDGEN_BIN_DIR +[ -d \$PARMGRIDGEN_LIB_DIR ] && _foamAddLib \$PARMGRIDGEN_LIB_DIR DOT_SH_EOF # @@ -135,13 +137,16 @@ cat << DOT_CSH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.cs # Load %{name}-%{version} libraries and binaries if available # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ setenv PARMGRIDGEN_DIR \$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS +setenv PARMGRIDGEN_BIN_DIR \$PARMGRIDGEN_DIR/bin +setenv PARMGRIDGEN_LIB_DIR \$PARMGRIDGEN_DIR/lib +setenv PARMGRIDGEN_INCLUDE_DIR \$PARMGRIDGEN_DIR/include -if ( -e \$PARMGRIDGEN_DIR/lib ) then - _foamAddLib \$PARMGRIDGEN_DIR/lib +if ( -e \$PARMGRIDGEN_BIN_DIR ) then + _foamAddPath \$PARMGRIDGEN_BIN_DIR endif -if ( -e \$PARMGRIDGEN_DIR/bin ) then - _foamAddPath \$PARMGRIDGEN_DIR/bin +if ( -e \$PARMGRIDGEN_LIB_DIR ) then + _foamAddLib \$PARMGRIDGEN_LIB_DIR endif DOT_CSH_EOF diff --git a/ThirdParty/rpmBuild/SPECS/ParMetis-3.1.1.spec b/ThirdParty/rpmBuild/SPECS/ParMetis-3.1.1.spec index a1efd7a2e..3f8725bf0 100644 --- a/ThirdParty/rpmBuild/SPECS/ParMetis-3.1.1.spec +++ b/ThirdParty/rpmBuild/SPECS/ParMetis-3.1.1.spec @@ -127,11 +127,14 @@ cat << DOT_SH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.sh # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ export PARMETIS_DIR=\$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS +export PARMETIS_BIN_DIR=\$PARMETIS_DIR/bin +export PARMETIS_LIB_DIR=\$PARMETIS_DIR/lib +export PARMETIS_INCLUDE_DIR=\$PARMETIS_DIR/include -[ -d \$PARMETIS_DIR/lib ] && _foamAddLib \$PARMETIS_DIR/lib +# Enable access to the runtime package applications and libraries +[ -d \$PARMETIS_BIN_DIR ] && _foamAddPath \$PARMETIS_BIN_DIR +[ -d \$PARMETIS_LIB_DIR ] && _foamAddLib \$PARMETIS_LIB_DIR -# Enable access to the package applications if present -[ -d \$PARMETIS_DIR/bin ] && _foamAddPath \$PARMETIS_DIR/bin DOT_SH_EOF # @@ -141,13 +144,16 @@ cat << DOT_CSH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.cs # Load %{name}-%{version} libraries and binaries if available # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ setenv PARMETIS_DIR \$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS +setenv PARMETIS_BIN_DIR \$PARMETIS_DIR/bin +setenv PARMETIS_LIB_DIR \$PARMETIS_DIR/lib +setenv PARMETIS_INCLUDE_DIR \$PARMETIS_DIR/include -if ( -e \$PARMETIS_DIR/lib ) then - _foamAddLib \$PARMETIS_DIR/lib +if ( -e \$PARMETIS_BIN_DIR ) then + _foamAddPath \$PARMETIS_BIN_DIR endif -if ( -e \$PARMETIS_DIR/bin ) then - _foamAddPath \$PARMETIS_DIR/bin +if ( -e \$PARMETIS_LIB_DIR ) then + _foamAddLib \$PARMETIS_LIB_DIR endif DOT_CSH_EOF diff --git a/ThirdParty/rpmBuild/SPECS/ParaView-3.8.1.spec b/ThirdParty/rpmBuild/SPECS/ParaView-3.8.1.spec index 4c4378768..d2529e6d0 100644 --- a/ThirdParty/rpmBuild/SPECS/ParaView-3.8.1.spec +++ b/ThirdParty/rpmBuild/SPECS/ParaView-3.8.1.spec @@ -171,6 +171,16 @@ Patch0: ParaView-3.8.1.patch_darwin 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 @@ -188,6 +198,10 @@ cat << DOT_SH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.sh # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 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. @@ -197,15 +211,15 @@ export PARAVIEW_VERSION=%{version} # startup of paraview or even make paraview crash on startup. export PV_PLUGIN_PATH=\$FOAM_LIBBIN/paraview_plugins -[ -d \$PARAVIEW_DIR/lib/paraview-3.8 ] && _foamAddLib \$PARAVIEW_DIR/lib/paraview-3.8 +[ -d \$PARAVIEW_LIB_DIR/paraview-3.8 ] && _foamAddLib \$PARAVIEW_LIB_DIR/paraview-3.8 # Enable access to the package applications if present -[ -d \$PARAVIEW_DIR/bin ] && _foamAddPath \$PARAVIEW_DIR/bin +[ -d \$PARAVIEW_BIN_DIR ] && _foamAddPath \$PARAVIEW_BIN_DIR if [ "$WM_ARCH" == "darwinIntel" ] then # Additional binary path is running on Mac OS X - [ -d \$PARAVIEW_DIR/bin/paraview.app/Contents/MacOS ] && _foamAddPath \$PARAVIEW_DIR/bin/paraview.app/Contents/MacOS + [ -d \$PARAVIEW_BIN_DIR/paraview.app/Contents/MacOS ] && _foamAddPath \$PARAVIEW_BIN_DIR/paraview.app/Contents/MacOS fi DOT_SH_EOF @@ -216,6 +230,10 @@ cat << DOT_CSH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.cs # 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_INCLUDE_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. @@ -225,17 +243,18 @@ setenv PARAVIEW_VERSION %{version} # startup of paraview or even make paraview crash on startup. setenv PV_PLUGIN_PATH \$FOAM_LIBBIN/paraview_plugins -if ( -e \$PARAVIEW_DIR/lib/paraview-3.8 ) then - _foamAddLib \$PARAVIEW_DIR/lib/paraview-3.8 +if ( -e \$PARAVIEW_BIN_DIR ) then + _foamAddPath \$PARAVIEW_BIN_DIR endif -if ( -e \$PARAVIEW_DIR/bin ) then - _foamAddPath \$PARAVIEW_DIR/bin +if ( -e \$PARAVIEW_LIB_DIR/paraview-3.8 ) then + _foamAddLib \$PARAVIEW_LIB_DIR/paraview-3.8 endif + # Additional binary path is running on Mac OS X -if ( -e \$PARAVIEW_DIR/bin/paraview.app/Contents/MacOS ) then - _foamAddPath \$PARAVIEW_DIR/bin/paraview.app/Contents/MacOS +if ( -e \$PARAVIEW_BIN_DIR/paraview.app/Contents/MacOS ) then + _foamAddPath \$PARAVIEW_BIN_DIR/paraview.app/Contents/MacOS endif DOT_CSH_EOF diff --git a/ThirdParty/rpmBuild/SPECS/Python-2.7.spec b/ThirdParty/rpmBuild/SPECS/Python-2.7.spec index 2c0788cc2..64c658fe2 100644 --- a/ThirdParty/rpmBuild/SPECS/Python-2.7.spec +++ b/ThirdParty/rpmBuild/SPECS/Python-2.7.spec @@ -115,11 +115,10 @@ cat << DOT_SH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.sh # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ export PYTHON_DIR=\$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS +export PYTHON_BIN_DIR=\$PYTHON_DIR/bin -[ -d \$PYTHON_DIR/lib ] && _foamAddLib \$PYTHON_DIR/lib - -# Enable access to the package applications if present -[ -d \$PYTHON_DIR/bin ] && _foamAddPath \$PYTHON_DIR/bin +# Enable access to the runtime package applications +[ -d \$PYTHON_BIN_DIR ] && _foamAddPath \$PYTHON_BIN_DIR DOT_SH_EOF # @@ -129,13 +128,10 @@ cat << DOT_CSH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.cs # Load %{name}-%{version} libraries and binaries if available # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ setenv PYTHON_DIR \$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS +setenv PYTHON_BIN_DIR \$PYTHON_DIR/bin -if ( -e \$PYTHON_DIR/lib ) then - _foamAddLib \$PYTHON_DIR/lib -endif - -if ( -e \$PYTHON_DIR/bin ) then - _foamAddPath \$PYTHON_DIR/bin +if ( -e \$PYTHON_BIN_DIR ) then + _foamAddPath \$PYTHON_BIN_DIR endif DOT_CSH_EOF diff --git a/ThirdParty/rpmBuild/SPECS/cmake-2.8.3.spec b/ThirdParty/rpmBuild/SPECS/cmake-2.8.3.spec index 2cecb4164..938370925 100644 --- a/ThirdParty/rpmBuild/SPECS/cmake-2.8.3.spec +++ b/ThirdParty/rpmBuild/SPECS/cmake-2.8.3.spec @@ -115,11 +115,10 @@ cat << DOT_SH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.sh # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ export CMAKE_DIR=\$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS +export CMAKE_BIN_DIR=\$CMAKE_DIR/bin -[ -d \$CMAKE_DIR/lib ] && _foamAddLib \$CMAKE_DIR/lib - -# Enable access to the package applications if present -[ -d \$CMAKE_DIR/bin ] && _foamAddPath \$CMAKE_DIR/bin +# Enable access to the runtime package applications +[ -d \$CMAKE_BIN_DIR ] && _foamAddPath \$CMAKE_BIN_DIR DOT_SH_EOF # @@ -129,13 +128,10 @@ cat << DOT_CSH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.cs # 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_DIR/lib ) then - _foamAddLib \$CMAKE_DIR/lib -endif - -if ( -e \$CMAKE_DIR/bin ) then - _foamAddPath \$CMAKE_DIR/bin +if ( -e \$CMAKE_BIN_DIR ) then + _foamAddPath \$CMAKE_BIN_DIR endif DOT_CSH_EOF diff --git a/ThirdParty/rpmBuild/SPECS/mesquite-2.1.2.spec b/ThirdParty/rpmBuild/SPECS/mesquite-2.1.2.spec index df833cf44..970fe791f 100644 --- a/ThirdParty/rpmBuild/SPECS/mesquite-2.1.2.spec +++ b/ThirdParty/rpmBuild/SPECS/mesquite-2.1.2.spec @@ -127,11 +127,13 @@ cat << DOT_SH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.sh # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ export MESQUITE_DIR=\$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS +export MESQUITE_BIN_DIR=\$MESQUITE_DIR/bin +export MESQUITE_LIB_DIR=\$MESQUITE_DIR/lib +export MESQUITE_INCLUDE_DIR=\$MESQUITE_DIR/include -[ -d \$MESQUITE_DIR/lib ] && _foamAddLib \$MESQUITE_DIR/lib - -# Enable access to the package applications if present -[ -d \$MESQUITE_DIR/bin ] && _foamAddPath \$MESQUITE_DIR/bin +# Enable access to the package runtime applications and libraries +[ -d \$MESQUITE_BIN_DIR ] && _foamAddPath \$MESQUITE_BIN_DIR +[ -d \$MESQUITE_LIB_DIR ] && _foamAddLib \$MESQUITE_LIB_DIR DOT_SH_EOF # @@ -141,13 +143,16 @@ cat << DOT_CSH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.cs # Load %{name}-%{version} libraries and binaries if available # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ setenv MESQUITE_DIR \$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS +setenv MESQUITE_BIN_DIR \$MESQUITE_DIR/bin +setenv MESQUITE_LIB_DIR \$MESQUITE_DIR/lib +setenv MESQUITE_INCLUDE_DIR \$MESQUITE_DIR/include -if ( -e \$MESQUITE_DIR/lib ) then - _foamAddLib \$MESQUITE_DIR/lib +if ( -e \$MESQUITE_BIN_DIR ) then + _foamAddPath \$MESQUITE_BIN_DIR endif -if ( -e \$MESQUITE_DIR/bin ) then - _foamAddPath \$MESQUITE_DIR/bin +if ( -e \$MESQUITE_LIB_DIR ) then + _foamAddLib \$MESQUITE_LIB_DIR endif DOT_CSH_EOF diff --git a/ThirdParty/rpmBuild/SPECS/metis-5.0pre2.spec b/ThirdParty/rpmBuild/SPECS/metis-5.0pre2.spec index 7ed9f0b5a..e78cf14be 100644 --- a/ThirdParty/rpmBuild/SPECS/metis-5.0pre2.spec +++ b/ThirdParty/rpmBuild/SPECS/metis-5.0pre2.spec @@ -128,11 +128,14 @@ cat << DOT_SH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.sh # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ export METIS_DIR=\$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS +export METIS_BIN_DIR=\$METIS_DIR/bin +export METIS_LIB_DIR=\$METIS_DIR/lib +export METIS_INCLUDE_DIR=\$METIS_DIR/include -[ -d \$METIS_DIR/lib ] && _foamAddLib \$METIS_DIR/lib +# Enable access to the package runtime applications and libraries +[ -d \$METIS_BIN_DIR ] && _foamAddPath \$METIS_BIN_DIR +[ -d \$METIS_LIB_DIR ] && _foamAddLib \$METIS_LIB_DIR -# Enable access to the package applications if present -[ -d \$METIS_DIR/bin ] && _foamAddPath \$METIS_DIR/bin DOT_SH_EOF # @@ -142,13 +145,16 @@ cat << DOT_CSH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.cs # Load %{name}-%{version} libraries and binaries if available # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ setenv METIS_DIR \$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS +setenv METIS_BIN_DIR \$METIS_DIR/bin +setenv METIS_LIB_DIR \$METIS_DIR/lib +setenv METIS_INCLUDE_DIR \$METIS_DIR/include -if ( -e \$METIS_DIR/lib ) then - _foamAddLib \$METIS_DIR/lib +if ( -e \$METIS_BIN_DIR ) then + _foamAddPath \$METIS_BIN_DIR endif -if ( -e \$METIS_DIR/bin ) then - _foamAddPath \$METIS_DIR/bin +if ( -e \$METIS_LIB_DIR ) then + _foamAddLib \$METIS_LIB_DIR endif DOT_CSH_EOF diff --git a/ThirdParty/rpmBuild/SPECS/openmpi-1.4.3.spec b/ThirdParty/rpmBuild/SPECS/openmpi-1.4.3.spec index f6fed128b..14504a918 100644 --- a/ThirdParty/rpmBuild/SPECS/openmpi-1.4.3.spec +++ b/ThirdParty/rpmBuild/SPECS/openmpi-1.4.3.spec @@ -134,32 +134,94 @@ Group: Development/Tools # 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 +# Load %{name}-%{version} libraries and binaries # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +export OPENMPI_DIR=\$WM_THIRD_PARTY_DIR/packages/openmpi-1.4.3/platforms/\$WM_OPTIONS +export OPENMPI_BIN_DIR=\$OPENMPI_DIR/bin +export OPENMPI_LIB_DIR=\$OPENMPI_DIR/lib -export OPENMPI_DIR=\$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS +# Enable access to the package runtime applications and libraries +[ -d \$OPENMPI_BIN_DIR ] && _foamAddPath \$OPENMPI_BIN_DIR +[ -d \$OPENMPI_LIB_DIR ] && _foamAddLib \$OPENMPI_LIB_DIR -[ -d \$OPENMPI_DIR/lib ] && _foamAddLib \$OPENMPI_DIR/lib +export MPI_HOME=\$OPENMPI_DIR +export MPI_ARCH_PATH=\$MPI_HOME +export OPAL_PREFIX=\$MPI_ARCH_PATH -# Enable access to the package applications if present -[ -d \$OPENMPI_DIR/bin ] && _foamAddPath \$OPENMPI_DIR/bin +# We initialize the rest of the environment using mpicc --showme: +export OPENMPI_INCLUDE_DIR="\`mpicc --showme:incdirs\`" +export OPENMPI_COMPILE_FLAGS="\`mpicc --showme:compile\`" +export OPENMPI_LINK_FLAGS="\`mpicc --showme:link\`" + +# Set the OpenFOAM compilation flags +export PINC=\$OPENMPI_COMPILE_FLAGS +export PLIBS=\$OPENMPI_LINK_FLAGS + + +if [ "\$FOAM_VERBOSE" -a "\$PS1" ] +then + echo "Using system installed OpenMPI:" + echo " OPENMPI_BIN_DIR : \$OPENMPI_BIN_DIR" + echo " OPENMPI_LIB_DIR : \$OPENMPI_LIB_DIR" + echo " OPENMPI_INCLUDE_DIR : \$OPENMPI_INCLUDE_DIR" + echo " OPENMPI_COMPILE_FLAGS : \$OPENMPI_COMPILE_FLAGS" + echo " OPENMPI_LINK_FLAGS : \$OPENMPI_LINK_FLAGS" + echo "" + echo " MPI_HOME : \$MPI_HOME" + echo " MPI_ARCH_PATH : \$MPI_ARCH_PATH" + echo " OPAL_PREFIX : \$OPAL_PREFIX" + echo " PINC : \$PINC" + echo " PLIBS : \$PLIBS" +fi 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 -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# Load %{name}-%{version} libraries and binaries +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ setenv OPENMPI_DIR \$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS +setenv OPENMPI_BIN_DIR \$OPENMPI_DIR/bin +setenv OPENMPI_LIB_DIR \$OPENMPI_DIR/lib -if ( -e \$OPENMPI_DIR/lib ) then - _foamAddLib \$OPENMPI_DIR/lib +# Enable access to the package runtime applications and libraries +if ( -e \$OPENMPI_BIN_DIR ) then + _foamAddPath \$OPENMPI_BIN_DIR endif -if ( -e \$OPENMPI_DIR/bin ) then - _foamAddPath \$OPENMPI_DIR/bin +if ( -e \$OPENMPI_LIB_DIR ) then + _foamAddLib \$OPENMPI_LIB_DIR endif + +setenv MPI_HOME \$OPENMPI_DIR +setenv MPI_ARCH_PATH \$MPI_HOME +setenv OPAL_PREFIX \$MPI_ARCH_PATH + +# We initialize the rest of the environment using mpicc --showme: +setenv OPENMPI_INCLUDE_DIR "\`mpicc --showme:incdirs\`" +setenv OPENMPI_COMPILE_FLAGS "\`mpicc --showme:compile\`" +setenv OPENMPI_LINK_FLAGS "\`mpicc --showme:link\`" + +# Set the OpenFOAM compilation flags +setenv PINC \$OPENMPI_COMPILE_FLAGS +setenv PLIBS \$OPENMPI_LINK_FLAGS + + +if (\$?FOAM_VERBOSE && \$?prompt) then + echo "Using system installed OpenMPI:" + echo " OPENMPI_BIN_DIR : \$OPENMPI_BIN_DIR" + echo " OPENMPI_LIB_DIR : \$OPENMPI_LIB_DIR" + echo " OPENMPI_INCLUDE_DIR : \$OPENMPI_INCLUDE_DIR" + echo " OPENMPI_COMPILE_FLAGS : \$OPENMPI_COMPILE_FLAGS" + echo " OPENMPI_LINK_FLAGS : \$OPENMPI_LINK_FLAGS" + echo "" + echo " MPI_HOME : \$MPI_HOME" + echo " MPI_ARCH_PATH : \$MPI_ARCH_PATH" + echo " OPAL_PREFIX : \$OPAL_PREFIX" + echo " PINC : \$PINC" + echo " PLIBS : \$PLIBS" +fi DOT_CSH_EOF %clean diff --git a/ThirdParty/rpmBuild/SPECS/openmpi-1.5.spec b/ThirdParty/rpmBuild/SPECS/openmpi-1.5.spec index fe6ddfcea..08011a693 100644 --- a/ThirdParty/rpmBuild/SPECS/openmpi-1.5.spec +++ b/ThirdParty/rpmBuild/SPECS/openmpi-1.5.spec @@ -134,32 +134,94 @@ Group: Development/Tools # 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 +# Load %{name}-%{version} libraries and binaries # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +export OPENMPI_DIR=\$WM_THIRD_PARTY_DIR/packages/openmpi-1.5/platforms/\$WM_OPTIONS +export OPENMPI_BIN_DIR=\$OPENMPI_DIR/bin +export OPENMPI_LIB_DIR=\$OPENMPI_DIR/lib -export OPENMPI_DIR=\$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS +# Enable access to the package runtime applications and libraries +[ -d \$OPENMPI_BIN_DIR ] && _foamAddPath \$OPENMPI_BIN_DIR +[ -d \$OPENMPI_LIB_DIR ] && _foamAddLib \$OPENMPI_LIB_DIR -[ -d \$OPENMPI_DIR/lib ] && _foamAddLib \$OPENMPI_DIR/lib +export MPI_HOME=\$OPENMPI_DIR +export MPI_ARCH_PATH=\$MPI_HOME +export OPAL_PREFIX=\$MPI_ARCH_PATH -# Enable access to the package applications if present -[ -d \$OPENMPI_DIR/bin ] && _foamAddPath \$OPENMPI_DIR/bin +# We initialize the rest of the environment using mpicc --showme: +export OPENMPI_INCLUDE_DIR="\`mpicc --showme:incdirs\`" +export OPENMPI_COMPILE_FLAGS="\`mpicc --showme:compile\`" +export OPENMPI_LINK_FLAGS="\`mpicc --showme:link\`" + +# Set the OpenFOAM compilation flags +export PINC=\$OPENMPI_COMPILE_FLAGS +export PLIBS=\$OPENMPI_LINK_FLAGS + + +if [ "\$FOAM_VERBOSE" -a "\$PS1" ] +then + echo "Using system installed OpenMPI:" + echo " OPENMPI_BIN_DIR : \$OPENMPI_BIN_DIR" + echo " OPENMPI_LIB_DIR : \$OPENMPI_LIB_DIR" + echo " OPENMPI_INCLUDE_DIR : \$OPENMPI_INCLUDE_DIR" + echo " OPENMPI_COMPILE_FLAGS : \$OPENMPI_COMPILE_FLAGS" + echo " OPENMPI_LINK_FLAGS : \$OPENMPI_LINK_FLAGS" + echo "" + echo " MPI_HOME : \$MPI_HOME" + echo " MPI_ARCH_PATH : \$MPI_ARCH_PATH" + echo " OPAL_PREFIX : \$OPAL_PREFIX" + echo " PINC : \$PINC" + echo " PLIBS : \$PLIBS" +fi 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 -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# Load %{name}-%{version} libraries and binaries +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ setenv OPENMPI_DIR \$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS +setenv OPENMPI_BIN_DIR \$OPENMPI_DIR/bin +setenv OPENMPI_LIB_DIR \$OPENMPI_DIR/lib -if ( -e \$OPENMPI_DIR/lib ) then - _foamAddLib \$OPENMPI_DIR/lib +# Enable access to the package runtime applications and libraries +if ( -e \$OPENMPI_BIN_DIR ) then + _foamAddPath \$OPENMPI_BIN_DIR endif -if ( -e \$OPENMPI_DIR/bin ) then - _foamAddPath \$OPENMPI_DIR/bin +if ( -e \$OPENMPI_LIB_DIR ) then + _foamAddLib \$OPENMPI_LIB_DIR endif + +setenv MPI_HOME \$OPENMPI_DIR +setenv MPI_ARCH_PATH \$MPI_HOME +setenv OPAL_PREFIX \$MPI_ARCH_PATH + +# We initialize the rest of the environment using mpicc --showme: +setenv OPENMPI_INCLUDE_DIR "\`mpicc --showme:incdirs\`" +setenv OPENMPI_COMPILE_FLAGS "\`mpicc --showme:compile\`" +setenv OPENMPI_LINK_FLAGS "\`mpicc --showme:link\`" + +# Set the OpenFOAM compilation flags +setenv PINC \$OPENMPI_COMPILE_FLAGS +setenv PLIBS \$OPENMPI_LINK_FLAGS + + +if (\$?FOAM_VERBOSE && \$?prompt) then + echo "Using system installed OpenMPI:" + echo " OPENMPI_BIN_DIR : \$OPENMPI_BIN_DIR" + echo " OPENMPI_LIB_DIR : \$OPENMPI_LIB_DIR" + echo " OPENMPI_INCLUDE_DIR : \$OPENMPI_INCLUDE_DIR" + echo " OPENMPI_COMPILE_FLAGS : \$OPENMPI_COMPILE_FLAGS" + echo " OPENMPI_LINK_FLAGS : \$OPENMPI_LINK_FLAGS" + echo "" + echo " MPI_HOME : \$MPI_HOME" + echo " MPI_ARCH_PATH : \$MPI_ARCH_PATH" + echo " OPAL_PREFIX : \$OPAL_PREFIX" + echo " PINC : \$PINC" + echo " PLIBS : \$PLIBS" +fi DOT_CSH_EOF %clean diff --git a/ThirdParty/rpmBuild/SPECS/qt-everywhere-opensource-src-4.7.0.spec b/ThirdParty/rpmBuild/SPECS/qt-everywhere-opensource-src-4.7.0.spec index 3e7ff82fd..c4082ca97 100644 --- a/ThirdParty/rpmBuild/SPECS/qt-everywhere-opensource-src-4.7.0.spec +++ b/ThirdParty/rpmBuild/SPECS/qt-everywhere-opensource-src-4.7.0.spec @@ -120,11 +120,10 @@ 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 -[ -d \$QT_DIR/lib ] && _foamAddLib \$QT_DIR/lib - -# Enable access to the package applications if present -[ -d \$QT_DIR/bin ] && _foamAddPath \$QT_DIR/bin +# Enable access to the runtime package applications +[ -d \$QT_BIN_DIR ] && _foamAddPath \$QT_BIN_DIR DOT_SH_EOF # @@ -134,13 +133,10 @@ cat << DOT_CSH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.cs # 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_DIR/lib ) then - _foamAddLib \$QT_DIR/lib -endif - -if ( -e \$QT_DIR/bin ) then - _foamAddPath \$QT_DIR/bin +if ( -e \$QT_BIN_DIR ) then + _foamAddPath \$QT_BIN_DIR endif DOT_CSH_EOF diff --git a/ThirdParty/rpmBuild/SPECS/scotch-5.1.10b.spec b/ThirdParty/rpmBuild/SPECS/scotch-5.1.10b.spec index ac0bc5978..fb7215e32 100644 --- a/ThirdParty/rpmBuild/SPECS/scotch-5.1.10b.spec +++ b/ThirdParty/rpmBuild/SPECS/scotch-5.1.10b.spec @@ -125,11 +125,13 @@ cat << DOT_SH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.sh # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ export SCOTCH_DIR=\$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS +export SCOTCH_BIN_DIR=\$SCOTCH_DIR/bin +export SCOTCH_LIB_DIR=\$SCOTCH_DIR/lib +export SCOTCH_INCLUDE_DIR=\$SCOTCH_DIR/include -[ -d \$SCOTCH_DIR/lib ] && _foamAddLib \$SCOTCH_DIR/lib - -# Enable access to the package applications if present -[ -d \$SCOTCH_DIR/bin ] && _foamAddPath \$SCOTCH_DIR/bin +# Enable access to the runtime package applications and libraries +[ -d \$SCOTCH_BIN_DIR ] && _foamAddPath \$SCOTCH_BIN_DIR +[ -d \$SCOTCH_LIB_DIR ] && _foamAddLib \$SCOTCH_LIB_DIR DOT_SH_EOF # @@ -139,13 +141,16 @@ cat << DOT_CSH_EOF > $RPM_BUILD_ROOT/%{_installPrefix}/etc/%{name}-%{version}.cs # Load %{name}-%{version} libraries and binaries if available # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ setenv SCOTCH_DIR \$WM_THIRD_PARTY_DIR/packages/%{name}-%{version}/platforms/\$WM_OPTIONS +setenv SCOTCH_BIN_DIR \$SCOTCH_DIR/bin +setenv SCOTCH_LIB_DIR \$SCOTCH_DIR/lib +setenv SCOTCH_INCLUDE_DIR \$SCOTCH_DIR/include -if ( -e \$SCOTCH_DIR/lib ) then - _foamAddLib \$SCOTCH_DIR/lib +if ( -e \$SCOTCH_BIN_DIR ) then + _foamAddPath \$SCOTCH_BIN_DIR endif -if ( -e \$SCOTCH_DIR/bin ) then - _foamAddPath \$SCOTCH_DIR/bin +if ( -e \$SCOTCH_LIB_DIR ) then + _foamAddLib \$SCOTCH_LIB_DIR endif DOT_CSH_EOF diff --git a/applications/utilities/postProcessing/graphics/PV3FoamReader/Allwmake b/applications/utilities/postProcessing/graphics/PV3FoamReader/Allwmake index dc8b46881..043bdaec4 100755 --- a/applications/utilities/postProcessing/graphics/PV3FoamReader/Allwmake +++ b/applications/utilities/postProcessing/graphics/PV3FoamReader/Allwmake @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash cd ${0%/*} || exit 1 # run from this directory set -x diff --git a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/Make/options b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/Make/options index bc47fcae6..8f901900b 100644 --- a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/Make/options +++ b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/Make/options @@ -2,7 +2,7 @@ EXE_INC = \ -I$(LIB_SRC)/finiteVolume/lnInclude \ -I$(LIB_SRC)/lagrangian/basic/lnInclude \ -I$(LIB_SRC)/meshTools/lnInclude \ - -I$(PARAVIEW_DIR)/include/paraview-3.8 \ + -I$(PARAVIEW_INCLUDE_DIR)/paraview-3.8 \ -I../PV3FoamReader LIB_LIBS = \ diff --git a/etc/cshrc b/etc/cshrc index ae0a4f792..1d328d656 100644 --- a/etc/cshrc +++ b/etc/cshrc @@ -117,7 +117,7 @@ setenv WM_COMPILER_LIB_ARCH # Compilation options (architecture, precision, optimised, debug or profiling) # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -setenv WM_NCOMPPROCS 8 +setenv WM_NCOMPPROCS 2 # WM_ARCH_OPTION = 32 | 64 if ( ! $?WM_ARCH_OPTION ) setenv WM_ARCH_OPTION 64 diff --git a/etc/prefs.csh-EXAMPLE b/etc/prefs.csh-EXAMPLE index 6222054e2..e0b063355 100644 --- a/etc/prefs.csh-EXAMPLE +++ b/etc/prefs.csh-EXAMPLE @@ -40,13 +40,91 @@ ## ~~~~~~~~~~~~~~~~~~~~~~~ #set compilerInstall=system -## Specify system openmpi -## ~~~~~~~~~~~~~~~~~~~~~~ +# Specify system openmpi +# ~~~~~~~~~~~~~~~~~~~~~~ +# +# Normally, you don't need to set more than these 3 env. variables +# The other openmpi related variables will be initialized using +# the command mpicc --showme: +# #setenv WM_MPLIB SYSTEMOPENMPI +#setenv OPENMPI_DIR path_to_system_installed_openmpi +#setenv OPENMPI_BIN_DIR $OPENMPI_DIR/bin +# +#setenv OPENMPI_LIB_DIR "`$OPENMPI_BIN_DIR/mpicc --showme:libdirs`" +#setenv OPENMPI_INCLUDE_DIR "`$OPENMPI_BIN_DIR/mpicc --showme:incdirs`" +#setenv OPENMPI_COMPILE_FLAGS "`$OPENMPI_BIN_DIR/mpicc --showme:compile`" +#setenv OPENMPI_LINK_FLAGS "`$OPENMPI_BIN_DIR/mpicc --showme:link`" + +# Specify system installed ThirdParty packages/libraries +# NB: The packages installed under $WM_THIRD_PARTY_DIR +# will always override these values. +# So build your ThirdParty directory accordingly. +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# System installed Mesquite +#setenv MESQUITE_SYSTEM 1 +#setenv MESQUITE_DIR path_to_system_installed_mesquite +#setenv MESQUITE_BIN_DIR $MESQUITE_DIR/bin +#setenv MESQUITE_LIB_DIR $MESQUITE_DIR/lib +#setenv MESQUITE_INCLUDE_DIR $MESQUITE_DIR/include + +# System installed Metis +#setenv METIS_SYSTEM 1 +#setenv METIS_DIR path_to_system_installed_metis +#setenv METIS_BIN_DIR $METIS_DIR/bin +#setenv METIS_LIB_DIR $METIS_DIR/lib +#setenv METIS_INCLUDE_DIR $METIS_DIR/include + +# System installed ParMetis +#setenv PARMETIS_SYSTEM 1 +#setenv PARMETIS_DIR path_to_system_installed_parmetis +#setenv PARMETIS_BIN_DIR $PARMETIS_DIR/bin +#setenv PARMETIS_LIB_DIR $PARMETIS_DIR/lib +#setenv PARMETIS_INCLUDE_DIR $PARMETIS_DIR/include + +# System installed ParMGridgen +#setenv PARMGRIDGEN_SYSTEM 1 +#setenv PARMGRIDGEN_DIR path_to_system_installed_parmgridgen +#setenv PARMGRIDGEN_BIN_DIR $PARMGRIDGEN_DIR/bin +#setenv PARMGRIDGEN_LIB_DIR $PARMGRIDGEN_DIR/lib +#setenv PARMGRIDGEN_INCLUDE_DIR $PARMGRIDGEN_DIR/include + +# System installed Scotch +#setenv SCOTCH_SYSTEM 1 +#setenv SCOTCH_DIR path_to_system_installed_scotch +#setenv SCOTCH_BIN_DIR $SCOTCH_DIR/bin +#setenv SCOTCH_LIB_DIR $SCOTCH_DIR/lib +#setenv SCOTCH_INCLUDE_DIR $SCOTCH_DIR/include + +# System installed CMake +#setenv CMAKE_SYSTEM 1 +#setenv CMAKE_DIR path_to_system_installed_cmake +#setenv CMAKE_BIN_DIR $CMAKE_DIR/bin + +# System installed Python +#setenv PYTHON_SYSTEM 1 +#setenv PYTHON_DIR path_to_system_installed_python +#setenv PYTHON_BIN_DIR $PYTHON_DIR/bin + +# System installed Qt +# This is the only package we assume is system installed by default. +# So we don't use a variable called QT_SYSTEM, but instead a variable +# called QT_THIRD_PARTY in order to override to the ThirdParty QT +# package. +#setenv QT_THIRD_PARTY 1 +#setenv QT_DIR path_to_system_installed_qt +#setenv QT_BIN_DIR $QT_DIR/bin + +# System installed ParaView +#setenv PARAVIEW_SYSTEM 1 +#setenv PARAVIEW_DIR path_to_system_installed_paraview +#setenv PARAVIEW_BIN_DIR $PARAVIEW_DIR/bin + # Specify ParaView version # ~~~~~~~~~~~~~~~~~~~~~~~~ -setenv ParaView_VERSION git # eg, cvs/git version -setenv ParaView_MAJOR 3.7 +#setenv ParaView_VERSION git # eg, cvs/git version +#setenv ParaView_MAJOR 3.7 # ----------------------------------------------------------------- end-of-file diff --git a/etc/prefs.sh-EXAMPLE b/etc/prefs.sh-EXAMPLE index 598c5710c..e2a65814f 100644 --- a/etc/prefs.sh-EXAMPLE +++ b/etc/prefs.sh-EXAMPLE @@ -36,17 +36,96 @@ # #------------------------------------------------------------------------------ +export FOAM_VERBOSE=1 + # Specify system compiler # ~~~~~~~~~~~~~~~~~~~~~~~ compilerInstall=system # Specify system openmpi # ~~~~~~~~~~~~~~~~~~~~~~ -export WM_MPLIB=SYSTEMOPENMPI +# +# Normally, you don't need to set more than these 3 env. variables +# The other openmpi related variables will be initialized using +# the command mpicc --showme: +# +#export WM_MPLIB=SYSTEMOPENMPI +#export OPENMPI_DIR=path_to_system_installed_openmpi +#export OPENMPI_BIN_DIR=$OPENMPI_DIR/bin +# +#export OPENMPI_LIB_DIR="`$OPENMPI_BIN_DIR/mpicc --showme:libdirs`" +#export OPENMPI_INCLUDE_DIR="`$OPENMPI_BIN_DIR/mpicc --showme:incdirs`" +#export OPENMPI_COMPILE_FLAGS="`$OPENMPI_BIN_DIR/mpicc --showme:compile`" +#export OPENMPI_LINK_FLAGS="`$OPENMPI_BIN_DIR/mpicc --showme:link`" + +# Specify system installed ThirdParty packages/libraries +# NB: The packages installed under $WM_THIRD_PARTY_DIR +# will always override these values. +# So build your ThirdParty directory accordingly. +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# System installed Mesquite +#export MESQUITE_SYSTEM=1 +#export MESQUITE_DIR=path_to_system_installed_mesquite +#export MESQUITE_BIN_DIR=$MESQUITE_DIR/bin +#export MESQUITE_LIB_DIR=$MESQUITE_DIR/lib +#export MESQUITE_INCLUDE_DIR=$MESQUITE_DIR/include + +# System installed Metis +#export METIS_SYSTEM=1 +#export METIS_DIR=path_to_system_installed_metis +#export METIS_BIN_DIR=$METIS_DIR/bin +#export METIS_LIB_DIR=$METIS_DIR/lib +#export METIS_INCLUDE_DIR=$METIS_DIR/include + +# System installed ParMetis +#export PARMETIS_SYSTEM=1 +#export PARMETIS_DIR=path_to_system_installed_parmetis +#export PARMETIS_BIN_DIR=$PARMETIS_DIR/bin +#export PARMETIS_LIB_DIR=$PARMETIS_DIR/lib +#export PARMETIS_INCLUDE_DIR=$PARMETIS_DIR/include + +# System installed ParMGridgen +#export PARMGRIDGEN_SYSTEM=1 +#export PARMGRIDGEN_DIR=path_to_system_installed_parmgridgen +#export PARMGRIDGEN_BIN_DIR=$PARMGRIDGEN_DIR/bin +#export PARMGRIDGEN_LIB_DIR=$PARMGRIDGEN_DIR/lib +#export PARMGRIDGEN_INCLUDE_DIR=$PARMGRIDGEN_DIR/include + +# System installed Scotch +#export SCOTCH_SYSTEM=1 +#export SCOTCH_DIR=path_to_system_installed_scotch +#export SCOTCH_BIN_DIR=$SCOTCH_DIR/bin +#export SCOTCH_LIB_DIR=$SCOTCH_DIR/lib +#export SCOTCH_INCLUDE_DIR=$SCOTCH_DIR/include + +# System installed CMake +#export CMAKE_SYSTEM=1 +#export CMAKE_DIR=path_to_system_installed_cmake +#export CMAKE_BIN_DIR=$CMAKE_DIR/bin + +# System installed Python +#export PYTHON_SYSTEM=1 +#export PYTHON_DIR=path_to_system_installed_python +#export PYTHON_BIN_DIR=$PYTHON_DIR/bin + +# System installed Qt +# This is the only package we assume is system installed by default. +# So we don't use a variable called QT_SYSTEM, but instead a variable +# called QT_THIRD_PARTY in order to override to the ThirdParty QT +# package. +#export QT_THIRD_PARTY=1 +#export QT_DIR=path_to_system_installed_qt +#export QT_BIN_DIR=$QT_DIR/bin + +# System installed ParaView +#export PARAVIEW_SYSTEM=1 +#export PARAVIEW_DIR=path_to_system_installed_paraview +#export PARAVIEW_BIN_DIR=$PARAVIEW_DIR/bin # Specify ParaView version # ~~~~~~~~~~~~~~~~~~~~~~~~ -export ParaView_VERSION=git # eg, cvs/git version -export ParaView_MAJOR=3.7 +#export ParaView_VERSION=git # eg, cvs/git version +#export ParaView_MAJOR=3.7 # ----------------------------------------------------------------- end-of-file diff --git a/etc/settings.csh b/etc/settings.csh index dfcda917b..7b4de6aac 100644 --- a/etc/settings.csh +++ b/etc/settings.csh @@ -144,52 +144,122 @@ unset MPI_ARCH_PATH switch ("$WM_MPLIB") case OPENMPI: - if (-e $WM_THIRD_PARTY_DIR/packages/openmpi-1.4.3 ) then + if (-d $WM_THIRD_PARTY_DIR/packages/openmpi-1.4.3 ) then set mpi_version=openmpi-1.4.3 + + if ($?FOAM_VERBOSE && $?prompt) then + echo "Using openmpi-1.4.3 from the ThirdParty package: $WM_THIRD_PARTY_DIR/packages/$mpi_version" + endif _foamSource $WM_THIRD_PARTY_DIR/packages/$mpi_version/platforms/$WM_OPTIONS/etc/$mpi_version.csh - setenv MPI_HOME $WM_THIRD_PARTY_DIR/packages/$mpi_version/platforms/$WM_OPTIONS - setenv MPI_ARCH_PATH $MPI_HOME + else if (-d $WM_THIRD_PARTY_DIR/packages/openmpi-1.5 ) then + set mpi_version=openmpi-1.5 - # Tell OpenMPI where to find its install directory - setenv OPAL_PREFIX $MPI_ARCH_PATH - else - set mpi_version=openmpi-1.5 - setenv MPI_HOME $WM_THIRD_PARTY_DIR/$mpi_version - setenv MPI_ARCH_PATH $MPI_HOME/platforms/$WM_OPTIONS - - # Tell OpenMPI where to find its install directory - setenv OPAL_PREFIX $MPI_ARCH_PATH - - _foamAddPath $MPI_ARCH_PATH/bin - _foamAddLib $MPI_ARCH_PATH/lib + if ($?FOAM_VERBOSE && $?prompt) then + echo "Using openmpi-1.5 from the ThirdParty package: $WM_THIRD_PARTY_DIR/packages/$mpi_version" + endif + _foamSource $WM_THIRD_PARTY_DIR/packages/$mpi_version/platforms/$WM_OPTIONS/etc/$mpi_version.csh endif + setenv FOAM_MPI_LIBBIN $FOAM_LIBBIN/$mpi_version unset mpi_version breaksw case SYSTEMOPENMPI: - - # This uses the installed openmpi. It needs mpicc installed! - set mpi_version=openmpi-system - # Set compilation flags here instead of in wmake/rules/../mplibSYSTEMOPENMPI - setenv PINC `mpicc --showme:compile` - setenv PLIBS `mpicc --showme:link` - set libDir=`echo "$PLIBS" | sed -e 's/.*-L\([^ ]*\).*/\1/'` + # make sure not the "old" mpi is used + # Not sure if this is necessary anymore. + # export OPAL_PREFIX= - if ($?FOAM_VERBOSE && $?prompt) then - echo "Using system installed MPI:" - echo " compile flags : $PINC" - echo " link flags : $PLIBS" - echo " libmpi dir : $libDir" + # Make sure OPENMPI_BIN_DIR is set and valid + if ($?OPENMPI_BIN_DIR != 0 ) then + if (-d "${OPENMPI_BIN_DIR}" ) then + # User defined value specified for OPENMPI_BIN_DIR + # + # WARNING: + # We assume this path specified by $OPENMPI_BIN_DIR is valid + # We assume the command mpicc is located somewhere under this path + # We assume the file mpi.h is located somewhere under this path + # + # Otherwise, please double check your openmpi installation, you are + # probably missing the openmpi runtime and/or development packages + # available for your system. + # + _foamAddPath $OPENMPI_BIN_DIR + endif + else + # Here, we assume your environment is already set for running + # and developping with openmpi. + # + # Initialize OPENMPI_BIN_DIR using the path to mpicc + set mpicc_cmd=`which mpicc` + setenv OPENMPI_BIN_DIR `dirname $mpicc_cmd` + unset mpicc_cmd endif - _foamAddLib $libDir + # Make sure OPENMPI_LIB_DIR is set + if ( $?OPENMPI_LIB_DIR == 0 ) then + # Initialize OPENMPI_LIB_DIR using the path to mpicc + setenv OPENMPI_LIB_DIR "`mpicc --showme:libdirs`" + endif + + # Make sure the dynamic libraries are accessible + if( $?OPENMPI_LIB_DIR != 0 ) then + _foamAddLib $OPENMPI_LIB_DIR + endif + + setenv MPI_HOME `dirname $OPENMPI_BIN_DIR` + setenv MPI_ARCH_PATH $MPI_HOME + setenv OPAL_PREFIX $MPI_ARCH_PATH + + # We initialize the rest of the environment using mpicc --showme: + if ($?OPENMPI_INCLUDE_DIR == 0) then + setenv OPENMPI_INCLUDE_DIR "`mpicc --showme:incdirs`" + endif + + if (${?OPENMPI_COMPILE_FLAGS} == 0) then + setenv OPENMPI_COMPILE_FLAGS "`mpicc --showme:compile`" + endif + + if (${?OPENMPI_COMPILE_FLAGS} == 0) then + setenv OPENMPI_COMPILE_FLAGS "`mpicc --showme:compile`" + endif + + if (${?OPENMPI_LINK_FLAGS} == 0) then + setenv OPENMPI_LINK_FLAGS "`mpicc --showme:link`" + endif + + # + # WARNING: We assume the file mpi.h will be available under the directories identified + # by the variable $OPENMPI_INCLUDE_DIR. Otherwise, please double check your + # system openmpi installation. + + # Set compilation flags here instead of in wmake/rules/../mplibSYSTEMOPENMPI + setenv PINC "$OPENMPI_COMPILE_FLAGS" + setenv PLIBS "$OPENMPI_LINK_FLAGS" + + # No longer needed, but we keep this as a reference, just in case... + #libDir `echo "$PLIBS" | sed -e 's/.*-L\([^ ]*\).*/\1/'` + #_foamAddLib $libDir + + if ($?FOAM_VERBOSE && $?prompt) then + echo "Using system installed OpenMPI:" + echo " OPENMPI_BIN_DIR : $OPENMPI_BIN_DIR" + echo " OPENMPI_LIB_DIR : $OPENMPI_LIB_DIR" + echo " OPENMPI_INCLUDE_DIR : $OPENMPI_INCLUDE_DIR" + echo " OPENMPI_COMPILE_FLAGS : $OPENMPI_COMPILE_FLAGS" + echo " OPENMPI_LINK_FLAGS : $OPENMPI_LINK_FLAGS" + echo "" + echo " MPI_HOME : $MPI_HOME" + echo " MPI_ARCH_PATH : $MPI_ARCH_PATH" + echo " OPAL_PREFIX : $OPAL_PREFIX" + echo " PINC : $PINC" + echo " PLIBS : $PLIBS" + endif setenv FOAM_MPI_LIBBIN $FOAM_LIBBIN/$mpi_version - unset mpi_version libDir + unset mpi_version breaksw case MPICH: @@ -300,31 +370,31 @@ endif # Mesquite library if available # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -if ( -e $WM_THIRD_PARTY_DIR/packages/mesquite-2.1.2 ) then +if ( $?MESQUITE_SYSTEM == 0 && -e $WM_THIRD_PARTY_DIR/packages/mesquite-2.1.2 ) then _foamSource $WM_THIRD_PARTY_DIR/packages/mesquite-2.1.2/platforms/$WM_OPTIONS/etc/mesquite-2.1.2.csh endif # Metis library if available # ~~~~~~~~~~~~~~~~~~~~~~~~~~ -if ( -e $WM_THIRD_PARTY_DIR/packages/metis-5.0pre2 ) then +if ( $?METIS_SYSTEM == 0&& -e $WM_THIRD_PARTY_DIR/packages/metis-5.0pre2 ) then _foamSource $WM_THIRD_PARTY_DIR/packages/metis-5.0pre2/platforms/$WM_OPTIONS/etc/metis-5.0pre2.csh endif # ParMetis library if available # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -if ( -e $WM_THIRD_PARTY_DIR/packages/ParMetis-3.1.1 ) then +if ( $?PARMETIS_SYSTEM == 0 && -e $WM_THIRD_PARTY_DIR/packages/ParMetis-3.1.1 ) then _foamSource $WM_THIRD_PARTY_DIR/packages/ParMetis-3.1.1/platforms/$WM_OPTIONS/etc/ParMetis-3.1.1.csh endif # ParMGridGen library if available # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -if ( -e $WM_THIRD_PARTY_DIR/packages/ParMGridGen-1.0 ) then +if ( $?PARMGRIDGEN_SYSTEM == 0 && -e $WM_THIRD_PARTY_DIR/packages/ParMGridGen-1.0 ) then _foamSource $WM_THIRD_PARTY_DIR/packages/ParMGridGen-1.0/platforms/$WM_OPTIONS/etc/ParMGridGen-1.0.csh endif # Scotch library if available # ~~~~~~~~~~~~~~~~~~~~~~~~~~~ -if ( -e $WM_THIRD_PARTY_DIR/packages/scotch-5.1.10b ) then +if ( $?SCOTCH_SYSTEM == 0 && -e $WM_THIRD_PARTY_DIR/packages/scotch-5.1.10b ) then _foamSource $WM_THIRD_PARTY_DIR/packages/scotch-5.1.10b/platforms/$WM_OPTIONS/etc/scotch-5.1.10b.csh endif @@ -338,25 +408,25 @@ endif # cmake # ~~~~~ -if ( -e "$WM_THIRD_PARTY_DIR"/packages/cmake-2.8.3 ) then +if ( $?CMAKE_SYSTEM == 0 && -e "$WM_THIRD_PARTY_DIR"/packages/cmake-2.8.3 ) then _foamSource $WM_THIRD_PARTY_DIR/packages/cmake-2.8.3/platforms/$WM_OPTIONS/etc/cmake-2.8.3.csh endif # Python # ~~~~~ -if ( -e "$WM_THIRD_PARTY_DIR"/packages/Python-2.7 ) then +if ( $?PYTHON_SYSTEM == 0 && -e "$WM_THIRD_PARTY_DIR"/packages/Python-2.7 ) then _foamSource $WM_THIRD_PARTY_DIR/packages/Python-2.7/platforms/$WM_OPTIONS/etc/Python-2.7.csh endif # QT # ~~~~~ -if ( -e "$WM_THIRD_PARTY_DIR"/packages/qt-everywhere-opensource-src-4.7.0 )then +if ( $?QT_SYSTEM == 0 && -e "$WM_THIRD_PARTY_DIR"/packages/qt-everywhere-opensource-src-4.7.0 )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 endif # PARAVIEW # ~~~~~ -if ( -e "$WM_THIRD_PARTY_DIR"/packages/ParaView-3.8.1 ) then +if ( $?PARAVIEW_SYSTEM == 0 && -e "$WM_THIRD_PARTY_DIR"/packages/ParaView-3.8.1 ) then _foamSource $WM_THIRD_PARTY_DIR/packages/ParaView-3.8.1/platforms/$WM_OPTIONS/etc/ParaView-3.8.1.csh endif diff --git a/etc/settings.sh b/etc/settings.sh index bec6bab7e..170d1d990 100644 --- a/etc/settings.sh +++ b/etc/settings.sh @@ -187,32 +187,21 @@ case "$WM_MPLIB" in OPENMPI) if [ -e $WM_THIRD_PARTY_DIR/packages/openmpi-1.4.3 ] then - if [ "$FOAM_VERBOSE" -a "$PS1" ] - then - echo "Using openmpi-1.4.3" - fi mpi_version=openmpi-1.4.3 - _foamSource $WM_THIRD_PARTY_DIR/packages/$mpi_version/platforms/$WM_OPTIONS/etc/$mpi_version.sh - - export MPI_HOME=$WM_THIRD_PARTY_DIR/packages/$mpi_version/platforms/$WM_OPTIONS - export MPI_ARCH_PATH=$MPI_HOME - - # Tell OpenMPI where to find its install directory - export OPAL_PREFIX=$MPI_ARCH_PATH - elif [ -e $WM_THIRD_PARTY_DIR/packages/openmpi-1.4.1 ] - then if [ "$FOAM_VERBOSE" -a "$PS1" ] then - echo "Using openmpi-1.4.1" + echo "Using openmpi-1.4.3 from the ThirdParty package: $WM_THIRD_PARTY_DIR/packages/$mpi_version" fi - mpi_version=openmpi-1.4.1 _foamSource $WM_THIRD_PARTY_DIR/packages/$mpi_version/platforms/$WM_OPTIONS/etc/$mpi_version.sh - export MPI_HOME=$WM_THIRD_PARTY_DIR/packages/$mpi_version/platforms/$WM_OPTIONS - export MPI_ARCH_PATH=$MPI_HOME - - # Tell OpenMPI where to find its install directory - export OPAL_PREFIX=$MPI_ARCH_PATH + elif [ -e $WM_THIRD_PARTY_DIR/packages/openmpi-1.5 ] + then + mpi_version=openmpi-1.5 + if [ "$FOAM_VERBOSE" -a "$PS1" ] + then + echo "Using openmpi-1.5 from the ThirdParty package: $WM_THIRD_PARTY_DIR/packages/$mpi_version" + fi + _foamSource $WM_THIRD_PARTY_DIR/packages/$mpi_version/platforms/$WM_OPTIONS/etc/$mpi_version.sh fi export FOAM_MPI_LIBBIN=$FOAM_LIBBIN/$mpi_version @@ -223,24 +212,80 @@ SYSTEMOPENMPI) mpi_version=openmpi-system # make sure not the "old" mpi is used - export OPAL_PREFIX= + # Not sure if this is necessary anymore. + # export OPAL_PREFIX= + + # Make sure OPENMPI_BIN_DIR is set and valid + if [ -n "${OPENMPI_BIN_DIR}" ] && [ -d "${OPENMPI_BIN_DIR}" ] + then + # User defined value specified for OPENMPI_BIN_DIR + # + # WARNING: + # We assume this path specified by $OPENMPI_BIN_DIR is valid + # We assume the command mpicc is located somewhere under this path + # We assume the file mpi.h is located somewhere under this path + # + # Otherwise, please double check your openmpi installation, you are + # probably missing the openmpi runtime and/or development packages + # available for your system. + # + _foamAddPath $OPENMPI_BIN_DIR + else + # Here, we assume your environment is already set for running + # and developping with openmpi. + # + # Initialize OPENMPI_BIN_DIR using the path to mpicc + export OPENMPI_BIN_DIR=$(dirname `which mpicc`) + fi + + # Make sure OPENMPI_LIB_DIR is set + if [ ! -n "${OPENMPI_LIB_DIR}" ] + then + # Initialize OPENMPI_LIB_DIR using the path to mpicc + export OPENMPI_LIB_DIR="`mpicc --showme:libdirs`" + fi + + # Make sure the dynamic libraries are accessible + [ -n "${OPENMPI_LIB_DIR}" ] && _foamAddLib $OPENMPI_LIB_DIR + + export MPI_HOME=`dirname $OPENMPI_BIN_DIR` + export MPI_ARCH_PATH=$MPI_HOME + export OPAL_PREFIX=$MPI_ARCH_PATH + + # We initialize the rest of the environment using mpicc --showme: + [ ! -n "${OPENMPI_INCLUDE_DIR}" ] && export OPENMPI_INCLUDE_DIR="`mpicc --showme:incdirs`" + [ ! -n "${OPENMPI_COMPILE_FLAGS}" ] && export OPENMPI_COMPILE_FLAGS="`mpicc --showme:compile`" + [ ! -n "${OPENMPI_LINK_FLAGS}" ] && export OPENMPI_LINK_FLAGS="`mpicc --showme:link`" + + # + # WARNING: We assume the file mpi.h will be available under the directories identified + # by the variable $OPENMPI_INCLUDE_DIR. Otherwise, please double check your + # system openmpi installation. # Set compilation flags here instead of in wmake/rules/../mplibSYSTEMOPENMPI - export PINC=`mpicc --showme:compile` - export PLIBS="`mpicc --showme:link`" - libDir=`echo "$PLIBS" | sed -e 's/.*-L\([^ ]*\).*/\1/'` + export PINC=$OPENMPI_COMPILE_FLAGS + export PLIBS=$OPENMPI_LINK_FLAGS + + # No longer needed, but we keep this as a reference, just in case... + #libDir=`echo "$PLIBS" | sed -e 's/.*-L\([^ ]*\).*/\1/'` + #_foamAddLib $libDir if [ "$FOAM_VERBOSE" -a "$PS1" ] then - echo "Using system installed MPI:" - echo " compile flags : $PINC" - echo " link flags : $PLIBS" - echo " libmpi dir : $libDir" + echo "Using system installed OpenMPI:" + echo " OPENMPI_BIN_DIR : $OPENMPI_BIN_DIR" + echo " OPENMPI_LIB_DIR : $OPENMPI_LIB_DIR" + echo " OPENMPI_INCLUDE_DIR : $OPENMPI_INCLUDE_DIR" + echo " OPENMPI_COMPILE_FLAGS : $OPENMPI_COMPILE_FLAGS" + echo " OPENMPI_LINK_FLAGS : $OPENMPI_LINK_FLAGS" + echo "" + echo " MPI_HOME : $MPI_HOME" + echo " MPI_ARCH_PATH : $MPI_ARCH_PATH" + echo " OPAL_PREFIX : $OPAL_PREFIX" + echo " PINC : $PINC" + echo " PLIBS : $PLIBS" fi - _foamAddLib $libDir - - export FOAM_MPI_LIBBIN=$FOAM_LIBBIN/$mpi_version unset mpi_version ;; @@ -372,79 +417,79 @@ export MPI_BUFFER_SIZE # Third party packages # # In order to use a pre-installed version of the ThirdParty packages, just set the -# appropriate XXX_DIR environment variable for a given package in order to disable -# the sourcing of the ThirdParty version of the same package. +# appropriate XXX_SYSTEM environment variable for a given package in your prefs.sh +# file in order to disable the sourcing of the ThirdParty version of the same package. # Load Mesquite library # ~~~~~~~~~~~~~~~~~~~~~~ -[ -e $WM_THIRD_PARTY_DIR/packages/mesquite-2.1.2 ] && { +[ -z "$MESQUITE_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/mesquite-2.1.2 ] && { _foamSource $WM_THIRD_PARTY_DIR/packages/mesquite-2.1.2/platforms/$WM_OPTIONS/etc/mesquite-2.1.2.sh } -[ "$FOAM_VERBOSE" -a "$PS1" ] && echo "MESQUITE_DIR is initialized to: $MESQUITE_DIR" +[ "$FOAM_VERBOSE" -a "$PS1" ] && echo " MESQUITE_DIR is initialized to: $MESQUITE_DIR" # Load Metis library # ~~~~~~~~~~~~~~~~~~ -[ -e $WM_THIRD_PARTY_DIR/packages/metis-5.0pre2 ] && { +[ -z "$METIS_SYSTEM" ] && [ -d $WM_THIRD_PARTY_DIR/packages/metis-5.0pre2 ] && { _foamSource $WM_THIRD_PARTY_DIR/packages/metis-5.0pre2/platforms/$WM_OPTIONS/etc/metis-5.0pre2.sh } -[ "$FOAM_VERBOSE" -a "$PS1" ] && echo "METIS_DIR is initialized to: $METIS_DIR" +[ "$FOAM_VERBOSE" -a "$PS1" ] && echo " METIS_DIR is initialized to: $METIS_DIR" # Load ParMetis library # ~~~~~~~~~~~~~~~~~~~~~ -[ -e $WM_THIRD_PARTY_DIR/packages/ParMetis-3.1.1 ] && { +[ -z "$PARMETIS_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/ParMetis-3.1.1 ] && { _foamSource $WM_THIRD_PARTY_DIR/packages/ParMetis-3.1.1/platforms/$WM_OPTIONS/etc/ParMetis-3.1.1.sh } -[ "$FOAM_VERBOSE" -a "$PS1" ] && echo "PARMETIS_DIR is initialized to: $PARMETIS_DIR" +[ "$FOAM_VERBOSE" -a "$PS1" ] && echo " PARMETIS_DIR is initialized to: $PARMETIS_DIR" # Load ParMGridGen library # ~~~~~~~~~~~~~~~~~~~~~~~~~ -[ -e $WM_THIRD_PARTY_DIR/packages/ParMGridGen-1.0 ] && { +[ -z "$PARMGRIDGEN_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/ParMGridGen-1.0 ] && { _foamSource $WM_THIRD_PARTY_DIR/packages/ParMGridGen-1.0/platforms/$WM_OPTIONS/etc/ParMGridGen-1.0.sh } -[ "$FOAM_VERBOSE" -a "$PS1" ] && echo "PARMGRIDGEN_DIR is initialized to: $PARMGRIDGEN_DIR" +[ "$FOAM_VERBOSE" -a "$PS1" ] && echo " PARMGRIDGEN_DIR is initialized to: $PARMGRIDGEN_DIR" # Load Scotch library # ~~~~~~~~~~~~~~~~~~~ -[ -e $WM_THIRD_PARTY_DIR/packages/scotch-5.1.10b ] && { +[ -z "$SCOTCH_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/scotch-5.1.10b ] && { _foamSource $WM_THIRD_PARTY_DIR/packages/scotch-5.1.10b/platforms/$WM_OPTIONS/etc/scotch-5.1.10b.sh } -[ "$FOAM_VERBOSE" -a "$PS1" ] && echo "SCOTCH_DIR is initialized to: $SCOTCH_DIR" +[ "$FOAM_VERBOSE" -a "$PS1" ] && echo " SCOTCH_DIR is initialized to: $SCOTCH_DIR" # Load cmake # ~~~~~~~~~~ -[ -e $WM_THIRD_PARTY_DIR/packages/cmake-2.8.3 ] && { +[ -z "$CMAKE_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/cmake-2.8.3 ] && { _foamSource $WM_THIRD_PARTY_DIR/packages/cmake-2.8.3/platforms/$WM_OPTIONS/etc/cmake-2.8.3.sh } -[ "$FOAM_VERBOSE" -a "$PS1" ] && echo "CMAKE_DIR is initialized to: $CMAKE_DIR" +[ "$FOAM_VERBOSE" -a "$PS1" ] && echo " CMAKE_DIR is initialized to: $CMAKE_DIR" # Load Python # ~~~~~~~~~~~ -[ -e $WM_THIRD_PARTY_DIR/packages/Python-2.7 ] && { +[ -z "$PYTHON_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/Python-2.7 ] && { _foamSource $WM_THIRD_PARTY_DIR/packages/Python-2.7/platforms/$WM_OPTIONS/etc/Python-2.7.sh } -[ "$FOAM_VERBOSE" -a "$PS1" ] && echo "PYTHON_DIR is initialized to: $PYTHON_DIR" +[ "$FOAM_VERBOSE" -a "$PS1" ] && echo " PYTHON_DIR is initialized to: $PYTHON_DIR" # Load QT # ~~~~~~~ -[ -e $WM_THIRD_PARTY_DIR/packages/qt-everywhere-opensource-src-4.7.0 ] && { +[ ! -z "$QT_THIRD_PARTY" ] && [ -e $WM_THIRD_PARTY_DIR/packages/qt-everywhere-opensource-src-4.7.0 ] && { _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 } -[ "$FOAM_VERBOSE" -a "$PS1" ] && echo "QT_DIR is initialized to: $QT_DIR" +[ "$FOAM_VERBOSE" -a "$PS1" ] && echo " QT_DIR is initialized to: $QT_DIR" # Load ParaView # ~~~~~~~~~~~~~ -[ -e $WM_THIRD_PARTY_DIR/packages/ParaView-3.8.1 ] && { +[ -z "$PARAVIEW_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/ParaView-3.8.1 ] && { _foamSource $WM_THIRD_PARTY_DIR/packages/ParaView-3.8.1/platforms/$WM_OPTIONS/etc/ParaView-3.8.1.sh } -[ "$FOAM_VERBOSE" -a "$PS1" ] && echo "PARAVIEW_DIR is initialized to: $PARAVIEW_DIR" +[ "$FOAM_VERBOSE" -a "$PS1" ] && echo " PARAVIEW_DIR is initialized to: $PARAVIEW_DIR" # cleanup environment: diff --git a/src/decompositionMethods/metisDecomp/Make/options b/src/decompositionMethods/metisDecomp/Make/options index 788f28f38..1cf9a25eb 100644 --- a/src/decompositionMethods/metisDecomp/Make/options +++ b/src/decompositionMethods/metisDecomp/Make/options @@ -1,10 +1,10 @@ EXE_INC = \ - -I$(METIS_DIR)/include \ + -I$(METIS_INCLUDE_DIR) \ -I../decompositionMethods/lnInclude \ -I../scotchDecomp/lnInclude LIB_LIBS = \ -L$(FOAM_LIBBIN)/dummy \ - -L$(METIS_DIR)/lib -lmetis \ - -L$(METIS_DIR)/lib -lGKlib + -L$(METIS_LIB_DIR) -lmetis \ + -L$(METIS_LIB_DIR) -lGKlib diff --git a/src/decompositionMethods/parMetisDecomp/Make/options b/src/decompositionMethods/parMetisDecomp/Make/options index 976c5f208..de0e5e368 100644 --- a/src/decompositionMethods/parMetisDecomp/Make/options +++ b/src/decompositionMethods/parMetisDecomp/Make/options @@ -2,13 +2,13 @@ include $(RULES)/mplib$(WM_MPLIB) EXE_INC = \ $(PFLAGS) $(PINC) \ - -I$(PARMETIS_DIR)/include/ParMETISLib \ - -I$(PARMETIS_DIR)/include \ + -I$(PARMETIS_INCLUDE_DIR)/ParMETISLib \ + -I$(PARMETIS_INCLUDE_DIR) \ -I../decompositionMethods/lnInclude \ -I../metisDecomp/lnInclude \ -I../scotchDecomp/lnInclude LIB_LIBS = \ -L$(FOAM_MPI_LIBBIN) \ - -L$(PARMETIS_DIR)/lib -lmetis-parmetis \ - -L$(PARMETIS_DIR)/lib -lparmetis + -L$(PARMETIS_LIB_DIR) -lmetis-parmetis \ + -L$(PARMETIS_LIB_DIR) -lparmetis diff --git a/src/decompositionMethods/scotchDecomp/Make/options b/src/decompositionMethods/scotchDecomp/Make/options index 41a8d9c0c..5541f6f5f 100644 --- a/src/decompositionMethods/scotchDecomp/Make/options +++ b/src/decompositionMethods/scotchDecomp/Make/options @@ -1,7 +1,7 @@ EXE_INC = \ - -I$(SCOTCH_DIR)/include \ + -I$(SCOTCH_INCLUDE_DIR) \ -I../decompositionMethods/lnInclude LIB_LIBS = \ - -L$(SCOTCH_DIR)/lib -lscotch \ - -L$(SCOTCH_DIR)/lib -lscotcherrexit + -L$(SCOTCH_LIB_DIR) -lscotch \ + -L$(SCOTCH_LIB_DIR) -lscotcherrexit diff --git a/src/dynamicMesh/meshMotion/mesquiteMotionSolver/Make/options b/src/dynamicMesh/meshMotion/mesquiteMotionSolver/Make/options index 47b48f53e..67eeecf61 100644 --- a/src/dynamicMesh/meshMotion/mesquiteMotionSolver/Make/options +++ b/src/dynamicMesh/meshMotion/mesquiteMotionSolver/Make/options @@ -1,9 +1,9 @@ EXE_INC = \ - -I$(MESQUITE_DIR)/include \ + -I$(MESQUITE_INCLUDE_DIR) \ -I$(LIB_SRC)/meshTools/lnInclude \ -I$(LIB_SRC)/dynamicMesh/dynamicMesh/lnInclude \ LIB_LIBS = \ -lmeshTools \ -ldynamicMesh \ - -L$(MESQUITE_DIR)/lib -lmesquite + -L$(MESQUITE_LIB_DIR) -lmesquite diff --git a/src/fvAgglomerationMethods/MGridGenGamgAgglomeration/Make/options b/src/fvAgglomerationMethods/MGridGenGamgAgglomeration/Make/options index 0ced04b6d..15ed33702 100644 --- a/src/fvAgglomerationMethods/MGridGenGamgAgglomeration/Make/options +++ b/src/fvAgglomerationMethods/MGridGenGamgAgglomeration/Make/options @@ -7,9 +7,9 @@ TYPE_REAL=-DTYPE_REAL EXE_INC = \ -I$(LIB_SRC)/finiteVolume/lnInclude \ - -I$(PARMGRIDGEN_DIR)/include/Lib \ - -I$(PARMGRIDGEN_DIR)/include/IMlib \ + -I$(PARMGRIDGEN_INCLUDE_DIR)/Lib \ + -I$(PARMGRIDGEN_INCLUDE_DIR)/IMlib \ $(TYPE_REAL) LIB_LIBS = \ - -L$(PARMGRIDGEN_DIR)/lib -lMGridGen + -L$(PARMGRIDGEN_LIB_DIR) -lMGridGen