Update Rsconscript and add main.d

This commit is contained in:
Josh Holtrop 2023-09-30 21:05:12 -04:00
parent c8658e5e00
commit 4c57df0774
3 changed files with 9 additions and 15 deletions

2
.gitignore vendored
View File

@ -1,4 +1,4 @@
fart /fart
*.bmp *.bmp
*.png *.png
/.rscons* /.rscons*

View File

@ -1,21 +1,11 @@
configure do configure do
check_cxx_compiler check_d_compiler
check_program "flex"
check_program "bison"
check_lib ":libfl.a"
check_lib "pthread"
check_lib "freeimage"
end end
env do |env| env do |env|
env["CCFLAGS"] += %w[-Wall -O2] env["DFLAGS"] += %w[-Werror -O2]
env["CPPPATH"] += glob("src/**") env["D_IMPORT_PATH"] += %w[src]
env.CFile("^/parser/lexer.cc", "src/parser/parser.ll") sources = glob("src/**/*.d")
env.CFile("^/parser/parser.cc", "src/parser/parser.yy")
env["CPPPATH"] += ["#{env.build_root}/parser"]
sources = glob("src/**/*.cc")
sources += ["^/parser/lexer.cc", "^/parser/parser.cc"]
env.Program("fart", sources) env.Program("fart", sources)
end end

4
src/fart/main.d Normal file
View File

@ -0,0 +1,4 @@
int main(string[] args)
{
return 0;
}