forked from JonathanSalwan/Triton
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.appveyor.yml
158 lines (141 loc) · 6.21 KB
/
.appveyor.yml
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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
version: 1.0.{build}
branches:
only:
- master
- /dev-.*/
configuration:
- Release
clone_folder: c:\projects\triton
environment:
CAPSTONE_INCLUDE_DIRS: c:\projects\triton\build\capstone-4.0.2\include
PLATFORM_TOOLSET: v142
CMAKE_TEMPLATE: Visual Studio 16 2019
matrix:
# 32-bit, python3.6, boost off
- platform: Win32
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
PYTHON: C:\Python36
CAPSTONE_LIBRARIES: c:\projects\triton\build\capstone-4.0.2\msvc\%configuration%\capstone.lib
LIEF_VERSION: 0.10.1
LIEF_ZIP: lief-0.10.1-cp36-cp36m-win32.whl
Z3_INCLUDE_DIRS: c:\projects\triton\build\z3-4.8.9-x86-win\include
Z3_LIBRARIES: c:\projects\triton\build\z3-4.8.9-x86-win\bin\libz3.lib
Z3_PKG_NAME: z3-4.8.9-x86-win
PYTHON_VERSION: 3.6
BOOST_INTERFACE: off
# 64-bit, python3.6, boost off
- platform: x64
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
PYTHON: C:\Python36-x64
CAPSTONE_LIBRARIES: c:\projects\triton\build\capstone-4.0.2\msvc\x64\%configuration%\capstone.lib
LIEF_VERSION: 0.10.1
LIEF_ZIP: lief-0.10.1-cp36-cp36m-win_amd64.whl
Z3_INCLUDE_DIRS: c:\projects\triton\build\z3-4.8.9-x64-win\include
Z3_LIBRARIES: c:\projects\triton\build\z3-4.8.9-x64-win\bin\libz3.lib
Z3_PKG_NAME: z3-4.8.9-x64-win
PYTHON_VERSION: 3.6
BOOST_INTERFACE: off
# 64-bit, python3.7, boost off
- platform: x64
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
PYTHON: C:\Python37-x64
CAPSTONE_LIBRARIES: c:\projects\triton\build\capstone-4.0.2\msvc\x64\%configuration%\capstone.lib
LIEF_VERSION: 0.10.1
LIEF_ZIP: lief-0.10.1-cp37-cp37m-win_amd64.whl
Z3_INCLUDE_DIRS: c:\projects\triton\build\z3-4.8.9-x64-win\include
Z3_LIBRARIES: c:\projects\triton\build\z3-4.8.9-x64-win\bin\libz3.lib
Z3_PKG_NAME: z3-4.8.9-x64-win
PYTHON_VERSION: 3.7
BOOST_INTERFACE: off
# 64-bit, python3.8, boost off
- platform: x64
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
PYTHON: C:\Python38-x64
CAPSTONE_LIBRARIES: c:\projects\triton\build\capstone-4.0.2\msvc\x64\%configuration%\capstone.lib
LIEF_VERSION: 0.12.1
LIEF_ZIP: lief-0.12.1-cp38-cp38-win_amd64.whl
Z3_INCLUDE_DIRS: c:\projects\triton\build\z3-4.8.9-x64-win\include
Z3_LIBRARIES: c:\projects\triton\build\z3-4.8.9-x64-win\bin\libz3.lib
Z3_PKG_NAME: z3-4.8.9-x64-win
PYTHON_VERSION: 3.8
BOOST_INTERFACE: off
# 64-bit, python3.9, boost off
- platform: x64
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
PYTHON: C:\Python39-x64
CAPSTONE_LIBRARIES: c:\projects\triton\build\capstone-4.0.2\msvc\x64\%configuration%\capstone.lib
LIEF_VERSION: 0.12.1
LIEF_ZIP: lief-0.12.1-cp39-cp39-win_amd64.whl
Z3_INCLUDE_DIRS: c:\projects\triton\build\z3-4.8.9-x64-win\include
Z3_LIBRARIES: c:\projects\triton\build\z3-4.8.9-x64-win\bin\libz3.lib
Z3_PKG_NAME: z3-4.8.9-x64-win
PYTHON_VERSION: 3.9
BOOST_INTERFACE: off
# 64-bit, python3.10, boost off
- platform: x64
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
PYTHON: C:\Python310-x64
CAPSTONE_LIBRARIES: c:\projects\triton\build\capstone-4.0.2\msvc\x64\%configuration%\capstone.lib
LIEF_VERSION: 0.12.1
LIEF_ZIP: lief-0.12.1-cp310-cp310-win_amd64.whl
Z3_INCLUDE_DIRS: c:\projects\triton\build\z3-4.8.9-x64-win\include
Z3_LIBRARIES: c:\projects\triton\build\z3-4.8.9-x64-win\bin\libz3.lib
Z3_PKG_NAME: z3-4.8.9-x64-win
PYTHON_VERSION: 3.10
BOOST_INTERFACE: off
# 64-bit, python3.10, boost on
- platform: x64
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
PYTHON: C:\Python310-x64
CAPSTONE_LIBRARIES: c:\projects\triton\build\capstone-4.0.2\msvc\x64\%configuration%\capstone.lib
LIEF_VERSION: 0.12.1
LIEF_ZIP: lief-0.12.1-cp310-cp310-win_amd64.whl
Z3_INCLUDE_DIRS: c:\projects\triton\build\z3-4.8.9-x64-win\include
Z3_LIBRARIES: c:\projects\triton\build\z3-4.8.9-x64-win\bin\libz3.lib
Z3_PKG_NAME: z3-4.8.9-x64-win
PYTHON_VERSION: 3.10
BOOST_INTERFACE: on
BOOST_ROOT: C:\Libraries\boost_1_73_0
Boost_INCLUDE_DIR: C:\Libraries\boost_1_73_0
install:
- set PATH=%PYTHON%;%PATH%
- cmd: cd C:\projects\triton
- cmd: mkdir build
- cmd: cd build
# Install z3 in the path
- cmd: echo Downloading z3...
- cmd: appveyor DownloadFile https://github.com/Z3Prover/z3/releases/download/z3-4.8.9/%Z3_PKG_NAME%.zip
- cmd: 7z x %Z3_PKG_NAME%.zip
- cmd: copy %Z3_PKG_NAME%\bin\libz3.dll C:\Windows\System32
- set PATH=C:\projects\triton\build\%Z3_PKG_NAME%\bin;%PATH%
- set PYTHONPATH=C:\projects\triton\build\%Z3_PKG_NAME%\bin\python;%PYTHONPATH%
# Install capstone
- cmd: echo Downloading capstone...
- cmd: appveyor DownloadFile https://github.com/aquynh/capstone/archive/4.0.2.zip
- cmd: 7z x 4.0.2.zip
- cmd: echo Building capstone...
- cmd: msbuild capstone-4.0.2\msvc\capstone.sln /p:Configuration=%configuration% /p:Platform=%platform% /p:PlatformToolset=%PLATFORM_TOOLSET% /t:capstone_static /m
# Install LIEF
- cmd: echo Downloading LIEF...
- cmd: appveyor DownloadFile https://github.com/lief-project/LIEF/releases/download/%LIEF_VERSION%/%LIEF_ZIP%
- cmd: echo Install LIEF...
- cmd: python -m pip install %LIEF_ZIP%
# Running cmake for Triton
- cmd: echo Running cmake for Triton...
- cmd: cmake -DBOOST_INTERFACE=%BOOST_INTERFACE% -DPYTHON_VERSION=%PYTHON_VERSION% .. -A %platform% -G "%CMAKE_TEMPLATE%"
build_script:
- cmd: msbuild c:\projects\triton\build\triton.sln /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll" /t:python-triton /m:3
# - cmd: cmake --build . --config release
test_script:
- cmd: ctest --test-dir . -C Release --output-on-failure
after_test:
# Check installation
- cmd: cmake --build . --config Release --target install
# generate artifact
- cmd: cd src\libtriton\%configuration%
- cmd: copy ..\..\..\%Z3_PKG_NAME%\bin\libz3.dll libz3.dll
- cmd: copy triton.dll triton.pyd
- cmd: if "%platform%"=="Win32" 7z a -t7z ..\..\..\..\triton.x86.release.7z *
- cmd: if "%platform%"=="x64" 7z a -t7z ..\..\..\..\triton.x64.release.7z *
artifacts:
- path: triton.*.7z