~zethra/stargazer

ref: fbbf828c33087d1601d81db7c99c41d71fcb930f stargazer/scripts/build -rwxr-xr-x 551 bytes
fbbf828c — Ben Aaron Goldberg config: add bad config for testing 4 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#!/bin/sh

set -e

CG=${CG:-cargo}
CGFLAGS=${CGFLAGS:-'--release'}
SCDOC=${SCDOC:-scdoc}
CGOUT=${CGOUT:-'./target/release/stargazer'}
STRIP=${STRIP:-strip}

# Build stargazer
$CG build $CGFLAGS

if command -v "$STRIP" &> /dev/null; then
	strip -s "$CGOUT"
else
	1>&2 echo 'Warning: strip not install - binary not striped'
fi

# Build docs
if command -v "$SCDOC" &> /dev/null; then
	$SCDOC < ./doc/stargazer.scd > stargazer.1
	$SCDOC < ./doc/stargazer-ini.scd > stargazer.ini.5
else
	1>&2 echo 'Warning: scdoc not install - man pages not generated'
fi