Skip to content

Commit a2082f9

Browse files
committed
Add make.sh script for windows support, update make-all.sh, add breadcrumb to premake to emulate Makefile contextual behavior
1 parent 81ba2aa commit a2082f9

File tree

7 files changed

+72
-9
lines changed

7 files changed

+72
-9
lines changed

.travis.before_install.windows.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+

.travis.yml

Lines changed: 34 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,14 @@ matrix:
3434
- os: osx
3535
compiler: clang
3636
env: CONFIG=release ARCH=x86_64
37+
- os: windows
38+
env: CONFIG=debug ARCH=x86_64
39+
- os: windows
40+
env: CONFIG=intermediate ARCH=x86_64
41+
- os: windows
42+
env: CONFIG=profile ARCH=x86_64
43+
- os: windows
44+
env: CONFIG=release ARCH=x86_64
3745
- os: linux
3846
compiler: gcc
3947
env: CONFIG=debug ARCH=x86
@@ -58,6 +66,14 @@ matrix:
5866
- os: osx
5967
compiler: clang
6068
env: CONFIG=release ARCH=x86
69+
- os: windows
70+
env: CONFIG=debug ARCH=x86
71+
- os: windows
72+
env: CONFIG=intermediate ARCH=x86
73+
- os: windows
74+
env: CONFIG=profile ARCH=x86
75+
- os: windows
76+
env: CONFIG=release ARCH=x86
6177
- os: linux
6278
compiler: gcc
6379
env: CONFIG=debug ARCH=x86_64 ARGS=--shared
@@ -82,6 +98,14 @@ matrix:
8298
- os: osx
8399
compiler: clang
84100
env: CONFIG=release ARCH=x86_64 ARGS=--shared
101+
- os: windows
102+
env: CONFIG=debug ARCH=x86_64 ARGS=--shared
103+
- os: windows
104+
env: CONFIG=intermediate ARCH=x86_64 ARGS=--shared
105+
- os: windows
106+
env: CONFIG=profile ARCH=x86_64 ARGS=--shared
107+
- os: windows
108+
env: CONFIG=release ARCH=x86_64 ARGS=--shared
85109
- os: linux
86110
compiler: gcc
87111
env: CONFIG=debug ARCH=x86 ARGS=--shared
@@ -106,6 +130,14 @@ matrix:
106130
- os: osx
107131
compiler: clang
108132
env: CONFIG=release ARCH=x86 ARGS=--shared
133+
- os: windows
134+
env: CONFIG=debug ARCH=x86 ARGS=--shared
135+
- os: windows
136+
env: CONFIG=intermediate ARCH=x86 ARGS=--shared
137+
- os: windows
138+
env: CONFIG=profile ARCH=x86 ARGS=--shared
139+
- os: windows
140+
env: CONFIG=release ARCH=x86 ARGS=--shared
109141
git:
110142
submodules: false
111143
before_install:
@@ -114,10 +146,10 @@ before_install:
114146
script:
115147
- cd Dependencies
116148
- "../premake.sh --architecture=${ARCH} gmake"
117-
- make -C Build -j4 config=${CONFIG}
149+
- "../make.sh ${CONFIG}"
118150
- cd ..
119151
- "./premake.sh --architecture=${ARCH} ${ARGS} gmake"
120-
- make -C Build -j4 config=${CONFIG}
152+
- "./make.sh ${CONFIG}"
121153
notifications:
122154
slack:
123155
secure: WGphmpc2xT8R701bspa9Q3z/I/zBoU+Sf069IXq/ATqgzqKBMxyjexQY4SwQmsEuZwC13Ax31uaT9hpcv02gEB29PDnCUFoRyWrdCrSDPsfAUvjY9LEDkUlxYXyeOqJ+jR7yleSIRK7CVyXJgHYvGXn9wwa7w/2JzgUvnhN8hFMLHWqX+bJ9oRPcZAzNkdT2TWxM5SkJCw5NL8UnSnY2Si1BKS1EFj3RX2FBgyHbYdBxXwTMSpSkzWpqvhTZruYLT7Hi9ZpUKgA0XIPxV+o2+ZYcoUczlBSa2yAK0yyestltMWhraYbCnIY6cRoqFXTRlX7SRSPYzf+HpDIZqlziX3jsNiUreYmWNZrp2sf4Lh76xUGsAvaqi3AeywPiWtT/t6z7GGHjIZ5TEIDRlFaMopTGNRTObEFG9VFCTFFprN7siie6roxAKs76gqC6t8w05fLS88Urerdf7dAMCo7ruVJ9dCKQgkLFM4XkNXrOKa2vNq1Iy0y30upd2SeuY0LTKlBS7BbeTxVsZOSO4obmy5HvJNzT76z8kw7OMBMwdVTaw8wLw3xuJkquZx+1em5ymO/YGzTelz34r5Dw6IMPn3Dfve1Q5skOTsGdJGNrxCogLhe6dEyj1ArKPzmYqmEA8y53pgCnbZ5IdQmmjYrri3ihUMrCOZkMYUjPwJrYe18=

