openfoam/bin/foamPackBinAll
Mark Olesen a3a2ea78be ENH: update, cleanup foam packing routines
- update packing for FOAM_EXT_LIBBIN and newer FOAM_APPBIN
- pack OpenFOAM source via 'git archive' for consistency with
  the git repository (use -nogit option to revert to manual packing)
- combine foamPackBin + foamPackThirdPartyBin
- add foamPackThirdPartyBinAll (like foamPackBinAll)

- relocate service scripts into bin/tools
- use more standard 'tgz' instead of 'gtgz'
2011-01-02 21:39:41 +01:00

67 lines
2.0 KiB
Bash
Executable File

#!/bin/sh
#------------------------------------------------------------------------------
# ========= |
# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
# \\ / O peration |
# \\ / A nd | Copyright (C) 1991-2011 OpenCFD Ltd.
# \\/ 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 3 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, see <http://www.gnu.org/licenses/>.
#
# Script
# foamPackBinAll [OPTION]
#
# Description
# Pack and compress all binary versions of OpenFOAM for release
#
# Script
# foamPackThirdPartyBinAll [OPTION]
#
# Description
# Pack and compress all binary versions of OpenFOAM ThirdParty for release
#
#------------------------------------------------------------------------------
binDir="${0%/*}" # this script is located in the bin/ dir
case "${0##*/}" in
*ThirdParty*)
# for ThirdParty
packDir=ThirdParty-$WM_PROJECT_VERSION
packBin=foamPackThirdPartyBin
;;
*)
# regular
packDir=$WM_PROJECT-$WM_PROJECT_VERSION
packBin=foamPackBin
;;
esac
[ -d $packDir ] || {
echo "Error: directory $packDir does not exist" 1>&2
exit 1
}
# obtain archOptions types from lib/
for archOptions in $packDir/lib/*
do
$binDir/$packBin $@ ${archOptions##*/}
done
#------------------------------------------------------------------------------