From 9fc9acbee8bd514b828897740dc882258ce6f61f Mon Sep 17 00:00:00 2001 From: "H. Diedrich" Date: Sat, 12 Apr 2014 22:28:20 +0200 Subject: [PATCH] Add new build targets. Update README and gitignore. Added `make clean` Added `make hello` to show Hello SDL Ported from https://github.com/ninenines/esdl2/pull/1 Part of the change was left out because there is no longer a secondary Makefile in c_src --- .gitignore | 1 + Makefile | 11 +++++++++++ README.md | 20 +++++++++++++++----- 3 files changed, 27 insertions(+), 5 deletions(-) diff --git a/.gitignore b/.gitignore index 82aa631..f59e983 100644 --- a/.gitignore +++ b/.gitignore @@ -4,3 +4,4 @@ ebin esdl2.d examples/*/*.beam priv +.DS_Store diff --git a/Makefile b/Makefile index 12cc181..64ccce3 100644 --- a/Makefile +++ b/Makefile @@ -33,3 +33,14 @@ endif bullet_engine:: all erlc -o examples/bullet_engine examples/bullet_engine/*.erl cd examples/bullet_engine && ./start.sh + +hello:: + erlc -o examples/hello_sdl examples/hello_sdl/*.erl + cd examples/hello_sdl && ./start.sh + +clean:: + @rm -f *.swp + @rm -f c_src/env.mk + @rm -rf ebin/ + @rm -f examples/*/*.beam + @echo clean diff --git a/README.md b/README.md index 8d538e2..7e7cdb5 100644 --- a/README.md +++ b/README.md @@ -1,19 +1,29 @@ ESDL2 ===== -SDL2 Erlang NIF. +SDL2 Erlang NIFs + +SDL provides cross-platform low level access to graphics, audio, keyboard, mouseand joystick hardware via OpenGL and Direct3D. This is an Erlang binding. http://www.libsdl.org/ Status ------ Week-end project. Work in progress. - -The following limitations apply: - + + Building + -------- + * Erlang 17.0+ is required - * SDL 2.0.3+ is required + * SDL 2.0.3+ is required (`http://www.libsdl.org/download-2.0.php`) + * SDL\_image is required (`https://www.libsdl.org/projects/SDL_image/`) * No support for UTF-8 strings, only Latin-1 +Tip: configure SDL\_image with --disable-webp for not having to install libwebp. + +Build using `make`. + +Ideas +----- The following ideas need to be investigated: * We may benefit from the reference receive optimization when doing calls