]> mj.ucw.cz Git - eval.git/blob - config
`md5crypt' now uses MD5 from libucw.
[eval.git] / config
1 # Configuration file for the MO Evaluator
2 # (c) 2001--2008 Martin Mares <mj@ucw.cz>
3
4 # The root of the whole directory hierarchy
5 MO_ROOT=/mo
6
7 # User and group used by the evaluator itself
8 EVAL_USER=mo-eval
9 EVAL_GROUP=mo-eval
10
11 # Test user for the sandbox. You can let mo-setup create more test users
12 # and then run several evaluators in parallel, each in its own sandbox.
13 # For testing, you can also leave TEST_USER undefined and run the sandbox
14 # with EVAL_USER privileges, but beware, this is INSECURE.
15 #TEST_USER=${TEST_USER:-mo-test1}
16 TEST_USERS="mo-test1 mo-test2"
17 TEST_GROUP=mo-test
18
19 # These values are used when creating logins for eval and contestants
20 # (group id's are from the same range)
21 EVAL_UID_MIN=65000
22 CT_UID_MIN=65100
23 CT_UID_MAX=65199
24
25 # Sometimes we need to get a list of all contestants (not in the evaluator
26 # itself, but in various auxiliary scripts). In such cases we call mo-get-users,
27 # which either uses an explicit list of contestants CT_USER_LIST (username<tab>fullname),
28 # or (if undefined) scans /etc/passwd for users with UID between CT_UID_MIN and CT_UID_MAX.
29 CT_USER_LIST=userlist
30
31 # (optional) Use remote submitting
32 REMOTE_SUBMIT=1
33 REMOTE_SUBMIT_USER=mo-submit
34 REMOTE_SUBMIT_GROUP=mo-submit
35
36 ### Programming language settings
37
38 # Known source file extensions
39 EXTENSIONS="c cc C cpp p pas"
40
41 # Some of the extensions can be aliases for other extensions
42 ALIAS_EXT_cc=cpp
43 ALIAS_EXT_C=cpp
44 ALIAS_EXT_p=pas
45
46 ## Variables which control compilation and execution
47 ## (see below for values for individual languages)
48
49 # Command used to run the compiler
50 COMP=false
51
52 # Sandbox options used when compiling
53 COMP_SANDBOX_OPTS='-m262144 -w60 -e -i/dev/null'
54
55 # Extra per-language sandbox options used when testing
56 LANG_SANDBOX_OPTS=
57
58 # Translation of runtime errors: a function, which receives the exit code as an argument and
59 # if it is recognized as a runtime error code, it prints its name to the standard output.
60 EXIT_CODE_HOOK=
61
62 # Hooks which can alter the contents of the sandbox in $BOXDIR before/after compilation/running
63 PRE_COMPILE_HOOK=
64 POST_COMPILE_HOOK=
65 PRE_RUN_HOOK=
66 POST_RUN_HOOK=
67
68 ## Settings for individual languages
69
70 # C
71 EXT_c_COMP='/usr/bin/gcc -std=gnu99 -O2 -g -o $EXE $EXTRA_CFLAGS $SRC -lm'
72 EXTRA_CFLAGS=
73
74 # C++
75 EXT_cpp_COMP='/usr/bin/g++ -O2 -g -o $EXE $EXTRA_CXXFLAGS $SRC -lm'
76 EXTRA_CXXFLAGS=
77
78 # Pascal
79 EXT_pas_COMP='/usr/bin/fpc -Ci -Cr -Ct -g -O2 -Sg -o$EXE $EXTRA_PFLAGS $SRC'
80 EXTRA_PFLAGS=
81 EXT_pas_EXIT_CODE_HOOK=fpc-exit-code
82
83 ### Per-task configuration variables (default values, override in per-task config)
84
85 # List of extra files needed for compilation. They are copied to the compiler
86 # sandbox from the problem's directory.
87 #COMP_EXTRAS="extras.h"
88
89 ## Tester settings (most can be overriden in per-test config):
90
91 # The following variables are automatically set by the evaluator:
92 # PROBLEM       name of the problem
93 # HDIR          home directory of the evaluator (i.e., this file is $HDIR/config)
94 # PDIR          directory containing problem data
95 # SDIR          directory containing contestant's solution
96 # TDIR          directory containing testing results
97 # TMPDIR        directory containing temporary files
98 # TEST          name of the current test
99
100 # Task type:
101 # offline       off-line task
102 # interactive   interactive task communicating via stdio with a testing program
103 # open-data     open-data task (i.e., we don't submit program, but output files)
104 TASK_TYPE=file
105
106 # I/O type (IO_TYPE sets defaults for IN_TYPE and OUT_TYPE)
107 # file          input from $PROBLEM.in, output to $PROBLEM.out (possible even for interactive tasks)
108 # stdio         input from stdin, output to stdout
109 # none          no input/output
110 IO_TYPE=stdio
111 #IN_TYPE=stdio
112 #OUT_TYPE=stdio
113
114 # A list of all tests
115 TESTS="1 2 3 4 5 6 7 8 9 10"
116
117 # A list of public tests (executed by submit and check scripts)
118 SAMPLE_TESTS="0"
119
120 # Number of points per test
121 POINTS_PER_TEST=1
122
123 # Time limit in seconds (can be fractional, but beware of noise)
124 TIME_LIMIT=10
125
126 # Memory limit in kilobytes
127 MEM_LIMIT=16384
128
129 # Command used for filtering of program output (optional)
130 # If turned on, program output (*.raw) is ran through this filter and the
131 # checkers are applied to the output of the filter (*.out).
132 # Can exit with code 1 if there is a syntax error in the output.
133 #OUTPUT_FILTER='tr -d '\''\r'\'' <$TDIR/$TEST.raw >$TDIR/$TEST.out'
134
135 # Command used to check output syntax (optional)
136 # Returns exit code 1 if syntax is wrong, 0 if correct
137 # fd1 is connect to evaluator log, feel free to log anything
138 # fd2 is an optional one-line verdict
139 #SYNTAX_CHECK='grep -v -- - $TDIR/$TEST.out'
140
141 # Command used to check output correctness
142 # Returns exit code 1 if output is incorrect, 0 if correct
143 # fd1 is connect to evaluator log, feel free to log anything
144 # fd2 is an optional one-line verdict
145 # The checker can generate $TDIR/$TEST.pts to assign points irregularly
146 OUTPUT_CHECK='diff -bBu $TDIR/$TEST.ok $TDIR/$TEST.out'
147
148 # Checker for interactive tasks
149 # Returns exit code 1 if test failed, 0 if passed
150 # fd0 and fd1 are connected to fd1 and fd0 of the program tested
151 # fd2 is an optional one-line verdict
152 # The checker can generate $TDIR/$TEST.pts to assign points irregularly
153 #IC_CHECK='$PDIR/checker $PDIR/$TEST.in $PDIR/$TEST.chk'
154
155 # Sandbox options used when testing
156 TEST_SANDBOX_OPTS='-a2 -f -m$MEM_LIMIT -t$TIME_LIMIT $LANG_SANDBOX_OPTS $BOX_EXTRAS'
157
158 # Extra options to be overridden in task configuration
159 BOX_EXTRAS=
160
161 ### Debugging and testing
162
163 # DEBUG: Let `ev' run sample tests, too.
164 #EV_SAMPLE=1
165
166 # DEBUG: Run `pedant' on all input data. Set either to `1' or to pedant's options.
167 #EV_PEDANT=1
168
169 # DEBUG: Skip checks (useful when generating output files by running model solution)
170 #EV_NOCHECK=1
171
172 # DEBUG: Skip output filters (if you suspect they are buggy)
173 #EV_NOFILTER=1
174
175 ### Variables overrides (most variables can be overridden for specific tests or source extensions):
176
177 #EXT_pas_TIME_LIMIT=100
178 #TEST_1_TIME_LIMIT=100
179 #EXT_pas_TEST_1_TIME_LIMIT=100