-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathcompile.sh
More file actions
22 lines (16 loc) · 1009 Bytes
/
compile.sh
File metadata and controls
22 lines (16 loc) · 1009 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#!/bin/bash
#
# first you need to compile inject-asm.x64.asm from a windows machine using:
#
# ML64 /c inject-asm.x64.asm /link /NODEFAULTLIB /RELEASE /MACHINE:X64
#
# Compile dropper .exe
#
x86_64-w64-mingw32-windres ./bin/project.rc ./bin/project.o
x86_64-w64-mingw32-gcc -DEXE -Wl,-subsystem,windows -s -Os -Wno-narrowing -I./bin implant.cpp helpers.cpp inject-asm.x64.obj -o ./bin/implant.exe -lstdc++ -static ./bin/project.o
# x86_64-w64-mingw32-gcc -DEXE -DDEBUG -s -Os -Wno-narrowing -I./bin implant.cpp helpers.cpp inject-asm.x64.obj -o ./bin/implant.exe -lstdc++ -static ./bin/project.o
#
# Compile dropper .dll
#
# x86_64-w64-mingw32-gcc -DDLL -shared -s -Os -Wno-narrowing -I./bin implant.cpp ./bin/fakeExport.def helpers.cpp inject-asm.x64.obj -o ./bin/implant.dll -lstdc++ -static ./bin/project.o
x86_64-w64-mingw32-gcc -DDEBUG -DDLL -shared -s -Os -Wno-narrowing -I./bin implant.cpp ./bin/fakeExport.def helpers.cpp inject-asm.x64.obj -o ./bin/implant.dll -lstdc++ -static ./bin/project.o