Compare commits
8 Commits
release-20
...
release-20
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
3f08b5b54a | ||
|
|
bfec99ae35 | ||
|
|
d9afd3aa81 | ||
|
|
e72113d91d | ||
|
|
7c4ff619c1 | ||
|
|
9c4217f450 | ||
|
|
cc09002171 | ||
|
|
5d8cdd7760 |
@@ -1,5 +0,0 @@
|
||||
[build]
|
||||
rustflags = ["-C", "target-feature=-bulk-memory"]
|
||||
|
||||
[target.wasm32-unknown-unknown]
|
||||
rustflags = ["-C", "target-feature=-bulk-memory"]
|
||||
@@ -30,6 +30,17 @@ jobs:
|
||||
npx @tailwindcss/cli -i input.css -o public/tailwind.css
|
||||
trunk build --release
|
||||
|
||||
# Manuel WASM Optimizasyonu
|
||||
WASM_FILE=$(ls dist/*.wasm | head -n 1)
|
||||
BEFORE=$(du -h "$WASM_FILE" | cut -f1)
|
||||
echo "Before optimization: $BEFORE"
|
||||
|
||||
wasm-opt --all-features -Oz "$WASM_FILE" -o "$WASM_FILE"
|
||||
|
||||
AFTER=$(du -h "$WASM_FILE" | cut -f1)
|
||||
echo "After optimization: $AFTER"
|
||||
echo "Optimization complete!"
|
||||
|
||||
- name: Build Backend (MIPS)
|
||||
env:
|
||||
# Ensure we are building a fully static binary
|
||||
|
||||
@@ -20,6 +20,8 @@ RUN apt-get update && apt-get install -y \
|
||||
jq \
|
||||
# Needed for some crate compilations
|
||||
protobuf-compiler \
|
||||
# Install binaryen to have wasm-opt available system-wide
|
||||
binaryen \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# 2. Install Node.js v20 (Manual install to support multi-arch cleanly)
|
||||
@@ -70,7 +72,7 @@ RUN . "$HOME/.cargo/env" && \
|
||||
ARCH=$(dpkg --print-architecture) && \
|
||||
if [ "$ARCH" = "amd64" ]; then TRUNK_ARCH="x86_64-unknown-linux-gnu"; \
|
||||
elif [ "$ARCH" = "arm64" ]; then TRUNK_ARCH="aarch64-unknown-linux-gnu"; fi && \
|
||||
wget -qO- "https://github.com/trunk-rs/trunk/releases/download/v0.21.5/trunk-$TRUNK_ARCH.tar.gz" | tar -xzf - -C /root/.cargo/bin/ && \
|
||||
wget -qO- "https://github.com/trunk-rs/trunk/releases/download/v0.21.14/trunk-$TRUNK_ARCH.tar.gz" | tar -xzf - -C /root/.cargo/bin/ && \
|
||||
chmod +x /root/.cargo/bin/trunk && \
|
||||
# Install wasm-bindgen-cli (Compiling from source to avoid glibc issues, doing it ONCE here)
|
||||
cargo install wasm-bindgen-cli --version 0.2.108
|
||||
|
||||
@@ -1,5 +0,0 @@
|
||||
[build]
|
||||
rustflags = ["-C", "target-feature=-bulk-memory"]
|
||||
|
||||
[target.wasm32-unknown-unknown]
|
||||
rustflags = ["-C", "target-feature=-bulk-memory"]
|
||||
@@ -10,6 +10,3 @@ command_arguments = ["-c", "npx @tailwindcss/cli -i input.css -o public/tailwind
|
||||
[build]
|
||||
target = "index.html"
|
||||
dist = "dist"
|
||||
|
||||
[tools]
|
||||
wasm_opt = "version_121"
|
||||
|
||||
Reference in New Issue
Block a user