add direct mode to Program builder - close #61

This commit is contained in:
josh committed 2019-04-14 12:35:28 -04:00
1 parent 9bf4b8fa96
commit ea2b1e73d1
17 files changed
+146 -23

No files matched your search

+5
View File
@@ -0,0 +1,5 @@
build do
Environment.new do |env|
env.Program("test.exe", Rscons.glob("*.c"), direct: true)
end
end
+7
View File
@@ -0,0 +1,7 @@
build do
Environment.new do |env|
lib = env.SharedLibrary("mylib", ["two.c", "three.c"], direct: true)
program = env.Program("test.exe", "main.c", "LIBS" => ["mylib"], "LIBPATH" => ["."])
env.depends(program, lib)
end
end
+7
View File
@@ -0,0 +1,7 @@
#include "two.h"
int main(int argc, char * argv[])
{
two();
return 0;
}
+7
View File
@@ -0,0 +1,7 @@
#include "three.h"
#include <stdio.h>
void three(void)
{
printf("three\n");
}
+1
View File
@@ -0,0 +1 @@
void three(void);
+7
View File
@@ -0,0 +1,7 @@
#include "two.h"
#include "three.h"
void two(void)
{
three();
}
+1
View File
@@ -0,0 +1 @@
void two(void);