klezVirus / inceptor

Template-Driven AV/EDR Evasion Framework
Other
1.6k stars 263 forks source link

Compilation failed when -hw in native #40

Closed bestrocker221 closed 2 years ago

bestrocker221 commented 2 years ago

Describe the bug [-] Error: clang-cl: error: no such file or directory: '/SUBSYSTEM:WINDOWS'

I see that the error goes away when not using -hw Not really sure why that is the case. Tried with adding the -Xlinker option before that but still same error. Tried with changing the order of the parameter in the cmdline but that did not matter.

To Reproduce

klezVirus commented 2 years ago

Hi @bestrocker221, thanks for pointing this out. I think that windows clang (CL) doesn't consider neither the -Xlinker option nor the --for-linker option. To forward the options to the linker you can use the /link option. The error was caused as in the LLVM and CLANG options the additional arguments given to the compiler for some reason appear to be missing the /link option.

I should have fixed it in f5d8a6b04fda807b57eca6c9847f13e5a102e729.

Let me know if you encounter this issue again.

bestrocker221 commented 2 years ago

Indeed that fixed the issue! Thanks again.