-
Notifications
You must be signed in to change notification settings - Fork 0
/
merge.py
84 lines (77 loc) · 6.54 KB
/
merge.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
import subprocess
# Path to ILMerge executable
ilmerge_path = "C:\\Program Files (x86)\\Microsoft\\ILMerge\\ILMerge.exe"
# Path to your main executable (e.g., YourApp.exe)
main_executable = "C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\Tic-Tac-Toe.exe"
# List of DLLs to merge
dlls_to_merge = [
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\combase.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\COMCTL32.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\comdlg32.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\DNSAPI.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\dwmapi.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\DWrite.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\GDI32.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\gdi32full.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\gdiplus.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\HID.DLL",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\IMM32.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\IPHLPAPI.DLL",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\KERNEL32.DLL",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\KERNELBASE.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libatk-1.0-0.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libbrotlicommon.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libbrotlidec.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libbz2-1.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libcairo-2.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libcairo-gobject-2.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libdatrie-1.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libepoxy-0.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libexpat-1.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libffi-8.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libfontconfig-1.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libfreetype-6.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libfribidi-0.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libgcc_s_seh-1.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libgdk_pixbuf-2.0-0.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libgdk-3-0.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libgio-2.0-0.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libglib-2.0-0.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libgmodule-2.0-0.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libgobject-2.0-0.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libgraphite2.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libgtk-3-0.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libharfbuzz-0.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libiconv-2.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libintl-8.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libpango-1.0-0.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libpangocairo-1.0-0.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libpangoft2-1.0-0.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libpangowin32-1.0-0.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libpcre2-8-0.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libpixman-1-0.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libpng16-16.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libstdc++-6.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libthai-0.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\libwinpthread-1.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\ucrtbase.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\USER32.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\USP10.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\win32u.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\WINMM.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\WINSPOOL.DRV",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\WS2_32.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\zlib1.dll",
"C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\ADVAPI32.dll",
]
# Output merged executable
output_executable = "C:\\Users\\user\\Desktop\\C-C++programming\\C_programming\\GTK+\\TicTacToe\\bin\\MergedApp.exe"
# Construct the command to run ILMerge
command = [
ilmerge_path,
f"/out:{output_executable}",
main_executable,
] + dlls_to_merge
# Run the ILMerge command
subprocess.run(command)
print("Merging completed.")