#!/bin/sh # $Id: clang.in 7100 2012-10-27 18:26:38Z cher $ # Copyright (c) 2012 Alexander Chernov # using EJUDGE_FLAGS we may pass additional flags LANG_CONFIG_DIR="/home/judges/compile/conf/lang.d" [ "${EJUDGE_LANG_CONFIG}" = "" ] && EJUDGE_LANG_CONFIG="${LANG_CONFIG_DIR}/clang.cfg" if [ -f "${EJUDGE_LANG_CONFIG}" ] then . "${EJUDGE_LANG_CONFIG}" else version="unknown" CLANGRUN="clang" CLANGDIR= fi if [ x"${version}" = x ] then echo "This language is not supported." >&2 exit 1 fi if [ x"${CLANGDIR}" != x ] then PATH="${CLANGDIR}:${PATH}" fi [ x"${EJUDGE_FLAGS}" = x ] && EJUDGE_FLAGS="-Wall -O2 -std=gnu99" unset LANG unset LC_ALL unset LC_MESSAGES unset LANGUAGE exec "${CLANGRUN}" ${EJUDGE_FLAGS} "$1" -o "$2" -lm