• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1:: Capstone disassembler engine (www.capstone-engine.org)
2:: Build Capstone libs (capstone.dll & capstone.lib) on Windows with CMake & Nmake
3:: By Nguyen Anh Quynh, Jorn Vernee, 2017, 2019
4
5@echo off
6
7set flags="-DCMAKE_BUILD_TYPE=Release -DCAPSTONE_BUILD_STATIC_RUNTIME=ON"
8
9if "%1"=="ARM" set %arch%=ARM
10if "%1"=="ARM64" set %arch%=ARM64
11if "%1"=="M68K" set %arch%=M68K
12if "%1"=="MIPS" set %arch%=MIPS
13if "%1"=="PowerPC" set %arch%=PPC
14if "%1"=="Sparc" set %arch%=SPARC
15if "%1"=="SystemZ" set %arch%=SYSZ
16if "%1"=="XCore" set %arch%=XCORE
17if "%1"=="x86" set %arch%=X86
18if "%1"=="TMS320C64x" set %arch%=TMS320C64X
19if "%1"=="M680x" set %arch%=M680X
20if "%1"=="EVM" set %arch%=EVM
21if "%1"=="MOS65XX" set %arch%=MOS65XX
22
23if not "%arch%"=="" set flags=%flags% and " -DCAPSTONE_ARCHITECTURE_DEFAULT=OFF -DCAPSTONE_%arch%_SUPPORT=ON"
24
25cmake %flags% -G "NMake Makefiles" ..
26nmake
27
28