diff options
author | François Andriot <albator78@libertysurf.fr> | 2015-06-29 20:17:57 +0200 |
---|---|---|
committer | François Andriot <albator78@libertysurf.fr> | 2015-06-29 20:17:57 +0200 |
commit | 2835777e9ae7bde053e0da2f083ee020f26ea04a (patch) | |
tree | 8695f4161ce1d52053a016a69712dcd8cea97d4d /redhat/build/get_specfile.sh | |
parent | d3c1f8ab667376639b6ff83e4eff50cd861fe5d2 (diff) | |
download | tde-packaging-2835777e9ae7bde053e0da2f083ee020f26ea04a.tar.gz tde-packaging-2835777e9ae7bde053e0da2f083ee020f26ea04a.zip |
RPM Packaging: massive update spec files
Diffstat (limited to 'redhat/build/get_specfile.sh')
-rwxr-xr-x | redhat/build/get_specfile.sh | 28 |
1 files changed, 16 insertions, 12 deletions
diff --git a/redhat/build/get_specfile.sh b/redhat/build/get_specfile.sh index 54094064b..fcc0b64c5 100755 --- a/redhat/build/get_specfile.sh +++ b/redhat/build/get_specfile.sh @@ -11,20 +11,24 @@ TDE_VERSION="${2:-14.0.0}" # Special case for QT3 if [ "${PKGNAME}" = "qt3" ]; then case "$(rpmdist.sh --dist)" in - .oss*) DIST_PACKAGING_DIR=${TDE_PACKAGING_DIR}/opensuse ;; - .mga*|.mdk*|.pclos*) DIST_PACKAGING_DIR=${TDE_PACKAGING_DIR}/mageia ;; + .oss*) DIST_PACKAGING_DIR="${TDE_PACKAGING_DIR}/opensuse" ;; + .mga*|.mdk*|.pclos*) DIST_PACKAGING_DIR="${TDE_PACKAGING_DIR}/mageia" ;; esac fi -SPECFILE=$(find "${DIST_PACKAGING_DIR}" -name "${PKGNAME}-${TDE_VERSION}.spec") -if [ ! -r "${SPECFILE}" ]; then - SPECFILE=$(find "${DIST_PACKAGING_DIR}" -name "${PKGNAME}.spec") - if [ ! -r "${SPECFILE}" ]; then - SPECFILE=$(find "${DIST_PACKAGING_DIR}" -name "trinity-${PKGNAME}-${TDE_VERSION}.spec") - if [ ! -r "${SPECFILE}" ]; then - SPECFILE=$(find "${DIST_PACKAGING_DIR}" -name "trinity-${PKGNAME}.spec") - fi +for filename in \ + "${PKGNAME}-${TDE_VERSION}.spec" \ + "${PKGNAME}-14.0.0.spec" \ + "${PKGNAME}.spec" \ + "trinity-${PKGNAME}-${TDE_VERSION}.spec" \ + "trinity-${PKGNAME}-14.0.0.spec" \ + "trinity-${PKGNAME}.spec" \ +; do + SPECFILE="$(find "${DIST_PACKAGING_DIR}" -name "${filename}")" + if [ -r "${SPECFILE}" ]; then + echo "${SPECFILE}" + exit 0 fi -fi +done -echo ${SPECFILE} +exit 1 |