Skip to content

Commit

Permalink
Hopefully fix msvc build.
Browse files Browse the repository at this point in the history
  • Loading branch information
Relintai committed Jul 15, 2024
1 parent 9d6680c commit 3cab5b1
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 2 deletions.
8 changes: 7 additions & 1 deletion editor_modules/denoise/SCsub
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,13 @@ env.modules_sources += thirdparty_obj
if env["platform"] == "windows" and not env.msvc:
env_thirdparty.Append(CPPFLAGS=["-mstackrealign"])

env_thirdparty.Append(CPPFLAGS=["-frtti"])

if not env.msvc:
env_thirdparty["CXXFLAGS"].remove("-fno-rtti")
env_thirdparty.Append(CXXFLAGS=["-frtti"])
else:
env_thirdparty["CXXFLAGS"].remove("/GR-")
env_thirdparty.Append(CXXFLAGS=["/GR"])

weights_in_path = thirdparty_dir + "weights/rtlightmap_hdr.tza"
weights_out_path = thirdparty_dir + "weights/rtlightmap_hdr.gen.cpp"
Expand Down
9 changes: 8 additions & 1 deletion editor_modules/raycast/SCsub
Original file line number Diff line number Diff line change
Expand Up @@ -103,9 +103,16 @@ if env["builtin_embree"]:
"-fno-tree-vectorize",
"-fvisibility=hidden",
"-fvisibility-inlines-hidden",
"-frtti" # embree needs it
]
)


if not env.msvc:
env_thirdparty["CXXFLAGS"].remove("-fno-rtti")
env_thirdparty.Append(CXXFLAGS=["-frtti"])
else:
env_thirdparty["CXXFLAGS"].remove("/GR-")
env_thirdparty.Append(CXXFLAGS=["/GR"])

env.modules_sources += thirdparty_obj

Expand Down

0 comments on commit 3cab5b1

Please sign in to comment.