From c90bca2424ac6c1093f9dfb8224e9358ef2a006b Mon Sep 17 00:00:00 2001 From: Oskari Timperi Date: Sun, 27 Oct 2019 10:15:46 +0200 Subject: Initial commit --- raylib.cfg | 13 +++++++++++++ raylib.nimble | 36 ++++++++++++++++++++++++++++++++++++ 2 files changed, 49 insertions(+) create mode 100644 raylib.cfg create mode 100644 raylib.nimble diff --git a/raylib.cfg b/raylib.cfg new file mode 100644 index 0000000..ace5ebc --- /dev/null +++ b/raylib.cfg @@ -0,0 +1,13 @@ +[n.global] +output = raylib + +[n.prepare] +download-lin = "https://github.com/raysan5/raylib/releases/download/2.5.0/raylib-2.5.0-Linux-amd64.tar.gz" +execute-lin = "tar -C raylib --strip-components=1 -x -f raylib/raylib-2.5.0-Linux-amd64.tar.gz" + +[n.include] +raylib/include + +[raylib.h] +dynlib-lin = lib/libraylib.so +preprocess = true diff --git a/raylib.nimble b/raylib.nimble new file mode 100644 index 0000000..5a4ce8c --- /dev/null +++ b/raylib.nimble @@ -0,0 +1,36 @@ +# Package + +version = "0.1.0" +author = "Oskari Timperi" +description = "A new awesome nimble package" +license = "Zlib" +srcDir = "src" + + + +# Dependencies + +requires "nim >= 1.0.2" +requires "nimgen >= 0.5.1" + +var + name = "nimraylib" + cmd = when defined(Windows): "cmd /c " else: "" + ext = when defined(Windows): ".exe" else: "" + ldpath = when defined(Linux): "LD_LIBRARY_PATH=x64 " else: "" + +# mkDir(name) + +task setup, "Checkout and generate": + if gorgeEx(cmd & "nimgen").exitCode != 0: + withDir(".."): + exec "nimble install nimgen -y" + exec cmd & "nimgen " & name & ".cfg" + +before install: + setupTask() + +# task test, "Test nimbass": +# exec "nim c -d:nimDebugDlOpen tests/basstest.nim" +# withDir("nimbass"): +# exec ldpath & "../tests/basstest" & ext -- cgit v1.2.3