Skip to content

Commit 3d3147d

Browse files
committed
windows bat files don't have getting/generating builtins.txt features so ported them from linux shell
1 parent c9a8277 commit 3d3147d

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

pre_win.sh

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# run this on mingw before running creator_win*.sh
2+
3+
curl -O https://raw.githubusercontent.com/Sei-Lisa/kwdb/master/outputs/builtins.txt
4+
5+
echo "#ifdef _MSC_VER" > builtins_txt.cc
6+
echo "#pragma execution_character_set(\"utf-8\")" >> builtins_txt.cc
7+
echo "#endif" >> builtins_txt.cc
8+
echo "const char *builtins_txt[] = {" >> builtins_txt.cc
9+
sed -e '/^\/\//d; s/"/\\\"/g; s/^/"/; s/$/",/' builtins.txt >> builtins_txt.cc || { rm -f builtins_txt.cc ; false ; }
10+
echo "(char*)0 };" >> builtins_txt.cc

0 commit comments

Comments
 (0)