Annotation of freem/mk-solaris-package, revision 1.8

1.1       snw         1: #!/usr/bin/bash
                      2: 
1.6       snw         3: #
1.8     ! snw         4: #   $Id: mk-solaris-package,v 1.7 2025/03/10 15:13:18 snw Exp $
1.6       snw         5: #    Solaris package builder
                      6: #
                      7: #  
                      8: #   Author: Serena Willis <snw@coherent-logic.com>
                      9: #    Copyright (C) 1998 MUG Deutschland
                     10: #    Copyright (C) 2023, 2025 Coherent Logic Development LLC
                     11: #
                     12: #
                     13: #   This file is part of FreeM.
                     14: #
                     15: #   FreeM is free software: you can redistribute it and/or modify
                     16: #   it under the terms of the GNU Affero Public License as published by
                     17: #   the Free Software Foundation, either version 3 of the License, or
                     18: #   (at your option) any later version.
                     19: #
                     20: #   FreeM is distributed in the hope that it will be useful,
                     21: #   but WITHOUT ANY WARRANTY; without even the implied warranty of
                     22: #   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
                     23: #   GNU Affero Public License for more details.
                     24: #
                     25: #   You should have received a copy of the GNU Affero Public License
                     26: #   along with FreeM.  If not, see <https://www.gnu.org/licenses/>.
                     27: #
1.7       snw        28: #   $Log: mk-solaris-package,v $
1.8     ! snw        29: #   Revision 1.7  2025/03/10 15:13:18  snw
        !            30: #   Enhance mk-solaris-package script to validate arguments
        !            31: #
1.7       snw        32: #   Revision 1.6  2025/03/09 19:14:24  snw
                     33: #   First phase of REUSE compliance and header reformat
                     34: #
1.6       snw        35: #
                     36: # SPDX-FileCopyrightText:  (C) 2025 Coherent Logic Development LLC
                     37: # SPDX-License-Identifier: AGPL-3.0-or-later
                     38: #
                     39: 
1.7       snw        40: PGM=$(basename $0)
                     41: 
                     42: if [[ $# != 2 ]]
                     43: then
                     44:     echo "usage:  ${PGM} <architecture> <os>"
                     45:     echo "        <architecture> should be sparc, sparcv9, i386, or amd64"
                     46:     echo "        <os> should be solaris or openindiana"
                     47:     exit 1
                     48: fi
                     49: 
1.2       snw        50: PKG=CLDfreem
1.4       snw        51: ARCH=$1
1.5       snw        52: OS=$2
1.4       snw        53: VERS=$(cat sem.ver)
                     54: SOLVER=$(uname -a | cut -d' ' -f3)
1.5       snw        55: PKGFILE=${PKG}-${VERS}-${OS}${SOLVER}-${ARCH}.pkg
1.1       snw        56: 
1.2       snw        57: cat <<EOF > pkginfo
                     58: PKG=${PKG}
1.3       snw        59: NAME=Coherent Logic Development FreeM programming language and database.
1.4       snw        60: ARCH=${ARCH}
                     61: VERSION=${VERS}
1.1       snw        62: CATEGORY=application
                     63: BASEDIR=/usr/local
                     64: EOF
1.2       snw        65: 
                     66: pkgmk -o -d /tmp -a ${ARCH}
                     67: touch ${PKGFILE}
                     68: pkgtrans -s /tmp ${PKGFILE} ${PKG}
                     69: rm -r /tmp/${PKG}

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>