Skip to content

Commit

Permalink
.app gets appended for macos compilation
Browse files Browse the repository at this point in the history
  • Loading branch information
ullmannJan committed Jul 20, 2024
1 parent 96c747a commit d9e336a
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions compiling/compile.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,22 +37,24 @@
if sys.platform == "darwin":
arguments.append("../img/logo/tape_measure_128.icns")
arguments.append("--windowed")
extension = ".app"

else:
arguments.append("../img/logo/tape_measure_128.ico")
extension = ""


PyInstaller.__main__.run(
arguments
)

# zip output for easy distribution
output_path = (script_path / f"../dist/{program_name}").resolve()
output_path = (script_path / f"../dist/{program_name}{extension}").resolve()
# Modify the output_path based on architecture
if zipped:

# Determine the architecture
arch = platform.machine()
extension = ""
match sys.platform:
case "win32":
archive_format = "zip"
Expand All @@ -63,7 +65,6 @@
case "darwin":
archive_format = "gztar"
suffix = "_mac"
extension = ".app"

# Append architecture to suffix
if "arm" in arch.lower():
Expand Down

0 comments on commit d9e336a

Please sign in to comment.