Guys I'm having trouble in compiling my python script to 'exe' using py2exe. When I run the setup script, it doesn't throw up any errors. But the 'exe' is not generated. Also, the 'dist' and 'build' directories are empty. My program uses PyQt4. When I remove the pyqt imports from my program, it compiles successfully and the exe is generated. I think there is some problem when Qt is imported.
The setup script looks like this.
import sys
from distutils.core import setup
import py2exe
sys.argv.append('py2exe')
setup(console=['larynx.pyw'])
My Gui program is this one.
import sys
from PyQt4.QtCore import *
from PyQt4.QtGui import *
from interface import Ui_MainWindow
class Window(QMainWindow):
def __init__(self):
QMainWindow.__init__(self)
self.ui = Ui_MainWindow()
self.ui.setupUi(self)
app = QApplication(sys.argv)
window = Window()
window.show()
sys.exit(app.exec_())