Subversion Repositories Kolibri OS

Rev

Rev 9844 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
9844 turbocat 1
if tup.getconfig("NO_TCC") ~= "" then return end
8687 turbocat 2
 
9843 turbocat 3
CFLAGS = " -r -nostdinc -nostdlib -DGNUC -D_BUILD_LIBC "
8687 turbocat 4
INCLUDES = " -I../include"
5
 
9843 turbocat 6
GAS_SRC = {
7
    "setjmp/setjmp.s",
8
    "setjmp/longjmp.s",
9
    "math/round.s",
10
    "math/atan.s",
11
    "math/pow2.s",
12
    "math/log10.s",
13
    "math/exp.s",
14
    "math/pow10.s",
15
    "math/log.s",
16
    "math/pow.s",
17
    "math/ceil.s",
18
    "math/cos.s",
19
    "math/sin.s",
20
    "math/asin.s",
21
    "math/modf.s",
22
    "math/floor.s",
23
    "math/fabs.s",
24
    "math/fmod.s",
25
    "math/log2.s",
26
    "math/acos.s",
27
    "math/modfl.s",
28
    "math/atan2.s",
29
    "math/sqrt.s",
30
    "math/tan.s",
31
    "string/memset.s",
32
    "string/memmove.s"
33
}
9774 turbocat 34
 
9846 turbocat 35
OBJS = {"libc.c"}
9774 turbocat 36
 
9843 turbocat 37
tup.append_table(OBJS,
38
  tup.foreach_rule(GAS_SRC, "as --32 %f -o %o", "%B.o")
39
)
9774 turbocat 40
 
9846 turbocat 41
tup.rule(OBJS, "kos32-tcc" .. CFLAGS .. INCLUDES .. " %f -o %o " .. " && strip %o --strip-unneeded " , "libc.o")
9843 turbocat 42
tup.rule("libc.o", "objconv -fcoff32 %f %o " .. tup.getconfig("KPACK_CMD"), "%B.obj")