Build offline OpenPrestige release bundles
Rename the injector and package it with an embedded payload for Windows, Linux, and macOS x64/ARM64. Add a core-only ImGui native build, multi-platform CI and release packaging, and shared per-user storage with legacy config migration.
This commit is contained in:
1 parent
5152e6e0a6
commit
2d6b2a3cd1
37 files changed
+1284
-451
No files matched your search
+28
-80
@@ -1,9 +1,7 @@
|
||||
"""Packs one platform's release zip, or writes SHA256SUMS.txt for dist/release. Called by release.bat.
|
||||
"""Package openprestige releases.
|
||||
|
||||
package_release.py zip <out_dir> <version> <platform> <injector> <native_lib> <payload_jar>
|
||||
package_release.py offline <out_dir> <version> <platform> <injector> <native_lib> <payload_jar>
|
||||
package_release.py checksums <out_dir>
|
||||
|
||||
Zips are written with unix permissions so PrestigeInjector stays executable after unzip on Linux/macOS.
|
||||
"""
|
||||
import hashlib
|
||||
import os
|
||||
@@ -11,69 +9,7 @@ import sys
|
||||
import time
|
||||
import zipfile
|
||||
|
||||
README = {
|
||||
"windows": """Prestige {version} - Windows (x86_64)
|
||||
|
||||
Contents
|
||||
PrestigeInjector.exe injector
|
||||
prestige_native.dll loader library (keep it next to the injector)
|
||||
{jar} the same client as a Fabric mod (optional, see below)
|
||||
|
||||
Inject
|
||||
1. Start Minecraft 1.21.11 with Fabric Loader 0.19+ and Fabric API.
|
||||
2. Run PrestigeInjector.exe and pick the game from the list.
|
||||
|
||||
If SmartScreen blocks the exe: More info -> Run anyway.
|
||||
""",
|
||||
"linux": """Prestige {version} - Linux (x86_64)
|
||||
|
||||
Works on any glibc distro from 2012 on (glibc 2.17+): Ubuntu, Debian, Fedora, Arch, Mint, openSUSE, ...
|
||||
Not for musl distros (Alpine) or ARM machines.
|
||||
|
||||
Contents
|
||||
PrestigeInjector injector
|
||||
libprestige_native.so loader library (keep it next to the injector)
|
||||
{jar} the same client as a Fabric mod (optional, see below)
|
||||
|
||||
Inject
|
||||
1. Start Minecraft 1.21.11 with Fabric Loader 0.19+ and Fabric API.
|
||||
2. In a terminal in this folder: ./PrestigeInjector
|
||||
Run it as the same user as the game. The game must not use -XX:+DisableAttachMechanism.
|
||||
""",
|
||||
"macos": """Prestige {version} - macOS (universal: Intel + Apple Silicon)
|
||||
|
||||
Contents
|
||||
PrestigeInjector injector
|
||||
libprestige_native.dylib loader library (keep it next to the injector)
|
||||
{jar} the same client as a Fabric mod (optional, see below)
|
||||
|
||||
Inject
|
||||
1. Start Minecraft 1.21.11 with Fabric Loader 0.19+ and Fabric API.
|
||||
2. In Terminal, in this folder, clear the download quarantine once:
|
||||
xattr -dr com.apple.quarantine .
|
||||
3. Run: ./PrestigeInjector
|
||||
Run it as the same user as the game. The game must not use -XX:+DisableAttachMechanism.
|
||||
""",
|
||||
}
|
||||
|
||||
MOD_NOTE = """
|
||||
Install as a mod instead
|
||||
Put {jar} into the mods/ folder of a Fabric 1.21.11 instance; no injector needed.
|
||||
Do not use both at once.
|
||||
"""
|
||||
|
||||
TESTED = "Tested on Prism Launcher with Minecraft 1.21.11 + Fabric.\n"
|
||||
|
||||
FOOTER = """
|
||||
Credits
|
||||
Cracked by Skid Solutions
|
||||
technix sourcing / Frida scripts
|
||||
stutheguyy fixing
|
||||
bynbang / nitrogenoliquido ZKM transformers
|
||||
dario AI models
|
||||
|
||||
Discord: https://discord.gg/x2FJyGrDNg
|
||||
"""
|
||||
FOOTER = '\nCredits\n Cracked by Skid Solutions\n technix sourcing / Frida scripts\n stutheguyy fixing\n bynbang / nitrogenoliquido ZKM transformers\n dario AI models\n\nDiscord: https://discord.gg/x2FJyGrDNg\n'
|
||||
|
||||
|
||||
def add(zf, arcname, data, mode):
|
||||
@@ -85,19 +21,31 @@ def add(zf, arcname, data, mode):
|
||||
|
||||
|
||||
def make_zip(out_dir, version, platform, injector, lib, jar):
|
||||
family = platform.split("-")[0]
|
||||
name = f"prestige-{version}-{platform}"
|
||||
jar_name = os.path.basename(jar)
|
||||
title, body = README[family].format(version=version, jar=jar_name).split("\n", 1)
|
||||
readme = title + "\n" + TESTED + body + MOD_NOTE.format(jar=jar_name) + FOOTER
|
||||
if family == "windows":
|
||||
readme = readme.replace("\n", "\r\n")
|
||||
if platform in ("windows-aarch64", "linux-aarch64"):
|
||||
native = "imgui-java64.dll" if platform.startswith("windows") else "libimgui-java64.so"
|
||||
with zipfile.ZipFile(jar) as payload:
|
||||
entry = f"prestige-natives/{platform}/{native}"
|
||||
if entry not in payload.namelist():
|
||||
raise ValueError(f"ARM64 payload is missing {entry}. Build the core ImGui natives first.")
|
||||
name = f"openprestige-{version}-{platform}"
|
||||
out = os.path.join(out_dir, name + ".zip")
|
||||
with zipfile.ZipFile(out, "w", zipfile.ZIP_DEFLATED, compresslevel=9) as zf:
|
||||
for path, mode in ((injector, 0o755), (lib, 0o644), (jar, 0o644)):
|
||||
with open(path, "rb") as f:
|
||||
add(zf, f"{name}/{os.path.basename(path)}", f.read(), mode)
|
||||
add(zf, f"{name}/README.txt", readme.encode(), 0o644)
|
||||
os.makedirs(out_dir, exist_ok=True)
|
||||
with zipfile.ZipFile(out, "w", zipfile.ZIP_DEFLATED, compresslevel=9) as bundle:
|
||||
executable = "OpenPrestigeInjector" + (".exe" if platform.startswith("windows-") else "")
|
||||
for path, filename, permissions in ((injector, executable, 0o755), (lib, os.path.basename(lib), 0o644)):
|
||||
with open(path, "rb") as file:
|
||||
add(bundle, f"{name}/{filename}", file.read(), permissions)
|
||||
readme = (f"OpenPrestige {version} - {platform}\n\n"
|
||||
f"Extract this complete folder and run {executable}.\n"
|
||||
"Original CLI: Up/Down selects a Minecraft JVM, Enter injects, Esc quits.\n"
|
||||
f"Keep {os.path.basename(lib)} beside the executable.\n"
|
||||
"The native library embeds its payload. No external JAR or runtime download is required.\n"
|
||||
"The launcher has no downloader or update checks.\n\n"
|
||||
"Requires a matching 64-bit Minecraft 1.21.11 Fabric JVM.\n"
|
||||
"Linux/macOS: run from a terminal as the same user as the game; attach must be enabled.\n"
|
||||
"The Fabric mod JAR is available separately. Use either injection or the mod.\n"
|
||||
+ FOOTER)
|
||||
add(bundle, f"{name}/README.txt", readme.encode(), 0o644)
|
||||
print(f" wrote {out} ({os.path.getsize(out) // 1024} KiB)")
|
||||
|
||||
|
||||
@@ -114,7 +62,7 @@ def checksums(out_dir):
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
if len(sys.argv) == 8 and sys.argv[1] == "zip":
|
||||
if len(sys.argv) == 8 and sys.argv[1] == "offline":
|
||||
make_zip(*sys.argv[2:])
|
||||
elif len(sys.argv) == 3 and sys.argv[1] == "checksums":
|
||||
checksums(sys.argv[2])
|
||||
|
||||
Reference in new issue
Block a user