Dependencies/premake5.lua

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
require( './premake' )
22

3+
-- This is a breadcrumb for the travis scripts
4+
print("Writing solution.txt...")
5+
local file = io.open("./Build/solution.txt", "w");
6+
file:write("Dependencies\n");
7+
file:close();
8+
39
workspace "Dependencies"
410
Helium.DoBasicWorkspaceSettings()
511

make-all.sh

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,27 @@
11
#!/bin/bash
22

3-
make -C Build $@ config=debug
3+
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
4+
5+
$DIR/make.sh debug
46
if [ "$?" -ne "0" ]; then
57
echo "Debug failed!"
68
exit 1
79
fi
810

9-
make -C Build $@ config=intermediate
11+
$DIR/make.sh intermediate
1012
if [ "$?" -ne "0" ]; then
1113
echo "Intermediate failed!"
1214
exit 1
1315
fi
1416

15-
make -C Build $@ config=profile
17+
$DIR/make.sh profile
1618
if [ "$?" -ne "0" ]; then
1719
echo "Profile failed!"
1820
exit 1
1921
fi
2022

21-
make -C Build $@ config=release
23+
$DIR/make.sh release
2224
if [ "$?" -ne "0" ]; then
2325
echo "Release failed!"
2426
exit 1
2527
fi
26-
27-
popd

make.sh

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
#!/bin/bash
2+
3+
pushd Build
4+
5+
if [ `uname` == "Darwin" ]; then
6+
make -j4 config=$1
7+
elif [ `uname` == "Linux" ]; then
8+
make -j4 config=$1
9+
else
10+
VSINSTALL=`"/c/Program Files (x86)/Microsoft Visual Studio/Installer/vswhere.exe" -property installationPath`
11+
VSINSTALL_BASH=`cygpath -a "$VSINSTALL"`
12+
SOLUTION=`cat solution.txt`
13+
#cmd //c "$VSINSTALL_BASH/VC/Auxiliary/Build/vcvars64.bat" \&\& devenv.com Dependencies.sln //build debug
14+
cmd //c "$VSINSTALL_BASH/VC/Auxiliary/Build/vcvars64.bat" \&\& msbuild $SOLUTION.sln //p:Configuration=$1 //verbosity:minimal
15+
fi
16+
17+
popd

premake.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
#!/bin/bash
2+
13
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
24

35
if [ ! -f $DIR/Dependencies/premake/bin/release/premake5 ]; then

premake5.lua

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,12 @@
11
require( './premake' )
22

3-
workspace "Core"
3+
-- This is a breadcrumb for the travis scripts
4+
print("Writing solution.txt...")
5+
local file = io.open("./Build/solution.txt", "w");
6+
file:write("Core\n");
7+
file:close();
48

9+
workspace "Core"
510
Helium.DoBasicWorkspaceSettings()
611

712
configuration "Debug"

0 commit comments

Comments
 (0)