Skip to content

Guard config.w32.h from multiple inclusion #17021

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Dec 8, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions win32/build/confutils.js
Original file line number Diff line number Diff line change
Expand Up @@ -2270,6 +2270,10 @@ function generate_config_h()

outfile = FSO.CreateTextFile("main/config.w32.h", true);

outfile.WriteLine("#ifndef CONFIG_W32_H");
outfile.WriteLine("#define CONFIG_W32_H");
outfile.WriteBlankLines(1);

indata = indata.replace(new RegExp("@PREFIX@", "g"), prefix);
outfile.Write(indata);

Expand Down Expand Up @@ -2317,6 +2321,8 @@ function generate_config_h()
outfile.WriteLine("#if __has_include(\"main/config.pickle.h\")");
outfile.WriteLine("#include \"main/config.pickle.h\"");
outfile.WriteLine("#endif");
outfile.WriteBlankLines(1);
outfile.WriteLine("#endif /* CONFIG_W32_H */");

outfile.Close();
}
Expand Down
Loading