00cc9309cb
de6e324bdseparate emu thread10d3daf86Roms List improvements95d202f37Let's make the rom list process on a separate thread so the emulator doesnt take ages to load.fc306967fWow the ROM Header was just completely busted. Game list view works nowbad1691eefuck this shit2b59e5f46game list in progressd26417b83remappable inputs in progressac4af8106inpute72abc240update readme430139dc9Qt6 frontend3080d4d45Fix this small bug too08cd13b85Cop0 unused functions do not actually pose a threat (as per manual). They don't do anything, so shall we.61bb4fb44make idle loop detection a little more specific with where the load goesb037de4c3SAZDFsdff12e81e73eneed to figure out why n64-systemtest loops indefinitely at some address that appears to be valid (i think it's me not invalidating the cache properly)204f0e13bidle skipping seems to work!cb8bb634asdkfjlasdf58e5c89c1Fix compilation issue on my machine (no idea)24fb2898eattempting more serious idle skipping214719577Place rsp.Step inside cached interpreter. Gains about 3 more fpsbb97dcc23mmmmm920b77d38wjkhasdfjhkasdf430ccdab4it's a start...4f42a673aCached interpreter plays Mario 64. Start looking into RSP as wellc9a030787idle skipping works!5fbda03cenew idea366637abaIdle skipping... maybe?609fa2fb0Cache instructions implemented but broken lmao. Commented out for nowe140a6d12- Stop using inheritance for CPU, instead use composition. - Introduce KAIZEN_JIT_ENABLED optional define instead of relying on __aarch64__ and the like. - More cache work68e613057prep cache impl811b4d809fix clang formatfda755f7didkd5024ebbfsmall MI refactor in preparation of (eventually) implementing the RDRAM interface properly694b45341Merge commit '206dcdedf195fb320913584180edb12c7731e396' as 'external/SDL'206dcdedfSquashed 'external/SDL/' content from commit 4d17b99d0a4d16e1cb4need to update sdl848b19920Fix compilation errordb61b5299Merge commit 'e94a94559f28e49678fbcf72199a5258137b0fe9' as 'external/imgui'e94a94559Squashed 'external/imgui/' content from commit 02e9b8cac52edb3757need to update imguic1a705e86Emulate weird JALR behaviour4b4c32f4bFix exception for "unusable COP1" in 4 instructions i missed accidentally (again)df5828142Bug putting 0s in the log everywheref8b580048Make isviewer a sink to file8241e9735Fix exception for "unusable COP1" in 4 instructions i missed accidentallyb29715f20small changesd9a620bc1make use of my new small utility library0d1aa938eAdd 'external/ircolib/' from commit 'ce3cd726c8df8388d554abf8bb55d55020eb4450'e64eb40b3Fuck git git-subtree-dir: external/ircolib git-subtree-split:de6e324bde
217 lines
6.0 KiB
Plaintext
217 lines
6.0 KiB
Plaintext
|
|
# NOTICE
|
|
|
|
> Please be aware that the Makefile build is deprecated.
|
|
> Use cmake instead.
|
|
|
|
<hr>
|
|
|
|
This documentation explains how to compile, install & run Capstone on MacOSX,
|
|
Linux, *BSD & Solaris. We also show steps to cross-compile for Microsoft Windows.
|
|
|
|
To natively compile for Windows using Microsoft Visual Studio, see BUILDING.md.
|
|
|
|
To compile using CMake, see BUILDING.md.
|
|
|
|
To compile using XCode on MacOSX, see xcode/README.md.
|
|
|
|
To compile for Windows CE (a.k.a, Windows Embedded Compact), see windowsce/COMPILE.md.
|
|
|
|
*-*-*-*-*-*
|
|
|
|
Capstone requires no prerequisite packages, so it is easy to compile & install.
|
|
|
|
|
|
|
|
(0) Tailor Capstone to your need.
|
|
|
|
Out of all architectures supported by Capstone, if you just need several
|
|
selected archs, choose the ones you want to compile in by editing "config.mk"
|
|
before going to next steps.
|
|
|
|
By default, all architectures are compiled.
|
|
|
|
The other way of customize Capstone without having to edit config.mk is to
|
|
pass the desired options on the commandline to ./make.sh. Currently,
|
|
Capstone supports 8 options, as followings.
|
|
|
|
- CAPSTONE_ARCHS: specify list of architectures to compiled in.
|
|
- CAPSTONE_USE_SYS_DYN_MEM: change this if you have your own dynamic memory management.
|
|
- CAPSTONE_DIET: use this to make the output binaries more compact.
|
|
- CAPSTONE_X86_REDUCE: another option to make X86 binary smaller.
|
|
- CAPSTONE_X86_ATT_DISABLE: disables AT&T syntax on x86.
|
|
- CAPSTONE_STATIC: build static library.
|
|
- CAPSTONE_SHARED: build dynamic (shared) library.
|
|
- CAPSTONE_DEBUG: enable debug build supporting assert().
|
|
|
|
By default, Capstone uses system dynamic memory management, both DIET and X86_REDUCE
|
|
modes are disable, and builds all the static & shared libraries.
|
|
|
|
To avoid editing config.mk for these customization, we can pass their values to
|
|
make.sh, as followings.
|
|
|
|
$ CAPSTONE_ARCHS="arm aarch64 x86" CAPSTONE_USE_SYS_DYN_MEM=no CAPSTONE_DIET=yes CAPSTONE_X86_REDUCE=yes ./make.sh
|
|
|
|
NOTE: on commandline, put these values in front of ./make.sh, not after it.
|
|
|
|
For each option, refer to docs/README for more details.
|
|
|
|
|
|
|
|
(1) Compile from source
|
|
|
|
On *nix (such as MacOSX, Linux, *BSD, Solaris):
|
|
|
|
- To compile for current platform, run:
|
|
|
|
$ ./make.sh
|
|
|
|
- On 64-bit OS, run the command below to cross-compile Capstone for 32-bit binary:
|
|
|
|
$ ./make.sh nix32
|
|
|
|
|
|
|
|
(2) Install Capstone on *nix
|
|
|
|
To install Capstone, run:
|
|
|
|
$ sudo ./make.sh install
|
|
|
|
For FreeBSD/OpenBSD, where sudo is unavailable, run:
|
|
|
|
$ su; ./make.sh install
|
|
|
|
Users are then required to enter root password to copy Capstone into machine
|
|
system directories.
|
|
|
|
Afterwards, run ./tests/test* to see the tests disassembling sample code.
|
|
|
|
|
|
NOTE: The core framework installed by "./make.sh install" consist of
|
|
following files:
|
|
|
|
/usr/include/capstone/arm.h
|
|
/usr/include/capstone/arm64.h
|
|
/usr/include/capstone/alpha.h
|
|
/usr/include/capstone/arc.h
|
|
/usr/include/capstone/bpf.h
|
|
/usr/include/capstone/capstone.h
|
|
/usr/include/capstone/evm.h
|
|
/usr/include/capstone/hppa.h
|
|
/usr/include/capstone/loongarch.h
|
|
/usr/include/capstone/m680x.h
|
|
/usr/include/capstone/m68k.h
|
|
/usr/include/capstone/mips.h
|
|
/usr/include/capstone/mos65xx.h
|
|
/usr/include/capstone/platform.h
|
|
/usr/include/capstone/ppc.h
|
|
/usr/include/capstone/sparc.h
|
|
/usr/include/capstone/systemz.h
|
|
/usr/include/capstone/tms320c64x.h
|
|
/usr/include/capstone/wasm.h
|
|
/usr/include/capstone/x86.h
|
|
/usr/include/capstone/xcore.h
|
|
/usr/include/capstone/tricore.h
|
|
/usr/lib/libcapstone.a
|
|
/usr/lib/libcapstone.so (for Linux/*nix), or /usr/lib/libcapstone.dylib (OSX)
|
|
|
|
|
|
|
|
(3) Cross-compile for Windows from *nix
|
|
|
|
To cross-compile for Windows, Linux & gcc-mingw-w64-i686 (and also gcc-mingw-w64-x86-64
|
|
for 64-bit binaries) are required.
|
|
|
|
- To cross-compile Windows 32-bit binary, simply run:
|
|
|
|
$ ./make.sh cross-win32
|
|
|
|
- To cross-compile Windows 64-bit binary, run:
|
|
|
|
$ ./make.sh cross-win64
|
|
|
|
Resulted files libcapstone.dll, libcapstone.dll.a & tests/test*.exe can then
|
|
be used on Windows machine.
|
|
|
|
|
|
|
|
(4) Cross-compile for iOS from Mac OSX.
|
|
|
|
To cross-compile for iOS (iPhone/iPad/iPod), Mac OSX with XCode installed is required.
|
|
|
|
- To cross-compile for ArmV7 (iPod 4, iPad 1/2/3, iPhone4, iPhone4S), run:
|
|
$ ./make.sh ios_armv7
|
|
|
|
- To cross-compile for ArmV7s (iPad 4, iPhone 5C, iPad mini), run:
|
|
$ ./make.sh ios_armv7s
|
|
|
|
- To cross-compile for Arm64 (iPhone 5S, iPad mini Retina, iPad Air), run:
|
|
$ ./make.sh ios_arm64
|
|
|
|
- To cross-compile for all iDevices (armv7 + armv7s + arm64), run:
|
|
$ ./make.sh ios
|
|
|
|
Resulted files libcapstone.dylib, libcapstone.a & tests/test* can then
|
|
be used on iOS devices.
|
|
|
|
|
|
|
|
(5) Cross-compile for Android
|
|
|
|
To cross-compile for Android (smartphone/tablet), Android NDK is required.
|
|
NOTE: Only ARM and AARCH64 are currently supported.
|
|
|
|
$ NDK=/android/android-ndk-r10e ./make.sh cross-android arm
|
|
or
|
|
$ NDK=/android/android-ndk-r10e ./make.sh cross-android arm64
|
|
|
|
Resulted files libcapstone.so, libcapstone.a & tests/test* can then
|
|
be used on Android devices.
|
|
|
|
|
|
|
|
(6) Compile on Windows with Cygwin
|
|
|
|
To compile under Cygwin gcc-mingw-w64-i686 or x86_64-w64-mingw32 run:
|
|
|
|
- To compile Windows 32-bit binary under Cygwin, run:
|
|
|
|
$ ./make.sh cygwin-mingw32
|
|
|
|
- To compile Windows 64-bit binary under Cygwin, run:
|
|
|
|
$ ./make.sh cygwin-mingw64
|
|
|
|
Resulted files libcapstone.dll, libcapstone.dll.a & tests/test*.exe can then
|
|
be used on Windows machine.
|
|
|
|
|
|
|
|
(7) By default, "cc" (default C compiler on the system) is used as compiler.
|
|
|
|
- To use "clang" compiler instead, run the command below:
|
|
|
|
$ ./make.sh clang
|
|
|
|
- To use "gcc" compiler instead, run:
|
|
|
|
$ ./make.sh gcc
|
|
|
|
|
|
|
|
(8) To uninstall Capstone, run the command below:
|
|
|
|
$ sudo ./make.sh uninstall
|
|
|
|
|
|
|
|
(9) Language bindings
|
|
|
|
So far, Python, Ocaml & Java are supported by bindings in the main code.
|
|
Look for the bindings under directory bindings/, and refer to README file
|
|
of corresponding languages.
|
|
|
|
Community also provide bindings for C#, Go, Ruby, NodeJS, C++ & Vala. Links to
|
|
these can be found at address http://capstone-engine.org/download.html
|