Skip to content

Commit afdf068

Browse files
python modify
1 parent 42c6a9b commit afdf068

File tree

4 files changed

+21
-23
lines changed

4 files changed

+21
-23
lines changed

win_scripts/build_win.py

+2
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,8 @@ def display_help():
4040

4141
try_run(f'autoninja -C out/thorium thorium_all -j{jobs}')
4242

43+
try_run(f'autoninja -C out/thorium setup mini_installer -j{jobs}')
44+
4345
# Move the installer
4446
installer_src = os.path.normpath(os.path.join(cr_src_dir, 'out', 'thorium', 'mini_installer.exe'))
4547
installer_dest = os.path.normpath(os.path.join(cr_src_dir, 'out', 'thorium', 'thorium_mini_installer.exe'))

win_scripts/setup.py

+17-21
Original file line numberDiff line numberDiff line change
@@ -132,6 +132,7 @@ def display_help():
132132
'other/fix-policy-templates.patch',
133133
'other/ftp-support-thorium.patch',
134134
'other/thorium-2024-ui.patch',
135+
'other/GPC.patch',
135136
]
136137
for patch in patches:
137138
relative_path = patch.replace('other/', '', 1)
@@ -164,6 +165,10 @@ def display_help():
164165
os.chdir(cr_src_dir)
165166
try_run(f'git apply --reject ftp-support-thorium.patch')
166167

168+
print( "\nPatching in GPC support\n")
169+
# Change directory to cr_src_dir and run commands
170+
os.chdir(cr_src_dir)
171+
try_run(f'git apply --reject GPC.patch')
167172

168173
print( "\nPatching for Thorium 2024 UI\n")
169174
# Change directory to cr_src_dir and run commands
@@ -233,11 +238,7 @@ def copy_woa():
233238
def copy_avx512():
234239
print("\nCopying AVX-512 build files\n")
235240
copy_directory(
236-
os.path.normpath(os.path.join(thor_src_dir, 'other', 'AVX512', 'build')),
237-
os.path.normpath(os.path.join(cr_src_dir, 'build'))
238-
)
239-
copy_directory(
240-
os.path.normpath(os.path.join(thor_src_dir, 'other', 'AVX512', 'third_party')),
241+
os.path.normpath(os.path.join(thor_src_dir, 'other', 'AVX2', 'third_party')),
241242
os.path.normpath(os.path.join(cr_src_dir, 'third_party'))
242243
)
243244
copy(
@@ -264,10 +265,6 @@ def copy_avx512():
264265
# Copy AVX2 build files
265266
def copy_avx2():
266267
print("\nCopying AVX2 build files\n")
267-
copy_directory(
268-
os.path.normpath(os.path.join(thor_src_dir, 'other', 'AVX2', 'build')),
269-
os.path.normpath(os.path.join(cr_src_dir, 'build'))
270-
)
271268
copy_directory(
272269
os.path.normpath(os.path.join(thor_src_dir, 'other', 'AVX2', 'third_party')),
273270
os.path.normpath(os.path.join(cr_src_dir, 'third_party'))
@@ -296,10 +293,6 @@ def copy_avx2():
296293
# Copy SSE4.1 build files
297294
def copy_sse4():
298295
print("\nCopying SSE4.1 build files\n")
299-
copy_directory(
300-
os.path.normpath(os.path.join(thor_src_dir, 'other', 'SSE4.1', 'build')),
301-
os.path.normpath(os.path.join(cr_src_dir, 'build'))
302-
)
303296
copy(
304297
os.path.normpath(os.path.join(thor_src_dir, 'other', 'SSE4.1', 'thor_ver')),
305298
os.path.normpath(os.path.join(cr_src_dir, 'out', 'thorium'))
@@ -324,10 +317,6 @@ def copy_sse4():
324317
# Copy SSE3 build files
325318
def copy_sse3():
326319
print("\nCopying SSE3 build files\n")
327-
copy_directory(
328-
os.path.normpath(os.path.join(thor_src_dir, 'other', 'SSE3', 'build')),
329-
os.path.normpath(os.path.join(cr_src_dir, 'build'))
330-
)
331320
copy(
332321
os.path.normpath(os.path.join(thor_src_dir, 'other', 'SSE3', 'thor_ver')),
333322
os.path.normpath(os.path.join(cr_src_dir, 'out', 'thorium'))
@@ -357,10 +346,6 @@ def copy_sse3():
357346
# Copy SSE2 build files
358347
def copy_sse2():
359348
print("\nCopying SSE2 build files\n")
360-
copy_directory(
361-
os.path.normpath(os.path.join(thor_src_dir, 'other', 'SSE2', 'build')),
362-
os.path.normpath(os.path.join(cr_src_dir, 'build'))
363-
)
364349
copy(
365350
os.path.normpath(os.path.join(thor_src_dir, 'other', 'SSE2', 'thor_ver')),
366351
os.path.normpath(os.path.join(cr_src_dir, 'out', 'thorium'))
@@ -381,6 +366,17 @@ def copy_sse2():
381366
if '--sse2' in sys.argv:
382367
copy_sse2()
383368

369+
print("\nPatching ANGLE for SSE2\n")
370+
copy(
371+
os.path.normpath(os.path.join(thor_src_dir, 'other', 'SSE2', 'angle-lockfree.patch')),
372+
os.path.normpath(os.path.join(cr_src_dir, 'third_party', 'angle', 'src'))
373+
)
374+
375+
# Change directory to angle_dir and run commands
376+
angle_dir = os.path.join(cr_src_dir, 'third_party', 'angle', 'src')
377+
os.chdir(angle_dir)
378+
try_run(f'git apply --reject angle-lockfree.patch')
379+
384380

385381
print("\nDone!\n")
386382
print("\nEnjoy Thorium!\n")

win_scripts/upstream_version.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ def display_help():
4141

4242

4343
# Set cr_ver
44-
cr_ver = "128.0.6613.194"
44+
cr_ver = "130.0.6723.142"
4545

4646

4747
print(f"\nCurrent Chromium version is: {cr_ver}\n")

win_scripts/version.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ def display_help():
5252

5353

5454
# Set thor_ver
55-
thor_ver = "128.0.6613.194"
55+
thor_ver = "130.0.6723.142"
5656

5757

5858
print(f"\nCurrent Thorium version is: {thor_ver}\n")

0 commit comments

Comments
 (0)