forked from capstone-engine/capstone
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
63 additions
and
59 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,59 +1,63 @@ | ||
# Capstone disassembler engine (www.capstone-engine.org) | ||
# Build Capstone libs for specified architecture, or all if none is specified (libcapstone.so & libcapstone.a) on *nix with CMake & make | ||
# By Nguyen Anh Quynh, Jorn Vernee, 2019 | ||
|
||
FLAGS="-DCMAKE_BUILD_TYPE=Release" | ||
# Uncomment below line to compile in Diet mode | ||
# FLAGS+=" -DCAPSTONE_BUILD_DIET=ON" | ||
|
||
case $1 in | ||
ARM) | ||
ARCH=ARM | ||
;; | ||
ARM64) | ||
ARCH=ARM64 | ||
;; | ||
M68K) | ||
ARCH=M68K | ||
;; | ||
MIPS) | ||
ARCH=MIPS | ||
;; | ||
PowerPC) | ||
ARCH=PPC | ||
;; | ||
Sparc) | ||
ARCH=SPARC | ||
;; | ||
SystemZ) | ||
ARCH=SYSZ | ||
;; | ||
XCore) | ||
ARCH=XCORE | ||
;; | ||
x86) | ||
ARCH=X86 | ||
;; | ||
TMS320C64x) | ||
ARCH=TMS320C64X | ||
;; | ||
M680x) | ||
ARCH=M680X | ||
;; | ||
EVM) | ||
ARCH=EVM | ||
;; | ||
MOS65XX) | ||
ARCH=MOS65XX | ||
;; | ||
*) | ||
;; | ||
esac | ||
|
||
if test "x$ARCH" = "x"; then | ||
FLAGS+=" -DCAPSTONE_ARCHITECTURE_DEFAULT=OFF -DCAPSTONE_$ARCH_SUPPORT=ON" | ||
fi | ||
|
||
cmake $FLAGS .. | ||
|
||
make -j8 | ||
#!/bin/sh | ||
|
||
# Capstone disassembler engine (www.capstone-engine.org) | ||
# Build Capstone libs for specified architecture, or all if none is specified (libcapstone.so & libcapstone.a) on *nix with CMake & make | ||
# By Nguyen Anh Quynh, Jorn Vernee, 2019 | ||
|
||
FLAGS="-DCMAKE_BUILD_TYPE=Release" | ||
# Uncomment below line to compile in Diet mode | ||
# FLAGS+=" -DCAPSTONE_BUILD_DIET=ON" | ||
|
||
case $1 in | ||
ARM) | ||
ARCH=ARM | ||
;; | ||
ARM64) | ||
ARCH=ARM64 | ||
;; | ||
M68K) | ||
ARCH=M68K | ||
;; | ||
MIPS) | ||
ARCH=MIPS | ||
;; | ||
PowerPC) | ||
ARCH=PPC | ||
;; | ||
Sparc) | ||
ARCH=SPARC | ||
;; | ||
SystemZ) | ||
ARCH=SYSZ | ||
;; | ||
XCore) | ||
ARCH=XCORE | ||
;; | ||
x86) | ||
ARCH=X86 | ||
;; | ||
TMS320C64x) | ||
ARCH=TMS320C64X | ||
;; | ||
M680x) | ||
ARCH=M680X | ||
;; | ||
EVM) | ||
ARCH=EVM | ||
;; | ||
MOS65XX) | ||
ARCH=MOS65XX | ||
;; | ||
*) | ||
;; | ||
esac | ||
|
||
if "${ARCH}" == ""; then | ||
FLAGS+=" -DCAPSTONE_ARCHITECTURE_DEFAULT=ON" | ||
else | ||
FLAGS+=" -DCAPSTONE_ARCHITECTURE_DEFAULT=OFF -DCAPSTONE_${ARCH}_SUPPORT=ON" | ||
fi | ||
|
||
cmake $FLAGS .. | ||
|
||
make -j8 |