aboutsummaryrefslogtreecommitdiff
path: root/old/moves_trans/v2/genmovecode.sh
diff options
context:
space:
mode:
Diffstat (limited to 'old/moves_trans/v2/genmovecode.sh')
-rwxr-xr-xold/moves_trans/v2/genmovecode.sh21
1 files changed, 0 insertions, 21 deletions
diff --git a/old/moves_trans/v2/genmovecode.sh b/old/moves_trans/v2/genmovecode.sh
deleted file mode 100755
index 9d5fa7a..0000000
--- a/old/moves_trans/v2/genmovecode.sh
+++ /dev/null
@@ -1,21 +0,0 @@
1#!/bin/sh
2
3type="${1:-src}"
4
5gcc -DDEBUG h48_to_"$type".c ../cube.c -o h48_to_"$type"
6
7lineavx() { printf '#define _move_cube_%s ' "$1"; }
8linesrc() { printf '_static cube_fast_t _move_cube_%s = ' "$1"; }
9sedavx() { sed '1,2s/$/ \\/ ; 3s/$/)/ ; 3q'; }
10sedsrc() { sed '3s/$/ };/ ; 3q'; }
11
12gen() {
13 for f in move_??_*.txt; do
14 move="$(echo $f | sed 's/.*_// ; s/\.txt//')"
15 line$type "$move"
16 ./h48_to_"$type" <"$f" | sed$type
17 done
18}
19
20gen
21rm -f h48_to_"$type" invert

Generated with cgit - Back to sebastiano.tronto.net