Skip to content

Commit acd1d08

Browse files
travis-ci: add mac build + prototype for windows.
additionally fix base-requirements.
1 parent 6aa092d commit acd1d08

File tree

2 files changed

+41
-20
lines changed

2 files changed

+41
-20
lines changed

.travis.yml

+40-19
Original file line numberDiff line numberDiff line change
@@ -1,40 +1,61 @@
11
git:
22
depth: 1
3-
language: cpp
4-
compiler: gcc
5-
sudo: false
6-
dist: trusty
73

84
env:
95
global:
106
- secure: "VsvGz6WqBVbT+RpnaWwYb16mVvQHQMvzfRxLlUEnYBVkKCWBgyECDXRL/ShBwGW+aMYW25ZPt/aJNk7rN/wvTrgGU2N9X6CrfVyGPp94HPSYPzEbZSXRoCGex30HkVVITYUBDd06CWuMMIOgS7At/XdJIR1ZjZpOr91Oze3YbGA="
117

12-
addons:
13-
apt:
14-
sources: ['ubuntu-toolchain-r-test']
15-
packages: ['g++-6', 'g++-6-multilib', 'lib32stdc++6', 'lib32z1-dev', 'libc6-dev-i386', 'linux-libc-dev', 'g++-multilib']
16-
8+
matrix:
9+
fast_finish: true
10+
include:
11+
- os: linux
12+
dist: trusty
13+
language: cpp
14+
compiler: gcc
15+
addons:
16+
apt:
17+
sources: ['ubuntu-toolchain-r-test']
18+
packages: ['lib32stdc++6', 'lib32z1-dev', 'libc6-dev-i386', 'linux-libc-dev', 'g++-multilib']
19+
env:
20+
- AMB="install --user"
21+
- PATH="~/.local/bin:$PATH"
22+
- RELEASE_PKG_FILE="package-lin.tgz"
23+
# - os: windows
24+
# language: cpp
25+
# env:
26+
# - AMB="install"
27+
# - PATH="$PATH:/C/ProgramData/chocolatey/bin:/C/ProgramData/chocolatey/lib/mingw/tools/install/mingw64/opt/bin"
28+
# - RELEASE_PKG_FILE="package-win.tgz"
29+
- os: mac
30+
osx_image: xcode7.2
31+
language: cpp
32+
compiler: clang
33+
env:
34+
- AMB="install"
35+
- PATH="~/.local/bin:$PATH"
36+
- RELEASE_PKG_FILE="package-mac.tgz"
37+
1738
before_script:
18-
- CHECKOUT_DIR=$PWD && cd ..
39+
- mkdir assets && cd assets
1940
- git clone https://github.com/alliedmodders/ambuild.git
2041
- cd ambuild
2142
- python setup.py build
22-
- python setup.py install --user
43+
- python setup.py $AMB
2344
- cd ..
2445
- git clone --depth 1 --recurse-submodules -j8 --shallow-submodules https://$OAUTH@github.com/SteamDatabase/SteamworksSDK.git SteamworksSDK
2546
- git clone --depth 1 --recurse-submodules -j8 --shallow-submodules -b sdk2013 https://github.com/alliedmodders/hl2sdk.git hl2sdk-sdk2013
26-
- git clone --depth 1 --recurse-submodules -j8 --shallow-submodules https://github.com/alliedmodders/metamod-source.git mmsource-central
47+
- git clone --depth 1 --recurse-submodules -j8 --shallow-submodules -b 1.10-dev https://github.com/alliedmodders/metamod-source.git mmsource-central
2748
- git clone --depth 1 --recurse-submodules -j8 --shallow-submodules -b 1.7-dev https://github.com/alliedmodders/sourcemod.git sourcemod-central
28-
- cd $CHECKOUT_DIR
49+
- cd ..
2950

3051
script:
31-
- PATH="~/.local/bin:$PATH"
32-
- mkdir build && cd build
33-
- python ../configure.py -s 'sdk2013' --hl2sdk-root=../../ --sm-path=../../sourcemod-central --mms-path=../../mmsource-central --steamworks-path=../../SteamworksSDK
52+
- mkdir build
53+
- cd build
54+
- cp ../AMBuildScript ../../
55+
- python2 ../configure.py -s sdk2013 --hl2sdk-root ../assets --sm-path ../assets/sourcemod-central --mms-path ../assets/mmsource-central --steamworks-path ../assets/SteamworksSDK
3456
- ambuild
35-
- tar czvf package-lin.tgz package
36-
- export RELEASE_PKG_FILE=$(ls *.tgz)
37-
57+
- tar czvf ${RELEASE_PKG_FILE} package
58+
3859
deploy:
3960
provider: releases
4061
api_key:

Extension/AMBuilder

+1-1
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,6 @@ for sdk_name in SteamWorks.sdks:
3535
binary.compiler.postlink += os.path.join(SteamWorks.steamworks_root, 'redistributable_bin', 'steam_api.lib'),;
3636

3737
if builder.target_platform == 'mac':
38-
binary.compiler.postlink += os.path.join(SteamWorks.steamworks_root, 'redistributable_bin', 'osx32', 'libsteam_api.dylib'),;
38+
binary.compiler.postlink += os.path.join(SteamWorks.steamworks_root, 'redistributable_bin', 'osx', 'libsteam_api.dylib'),;
3939

4040
SteamWorks.extensions += builder.Add(project)

0 commit comments

Comments
 (0)