Skip to content

Commit 61a3251

Browse files
authored
Create README_compile_macOS.md
1 parent abb2614 commit 61a3251

File tree

1 file changed

+49
-0
lines changed

1 file changed

+49
-0
lines changed

README_compile_macOS.md

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
# Mednafen
2+
3+
## Compiling this Repository on macOS (tested on Monterey)
4+
5+
### Dependencies
6+
7+
Mednafen is built upon a number of external libraries which are required in order to have a successful compile.
8+
9+
The below is assuming that you already have a working install of Homebrew/MacPorts, and a working set of git/autoconf/automake/gcc/make and the Xcode Command Line Tools installed,
10+
if not the following (and other) commands may still be needed:
11+
12+
```
13+
Get Xcode Command Line tools:
14+
xcode-select --install
15+
```
16+
17+
We have confirmed a successful Mednafen build on macOS Monterey running on both Intel(x86_64) and Apple silicon M1(ARM64) architectures and will provide instructions accordingly.
18+
19+
For a native Intel(x86_64) build we will use "Homebrew" to pull in the needed Mednafen dependencies:
20+
```
21+
brew install pkg-config gettext sdl2 libsndfile jack lzo zstd
22+
```
23+
24+
For a native Apple silicon M1(ARM64) build we will have to use "MacPorts" in order to get the correct Mednafen dependencies to build:
25+
```
26+
sudo port -N install pkgconfig clang-14 libiconv libsdl2 libcdio gettext libsndfile libmpcdec zlib
27+
```
28+
29+
### Compilation Commands
30+
31+
Mednafen's build process makes use of 'configure' in order to set up environment-specific options in preparation
32+
for the compile; the below instructions to build Mednafen will attempt to use all of your machine's threads when compiling as the compilation process can take up quite some time, the procedure is as follows :
33+
34+
```
35+
./configure --enable-ss
36+
37+
make -j -j `sysctl -n hw.logicalcpu`
38+
```
39+
40+
At this point, the Mednafen binary can be found in the mednafen/src/ folder; you may manually copy/move it
41+
from there, or use the prescribed:
42+
```
43+
sudo make install
44+
```
45+
46+
## Further Mednafen documentation:
47+
48+
Mednafen has quite a few options that can affect the experience, luckily the Mednafen documentation site has quite a few pages of resources that live here:
49+
[https://mednafen.github.io/documentation/)

0 commit comments

Comments
 (0)