42 lines
774 B
C
42 lines
774 B
C
#include "god/c.h"
|
|
#include "god/ld.h"
|
|
|
|
char* tier1_lib = 0;
|
|
void tier1_build(struct build_data b)
|
|
{
|
|
char* files[] = {
|
|
"tier1/commandline.cpp",
|
|
"tier1/utlbuffer.cpp",
|
|
"tier1/utlmap.cpp",
|
|
"tier1/utlstring.cpp",
|
|
"tier1/utlvector.cpp",
|
|
NULL,
|
|
};
|
|
struct C_Macro macros[] = {
|
|
(struct C_Macro){"TIER0_IMPLEMENTATION","1"},
|
|
NULL,
|
|
};
|
|
|
|
|
|
struct project p = {
|
|
.b = &b,
|
|
.files = files,
|
|
.name = "tier1",
|
|
};
|
|
|
|
struct project o = C_compile(p, (struct C_settings){
|
|
.generation_flags = C_GENERATION_FLAGS_PIC,
|
|
.compile_flags = C_COMPILE_FLAGS_WALL,
|
|
.include_dirs = include_dirs,
|
|
.macros = macros,
|
|
});
|
|
char* libs[] = {
|
|
"c",
|
|
NULL,
|
|
};
|
|
|
|
tier1_lib = ld_link_project(o, (struct link_settings){
|
|
.type = LINK_TYPE_STATIC,
|
|
.libs = libs,
|
|
});
|
|
} |