2

I have created a game in python3 & pygame. It is simple and uses a couple images and sound files. I used cx_freeze to make it into a windows exe file, but I don't know how to create a mac file for it instead (While being on a windows machine)

I can't do it on a mac, since I don't have one. I tried using the bdist_dmg and bdist_mac commands but it is not recognized. By this, I mean that I went into cmd and typed: "py setup.py bdist_mac" which should turn my setup file (Down Below) into a dmg file.

import cx_Freeze
import os
os.environ['TCL_LIBRARY'] = "C:\\Users\\knify\\AppData\\Local\\Programs\\Python\\Python37-32\\tcl\\tcl8.6"
os.environ['TK_LIBRARY'] = "C:\\Users\\knify\\AppData\\Local\\Programs\\Python\\Python37-32\\tcl\\tk8.6"

executables = [cx_Freeze.Executable("file.py")]

cx_Freeze.setup(
    name="Game",
    options={"build_exe": {"packages":["pygame","time","random"],
                       "include_files": ["bg.jpg","one.png","two.png","three.png","four.png","five.png","bg.png","block.png","button.png","icon.png","pointer.png","sound.wav","wood.jpg"]}},
executables = executables

)
  • 1
    as I know to create version for Mac you have to do it on Mac - it may have to add to project libraries which exist only on Mac and are not part of Python. The same with Linux - to create version for Linux you have to do it on Linux. – furas Apr 09 '19 at 17:07

0 Answers0