title: Create a python standalone executable for CentOS
body: <p>I have a python script written to run on a system in our office which runs CentOS. It has Python2.6.6 installed by root user and hence I don't have access to install pip or any other tool. My goal is to create a standalone executable such that users shall be able to run the python script without the hassle of writing commands and running it from the terminal. Here's the script</p>
  <pre><code>import Tkinter as tk
  
  global root
  
  
  def file_download():
      root.withdraw()
      # download functionality code
      root.deiconify()
  
  
  def file_upload():
      root.withdraw()
      # upload functionality code
      root.deiconify()
  
  
  def sim_dialog():
      global root
  
      root = tk.Tk()
      root.title('Sample file manager')
      root.resizable(0, 0)
      dwnld = tk.Button(root, text=&quot;Download&quot;, width=10, command=file_download)
      dwnld.pack(expand=0, padx=90, pady=10)
      upld = tk.Button(root, text=&quot;Upload&quot;, width=10, command=file_upload)
      upld.pack(expand=0, padx=90, pady=10)
  
      root.mainloop()
  
  
  sim_dialog()
  
  </code></pre>
  <p>Just like windows, double click should launch the application. After checking some forums added shebang line #!/usr/bin/env python2.6 in my script but nothing happens.</p>
  <p>Please help me figure out (one of the below)</p>
  <ul>
  <li>Correct shebang line</li>
  <li>Create standalone executable for CentOS. Please note I don't have root access and hence I can't install pip or any other tools or libraries.</li>
  <li>Create standalone executable for CentOS using Python on Windows. I'm free to do anything on windows as I have successfully created virtual environment.</li>
  </ul>
  <p>Thanks in advance for the help and please let me know if any more information is required.</p>
  <hr />
  <p>I've been suggested to create desktop shortcut</p>
  <pre><code>[Desktop Entry]
  Version=1.0
  Type=Application
  Terminal=false          # true if it's a terminal application
  Exec=/home/user001/Desktop/sim_dialog.py  # or just the name, e.g. polo-gtk
  Name=sim_dialog
  Comment=
  Icon=
  </code></pre>
  <p>Ran this desktop shortcut with and without shebang line. Doesn't work in both the cases.</p>