mirror of
https://github.com/Mercury-Language/mercury.git
synced 2025-12-06 07:49:02 +00:00
scripts/c2init.in:
scripts/mercury.in:
scripts/mmake.in:
scripts/mmc.in:
scripts/prepare_install_dir.in:
Indent by four spaces, not by tabs, or by three spaces.
Use ${varname}, not just $varname.
Put successive commands on separate lines.
Indent case statements in a consistent manner: put case patterns
on their own lines; put ;;s on their own lines.
Put quotes around strings that should be considered one word
even if they are empty or contain spaces.
38 lines
1.3 KiB
Bash
38 lines
1.3 KiB
Bash
#! /bin/sh
|
|
#---------------------------------------------------------------------------#
|
|
# vim: ts=4 sw=4 et ft=sh
|
|
#---------------------------------------------------------------------------#
|
|
# @configure_input@
|
|
#---------------------------------------------------------------------------#
|
|
# Copyright (C) 1994-1998, 2000-2005 The University of Melbourne.
|
|
# Copyright (C) 2020 The Mercury team.
|
|
# This file may only be copied under the terms of the GNU General
|
|
# Public License - see the file COPYING in the Mercury distribution.
|
|
#---------------------------------------------------------------------------#
|
|
#
|
|
# mercury - Melbourne Mercury Compiler.
|
|
#
|
|
# Use `mercury -h' for help.
|
|
#
|
|
# Environment variables: MERCURY_STDLIB_DIR, MERCURY_CONFIG_DIR,
|
|
# MERCURY_COMPILER, MERCURY_C_COMPILER, MERCURY_DEFAULT_GRADE,
|
|
# MERCURY_DEFAULT_OPT_LEVEL.
|
|
|
|
prefix=@prefix@
|
|
exec_prefix=@exec_prefix@
|
|
MERCURY_COMPILER=${MERCURY_COMPILER-"@bindir@/mercury_compile"}
|
|
MERCURY_CONFIG_DIR=${MERCURY_CONFIG_DIR-${MERCURY_STDLIB_DIR-'@CONFIG_LIBDIR@'}}
|
|
export MERCURY_COMPILER MERCURY_CONFIG_DIR
|
|
|
|
# Set the MACOSX_DEPLOYMENT_TARGET environment variable if needed.
|
|
@SET_MACOSX_DEPLOYMENT_TARGET@
|
|
|
|
case "$#" in
|
|
0)
|
|
@MMC_INVOKE_CMD@ ${MERCURY_COMPILER}
|
|
;;
|
|
*)
|
|
@MMC_INVOKE_CMD@ ${MERCURY_COMPILER} "$@"
|
|
;;
|
|
esac
|