OILS / deps / source.medo / time-helper / WEDGE View on Github | oilshell.org

43 lines, 33 significant
1# Wedge definition for time-helper
2#
3# Loaded by deps/wedge.sh.
4
5set -o nounset
6set -o pipefail
7set -o errexit
8
9# sourced
10WEDGE_NAME='time-helper'
11WEDGE_VERSION='2023-02-28'
12WEDGE_IS_ABSOLUTE=1 # TODO: consider relaxing
13
14wedge-make() {
15 local src_dir=$1
16 local build_dir=$2
17 local install_dir=$3
18
19 # TODO: Should not have access to this home dir!!!
20 # Usually this is _cache, but it's not here
21 local repo_root=/home/uke0/oil
22
23 local in=$repo_root/benchmarks/time-helper.c
24 local out=$build_dir/time-helper
25
26 # Copied from build/py.sh time-helper
27 cc -std=c99 -o $out $in
28}
29
30wedge-install() {
31 local build_dir=$1
32 local install_dir=$2
33
34 # TODO: The harness should make this
35 mkdir -p $install_dir
36 cp $build_dir/time-helper $install_dir/time-helper
37}
38
39wedge-smoke-test() {
40 local install_dir=$1
41
42 $install_dir/time-helper -o /dev/stdout -x true
43}