51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
|
#-- linux
# linux uses the ELF{32,64} binary format, and generating these
# from yasm is trivial. linux only supports one ABI per format,
# at least with ELF, so that's all we need to do.
#${OUT}/$(mod).%.x86.lin.32.o: %.x86.lin.32.s
$(call arch,x86.lin.32)
yasm -felf32 $< -o $@
#${OUT}/$(mod).%.x86.lin.64.o: %.x86.lin.64.s
$(call arch,x86.lin.64)
yasm -felf64 $< -o $@
#-- freebsd
# the freebsd ABI is different, so it will require different code
# (though there might be ways to minimize that). freebsd uses the
# same binary format as Linux (though it also supports a.out and
# COFF) but because freebsd can interpret multiple different ABIs
# the object files need to be "branded" with the correct one
|
|
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
|
#-- linux
# linux uses the ELF{32,64} binary format, and generating these
# from yasm is trivial. linux only supports one ABI per format,
# at least with ELF, so that's all we need to do.
#${OUT}/$(mod).%.x86.lin.32.o: %.x86.lin.32.s
$(call arch,x86.lin.32)
yasm -gdwarf2 -felf32 $< -o $@
#${OUT}/$(mod).%.x86.lin.64.o: %.x86.lin.64.s
$(call arch,x86.lin.64)
yasm -gdwarf2 -felf64 $< -o $@
#-- freebsd
# the freebsd ABI is different, so it will require different code
# (though there might be ways to minimize that). freebsd uses the
# same binary format as Linux (though it also supports a.out and
# COFF) but because freebsd can interpret multiple different ABIs
# the object files need to be "branded" with the correct one
|