/
windowsBuild
executable file
·57 lines (38 loc) · 1.05 KB
/
windowsBuild
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
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
#!/bin/bash
# Run the codegen and get the files
# Get to the codegen
cd ../codegen/
# Run it
python main.py templates
# Copy the appropriate files over
cp -f -r ./output/visualizer/* ../visualizer/lib/parser/
# First compile parser for linux
# Get to Parser directory:
cd ../visualizer/lib/parser
# We want to remove all linux binaries and helper files
make clean
# Build Parser for Windows:
make TARGET=mingw
# Congrats, a windows parser has now been built for you.
# Back to the root directory:
cd ../../
# Build Makefiles for windows:
qmake -spec win32-x-g++
# Leave off release if you want a debug build
make release
# Clean up windows mess
make clean
# Your visualizer.exe executable will now be in ./release or ./debug
# Now reset everything so that it compiles appropriately in linux
# Build linux make files
qmake
# Get to parser directory:
cd ./lib/parser
# Remove windows specific stuff
make clean
# Congrats, you're done
cd ../..
mkdir release/piracy
cp -r ./piracy/textures ./release/piracy
cp ./options.cfg ./release/
cp ./textures.r ./release/