Skip to content

Commit

Permalink
Merge pull request #57 from pkerspe/master
Browse files Browse the repository at this point in the history
Add documentation for MacOS to load sdl drivers
  • Loading branch information
kisvegabor authored Jan 14, 2024
2 parents 2ebfc90 + 95f6f00 commit 788ff39
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
7 changes: 7 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,13 @@ Use [Homebrew](https://brew.sh/):
```sh
brew install sdl2
```
Note:
On MacOS you need to include (uncomment in provided example platformio.ini file) these lines in your platformio.ini file to import the drivers:
```
; SDL2 includes
!find /opt/homebrew/Cellar/sdl2 -name "include" | sed "s/^/-I /"
!find /opt/homebrew/Cellar/sdl2 -name "libSDL2.a" | xargs dirname | sed "s/^/-L /"
```

**Windows**

Expand Down
4 changes: 4 additions & 0 deletions platformio.ini
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,10 @@ build_flags =
; LVGL memory options, setup for the demo to run properly
-D LV_MEM_CUSTOM=1
-D LV_MEM_SIZE="(128U * 1024U)"

; SDL2 includes, uncomment the next two lines on MAC OS if you intalled sdl via homebrew
; !find /opt/homebrew/Cellar/sdl2 -name "include" | sed "s/^/-I /"
; !find /opt/homebrew/Cellar/sdl2 -name "libSDL2.a" | xargs dirname | sed "s/^/-L /"

lib_deps =
${env.lib_deps}
Expand Down

0 comments on commit 788ff39

Please sign in to comment.