Skip to content

Commit

Permalink
simplified arch os handling
Browse files Browse the repository at this point in the history
  • Loading branch information
biast12 committed Nov 15, 2024
1 parent 6ada0cf commit 395cd15
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 12 deletions.
3 changes: 1 addition & 2 deletions build.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
#!/bin/bash
#!/usr/bin/env bash

clear
dirpath=$(dirname "$(readlink -f "$0")")

# Check if the virtual environment exists
Expand Down
10 changes: 2 additions & 8 deletions build.spec
Original file line number Diff line number Diff line change
Expand Up @@ -52,14 +52,8 @@ hiddenimports: list[str] = [

if sys.platform == "linux":
arch = platform.machine()
if arch == "x86_64":
datas.append((Path("/usr/lib/x86_64-linux-gnu/girepository-1.0/AyatanaAppIndicator3-0.1.typelib"), "gi_typelibs"))
binaries.append((Path("/usr/lib/x86_64-linux-gnu/libayatana-appindicator3.so.1"), "."))
elif arch == "aarch64":
datas.append((Path("/usr/lib/aarch64-linux-gnu/girepository-1.0/AyatanaAppIndicator3-0.1.typelib"), "gi_typelibs"))
binaries.append((Path("/usr/lib/aarch64-linux-gnu/libayatana-appindicator3.so.1"), "."))
else:
raise ValueError(f"Unsupported architecture: {arch}")
datas.append((Path(f"/usr/lib/{arch}-linux-gnu/girepository-1.0/AyatanaAppIndicator3-0.1.typelib"), "gi_typelibs"))
binaries.append((Path(f"/usr/lib/{arch}-linux-gnu/libayatana-appindicator3.so.1"), "."))

hiddenimports.extend([
"gi.repository.Gtk",
Expand Down
3 changes: 1 addition & 2 deletions setup_env.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
#!/bin/bash
#!/usr/bin/env bash

clear
dirpath=$(dirname "$(readlink -f "$0")")

# Check if git is installed
Expand Down

0 comments on commit 395cd15

Please sign in to comment.