aboutsummaryrefslogtreecommitdiff
path: root/src/tests/slab_test
diff options
context:
space:
mode:
authorAlex Auvolat <alex@adnab.me>2016-07-30 23:17:12 +0200
committerAlex Auvolat <alex@adnab.me>2016-07-30 23:17:12 +0200
commitf58f65c30de315d4419f69a92a708cbed797ff37 (patch)
treeefaaa82089523dc0f7a3b9a6ab4c963550f9b241 /src/tests/slab_test
parentfa5327d4cc5e47656326b8c0c55d23cd71b04462 (diff)
downloadkogata-f58f65c30de315d4419f69a92a708cbed797ff37.tar.gz
kogata-f58f65c30de315d4419f69a92a708cbed797ff37.zip
Release mode (enables some optimizations) ; fix tests.
Diffstat (limited to 'src/tests/slab_test')
-rw-r--r--src/tests/slab_test/bam.lua19
-rw-r--r--src/tests/slab_test/slab_test.c2
2 files changed, 12 insertions, 9 deletions
diff --git a/src/tests/slab_test/bam.lua b/src/tests/slab_test/bam.lua
index 87c6666..cd5ad2d 100644
--- a/src/tests/slab_test/bam.lua
+++ b/src/tests/slab_test/bam.lua
@@ -1,11 +1,14 @@
-local source = {"src/common/libkogata/slab_alloc.c",
- "src/tests/slab_test/slab_test.c"}
-local obj = Compile(host_settings, source)
+return function(s)
+ local source = {"src/common/libkogata/slab_alloc.c",
+ "src/tests/slab_test/slab_test.c"}
+ local obj = Compile(s.host_settings, source)
-local bin = Link(host_settings, "build/tests/slab_test", obj)
+ local f = s.host_settings.cc.Output(s.host_settings, "tests/slab_test")
+ local bin = Link(s.host_settings, f, obj)
-local slab_test = "build/tests/slab_test.log"
-AddJob(slab_test, "slab_test", "./" .. bin .. " > " .. slab_test)
-AddDependency(slab_test, bin)
+ local slab_test = f .. ".log"
+ AddJob(slab_test, "slab_test", "./" .. bin .. " > " .. slab_test)
+ AddDependency(slab_test, bin)
-table.insert(tests, slab_test)
+ return slab_test
+end
diff --git a/src/tests/slab_test/slab_test.c b/src/tests/slab_test/slab_test.c
index 747c785..31af03d 100644
--- a/src/tests/slab_test/slab_test.c
+++ b/src/tests/slab_test/slab_test.c
@@ -1,4 +1,4 @@
-#include <slab_alloc.h>
+#include <kogata/slab_alloc.h>
#include <stdlib.h>
#include <stdio.h>