Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,8 @@ Inspired by Noita, this is a simple "falling sand" simulation to demonstrate the
- The executable will be placed in `bin\`
- run `bin\SandSim.exe`
- **mac**:
- You'll need gcc
- From the terminal, `cd`into the root directory for this project.
- run `bash ./proc/osx/gcc.sh`
- run `bash ./proc/osx/clang.sh`
- The exectuable will be placed in `bin/`
- run `./bin/SandSim`
- **linux**:
Expand Down
40 changes: 40 additions & 0 deletions proc/osx/clang.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
#!bin/sh

rm -rf bin
mkdir bin
cd bin

proj_root_dir=$(pwd)/../

flags=(
-std=c99 -ObjC
)

# Include directories
inc=(
-I ../third_party/include/
-I ../include/
)

# Source files
src=(
../source/main.c
../source/render_passes/*.c
)

fworks=(
-framework OpenGL
-framework CoreFoundation
-framework CoreVideo
-framework IOKit
-framework Cocoa
-framework Carbon

)

clang -O3 ${fworks[*]} ${inc[*]} ${src[*]} ${flags[*]} -o SandSim

cd ..