This commit is contained in:
Nishi 2026-05-15 00:01:48 +09:00
commit 9eb085ee28
3 changed files with 9 additions and 9 deletions

View file

@ -194,9 +194,9 @@ Compiler.prototype.output = function(target) {
} else if(target instanceof pmake.LibraryProject) {
return "lib" + target.output + ".a";
} else if(target instanceof pmake.ExecutableProject) {
if(pmake.system.target == "Windows"){
if(pmake.system.target == "Windows") {
return target.output + ".exe";
}else{
} else {
return target.output;
}
}
@ -208,7 +208,7 @@ const POSIXCompiler = pmake.inherit(Compiler, function(target) {
this.ar = "ar";
this.cc = "cc";
this.cxx = "c++";
this.rc = "windres";
this.rc = "windres";
});
POSIXCompiler.prototype.compile = function(target, obj, src) {
@ -219,9 +219,9 @@ POSIXCompiler.prototype.compile = function(target, obj, src) {
const includes = pmake.includes(target).map(add_i).join(" ");
const flags = includes + " -c -o " + obj + " " + src;
if(src.endsWith(".rc")){
if(src.endsWith(".rc")) {
return this.prefix + this.rc + " -O coff " + src + " " + obj;
}else if(src.endsWith(".c")) {
} else if(src.endsWith(".c")) {
return this.prefix + this.cc + " " + flags;
} else if(is_cxx(src)) {
return this.prefix + this.cxx + " " + flags;